Search annotations

This API is responsible for searching annotations.

[POST]/api/v1/annotations/search

Response: A list of the requested annotations.

Header

Header used on this API are those taken from header standards of TS Digital.

Content-type is accepted in application/json

Query Parameters

No query parameters are needed to make this request.

Body

{
  "limit": "integer",
  "from": "integer",
  "ownership": {
    "type": "WS",
    "identifier": "string"
  },
  "sort": {
    "name": "CREATED",
    "order": "ASC"
  },
  "type": "string",
  "reference_ids": [
    "string"
  ],
  "show_deleted": true,
  "search_words": "string"
}

Response

On successful response

If successful, the API responds with HTTP code 200(OK) with the following body:

{
  "count": "integer",
  "data": [
    {
      "id": "string",
      "type": "string",
      "text": "string",
      "classification": "string",
      "referencingDate": "string",
      "referencePeriod": "string",
      "referenceType": "string",
      "referenceIds": [
        "string"
      ],
      "deleted": true,
      "ownership": {
        "type": "WS",
        "identifier": "string"
      },
      "itemClassifier": "string",
      "insertedBy": "string",
      "insertedAt": "2022-10-31T15:02:44.115Z",
      "modifiedAt": "2022-10-31T15:02:44.115Z"
    }
  ]
}

The elements inside the data list contain the following fields:

On error response

In the event of an error, the API responds with a body JSON with the following format:

{
  "code": "string",
  "timestamp": "2022-10-28T13:01:00.754Z",
  "message": "string",
  "subErrors": [
    {}
  ]
}

Possible errors are:


Revision #4
Created 2022-10-31 14:58:20 UTC by Endri Qejvanaj
Updated 2023-01-10 13:34:50 UTC by Endri Qejvanaj