Replace the filter attributes of a corpus
POST/v2/corpora/:corpus_key/replace_filter_attributes
Replace the filter attributes of a corpus. This does not happen immediately, but instead creates a job and will complete when that job completes. Until that job completes, using new filter attributes will not work.
You can monitor the status of the filter change using the returned job id.
Request
Path Parameters
Possible values: <= 50 characters
, Value must match regular expression [a-zA-Z0-9_\=\-]+$
Key of the corpus to have filters replaced.
- application/json
Body
- Array [
- ]
filter_attributes object[]required
The new filter attributes.
The JSON path of the filter attribute in a document or document part metadata.
Possible values: [document
, part
]
Indicates whether this a document or document part metadata filter.
Description of the filter. May be omitted.
Default value: true
Indicates whether an index should be created for the filter. Creating an index will improve query latency when using the filter.
Possible values: [integer
, real_number
, text
, boolean
, list[integer]
, list[real_number]
, list[text]
]
The value type of the filter.
Responses
- 200
- 403
- 404
Successfully created a job that will replace the filter attributes.
- application/json
- Schema
- Example (from schema)
Schema
Possible values: Value must match regular expression job_.+$
Job that was created in order to replace filter attributes.
{
"job_id": "string"
}
Permissions don't allow replacing filter attributes.
- application/json
- Schema
- Example (from schema)
Schema
The messages describing why the error occurred.
The ID of the request that can be used to help Vectara support debug what went wrong .
{
"messages": [
"Internal server error."
],
"request_id": "string"
}
Corpus not found.
- application/json
- Schema
- Example (from schema)
Schema
The ID cannot found.
ID of the request that can be used to help Vectara support debug what went wrong.
{
"id": "string",
"messages": [
"string"
],
"request_id": "string"
}