curl --request PATCH \
--url https://{projectHost}/collections/{collectionName} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"description": "Updated product catalog",
"tags": {
"environment": "staging"
},
"snapshotRetentionInDays": 14
}
'{
"collection": {
"projectName": "example-project-name",
"collectionName": "example-collection-name",
"indexConfigs": {
"title": {
"type": "text",
"analyzers": [
"english"
]
},
"category": {
"type": "keyword"
}
},
"description": "Product catalog",
"tags": {
"environment": "production"
},
"numPartitions": 1,
"numDocs": 1000,
"defaultBranchName": "main",
"snapshotRetentionInDays": 30,
"createdAt": 1788336000000,
"updatedAt": 1788336000000,
"dataUpdatedAt": 1788336060000
}
}{
"message": "Invalid request"
}{
"message": "Authentication failed"
}{
"message": "Resource not found"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "Too many requests"
}{
"message": "Internal server error"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}Configure a collection
Configure a collection.
curl --request PATCH \
--url https://{projectHost}/collections/{collectionName} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"description": "Updated product catalog",
"tags": {
"environment": "staging"
},
"snapshotRetentionInDays": 14
}
'{
"collection": {
"projectName": "example-project-name",
"collectionName": "example-collection-name",
"indexConfigs": {
"title": {
"type": "text",
"analyzers": [
"english"
]
},
"category": {
"type": "keyword"
}
},
"description": "Product catalog",
"tags": {
"environment": "production"
},
"numPartitions": 1,
"numDocs": 1000,
"defaultBranchName": "main",
"snapshotRetentionInDays": 30,
"createdAt": 1788336000000,
"updatedAt": 1788336000000,
"dataUpdatedAt": 1788336060000
}
}{
"message": "Invalid request"
}{
"message": "Authentication failed"
}{
"message": "Resource not found"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "Too many requests"
}{
"message": "Internal server error"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}Authorizations
Project API Key.
Path Parameters
Collection name.
Body
- Option 1
- Option 2
- Option 3
- Option 4
Provide at least one non-null supported field. Omitted or null fields are unchanged. Supplied tags replace the entire metadata map; {} clears tags. An empty description clears it. indexConfigs must preserve the complete existing schema. New fields may be added at any object depth while retaining existing fields and their settings.
Nonempty full schema. Collection updates preserve all existing fields and their settings while allowing new top-level fields and nested children at any depth. Removing or changing an existing field is rejected.
Show child attributes
Show child attributes
255Replaces the entire collection metadata map; {} clears it. Up to five entries.
Show child attributes
Show child attributes
Number of days to retain committed snapshots.
1 <= x <= 31Response
Updated collection
Show child attributes
Show child attributes
Was this page helpful?