Update a Document
PATCH/documents/:id
Updates a Datasphere Document by ID
Request
Path Parameters
Unique ID of a Document.
- application/json
Body
required
Document tags.
Responses
- 200
- 401
- 404
- 422
The request has succeeded.
- application/json
- Schema
- Example (from schema)
Schema
Unique ID of a Document.
Name of the Document.
Possible values: [submitted
, in_progress
, completed
, failed
]
The current Status of the Document.
Document tags.
Possible values: [sentence
, paragraph
, page
, sliding
]
Strategy to use when chunking the document.
Max Sentences per Chunk (only used for chunking type 'sentence')
Split on Newlines (only used for chunking type 'sentence')
Overlap Size (only used for chunking type 'sliding')
Chunk Size (only used for chunking type 'sliding')
Number of Chunks in the Document.
Document Creation Date.
Document Update Date.
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"filename": "player_list.pdf",
"status": "submitted",
"tags": [
"sports",
"football",
"game"
],
"chunking_strategy": "sentence",
"max_sentences_per_chunk": "80",
"split_newlines": true,
"overlap_size": "10",
"chunk_size": "50",
"number_of_chunks": 2345,
"created_at": "2024-05-06T12:20-12Z",
"updated_at": "2024-05-06T12:20-12Z"
}
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}"
}
]
}