Skip to main content
POST
/
api
/
v1
/
watchers
Create watcher
curl --request POST \
  --url http://localhost:3000/api/v1/watchers \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "taskId": "<string>",
  "targetStatus": "pending",
  "action": {
    "type": "<string>"
  }
}
'
{
  "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
taskId
string
required
Minimum string length: 1
targetStatus
enum<string>
required
Available options:
pending,
assigned,
in_progress,
review,
done,
failed,
awaiting_approval
action
object
required

Response

Watcher created

ok
boolean
required
data
unknown