Skip to main content
POST
/
document
/
search
Search Documents
curl --request POST \
  --url https://{api-address}.org.machina.gg/document/search \
  --header 'Content-Type: application/json' \
  --header 'x-api-token: <api-key>' \
  --data '{
  "filters": {},
  "sorters": [
    "name",
    1
  ],
  "page": 1,
  "page_size": 10
}'
{
  "data": [
    {
      "_id": "67e1fc8c2a5ade8c69c03fe7",
      "created": "Tue, 25 Mar 2025 00:45:00 GMT",
      "date": "Tue, 25 Mar 2025 00:45:00 GMT",
      "embed-vector": false,
      "metadata": {
        "agent_id": "123"
      },
      "name": "New test document",
      "status": null,
      "updated": "Tue, 25 Mar 2025 00:45:00 GMT",
      "value": {
        "chat": [
          "What is Lorem Ipsum?",
          "Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.",
          " It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum."
        ]
      }
    }
  ],
  "status": true,
  "total_documents": 4
}

Authorizations

x-api-token
string
header
required

Body

application/json
filters
object
Example:
sorters
string[]
Example:
page
integer
default:1
Example:
page_size
integer
default:10
Example:

Response

data
object[]
total_documents
integer
Example:
status
boolean
Example: