latestOpenAPI 3.1.02026-08-22154287463.4 KB

858365328f92

Invocations

Update invocation

Update an invocation's status or output. This can be used to cancel an invocation by setting the status to "failed".

patch/invocations/{id}

Path parameters

idstring required

Invocation ID

Request body

outputstring

Updated output of the invocation rendered as JSON string.

status'succeeded' | 'failed' required

New status for the invocation.

Response

Invocation updated successfully

action_namestring required

Name of the action invoked

app_namestring required

Name of the application

finished_atstring date-time nullable

RFC 3339 Nanoseconds timestamp when the invocation finished (null if still running)

idstring required

ID of the invocation

outputstring

Output produced by the action, rendered as a JSON string. This could be: string, number, boolean, array, object, or null.

payloadstring

Payload provided to the invocation. This is a string that can be parsed as JSON.

started_atstring date-time required

RFC 3339 Nanoseconds timestamp when the invocation started

status'queued' | 'running' | 'succeeded' | 'failed' required

Status of the invocation

status_reasonstring

Status reason

versionstring required

Version label for the application

Example response

{
  "action_name": "analyze",
  "app_name": "my-app",
  "finished_at": "2024-05-19T15:30:05.000000000Z07:00",
  "id": "rr33xuugxj9h0bkf1rdt2bet",
  "output": "{\"result\":\"success\",\"data\":\"processed input\"}",
  "payload": "{\"data\":\"example input\"}",
  "started_at": "2024-05-19T15:30:00.000000000Z07:00",
  "status": "succeeded",
  "status_reason": "Invocation completed successfully",
  "version": "1.0.0"
}