POST
/
api
/
v1
/
agents
{
  "id": "<string>",
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z",
  "name": "<string>",
  "status": "ACTIVE",
  "autoConfirm": true,
  "description": "",
  "emailTrigger": {
    "active": true,
    "allowedSenders": [
      "<string>"
    ],
    "email": "<string>"
  },
  "dataSchema": {
    "title": "DataToExtract",
    "description": "",
    "type": "object",
    "properties": {},
    "required": [
      "<string>"
    ]
  },
  "dataDestinations": [
    {
      "type": "ASKUI_WORKFLOW",
      "host": "SELF",
      "runnerTags": [
        "<string>"
      ],
      "workflows": [
        "<string>"
      ]
    }
  ],
  "workspaceId": "<string>",
  "folderPath": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
name
string
required

The name of the agent. The name must only contain the following characters: a-z, A-Z, 0-9, -, _, and space. The name must not be empty. The name must start and end with a letter or a number. The name must not be longer than 64 characters.

workspaceId
string<uuid4>
required
templateId
string
required

The ID of the template to copy files from.

description
string
default:""
Maximum length: 1024
dataSchema
object | null

The JSON schema of the data that the agent is going to extract from documents uploaded. The schema must comply with Draft 2020-12. The schema (root) must be an object with at least one property. The size of the schema must not exceed 15 MB.

autoConfirm
boolean
default:false

If true, the agent will automatically confirm the data extracted, i.e., no review is necessary.

dataDestinations
Datadestinations · array
parentId
string<uuid4> | null

The ID of an agent that this agent is created from, i.e., of the previous version of this agent. Parent is going to be archived as part of the creation of the new (active) agent.

emailTrigger
object

Response

Successful Response

name
string
required

The name of the agent. The name must only contain the following characters: a-z, A-Z, 0-9, -, _, and space. The name must not be empty. The name must start and end with a letter or a number. The name must not be longer than 64 characters.

status
enum<string>
required
Available options:
ACTIVE,
ARCHIVED
autoConfirm
boolean
required

If true, the agent will automatically confirm the data extracted, i.e., no review is necessary.

emailTrigger
object
required
dataDestinations
Datadestinations · array
required
workspaceId
string<uuid4>
required
id
string<uuid4>
createdAt
string<date-time>
updatedAt
string<date-time>
description
string
default:""
Maximum length: 1024
dataSchema
object | null
The data schema describes the data to extract in form of a [JSON schema draft 2020-12](https://json-schema.org/draft/2020-12/release-notes). Use the ["description" keyword](https://json-schema.org/understanding-json-schema/reference/annotations) of each property to provide additional information about the field, e.g., the prompt for extraction from sources.
folderPath
string | null