v1

latestOpenAPI 3.1.0MIT2026-07-17116965.4 KB
Index

Replace new document in a table

Replace an existing document. Input has same format as insert operation. Responds with an object in format:

{'table':'products','id':1,'created':false,'result':'updated','status':200}
post/replace

Request body

tablestring required

Name of the table to insert the document into

clusterstring

Name of the cluster to insert the document into

idinteger

Document ID. If not provided, an ID will be auto-generated

docobject required

Object containing document data

Example request

{
  "table": "test",
  "doc": {
    "title": "This is some title",
    "gid": 100
  }
}

Response

OK

tablestring

Name of the document table

idinteger

ID of the document affected by the request operation

createdboolean

Indicates whether the document was created as a result of the operation

resultstring

Result of the operation, typically 'created', 'updated', or 'deleted'

foundboolean

Indicates whether the document was found in the table

statusinteger

HTTP status code representing the result of the operation

Example response

{
  "table": "test",
  "id": 1,
  "result": "created",
  "created": true,
  "status": 201
}