meilisearch/meilisearch-rust

Update .code-samples.meilisearch.yaml

bidoubiwa opened this issue · 0 comments

Related to meilisearch/integration-guides#155

Following the documentation issue (meilisearch/documentation#1290) and PR (meilisearch/documentation#1214) an additional code-sample must be added in the .code-samples.meilisearch.yaml file at the root of the repository.

Information:

Using the following information the code-sample must be created in the repository language.

  • code-sample id: settings_guide_sortable_1
  • index: books
  • route: /settings
  • method: POST
  • content-type: application/json
  • data body:
    {
      "sortableAttributes": [
        "price",
        "author"
      ]
    }

Code Example

In cURL the samples is defined the following way:

curl \
  -X POST 'http://localhost:7700/indexes/books/settings' \
  -H 'Content-Type: application/json' \
  --data-binary '{
    "sortableAttributes": [
      "price",
      "author"
    ]
  }'