API

Automations

Recurring missions: a stored prompt plus a cadence.

GET
/automations

Response Body

application/json

application/json

curl -X GET "https://example.com/automations"
{  "data": [    {      "id": "string",      "orgId": "string",      "projectId": "string",      "name": "string",      "prompt": "string",      "templateKey": "string",      "triggers": [        {          "kind": "schedule",          "schedule": {            "interval": "daily",            "time": "string",            "timezone": "string",            "weekday": "monday",            "dayOfMonth": 1          }        }      ],      "labels": [        "string"      ],      "skipIfPreviousOpen": true,      "enabled": true,      "nextRunAt": 0,      "lastRunAt": 0,      "createdAt": 0,      "updatedAt": 0    }  ],  "nextCursor": "string"}
POST
/automations

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/automations" \  -H "Content-Type: application/json" \  -d '{    "projectId": "string",    "name": "string",    "prompt": "string",    "triggers": [      {        "kind": "schedule",        "schedule": {          "interval": "daily",          "time": "string",          "timezone": "string"        }      }    ]  }'
{  "id": "string",  "orgId": "string",  "projectId": "string",  "name": "string",  "prompt": "string",  "templateKey": "string",  "triggers": [    {      "kind": "schedule",      "schedule": {        "interval": "daily",        "time": "string",        "timezone": "string",        "weekday": "monday",        "dayOfMonth": 1      }    }  ],  "labels": [    "string"  ],  "skipIfPreviousOpen": true,  "enabled": true,  "nextRunAt": 0,  "lastRunAt": 0,  "createdAt": 0,  "updatedAt": 0}
GET
/automations/templates

Response Body

application/json

curl -X GET "https://example.com/automations/templates"
{  "data": [    {      "key": "string",      "name": "string",      "blurb": "string",      "prompt": "string",      "suggestedSchedule": {        "interval": "daily",        "time": "string",        "timezone": "string",        "weekday": "monday",        "dayOfMonth": 1      }    }  ]}
GET
/automations/{automationId}

Path Parameters

automationId*string
Length1 <= length

Response Body

application/json

application/json

curl -X GET "https://example.com/automations/string"
{  "id": "string",  "orgId": "string",  "projectId": "string",  "name": "string",  "prompt": "string",  "templateKey": "string",  "triggers": [    {      "kind": "schedule",      "schedule": {        "interval": "daily",        "time": "string",        "timezone": "string",        "weekday": "monday",        "dayOfMonth": 1      }    }  ],  "labels": [    "string"  ],  "skipIfPreviousOpen": true,  "enabled": true,  "nextRunAt": 0,  "lastRunAt": 0,  "createdAt": 0,  "updatedAt": 0}
PATCH
/automations/{automationId}

Path Parameters

automationId*string
Length1 <= length

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

curl -X PATCH "https://example.com/automations/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "id": "string",  "orgId": "string",  "projectId": "string",  "name": "string",  "prompt": "string",  "templateKey": "string",  "triggers": [    {      "kind": "schedule",      "schedule": {        "interval": "daily",        "time": "string",        "timezone": "string",        "weekday": "monday",        "dayOfMonth": 1      }    }  ],  "labels": [    "string"  ],  "skipIfPreviousOpen": true,  "enabled": true,  "nextRunAt": 0,  "lastRunAt": 0,  "createdAt": 0,  "updatedAt": 0}
DELETE
/automations/{automationId}

Path Parameters

automationId*string
Length1 <= length

Response Body

application/json

application/json

application/json

curl -X DELETE "https://example.com/automations/string"
{  "ok": true,  "id": "string"}
GET
/automations/{automationId}/runs

Path Parameters

automationId*string
Length1 <= length

Response Body

application/json

application/json

curl -X GET "https://example.com/automations/string/runs"
{  "data": [    {      "id": "string",      "automationId": "string",      "projectId": "string",      "scheduledFor": 0,      "kind": "scheduled",      "status": "dispatching",      "issueId": "string",      "issueUrl": "string",      "reason": "string",      "lastError": "string",      "createdAt": 0,      "updatedAt": 0,      "missionProgress": "string",      "missionActivity": "string",      "missionCostUsd": 0,      "missionTitle": "string"    }  ],  "nextCursor": "string"}
POST
/automations/{automationId}/run

Path Parameters

automationId*string
Length1 <= length

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/automations/string/run"
{  "ok": true,  "runId": "string",  "issueId": "string",  "status": "dispatching"}

How is this page?