Skip to content

REST API

Delete documents by keys, query, or all

POST/v1alpha1/indexes/{name}/documents/actions/deletedocuments.delete

Deletes multiple documents matching a list of primary keys or a search query, or empties the index. The request body must name exactly one of keys, query, and all.

When deleting by keys, all keys are validated before any documents are removed. If any key is invalid, no documents are removed. When deleting by query, the operation removes matching committed searchable documents along with any uncommitted documents indexed since the last commit. A query requires at least one clause. To empty the index, set all to true.

Path parameters

namestringrequired
Name of the index to write to, optionally specifying a generation such as books@2.

Body

DeleteRequestRequired

Which documents to remove. The request must name exactly one of keys, query, and all (document:delete:target_required, document:delete:target_conflicting).

keysany[]
List of primary keys to delete, formatted according to the key field type. All keys are validated before any documents are removed; if any key is invalid, no documents are removed. An empty array deletes nothing, and requesting the deletion of an unindexed key produces a success response.
Query clauses matching documents to delete, using search query clause syntax. Removes matching committed searchable documents and any uncommitted documents indexed since the last commit. The array requires at least one clause (document:delete:query_empty). To empty the index, send all instead.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
9 types
FieldClausetype: "field"
Matches documents by the value of a single field. The targeted field must be indexed for the requested matcher usage; if it is not configured for that usage, the request returns search:usage_unsupported.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
fieldstringrequired
Target field, as named in the index definition.
Example
"category"
matchMatcherrequired
Criteria evaluated against the field's values.
Example
{
"value": "fiction"
}
9 types
EqualsMatchertype: "equals"
Matches field values equal to value.
Example
{
"value": "fiction"
}
valueanyrequired
The value that the field value must equal.
Example
"fiction"
InMatchertype: "in"
Matches field values equal to any value in values. An empty array matches no documents.
Example
{
"type": "in",
"values": [
"fiction",
"poetry"
]
}
valuesany[]required
The values that a field value may equal.
AnyMatchertype: "any"
Matches any document that contains a value for the field.
Example
{
"type": "any"
}
PrefixMatchertype: "prefix"
Matches string field values starting with value, evaluated against the entire field value.
Example
{
"type": "prefix",
"value": "EX-"
}
valuestringrequired
The prefix that a field value must start with.
Example
"EX-"
UnderMatchertype: "under"
Matches values at or below the specified path in a hierarchical tree. Requires a field configured with hierarchy. Path segments must match complete levels, so Men/Sho matches nothing where a prefix matcher matches.
Example
{
"type": "under",
"path": "Men/Shoes"
}
pathstringrequired
Path in the hierarchical tree to match at or below.
Example
"Men/Shoes"
RangeMatchertype: "range"
Matches values within bounds. Accepts inclusive (gte, lte) and exclusive (gt, lt) bounds; either side may be left open, and at least one bound is required (search:matcher:range_empty).
Example
{
"type": "range",
"gte": 10,
"lt": 20
}
gteany
Lower bound, the value itself included.
Example
10
gtany
Lower bound, the value itself excluded.
lteany
Upper bound, the value itself included.
ltany
Upper bound, exclusive.
Example
20
RangesMatchertype: "ranges"
Matches values falling within any of the specified range objects. An empty array matches no documents, matching the behavior of an empty in matcher.
Example
{
"type": "ranges",
"values": [
{
"gte": 10,
"lt": 20
},
{
"gte": 50
}
]
}
valuesMatcherRange[]required
The ranges to evaluate, each requiring at least one bound. A bucket returned by a range facet sets from as gte and to as lt.
Example
{
"gte": 10,
"lt": 20
}
4 properties
gteany
Lower bound, the value itself included.
Example
10
gtany
Lower bound, the value itself excluded.
lteany
Upper bound, the value itself included.
ltany
Upper bound, exclusive.
Example
20
TextMatchertype: "text"
Matches text within a single field using field-level analysis.
Example
{
"type": "text",
"text": "silent spring",
"match": "phrase"
}
textstringrequired
The query text to match.
matchMatch
Term matching mode. phrase requires terms to appear in exact order and adjacent; user parses search syntax such as quotes and negation.
Default
"all"
Values
"all", "any", "phrase", "user"
joinJoin
How the parts of user text combine: all requires every word and every quoted phrase, any accepts a document that holds one of them. Excluded terms (-word) always apply. Setting join with any other match returns search:clause:join_unsupported.
Default
"all"
Values
"all", "any"
prefixPrefix
Prefix matching behavior on the final query term. last_token matches the trailing word as a prefix; off requires an exact word match.
Default
"last_token"
Values
"last_token", "off"
Typo tolerance handling. auto follows the field's typoTolerance configuration; off disables typo tolerance for the matcher.
Default
"auto"
Values
"auto", "off"
slopinteger
Number of intervening words permitted between terms in a phrase, without changing their relative order. Only applies to phrase queries or quoted phrases in user mode.
Default
0
Format
int32
relaxRelax
Query relaxation strategy applied only when the query returns zero matches. See Finding something rather than nothing.
Default
"unmatched"
Values
"off", "unmatched", "words"
interpretInterpretMode
Whether parts of user text are read as filters on the fields of the index: auto reads a number typed next to the unit of a number field, or next to a comparative word such as under, as a filter on that field; off takes every word as text. Whatever was read is reported as interpreted beside the results. See Reading numbers and units.
Default
"auto"
Values
"auto", "off"
DistanceMatchertype: "distance"
Matches geopoint values within radius meters of the specified latitude and longitude coordinates.
Example
{
"type": "distance",
"lat": 59.3,
"lon": 18.1,
"radius": 5000
}
latnumberrequired
Latitude of the origin, in degrees.
Format
double
Range
-90 to 90
Example
59.3
lonnumberrequired
Longitude of the origin, in degrees.
Format
double
Range
-180 to 180
Example
18.1
radiusnumberrequired
Maximum distance from the origin in meters.
Format
double
Example
5000
TextClausetype: "text"
Matches query text across one or more fields. Phrase queries operate within a single field and match terms exactly as typed, regardless of field typoTolerance. Fields defined only for autocomplete do not support phrase matching. See text.
Example
{
"type": "text",
"text": "silent spr",
"fields": {
"name": 3,
"description": null
}
}
textstringrequired
The query text to match.
Example
"silent spr"
fieldsmap of number
Object mapping field names to score weights. A field mapped to null uses the weight from its field definition. If omitted, searches all searchable fields, skipping autocomplete-only fields.
1 property
<key>number
Format
float
matchMatch
Term matching mode. phrase requires terms to appear in exact order and adjacent; user parses search syntax such as quotes and negation.
Default
"all"
Values
"all", "any", "phrase", "user"
joinJoin
How the parts of user text combine: all requires every word and every quoted phrase, any accepts a document that holds one of them. Excluded terms (-word) always apply, and a filter read out of the text is one of the parts. Setting join with any other match returns search:clause:join_unsupported. See Reading what was typed.
Default
"all"
Values
"all", "any"
prefixPrefix
Prefix matching behavior on the final query term. last_token matches the trailing word as a prefix; off requires an exact word match.
Default
"last_token"
Values
"last_token", "off"
Typo tolerance handling. auto follows each field's typoTolerance configuration; off disables typo tolerance for the clause.
Default
"auto"
Values
"auto", "off"
slopinteger
Number of intervening words permitted between terms in a phrase, without changing their relative order. Setting slop above 0 with "match": "all" or "match": "any" returns search:clause:slop_unsupported.
Default
0
Format
int32
relaxRelax
Query relaxation strategy applied only when the query returns zero matches. See Finding something rather than nothing.
Default
"unmatched"
Values
"off", "unmatched", "words"
combineCombine
Scope for multi-field term matching. term evaluates each term across all targeted fields, so terms may appear in different fields; field requires a single field to satisfy match on its own. Ignored by phrase queries.
Default
"term"
Values
"term", "field"
interpretInterpret
Whether parts of user text are read as filters on the fields of the index, given as a mode or as the targets to read on. See Reading numbers and units.
Default
"auto"
2 types
Whether parts of user text are read as filters: auto reads a number typed next to a unit or a comparative word as a filter on the field declaring that unit, off takes every word as text.
Reads user text as filters on the named targets only. A number typed with a unit is read on every target declaring that unit; a number typed without one is read on every target holding a currency, when they all hold the same currency.
Example
{
"fields": [
{
"field": "prices.amount"
}
]
}
fieldsInterpretTarget[]required
The targets a reading may be a filter on. At least one is required.
Example
{
"field": "prices.amount",
"when": [
{
"field": "prices.list",
"match": {
"value": "customer"
}
}
],
"fallback": [
{
"field": "prices.amount",
"when": [
{
"field": "prices.list",
"match": {
"value": "store"
}
}
]
}
]
}
3 properties
fieldstringrequired
The field, as named in the index definition.
Example
"prices.amount"
Clauses that must hold where the number is read: in the same value as the field for a field inside a nested list, and for the document otherwise. Takes what a nested clause takes: field, text, and, or, not and boost. A clause naming a field outside the list returns search:nested:field_not_inside.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
Targets read instead, in order, where the document holds no value on this one - a product with no price on the customer's list is read on the store's list. Every target of the chain must declare the same unit; one in another unit returns search:interpret:fallback_unit_mismatch.
Example
{
"field": "prices.amount",
"when": [
{
"field": "prices.list",
"match": {
"value": "customer"
}
}
],
"fallback": [
{
"field": "prices.amount",
"when": [
{
"field": "prices.list",
"match": {
"value": "store"
}
}
]
}
]
}
KnnClausetype: "knn"
Matches the k nearest documents by vector distance in a specified field, scored by proximity. Cannot be combined with hits (search:hits:knn_unsupported).
Example
{
"type": "knn",
"field": "embedding",
"vector": [
0.1,
0.2
],
"k": 10,
"filter": [
{
"field": "published",
"match": {
"value": true
}
}
]
}
fieldstringrequired
The vector field to search.
Example
"embedding"
vectornumber[]required
The query vector. Its length must match the dimensions declared in the field definition.
Format
float
kintegerrequired
Number of nearest documents to return, at most EXOFIND_SEARCH_MAX_KNN_K.
Format
int32
filterClause[]
Clauses that documents must satisfy before nearest-neighbor evaluation.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
NestedClausetype: "nested"
Matches documents where a single element of a nested object field satisfies all child clauses. A nested clause on a flattened object field returns search:nested:path_not_nested; on a non-object field it returns an error. See nested.
Example
{
"type": "nested",
"path": "variants",
"clauses": [
{
"field": "variants.color",
"match": {
"value": "red"
}
},
{
"field": "variants.price",
"match": {
"type": "range",
"lt": 20
}
}
]
}
pathstringrequired
Name of the nested object field.
Example
"variants"
clausesClause[]
Clauses evaluated within a single nested object value, naming fields by their dotted path. An empty array matches any document where the object field is present. May contain field, text, knn, and, or, not and boost; a clause that only means something for whole documents, such as another nested or a fuse, returns search:nested:clause_unsupported.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
scoreScore
Scoring mode for aggregating matching nested values. Only applies when scoring clauses exist within the nested clause.
Default
"max"
Values
"max", "min", "avg", "total"
AndClausetype: "and"
Matches documents where all child clauses match.
Example
{
"type": "and",
"clauses": [
{
"field": "category",
"match": {
"value": "fiction"
}
},
{
"field": "published",
"match": {
"value": true
}
}
]
}
clausesClause[]required
Child clauses, all of which must match.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
OrClausetype: "or"
Matches documents where at least one child clause matches.
Example
{
"type": "or",
"clauses": [
{
"field": "category",
"match": {
"value": "fiction"
}
},
{
"field": "category",
"match": {
"value": "poetry"
}
}
]
}
clausesClause[]required
Child clauses, at least one of which must match.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
NotClausetype: "not"
Matches documents where no child clause matches.
Example
{
"type": "not",
"clauses": [
{
"field": "discontinued",
"match": {
"value": true
}
}
]
}
clausesClause[]required
Child clauses, none of which may match.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
BoostClausetype: "boost"
Increases the relevance score of documents that satisfy child clauses without excluding non-matching documents.
Example
{
"type": "boost",
"weight": 2,
"clauses": [
{
"field": "featured",
"match": {
"value": true
}
}
]
}
weightnumberrequired
Multiplier applied to matching documents. Values greater than 1 increase score; values between 0 and 1 decrease score. Leaving it out, or setting it below 0 or to a non-finite number, returns search:clause:weight_out_of_range.
Format
float
Example
2
clausesClause[]required
Clauses required to apply the boost weight.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
FuseClausetype: "fuse"
Matches documents across several rankings, scored and merged by rank. Documents are scored by the sum of weight / (rankConstant + rank) across the rankings that reached them. Because the clause reads only result positions, scores from different scales (such as BM25 text relevance and vector similarity) combine without normalization. Matches at most depth results per ranking. See fuse.
Example
{
"type": "fuse",
"depth": 200,
"rankConstant": 60,
"rankings": [
{
"clauses": [
{
"type": "text",
"text": "waterproof jacket",
"fields": {
"name": null
}
}
]
},
{
"clauses": [
{
"type": "knn",
"field": "embedding",
"vector": [
0.1,
0.2
],
"k": 200
}
],
"weight": 0.5
}
],
"filter": [
{
"field": "inStock",
"match": {
"value": true
}
}
]
}
rankingsFuseRanking[]required
Rankings to run and merge. Specifying fewer than two rankings returns search:clause:rankings_too_few.
Example
{
"clauses": [
{
"type": "text",
"text": "waterproof jacket",
"fields": {
"name": null
}
}
],
"weight": 0.5
}
2 properties
clausesClause[]required
Clauses the ranking searches for, combined with an implicit AND. At least one clause is required.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
weightnumber
Multiplier that scales the ranking's contribution relative to other rankings. It cannot reorder results within the ranking.
Default
1
Format
float
depthinteger
Number of results read from each ranking. Pagination cannot exceed the merged list, similar to k in a knn clause. Must be at least 1, and at most EXOFIND_SEARCH_MAX_FUSE_DEPTH.
Default
100
Format
int32
rankConstantnumber
Constant added to each rank before it is inverted. Lower values increase the weight of the highest-ranked results in each ranking; higher values flatten the difference across ranks, giving more weight to documents found by multiple rankings. Must be above 0.
Default
60
Format
float
filterClause[]
Clauses that narrow every ranking before it is cut to depth. A knn clause inside a ranking applies filter entries as a pre-filter, ensuring the vector ranking returns k results. Clauses placed beside the fuse clause filter the merged list after each ranking is cut to depth.
Example
{
"field": "category",
"match": {
"value": "fiction"
}
}
allboolean
Set to true to remove every document and empty the index. Cannot be combined with keys or query.
localestring
BCP 47 locale tag used to match locale-specific fields, defaulting to each field's default locale. Valid only when specifying query (document:delete:locale_without_query).
Example
"sv"

Responses

200
The documents were removed.
DeleteResponse

The count of deleted documents.

deletedinteger
How many documents were removed. For requests using keys, this is the number of keys provided in the request, since requesting the deletion of an unindexed key produces a success response. For requests using query, this is the number of matching committed searchable documents.
Format
int32
Example
3
freshnessstring
A freshness token for the state the change lands in. Pass it as freshness.atLeast on a search, or in the X-Exofind-Freshness header of a read, and that request is answered only once the node holds the change. Opaque; pass it back unchanged. See Freshness.
Example
"AQoIcHJvZHVjdHMSATIYBw"
400
The body does not name what to delete, or it names a key or a query the index cannot use.
ErrorResponse

The body of every failed request. Error codes use colon-separated namespaces such as index:field:name_invalid, are stable across API versions, and are never renamed or reused, so clients match on code rather than on message. See Errors.

codestring
Identifies the failure type. For validation failures, this is validation and the individual problems are listed in errors. For all other failures, this matches the code of the single entry in errors.
Example
"validation"
messagestring
Human-readable message for log output. Match on code rather than on message. When a validation failure contains one problem, this is that problem's message. When it contains several, it reads Request contains N errors.
Example
"Request contains 2 errors"
All problems found in the request. A validation failure reports every field with a problem, so a caller can fix them in one pass rather than one request at a time.
Example
{
"code": "index:field:primary_key:multiple_unsupported",
"message": "Field `id` is marked as a primary key and multiple, primary keys can not have multiple values",
"path": "id"
}
4 properties
codestring
The error code identifying this specific problem.
Example
"index:field:primary_key:multiple_unsupported"
messagestring
Human-readable description of this problem.
Example
"Field `id` is marked as a primary key and multiple, primary keys can not have multiple values"
pathstring
Location of the offending value in the request, such as fields.title or documents[1].nonexistent. Names join with ., one element of a list reads [n] counted from zero, and a key of a free-form map such as metadata goes in brackets and double quotes when it holds a dot or a bracket, as metadata["build.sha"]. A field inside an object field carries its own dotted path, so a path here reaches a field the same way a query does. Omitted when the problem applies to the request as a whole. See API conventions.
Example
"id"
argumentsmap of string
The values the message was rendered with, so a client can render a message of its own from the code.
1 property
<key>string
Error codes
document:delete:target_required
The body holds none of `keys`, `query`, and `all`.
document:delete:target_conflicting
The body holds more than one of `keys`, `query`, and `all`. Send one of them.
document:delete:query_empty
The body holds a `query` without clauses. Send `all` to empty the index.
document:delete:locale_without_query
The body states a `locale` without a `query`.
search:value_invalid
A key cannot be read as the type of the primary key field.
document:key_required
An entry of `keys` carries no key.
index:no_primary_key
The index definition declares no primary key, so a document cannot be named by `keys`.
request:value_required
A part of `query` that needs a value carries none. The `path` names it.
search:clause:field_required
A `field` clause of `query` does not name the field to match.
search:clause:match_required
A `field` clause of `query` does not say what to look for in the field.
search:clause:text_required
A `text` clause of `query` carries no text to search for.
search:clause:path_required
A `nested` clause of `query` does not name the object field to match inside.
search:clause:vector_required
A `knn` clause of `query` carries no vector to find the neighbours of.
search:clause:k_out_of_range
The `k` of a `knn` clause is missing or not above zero.
search:clause:weight_out_of_range
The `weight` of a `boost` clause is missing, below zero or not a finite number.
search:clause:slop_out_of_range
The `slop` of a `text` clause is below zero.
search:clause:slop_unsupported
A `text` clause sets `slop` without matching as a phrase.
search:clause:join_unsupported
A `text` clause sets `join` without matching what somebody typed.
search:clause:rankings_too_few
A `fuse` clause holds fewer than two rankings to fuse.
search:clause:ranking_empty
A ranking of a `fuse` clause holds nothing to rank by.
search:clause:rank_constant_out_of_range
The `rankConstant` of a `fuse` clause is not a number above zero.
search:clause:depth_out_of_range
The `depth` of a `fuse` clause is below one result.
search:clause:interpret_fields_required
The `interpret` of a `text` clause names no target field.
search:clause:interpret_when_unsupported
The `when` of an `interpret` target holds a `nested`, `knn` or `fuse` clause.
search:matcher:value_required
A matcher carries no value to look for.
search:matcher:range_empty
A range matcher carries no bound.
search:matcher:range_conflicting
A range matcher combines `gte` with `gt`, or `lte` with `lt`.
search:matcher:origin_required
A distance matcher carries no `lat` and `lon` to measure from.
search:matcher:radius_required
A distance matcher does not say how far from the origin values may be.
search:field_unknown
A clause, sort or facet names a field the index does not have.
search:usage_unsupported
A clause, sort or facet uses a field in a way the definition does not enable for it.
search:matcher:type_unsupported
A matcher is used on a field whose type cannot answer it.
search:locale_unsupported
The `locale` names one the engine has no rules for.
search:no_searchable_fields
A text clause names no fields and the index has none defined for matching.
search:nested:path_not_nested
A `nested` clause names a path whose values are flattened.
search:nested:field_not_inside
A clause inside a `nested` clause names a field outside its path.
search:nested:field_outside
A clause outside a `nested` clause names a field inside a nested list.
search:nested:clause_unsupported
A `nested` clause holds a clause that cannot run against a single value, such as `fuse`.
search:interpret:unit_required
An `interpret` target names a field that is not a number field or declares no `unit`.
search:interpret:fallback_unit_mismatch
A `fallback` target declares another unit than the target it stands in for.
search:clause:k_required
A `knn` clause carries no `k`.
index:generation:unsettled
The generation the index serves from kept changing while the write was made. Send the request again.
401
The request carries no credential this node accepts. Absent, malformed, unknown and lapsed keys are all answered alike, so a refusal cannot be used to find out which keys exist. The response carries WWW-Authenticate: Bearer.
ErrorResponse

The body of every failed request. Error codes use colon-separated namespaces such as index:field:name_invalid, are stable across API versions, and are never renamed or reused, so clients match on code rather than on message. See Errors.

codestring
Identifies the failure type. For validation failures, this is validation and the individual problems are listed in errors. For all other failures, this matches the code of the single entry in errors.
Example
"validation"
messagestring
Human-readable message for log output. Match on code rather than on message. When a validation failure contains one problem, this is that problem's message. When it contains several, it reads Request contains N errors.
Example
"Request contains 2 errors"
All problems found in the request. A validation failure reports every field with a problem, so a caller can fix them in one pass rather than one request at a time.
Example
{
"code": "index:field:primary_key:multiple_unsupported",
"message": "Field `id` is marked as a primary key and multiple, primary keys can not have multiple values",
"path": "id"
}
4 properties
codestring
The error code identifying this specific problem.
Example
"index:field:primary_key:multiple_unsupported"
messagestring
Human-readable description of this problem.
Example
"Field `id` is marked as a primary key and multiple, primary keys can not have multiple values"
pathstring
Location of the offending value in the request, such as fields.title or documents[1].nonexistent. Names join with ., one element of a list reads [n] counted from zero, and a key of a free-form map such as metadata goes in brackets and double quotes when it holds a dot or a bracket, as metadata["build.sha"]. A field inside an object field carries its own dotted path, so a path here reaches a field the same way a query does. Omitted when the problem applies to the request as a whole. See API conventions.
Example
"id"
argumentsmap of string
The values the message was rendered with, so a client can render a message of its own from the code.
1 property
<key>string
Error codes
auth:unauthenticated
The request carries no credential this node accepts.
403
The API key does not have the documents.delete permission.
ErrorResponse

The body of every failed request. Error codes use colon-separated namespaces such as index:field:name_invalid, are stable across API versions, and are never renamed or reused, so clients match on code rather than on message. See Errors.

codestring
Identifies the failure type. For validation failures, this is validation and the individual problems are listed in errors. For all other failures, this matches the code of the single entry in errors.
Example
"validation"
messagestring
Human-readable message for log output. Match on code rather than on message. When a validation failure contains one problem, this is that problem's message. When it contains several, it reads Request contains N errors.
Example
"Request contains 2 errors"
All problems found in the request. A validation failure reports every field with a problem, so a caller can fix them in one pass rather than one request at a time.
Example
{
"code": "index:field:primary_key:multiple_unsupported",
"message": "Field `id` is marked as a primary key and multiple, primary keys can not have multiple values",
"path": "id"
}
4 properties
codestring
The error code identifying this specific problem.
Example
"index:field:primary_key:multiple_unsupported"
messagestring
Human-readable description of this problem.
Example
"Field `id` is marked as a primary key and multiple, primary keys can not have multiple values"
pathstring
Location of the offending value in the request, such as fields.title or documents[1].nonexistent. Names join with ., one element of a list reads [n] counted from zero, and a key of a free-form map such as metadata goes in brackets and double quotes when it holds a dot or a bracket, as metadata["build.sha"]. A field inside an object field carries its own dotted path, so a path here reaches a field the same way a query does. Omitted when the problem applies to the request as a whole. See API conventions.
Example
"id"
argumentsmap of string
The values the message was rendered with, so a client can render a message of its own from the code.
1 property
<key>string
Error codes
auth:forbidden
The key is accepted but does not hold the `documents.delete` permission.
404
No index with the specified name exists on this node, or the API key lacks permissions on the index.
ErrorResponse

The body of every failed request. Error codes use colon-separated namespaces such as index:field:name_invalid, are stable across API versions, and are never renamed or reused, so clients match on code rather than on message. See Errors.

codestring
Identifies the failure type. For validation failures, this is validation and the individual problems are listed in errors. For all other failures, this matches the code of the single entry in errors.
Example
"validation"
messagestring
Human-readable message for log output. Match on code rather than on message. When a validation failure contains one problem, this is that problem's message. When it contains several, it reads Request contains N errors.
Example
"Request contains 2 errors"
All problems found in the request. A validation failure reports every field with a problem, so a caller can fix them in one pass rather than one request at a time.
Example
{
"code": "index:field:primary_key:multiple_unsupported",
"message": "Field `id` is marked as a primary key and multiple, primary keys can not have multiple values",
"path": "id"
}
4 properties
codestring
The error code identifying this specific problem.
Example
"index:field:primary_key:multiple_unsupported"
messagestring
Human-readable description of this problem.
Example
"Field `id` is marked as a primary key and multiple, primary keys can not have multiple values"
pathstring
Location of the offending value in the request, such as fields.title or documents[1].nonexistent. Names join with ., one element of a list reads [n] counted from zero, and a key of a free-form map such as metadata goes in brackets and double quotes when it holds a dot or a bracket, as metadata["build.sha"]. A field inside an object field carries its own dotted path, so a path here reaches a field the same way a query does. Omitted when the problem applies to the request as a whole. See API conventions.
Example
"id"
argumentsmap of string
The values the message was rendered with, so a client can render a message of its own from the code.
1 property
<key>string
Error codes
index:not_found
The node holds no such index, or the key has no permission on it.
409
No node is available to write the index, the index is currently synchronizing, or the target generation is locked by an active reindex job.
ErrorResponse

The body of every failed request. Error codes use colon-separated namespaces such as index:field:name_invalid, are stable across API versions, and are never renamed or reused, so clients match on code rather than on message. See Errors.

codestring
Identifies the failure type. For validation failures, this is validation and the individual problems are listed in errors. For all other failures, this matches the code of the single entry in errors.
Example
"validation"
messagestring
Human-readable message for log output. Match on code rather than on message. When a validation failure contains one problem, this is that problem's message. When it contains several, it reads Request contains N errors.
Example
"Request contains 2 errors"
All problems found in the request. A validation failure reports every field with a problem, so a caller can fix them in one pass rather than one request at a time.
Example
{
"code": "index:field:primary_key:multiple_unsupported",
"message": "Field `id` is marked as a primary key and multiple, primary keys can not have multiple values",
"path": "id"
}
4 properties
codestring
The error code identifying this specific problem.
Example
"index:field:primary_key:multiple_unsupported"
messagestring
Human-readable description of this problem.
Example
"Field `id` is marked as a primary key and multiple, primary keys can not have multiple values"
pathstring
Location of the offending value in the request, such as fields.title or documents[1].nonexistent. Names join with ., one element of a list reads [n] counted from zero, and a key of a free-form map such as metadata goes in brackets and double quotes when it holds a dot or a bracket, as metadata["build.sha"]. A field inside an object field carries its own dotted path, so a path here reaches a field the same way a query does. Omitted when the problem applies to the request as a whole. See API conventions.
Example
"id"
argumentsmap of string
The values the message was rendered with, so a client can render a message of its own from the code.
1 property
<key>string
Error codes
indexer:unavailable
No node is available to write the index. Send the request again once one is.
index:out_of_date
The index is synchronizing. Send the request again.
index:readonly
The node lost the writer role while the request ran. Send the request again to reach the new writer.
reindex:target_busy
An active reindex job holds the target generation. Wait for the job, or write to another generation.
502
The request was forwarded to the index writer and the writer did not respond.
ErrorResponse

The body of every failed request. Error codes use colon-separated namespaces such as index:field:name_invalid, are stable across API versions, and are never renamed or reused, so clients match on code rather than on message. See Errors.

codestring
Identifies the failure type. For validation failures, this is validation and the individual problems are listed in errors. For all other failures, this matches the code of the single entry in errors.
Example
"validation"
messagestring
Human-readable message for log output. Match on code rather than on message. When a validation failure contains one problem, this is that problem's message. When it contains several, it reads Request contains N errors.
Example
"Request contains 2 errors"
All problems found in the request. A validation failure reports every field with a problem, so a caller can fix them in one pass rather than one request at a time.
Example
{
"code": "index:field:primary_key:multiple_unsupported",
"message": "Field `id` is marked as a primary key and multiple, primary keys can not have multiple values",
"path": "id"
}
4 properties
codestring
The error code identifying this specific problem.
Example
"index:field:primary_key:multiple_unsupported"
messagestring
Human-readable description of this problem.
Example
"Field `id` is marked as a primary key and multiple, primary keys can not have multiple values"
pathstring
Location of the offending value in the request, such as fields.title or documents[1].nonexistent. Names join with ., one element of a list reads [n] counted from zero, and a key of a free-form map such as metadata goes in brackets and double quotes when it holds a dot or a bracket, as metadata["build.sha"]. A field inside an object field carries its own dotted path, so a path here reaches a field the same way a query does. Omitted when the problem applies to the request as a whole. See API conventions.
Example
"id"
argumentsmap of string
The values the message was rendered with, so a client can render a message of its own from the code.
1 property
<key>string
Error codes
indexer:unreachable
The request was forwarded to the index writer and the writer did not answer. Send it again.
503
The request raced the index being closed to free local resources. Repeating the request reopens the index.
ErrorResponse

The body of every failed request. Error codes use colon-separated namespaces such as index:field:name_invalid, are stable across API versions, and are never renamed or reused, so clients match on code rather than on message. See Errors.

codestring
Identifies the failure type. For validation failures, this is validation and the individual problems are listed in errors. For all other failures, this matches the code of the single entry in errors.
Example
"validation"
messagestring
Human-readable message for log output. Match on code rather than on message. When a validation failure contains one problem, this is that problem's message. When it contains several, it reads Request contains N errors.
Example
"Request contains 2 errors"
All problems found in the request. A validation failure reports every field with a problem, so a caller can fix them in one pass rather than one request at a time.
Example
{
"code": "index:field:primary_key:multiple_unsupported",
"message": "Field `id` is marked as a primary key and multiple, primary keys can not have multiple values",
"path": "id"
}
4 properties
codestring
The error code identifying this specific problem.
Example
"index:field:primary_key:multiple_unsupported"
messagestring
Human-readable description of this problem.
Example
"Field `id` is marked as a primary key and multiple, primary keys can not have multiple values"
pathstring
Location of the offending value in the request, such as fields.title or documents[1].nonexistent. Names join with ., one element of a list reads [n] counted from zero, and a key of a free-form map such as metadata goes in brackets and double quotes when it holds a dot or a bracket, as metadata["build.sha"]. A field inside an object field carries its own dotted path, so a path here reaches a field the same way a query does. Omitted when the problem applies to the request as a whole. See API conventions.
Example
"id"
argumentsmap of string
The values the message was rendered with, so a client can render a message of its own from the code.
1 property
<key>string
Error codes
index:closed
The request raced the index being closed to free local resources. Sending it again reopens the index.

Authorization

Permission
documents.delete
Checked on
The index the path names
Roles
writer, admin

An API key sent as a bearer token, such as Authorization: Bearer exok_4ff6b760264c1918_ePQcdT1O9HSATZoXfDbT8hhHGsP9VpZH. A key carries grants that pair permissions with index patterns; the permission each endpoint needs is named beside it. Nodes running with EXOFIND_AUTH_MODE=none accept requests without a credential, and a node with EXOFIND_AUTH_ANONYMOUS_KEY set serves requests that carry none with the permissions of that key.

Exofind is built by Level Four AB and is available under the Apache License 2.0.