POST
/
v1
/
runs
/
chain
Create Run Chain
curl --request POST \
  --url https://api.cyberdesk.io/v1/runs/chain \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "steps": [
    {
      "workflow_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "session_alias": "<string>",
      "inputs": {}
    }
  ],
  "shared_inputs": {},
  "shared_sensitive_inputs": {},
  "shared_file_inputs": [
    {
      "filename": "<string>",
      "content": "<string>",
      "target_path": "<string>",
      "cleanup_imports_after_run": false
    }
  ],
  "keep_session_after_completion": true,
  "machine_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "pool_ids": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ],
  "session_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}'
{
  "session_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "run_ids": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Request to create and run a multi-step chain on a single reserved session/machine

steps
ChainStep · object[]
required
Minimum length: 1
shared_inputs
object | null
shared_sensitive_inputs
object | null
shared_file_inputs
FileInput · object[] | null
keep_session_after_completion
boolean | null
default:false
machine_id
string<uuid> | null
pool_ids
string<uuid>[] | null

Pool IDs to filter available machines when starting a new session. Machine must belong to ALL of these pools (intersection). Ignored when machine_id is provided.

session_id
string<uuid> | null

Response

Successful Response

Response for chain creation

session_id
string<uuid>
required
run_ids
string<uuid>[]
required