I'm working with Docusaurus v3 and it suggested us...
# community-help
s
I'm working with Docusaurus v3 and it suggested using on-premise Typesense for search. I've followed the Typesense documentation and installed the client ( https://typesense.org/docs/guide/docsearch.html#run-the-scraper), but I need the configuration for the Typesense scrapper. The link in the documentation leads to a configuration that is four years old and isn't functioning. Could someone please provide me with the updated configuration for the scrapper? Thank you! scrapper :
Copy code
docker run -it --env-file=/path/to/your/.env -e "CONFIG=$(cat config.json | jq -r tostring)" typesense/docsearch-scraper:0.11.0
Config file :
Copy code
{
  "index_name": "my-index",
  "start_urls": [
    "<http://host.docker.internal>"
  ],
  "sitemap_urls": [
    "<http://host.docker.internal/sitemap.xml>"
  ],
  "sitemap_alternate_links": true,
  "selectors": {
    "lvl0": {
      "selector": "(//ul[contains(@class,'menu__list')]//a[contains(@class, 'menu__link menu__link--sublist menu__link--active')]/text() | //nav[contains(@class, 'navbar')]//a[contains(@class, 'navbar__link--active')]/text())[last()]",
      "type": "xpath",
      "global": true,
      "default_value": "Documentation"
    },
    "lvl1": "header h1",
    "lvl2": "article h2",
    "lvl3": "article h3",
    "lvl4": "article h4",
    "lvl5": "article h5, article td:first-child",
    "lvl6": "article h6",
    "text": "article p, article li, article td:last-child"
  },
  "strip_chars": " .,;:#",
  "custom_settings": {
    "separatorsToIndex": "_",
    "attributesForFaceting": [
      "language",
      "version",
      "type",
      "docusaurus_tag"
    ],
    "attributesToRetrieve": [
      "hierarchy",
      "content",
      "anchor",
      "url",
      "url_without_anchor",
      "type"
    ]
  },
  "conversation_id": [
    "833762294"
  ],
  "nb_hits": 46250
}
I am getting this error in typsense server :
Copy code
core_api.cpp:185] Create collection request body is malformed.