Skip to content

Fix localized-attributes samples #3228

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 17, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions .code-samples.meilisearch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1350,11 +1350,9 @@ update_localized_attribute_settings_1: |-
curl \
-X PUT 'MEILISEARCH_URL/indexes/INDEX_NAME/settings/localized-attributes' \
-H 'Content-Type: application/json' \
--data-binary '{
"localizedAttributes": [
{"locales": ["jpn"], "attributePatterns": ["*_ja"]}
]
}'
--data-binary '[
{"locales": ["jpn"], "attributePatterns": ["*_ja"]}
]'
reset_localized_attribute_settings_1: |-
curl \
-X DELETE 'MEILISEARCH_URL/indexes/INDEX_NAME/settings/localized-attributes'
Expand Down
22 changes: 9 additions & 13 deletions reference/api/settings.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -856,11 +856,9 @@ Get the localized attributes settings of an index.
##### Response: `200 OK`

```json
{
"localizedAttributes": [
{"locales": ["jpn"], "attributePatterns": ["*_ja"]}
]
}
[
{"locales": ["jpn"], "attributePatterns": ["*_ja"]}
]
```

### Update localized attribute settings
Expand All @@ -878,14 +876,12 @@ Update the localized attributes settings of an index.
#### Body

```
{
"localizedAttributes": [
{
"locales": [<String>, …],
"attributePatterns": [<String>, …],
}
]
}
[
{
"locales": [<String>, …],
"attributePatterns": [<String>, …],
}
]
```

| Name | Type | Default value | Description |
Expand Down
Loading