Search Documents
POST/documents/search
Search Datasphere Documents
Request
- application/json
Body
required
Document tags.
Unique ID of a Document.
Search term.
Possible values: <= 78.3836717690617
Specifies how closely related the query is to the document. Low distance means high relevance and similarity. High distance means low relevance and similarity.
Specifies number of returned Chunks.
Default value: en
Language of the Document.
Default value: NOUN,VERB,ADJ,ADV
Part of Speech considered for expansion or analysis.
Default value: 10
Maximum number of synonyms to consider.
Responses
- 200
- 401
- 404
- 422
The request has succeeded.
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
A search result.
Unique ID of a Document.
[
{
"text": "Cristiano Ronaldo is the highest-paid football player in the world in 2024",
"document_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}
]
Access is unauthorized.
- application/json
- Schema
Schema
string
Possible values: [Unauthorized
]
The server cannot find the requested resource.
- application/json
- Schema
Schema
string
Possible values: [Not Found
]
Client error
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
errors
object[]
required
Error type.
Error code.
Error details.
Request parameter associated with this error.
Link to developer resource for this error.
{
"errors": [
{
"type": "validation_error",
"code": "invalid_parameter",
"message": "Invalid tags",
"attribute": "tags",
"url": "https://developer.signalwire.com/rest/overview/error-codes#{code}"
}
]
}