Skip to main content
POST
/
api
/
v1
/
tasks
Create task
curl --request POST \
  --url http://localhost:3890/api/v1/tasks \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "title": "<string>",
  "description": "<string>",
  "assignTo": "<string>",
  "draft": true,
  "expectations": [
    null
  ],
  "expectedOutcomes": [
    {
      "label": "<string>",
      "description": "<string>",
      "path": "<string>",
      "mimeType": "<string>",
      "required": true,
      "tags": [
        "<string>"
      ]
    }
  ],
  "dependsOn": [
    "<string>"
  ],
  "group": "<string>",
  "maxDuration": 1,
  "retryPolicy": {
    "escalateAfter": 1,
    "fallbackAgent": "<string>",
    "escalateModel": "<string>"
  },
  "sideEffects": true
}
'
{
  "ok": true,
  "data": null
}

Authorizations

Authorization
string
header
required

API key passed as a Bearer token. Configure via the apiKeys field in polpo.json or the POLPO_API_KEY environment variable.

Body

application/json
title
string
required
Minimum string length: 1
description
string
required
Minimum string length: 1
assignTo
string
required
Minimum string length: 1
draft
boolean
expectations
null[]
expectedOutcomes
object[]
dependsOn
string[]
group
string
maxDuration
number
Required range: x > 0
retryPolicy
object
notifications
object
sideEffects
boolean

Response

Task created

ok
boolean
required
data
unknown