Skip to content

Commit 6a0ab95

Browse files
committed
Fix localized-attributes samples
1 parent d94c1e9 commit 6a0ab95

File tree

2 files changed

+12
-18
lines changed

2 files changed

+12
-18
lines changed

.code-samples.meilisearch.yaml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1350,11 +1350,9 @@ update_localized_attribute_settings_1: |-
13501350
curl \
13511351
-X PUT 'MEILISEARCH_URL/indexes/INDEX_NAME/settings/localized-attributes' \
13521352
-H 'Content-Type: application/json' \
1353-
--data-binary '{
1354-
"localizedAttributes": [
1355-
{"locales": ["jpn"], "attributePatterns": ["*_ja"]}
1356-
]
1357-
}'
1353+
--data-binary '[
1354+
{"locales": ["jpn"], "attributePatterns": ["*_ja"]}
1355+
]'
13581356
reset_localized_attribute_settings_1: |-
13591357
curl \
13601358
-X DELETE 'MEILISEARCH_URL/indexes/INDEX_NAME/settings/localized-attributes'

reference/api/settings.mdx

Lines changed: 9 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -856,11 +856,9 @@ Get the localized attributes settings of an index.
856856
##### Response: `200 OK`
857857

858858
```json
859-
{
860-
"localizedAttributes": [
861-
{"locales": ["jpn"], "attributePatterns": ["*_ja"]}
862-
]
863-
}
859+
[
860+
{"locales": ["jpn"], "attributePatterns": ["*_ja"]}
861+
]
864862
```
865863

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

880878
```
881-
{
882-
"localizedAttributes": [
883-
{
884-
"locales": [<String>, …],
885-
"attributePatterns": [<String>, …],
886-
}
887-
]
888-
}
879+
[
880+
{
881+
"locales": [<String>, …],
882+
"attributePatterns": [<String>, …],
883+
}
884+
]
889885
```
890886

891887
| Name | Type | Default value | Description |

0 commit comments

Comments
 (0)