Skip to main content
POST
/
runs
/
{run_id}
/
complete
Complete a canonical run
curl --request POST \
  --url https://api.veryfront.com/runs/{run_id}/complete \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "metadata": {
    "provider": "<string>",
    "model": "<string>",
    "inputTokens": 123,
    "outputTokens": 123,
    "finishReason": "<string>",
    "cachedInputTokens": 123,
    "reasoningTokens": 123,
    "providerRequestId": "<string>"
  },
  "terminal_error_code": "<string>",
  "terminal_error_message": "<string>"
}
'
{
  "completed": true,
  "run": {
    "run_id": "<string>",
    "owner": {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
    },
    "parent_run_id": "<string>",
    "root_run_id": "<string>",
    "target": "<string>",
    "workflow_id": "<string>",
    "schedule_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "batch_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "runtime_target_environment_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "runtime_target_branch_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "error": {
      "message": "<string>",
      "code": "<string>"
    },
    "logs": "<string>",
    "artifacts": [
      null
    ],
    "duration_ms": 123,
    "exit_code": 123,
    "start_mode": "<string>",
    "timeout_seconds": 123,
    "backoff_limit": 123,
    "trigger_id": "<string>",
    "created_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "updated_at": "<string>",
    "created_at": "<string>",
    "started_at": "<string>",
    "completed_at": "<string>",
    "metadata": null,
    "input": null,
    "config": null,
    "output": null
  }
}

Authorizations

Authorization
string
header
required

Use a JWT bearer token or a Veryfront API key in the Authorization header.

Path Parameters

run_id
string
required
Minimum string length: 1

Body

application/json
status
enum<string>
required
Available options:
completed,
failed,
cancelled
metadata
object
terminal_error_code
string | null
terminal_error_message
string | null

Response

Run completed

completed
boolean
required
run
object
required