{"openapi":"3.1.0","info":{"title":"ZeroShot API","version":"2026-10-27","description":"ZeroShot runs jobs on AutoFAB Robots. A job holds tasks; each task has one executor: ranger (works out a new goal), atlas (repeats a learned routine), person (a human answers it) or app:<id> (an installed application's operation). One plan per organization: $99 a month, any number of robots, 10 Ranger runs and 100 hours of Atlas included each month. Past that Ranger costs $10 per successful task and nothing if it fails or gives up; Atlas costs $1/hr, billed per second. zs_test_ keys run on a test robot, not charged, and instant; end the instruction with [give_up], [fault] or [out_of_credit] to force that outcome. Webhooks are signed: ZeroShot-Signature: t=<unix>,v1=<hex HMAC-SHA256 of \"<t>.<body>\" with the endpoint's whsec_ secret>; refuse a t older than 5 minutes. A non-2xx is retried after 60s, 300s, 1800s, 7200s, 21600s, 43200s."},"servers":[{"url":"https://api.autofab.net"}],"components":{"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","description":"A zs_live_ or zs_test_ key. Scopes: tasks:read, tasks:write, robots:read, billing:read, farm:read, account:read, account:write."},"session":{"type":"http","scheme":"bearer","description":"A signed-in platform session (key management only)."},"deviceToken":{"type":"http","scheme":"bearer","description":"A robot's own per-fab device token (the robot door only)."}},"parameters":{"version":{"name":"ZeroShot-Version","in":"header","required":false,"schema":{"enum":["2026-10-27"]}},"idempotency":{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":255}}},"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","doc_url"],"properties":{"code":{"enum":["authentication_required","invalid_api_key","api_key_revoked","sign_in_required","insufficient_scope","not_org_member","not_org_owner","insufficient_role","staff_only","invalid_request","authorization_pending","slow_down","expired_token","access_denied","too_many_requests","api_version_invalid","not_found","robot_not_found","method_not_allowed","idempotency_key_reused","idempotency_in_progress","insufficient_credit","monthly_limit","robot_dispatch_unavailable","plan_required","billing_unavailable","internal_error"]},"message":{"type":"string"},"doc_url":{"type":"string","format":"uri"}}}}},"Task":{"type":"object","required":["id","object","livemode","mode","status","robot_id"],"properties":{"id":{"type":"string","format":"uuid"},"object":{"const":"task"},"livemode":{"type":"boolean"},"mode":{"enum":["ranger","atlas"]},"status":{"enum":["running","succeeded","failed","gave_up"]},"robot_id":{"type":"string"},"instruction":{"type":["string","null"]},"routine_id":{"type":["string","null"]},"outcome_reason":{"type":["string","null"]},"frames":{"type":"array","items":{"type":"string"},"description":"Keys of the frames behind the outcome."},"steps":{"type":"integer"},"active_seconds":{"type":"number"},"price_usd":{"type":"number"},"give_up":{"type":"object","description":"The task's give-up budget (Ranger): active minutes and failed tries at one step.","properties":{"max_active_minutes":{"type":"integer"},"max_failed_tries":{"type":"integer"}}},"created":{"type":"string","format":"date-time"},"ended":{"type":["string","null"],"format":"date-time"}}},"TaskEvent":{"type":"object","required":["id","object","type"],"properties":{"id":{"type":"string"},"object":{"const":"task.event"},"type":{"enum":["task.started","step.passed","step.failed","task.succeeded","task.failed","task.gave_up"]},"step":{"type":"string"},"attempt":{"type":"integer"},"reason":{"type":["string","null"]},"active_seconds":{"type":"number"},"frames":{"type":"array","items":{"type":"string"}},"created":{"type":["string","null"],"format":"date-time"}}},"Robot":{"type":"object","required":["id","object","name","status","livemode"],"properties":{"id":{"type":"string"},"object":{"const":"robot"},"name":{"type":"string"},"model":{"type":"string"},"status":{"type":"string"},"last_seen_at":{"type":["string","null"],"format":"date-time"},"livemode":{"type":"boolean"}}},"Balance":{"type":"object","required":["object","livemode","currency","available_usd","held_usd"],"properties":{"object":{"const":"balance"},"livemode":{"type":"boolean"},"currency":{"const":"usd"},"available_usd":{"type":"number"},"held_usd":{"type":"number","description":"$10 held per running live Ranger task."}}},"UsageDay":{"type":"object","properties":{"day":{"type":"string","format":"date"},"mode":{"enum":["ranger","atlas"]},"tasks":{"type":"integer"},"succeeded":{"type":"integer"},"failed":{"type":"integer"},"gave_up":{"type":"integer"},"active_seconds":{"type":"number"},"charged_usd":{"type":"number"}}},"ApiKey":{"type":"object","required":["id","object","name","livemode","scopes","redacted"],"properties":{"id":{"type":"string","format":"uuid"},"object":{"const":"api_key"},"name":{"type":"string"},"livemode":{"type":"boolean"},"scopes":{"type":"array","items":{"enum":["tasks:read","tasks:write","robots:read","billing:read","farm:read","account:read","account:write"]}},"redacted":{"type":"string"},"secret":{"type":"string","description":"Only in the response that creates the key."},"created":{"type":"string","format":"date-time"},"last_used":{"type":["string","null"]},"revoked":{"type":["string","null"]}}},"CreditSettings":{"type":"object","required":["object","auto_reload","monthly_limit_usd","spent_this_month_usd"],"properties":{"object":{"const":"credit_settings"},"auto_reload":{"type":"object","properties":{"enabled":{"type":"boolean"},"below_usd":{"type":"number"},"amount_usd":{"type":"number"}}},"monthly_limit_usd":{"type":["number","null"]},"spent_this_month_usd":{"type":"number"},"updated":{"type":["string","null"],"format":"date-time"}}},"WebhookEndpoint":{"type":"object","required":["id","object","livemode","url","events","status"],"properties":{"id":{"type":"string","format":"uuid"},"object":{"const":"webhook_endpoint"},"livemode":{"type":"boolean"},"url":{"type":"string","format":"uri"},"events":{"type":"array","items":{"enum":["task.succeeded","task.gave_up","robot.offline","balance.low"]}},"description":{"type":["string","null"]},"status":{"enum":["enabled","disabled"]},"secret":{"type":"string","description":"whsec_…, only in the response that creates the endpoint."},"created":{"type":"string","format":"date-time"}}},"WebhookDelivery":{"type":"object","required":["id","object","event_id","endpoint_id","status","attempts"],"properties":{"id":{"type":"integer"},"object":{"const":"webhook_delivery"},"event_id":{"type":"string"},"endpoint_id":{"type":"string","format":"uuid"},"status":{"enum":["pending","succeeded","failed"]},"attempts":{"type":"integer"},"next_attempt_at":{"type":["string","null"],"format":"date-time"},"last_status":{"type":["integer","null"],"description":"The endpoint's HTTP status."},"last_duration_ms":{"type":["integer","null"]},"last_error":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"},"delivered_at":{"type":["string","null"],"format":"date-time"}}},"Event":{"type":"object","required":["id","object","type","created","livemode","data"],"description":"The body of every webhook.","properties":{"id":{"type":"string"},"object":{"const":"event"},"type":{"enum":["task.succeeded","task.gave_up","robot.offline","balance.low","webhook.test"]},"created":{"type":"integer","description":"Unix seconds."},"livemode":{"type":"boolean"},"api_version":{"type":"string"},"data":{"type":"object","properties":{"object":{"type":"object"}}}}}}},"paths":{"/v1/device/code":{"post":{"operationId":"startDeviceSignIn","summary":"Start a CLI sign-in (no credential)","description":"RFC 8628. Returns a long device_code for the CLI to keep and a short user_code for the person to enter at verification_uri. Poll POST /v1/device/token with the device_code. kind robot (`autofab login --robot`, BUILD-348) signs the computer in as a robot: approving it creates the robot and its device token, and no API key.","security":[],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"client_name":{"type":"string","maxLength":80},"kind":{"enum":["person","robot"]},"host":{"type":"object","description":"A robot computer's own facts; unknown fields are dropped","properties":{"os":{"type":"string","maxLength":80},"arch":{"type":"string","maxLength":80},"hostname":{"type":"string","maxLength":80},"version":{"type":"string","maxLength":80},"devices":{"type":"array","maxItems":32,"items":{"type":"string"}}}}}}}}},"responses":{"200":{"description":"The codes and how often to poll"},"429":{"description":"Error: too_many_requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/device/token":{"post":{"operationId":"pollDeviceSignIn","summary":"Collect the key once the person approves (no credential)","description":"Answers 400 authorization_pending until the person approves, slow_down if polled too fast, expired_token, or access_denied. On approval it returns, exactly once, the API key's secret (kind person) or the robot's device_token and fab_id (kind robot).","security":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["device_code"],"properties":{"device_code":{"type":"string"}}}}}},"responses":{"200":{"description":"kind person: the key's secret with its org and mode; kind robot: device_token, fab_id, org_id"},"400":{"description":"Error: authorization_pending, slow_down, expired_token, access_denied, invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/device/lookup":{"get":{"operationId":"lookupDeviceSignIn","summary":"What a sign-in code is for (signed in)","security":[{"session":[]}],"parameters":[{"name":"user_code","in":"query","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The client asking, its kind (and a robot's host facts), how long the code lasts"},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/device/approve":{"post":{"operationId":"approveDeviceSignIn","summary":"Approve or refuse a CLI sign-in (organization owner)","security":[{"session":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["user_code","org_id"],"properties":{"user_code":{"type":"string"},"org_id":{"type":"string","format":"uuid"},"mode":{"enum":["live","test"],"description":"a person's sign-in only"},"name":{"type":"string","maxLength":80,"description":"a robot's name (robot sign-in)"},"deny":{"type":"boolean"}}}}}},"responses":{"200":{"description":"approved (a key, or for a robot sign-in the robot and its token) or denied"},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: not_org_owner","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/device/revoke":{"post":{"operationId":"revokeDeviceToken","summary":"Sign this robot computer out: its device token stops working (device token)","security":[{"deviceToken":[]}],"responses":{"200":{"description":"revoked"},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/openapi.json":{"get":{"operationId":"getOpenApi","summary":"This document","security":[],"responses":{"200":{"description":"OpenAPI 3.1"}}}},"/v1/robot/applications/{id}/lease":{"post":{"operationId":"robotLeaseApplicationTask","summary":"Take this robot's next operation for an application (device token)","description":"Only this robot's own live tasks, on printers it names in `printers`; a task on any other printer is ended failed with the reason. Null when nothing is ready. Keep the lease with the heartbeat route.","security":[{"deviceToken":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["printers"],"properties":{"printers":{"type":"array","items":{"type":"string"}}}}}}},"responses":{"200":{"description":"The leased task (with cleared_by and clear_unverified), or null"},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/robot/applications/{id}/tasks/{task_id}/heartbeat":{"post":{"operationId":"robotHeartbeatApplicationTask","summary":"Keep this robot's lease on an operation (device token)","security":[{"deviceToken":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"task_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["lease_token"],"properties":{"lease_token":{"type":"string","format":"uuid"}}}}}},"responses":{"200":{"description":"status ok, lost, cancelled or ended"},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/robot/applications/{id}/tasks/{task_id}/complete":{"post":{"operationId":"robotCompleteApplicationTask","summary":"Report how this robot's operation ended (device token)","security":[{"deviceToken":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"task_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["lease_token","outcome"],"properties":{"lease_token":{"type":"string","format":"uuid"},"outcome":{"enum":["succeeded","failed"]},"reason":{"type":"string","maxLength":2000}}}}}},"responses":{"200":{"description":"The outcome recorded; again when it was already"},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/robot/applications/{id}/events":{"post":{"operationId":"robotEmitApplicationEvent","summary":"Send an application event from this robot's printer (device token)","description":"Submits the jobs its triggers name only when every trigger for the event in the account is this robot's, on this printer; otherwise nothing is submitted and `refused` says why.","security":[{"deviceToken":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["event","printer_id"],"properties":{"event":{"type":"string"},"printer_id":{"type":"string"}}}}}},"responses":{"200":{"description":"The new job ids"},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/robot/clears":{"post":{"operationId":"robotRequestClear","summary":"Ask the cloud to clear this robot's printer bed (device token)","description":"The robot's print queue, with the harness backend set to cloud, asks for a bed clear instead of running one itself: one live task on this robot's work queue (executor ranger or atlas, resources robot and printer), leased and driven by the cloud harness; the lease carries op_input.printer_id and op_input.queue_job_id. Idempotent on job_id while that job's clear is open (then 200 with the same task).","security":[{"deviceToken":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["printer_id","job_id"],"properties":{"printer_id":{"type":"string"},"job_id":{"type":"string","description":"The robot's queue job for the printed part."},"mode":{"type":"string","enum":["ranger","atlas"],"default":"ranger"},"part":{"type":"object","properties":{"width_mm":{"type":"number"},"sha":{"type":"string","description":"The print file's digest."}}}}}}}},"responses":{"200":{"description":"That job's clear is already open: the same task"},"201":{"description":"The clear task"},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Error: insufficient_credit","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/robot/clears/{task_id}/cancel":{"post":{"operationId":"robotCancelClear","summary":"Cancel a bed clear this robot's queue gave up on (device token)","description":"The robot's queue stopped waiting for the clear (its wait window, its backstop, a restart): the task is cancelled so it never starts the arm later. Own robot only; idempotent (an ended task answers with its outcome and cancelled false).","security":[{"deviceToken":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"reason":{"type":"string"}}}}}},"responses":{"200":{"description":"cancelled, and the task's outcome"},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tasks":{"post":{"operationId":"tasks_create","summary":"Run a task","description":"Run one task on a robot now, outside a job. Ranger (default) works out the instruction; Atlas repeats routine_id. A live Ranger task holds $10 and charges it only on success. With a zs_test_ key it runs on the test robot at once and is never charged; put [give_up], [fault] or [out_of_credit] in the instruction to force that outcome. To queue work with several tasks, dependencies or a schedule, use zeroshot_work_submit.","x-zeroshot-action":"tasks.create","x-zeroshot-mcp-tool":"zeroshot_tasks_create","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"instruction":{"type":"string","description":"What to do, in plain words (1 to 2000 characters).","minLength":1,"maxLength":2000},"robot_id":{"type":"string","description":"A robot from zeroshot_robots_list; test keys default to zs_test_robot."},"mode":{"type":"string","enum":["ranger","atlas"],"description":"Default ranger."},"routine_id":{"type":"string","description":"The learned routine, for Atlas."},"give_up":{"type":"object","properties":{"max_active_minutes":{"type":"integer","minimum":1,"maximum":20,"description":"Ranger gives up after this many minutes of active time (default 20)."},"max_failed_tries":{"type":"integer","minimum":1,"maximum":20,"description":"Ranger gives up after this many failed tries at one step (default 10)."}},"required":[],"additionalProperties":false}},"required":["instruction"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Task"}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Error: insufficient_credit, plan_required, monthly_limit","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: robot_not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error: idempotency_key_reused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Error: robot_dispatch_unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"tasks_list","summary":"List tasks","description":"Tasks in this key's mode, newest first.","x-zeroshot-action":"tasks.list","x-zeroshot-mcp-tool":"zeroshot_tasks_list","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"$ref":"#/components/schemas/Task"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tasks/{id}":{"get":{"operationId":"tasks_get","summary":"Read a task","description":"One task: status (running, succeeded, failed, gave_up), why, frames, active seconds and price.","x-zeroshot-action":"tasks.get","x-zeroshot-mcp-tool":"zeroshot_tasks_get","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","description":"The task id."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Task"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tasks/{id}/events":{"get":{"operationId":"tasks_events","summary":"Read a task's steps","description":"What happened during a task, step by step, with each step's frames.","x-zeroshot-action":"tasks.events","x-zeroshot-mcp-tool":"zeroshot_tasks_events","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","description":"The task id."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"$ref":"#/components/schemas/TaskEvent"}}}}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/robots":{"get":{"operationId":"robots_list","summary":"List robots","description":"The account's robots and their status (a test key sees the test robot).","x-zeroshot-action":"robots.list","x-zeroshot-mcp-tool":"zeroshot_robots_list","security":[{"session":[]},{"apiKey":["robots:read"]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"$ref":"#/components/schemas/Robot"}}}}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/robots/{id}":{"get":{"operationId":"robots_get","summary":"Read a robot","description":"One robot and its status.","x-zeroshot-action":"robots.get","x-zeroshot-mcp-tool":"zeroshot_robots_get","security":[{"session":[]},{"apiKey":["robots:read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","description":"The robot id."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Robot"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: robot_not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/hardware_units":{"get":{"operationId":"hardware_list","summary":"Hardware orders","description":"Bought robots, from paid to shipped to online, with tracking. A test key gets an empty list: farm data is live data.","x-zeroshot-action":"hardware.list","x-zeroshot-mcp-tool":"zeroshot_hardware_list","security":[{"session":[]},{"apiKey":["farm:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"livemode":{"type":"boolean"},"data":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/print_outcomes":{"get":{"operationId":"print_outcomes_list","summary":"Print results","description":"Each print's result on the farm. A test key gets an empty list: farm data is live data.","x-zeroshot-action":"print_outcomes.list","x-zeroshot-mcp-tool":"zeroshot_print_outcomes_list","security":[{"session":[]},{"apiKey":["farm:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"livemode":{"type":"boolean"},"data":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/files":{"get":{"operationId":"files_list","summary":"Files","description":"Uploaded part files. A test key gets an empty list: farm data is live data.","x-zeroshot-action":"files.list","x-zeroshot-mcp-tool":"zeroshot_files_list","security":[{"session":[]},{"apiKey":["farm:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"livemode":{"type":"boolean"},"data":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/parts":{"get":{"operationId":"parts_list","summary":"Parts","description":"Parts, including learned ones. A test key gets an empty list: farm data is live data.","x-zeroshot-action":"parts.list","x-zeroshot-mcp-tool":"zeroshot_parts_list","security":[{"session":[]},{"apiKey":["farm:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"livemode":{"type":"boolean"},"data":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/products":{"get":{"operationId":"products_list","summary":"Products","description":"Products (kits of parts). A test key gets an empty list: farm data is live data.","x-zeroshot-action":"products.list","x-zeroshot-mcp-tool":"zeroshot_products_list","security":[{"session":[]},{"apiKey":["farm:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"livemode":{"type":"boolean"},"data":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/inventory":{"get":{"operationId":"inventory_list","summary":"Inventory","description":"Parts cleared from the robots, newest first. A test key gets an empty list: farm data is live data.","x-zeroshot-action":"inventory.list","x-zeroshot-mcp-tool":"zeroshot_inventory_list","security":[{"session":[]},{"apiKey":["farm:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"livemode":{"type":"boolean"},"data":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/team":{"get":{"operationId":"team_list","summary":"Team","description":"The organization's members and their roles. A test key gets an empty list: farm data is live data.","x-zeroshot-action":"team.list","x-zeroshot-mcp-tool":"zeroshot_team_list","security":[{"session":[]},{"apiKey":["farm:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"livemode":{"type":"boolean"},"data":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/machine_subscriptions":{"get":{"operationId":"subscriptions_list","summary":"Organization plan","description":"The organization plan: $99 a month for the organization, any number of robots and printers. A test key gets an empty list: farm data is live data.","x-zeroshot-action":"subscriptions.list","x-zeroshot-mcp-tool":"zeroshot_subscriptions_list","security":[{"session":[]},{"apiKey":["farm:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"livemode":{"type":"boolean"},"data":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/balance":{"get":{"operationId":"balance_get","summary":"Balance","description":"Prepaid credit available, and what is held for running Ranger tasks.","x-zeroshot-action":"balance.get","x-zeroshot-mcp-tool":"zeroshot_balance_get","security":[{"session":[]},{"apiKey":["billing:read"]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Balance"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/usage":{"get":{"operationId":"usage_get","summary":"Usage","description":"Usage by day (UTC): tasks by outcome, active seconds and charges.","x-zeroshot-action":"usage.get","x-zeroshot-mcp-tool":"zeroshot_usage_get","security":[{"session":[]},{"apiKey":["billing:read"]}],"parameters":[{"name":"from","in":"query","required":false,"schema":{"type":"string","format":"date","description":"YYYY-MM-DD (default 30 days ago)."}},{"name":"to","in":"query","required":false,"schema":{"type":"string","format":"date","description":"YYYY-MM-DD (default today)."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"$ref":"#/components/schemas/UsageDay"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/credit/settings":{"get":{"operationId":"credit_get_settings","summary":"Credit settings","description":"Auto-reload, the monthly spending limit, and what was spent this month.","x-zeroshot-action":"credit.get_settings","x-zeroshot-mcp-tool":"zeroshot_credit_get_settings","security":[{"session":[]},{"apiKey":["billing:read"]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditSettings"}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"credit_update_settings","summary":"Change credit settings","description":"Turn auto-reload on (reload amount_usd when the balance falls below below_usd) or off (null), and set or clear (null) the monthly spending limit. Whole dollars. Live keys only; only the fields sent change.","x-zeroshot-action":"credit.update_settings","x-zeroshot-mcp-tool":"zeroshot_credit_update_settings","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"auto_reload":{"type":["object","null"],"properties":{"enabled":{"type":"boolean"},"below_usd":{"type":"integer","minimum":10,"maximum":1000},"amount_usd":{"type":"integer","minimum":10,"maximum":5000}}},"monthly_limit_usd":{"type":["integer","null"],"minimum":10,"maximum":100000}},"required":[],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditSettings"}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_owner","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/keys":{"post":{"operationId":"keys_create","summary":"Create an API key","description":"A new key in this key's mode, with at most this key's scopes (a signed-in owner sends org_id). The full key is in the answer once; keep it safe.","x-zeroshot-action":"keys.create","x-zeroshot-mcp-tool":"zeroshot_keys_create","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","description":"A name to recognise it by.","maxLength":80},"mode":{"type":"string","enum":["live","test"]},"scopes":{"type":"array","items":{"type":"string","enum":["tasks:read","tasks:write","robots:read","billing:read","farm:read","account:read","account:write"]},"description":"Default: this key's scopes."}},"required":["name","mode"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKey"}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_owner","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"keys_list","summary":"List API keys","description":"The organization's API keys (never their secrets).","x-zeroshot-action":"keys.list","x-zeroshot-mcp-tool":"zeroshot_keys_list","security":[{"session":[]},{"apiKey":["account:read"]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"$ref":"#/components/schemas/ApiKey"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/keys/{id}/revoke":{"post":{"operationId":"keys_revoke","summary":"Revoke an API key","description":"Revoke a key now; calls with it fail from then on.","x-zeroshot-action":"keys.revoke","x-zeroshot-mcp-tool":"zeroshot_keys_revoke","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"The key id."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKey"}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_owner","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/requests":{"get":{"operationId":"requests_list","summary":"Request log","description":"The request log: every call, status, timing and error code. A key reads its own mode's; a signed-in person reads both, or the mode asked for.","x-zeroshot-action":"requests.list","x-zeroshot-mcp-tool":"zeroshot_requests_list","security":[{"session":[]},{"apiKey":["account:read"]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"How many, newest first (default 50)."}},{"name":"mode","in":"query","required":false,"schema":{"type":"string","enum":["live","test"]}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/webhook_endpoints":{"post":{"operationId":"webhooks_create","summary":"Add a webhook endpoint","description":"Send signed events to a public https URL. The signing secret is in the answer once.","x-zeroshot-action":"webhooks.create","x-zeroshot-mcp-tool":"zeroshot_webhooks_create","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"url":{"type":"string","description":"A public https URL."},"events":{"type":"array","minItems":1,"items":{"type":"string","enum":["task.succeeded","task.gave_up","robot.offline","balance.low"]}},"mode":{"type":"string","enum":["live","test"]},"description":{"type":"string","description":"What it is for.","maxLength":200}},"required":["url","events","mode"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpoint"}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_owner","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"webhooks_list","summary":"List webhook endpoints","description":"The organization's webhook endpoints.","x-zeroshot-action":"webhooks.list","x-zeroshot-mcp-tool":"zeroshot_webhooks_list","security":[{"session":[]},{"apiKey":["account:read"]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"$ref":"#/components/schemas/WebhookEndpoint"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/webhook_endpoints/{id}/disable":{"post":{"operationId":"webhooks_disable","summary":"Disable a webhook endpoint","description":"Stop sending events to an endpoint.","x-zeroshot-action":"webhooks.disable","x-zeroshot-mcp-tool":"zeroshot_webhooks_disable","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"The endpoint id."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpoint"}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_owner","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/webhook_endpoints/{id}/test":{"post":{"operationId":"webhooks_test","summary":"Test a webhook endpoint","description":"Send a webhook.test event now and see how the delivery went.","x-zeroshot-action":"webhooks.test","x-zeroshot-mcp-tool":"zeroshot_webhooks_test","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"The endpoint id."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookDelivery"}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_owner","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/webhook_deliveries":{"get":{"operationId":"webhooks_deliveries","summary":"Webhook delivery log","description":"Every webhook delivery and its attempts, newest first.","x-zeroshot-action":"webhooks.deliveries","x-zeroshot-mcp-tool":"zeroshot_webhooks_deliveries","security":[{"session":[]},{"apiKey":["account:read"]}],"parameters":[{"name":"endpoint_id","in":"query","required":false,"schema":{"type":"string","description":"Only this endpoint's."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"$ref":"#/components/schemas/WebhookDelivery"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/jobs":{"post":{"operationId":"work_submit","summary":"Submit a job","description":"Ask for something in plain words. The job is queued with one Ranger task, which works out the goal on the chosen robot once a runner picks it up. Nothing is charged until the task starts: Ranger is $10 only on success. With a zs_test_ key the job runs on the test robot and is never charged. on_failure says what a failed task does: abort (the default), retry, escalate to Ranger, or hand to a person (the task then waits in needs-you). Read the result with work.get.","x-zeroshot-action":"work.submit","x-zeroshot-mcp-tool":"zeroshot_work_submit","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"goal":{"type":"string","description":"What to do, in plain words (1 to 2000 characters).","minLength":1,"maxLength":2000},"robot_id":{"type":"string","description":"A robot from zeroshot_robots_list. Test keys default to zs_test_robot."},"on_failure":{"type":"string","enum":["abort","retry","ranger","person"]}},"required":["goal"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["job"]},"livemode":{"type":"boolean"},"goal":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"paused":{"type":"boolean"},"tasks":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["task"]},"executor":{"type":"string","description":"Who runs it: ranger, atlas, a person or an application."},"robot_id":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"reason":{"type":"string"},"priority":{"type":"integer","description":"Higher runs first."},"attempt":{"type":"integer","description":"1 for the first try; a retry or escalation is the next."},"retry_of":{"type":"string","description":"The task this one replaced, if any."},"created":{"type":"string"}}}},"created":{"type":"string"}}}}}}}}},"/v1/jobs/{id}":{"get":{"operationId":"work_get","summary":"Read a job","description":"A job and its tasks, with each task's status: queued until a runner takes it, running, then succeeded, failed, gave_up or out_of_credit (a run that could not start for want of credit). A job is as far along as its furthest task.","x-zeroshot-action":"work.get","x-zeroshot-mcp-tool":"zeroshot_work_get","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","description":"The job id from work.submit."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["job"]},"livemode":{"type":"boolean"},"goal":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"paused":{"type":"boolean"},"tasks":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["task"]},"executor":{"type":"string","description":"Who runs it: ranger, atlas, a person or an application."},"robot_id":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"reason":{"type":"string"},"priority":{"type":"integer","description":"Higher runs first."},"attempt":{"type":"integer","description":"1 for the first try; a retry or escalation is the next."},"retry_of":{"type":"string","description":"The task this one replaced, if any."},"created":{"type":"string"}}}},"created":{"type":"string"}}}}}}}}},"/v1/jobs/{id}/events":{"get":{"operationId":"work_events","summary":"Read a job's run log","description":"Every step of every task in a job, oldest first: look, decide, move and check, plus refusals and escalations, each with the exact call behind it and what came back. All events of one task share a trace id. Poll it while the job is running.","x-zeroshot-action":"work.events","x-zeroshot-mcp-tool":"zeroshot_work_events","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","description":"The job id from work.submit."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"object","properties":{"object":{"type":"string","enum":["run_event"]},"task_id":{"type":"string","format":"uuid"},"trace_id":{"type":"string"},"seq":{"type":"integer","description":"Order within the task, from 1."},"kind":{"type":"string","enum":["look","decide","move","check","refusal","escalation","handback","step"]},"call":{"type":"object","description":"What was asked: the prompt reference, tool call, command."},"result":{"type":"object","description":"What came back."},"created":{"type":"string"}}}}}}}}}}}},"/v1/jobs/{id}/cancel":{"post":{"operationId":"work_cancel","summary":"Cancel a job","description":"Cancels every task of the job that has not finished. A task that holds credit gives it back; a task that is running stops at its next step. Safe to repeat. The job reads back as cancelled.","x-zeroshot-action":"work.cancel","x-zeroshot-mcp-tool":"zeroshot_work_cancel","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The job id from work.submit."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["job"]},"livemode":{"type":"boolean"},"goal":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"paused":{"type":"boolean"},"tasks":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["task"]},"executor":{"type":"string","description":"Who runs it: ranger, atlas, a person or an application."},"robot_id":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"reason":{"type":"string"},"priority":{"type":"integer","description":"Higher runs first."},"attempt":{"type":"integer","description":"1 for the first try; a retry or escalation is the next."},"retry_of":{"type":"string","description":"The task this one replaced, if any."},"created":{"type":"string"}}}},"created":{"type":"string"}}}}}}}}},"/v1/jobs/{id}/pause":{"post":{"operationId":"work_pause","summary":"Pause a job","description":"Stops new tasks of the job from starting. A task already running finishes its work. Undo with work.resume.","x-zeroshot-action":"work.pause","x-zeroshot-mcp-tool":"zeroshot_work_pause","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The job id from work.submit."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["job"]},"livemode":{"type":"boolean"},"goal":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"paused":{"type":"boolean"},"tasks":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["task"]},"executor":{"type":"string","description":"Who runs it: ranger, atlas, a person or an application."},"robot_id":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"reason":{"type":"string"},"priority":{"type":"integer","description":"Higher runs first."},"attempt":{"type":"integer","description":"1 for the first try; a retry or escalation is the next."},"retry_of":{"type":"string","description":"The task this one replaced, if any."},"created":{"type":"string"}}}},"created":{"type":"string"}}}}}}}}},"/v1/jobs/{id}/resume":{"post":{"operationId":"work_resume","summary":"Resume a paused job","description":"Lets the job's tasks start again.","x-zeroshot-action":"work.resume","x-zeroshot-mcp-tool":"zeroshot_work_resume","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The job id from work.submit."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["job"]},"livemode":{"type":"boolean"},"goal":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"paused":{"type":"boolean"},"tasks":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"object":{"type":"string","enum":["task"]},"executor":{"type":"string","description":"Who runs it: ranger, atlas, a person or an application."},"robot_id":{"type":"string"},"status":{"type":"string","enum":["queued","running","succeeded","failed","gave_up","out_of_credit","cancelled"]},"reason":{"type":"string"},"priority":{"type":"integer","description":"Higher runs first."},"attempt":{"type":"integer","description":"1 for the first try; a retry or escalation is the next."},"retry_of":{"type":"string","description":"The task this one replaced, if any."},"created":{"type":"string"}}}},"created":{"type":"string"}}}}}}}}},"/v1/tasks/{id}/priority":{"post":{"operationId":"work_reorder","summary":"Change a task's priority","description":"Higher priority runs first; ties go to the earlier deadline, then the earlier submission. Only a task that has not finished can be reordered.","x-zeroshot-action":"work.reorder","x-zeroshot-mcp-tool":"zeroshot_work_reorder","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"A task id from work.get."},"priority":{"type":"integer","minimum":-100,"maximum":100,"description":"0 is normal."}},"required":["id","priority"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"object":{"type":"string","enum":["task"]},"priority":{"type":"integer"}}}}}}}}},"/v1/events":{"post":{"operationId":"work_fire_event","summary":"Send an event","description":"Tells ZeroShot something happened (for example print.finished). Every template triggered by that event submits a job. Returns the new job ids; none if nothing listens.","x-zeroshot-action":"work.fire_event","x-zeroshot-mcp-tool":"zeroshot_work_fire_event","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"event":{"type":"string","minLength":1,"maxLength":120,"description":"An event name, like print.finished."}},"required":["event"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"string"}}}}}}}}}},"/v1/templates":{"post":{"operationId":"work_template_create","summary":"Create a job template","description":"A reusable job: its goal and its tasks (with resources and dependencies). Give it on_event to submit it whenever that event is sent, and/or cron (five fields, UTC, like '*/15 * * * *') to submit it on a schedule. on_failure says what a failed task does: abort the job, retry, escalate to Ranger, or hand to a person.","x-zeroshot-action":"work.template_create","x-zeroshot-mcp-tool":"zeroshot_work_template_create","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"goal":{"type":"string","minLength":1,"maxLength":2000},"tasks":{"type":"array","items":{"type":"object","properties":{"executor":{"type":"string","pattern":"ranger|atlas|person|app:[a-z][a-z0-9_]{1,40}","description":"ranger, atlas, person, or an installed application's executor like app:print_farm (then op is required)."},"op":{"type":"string","pattern":"[a-z][a-z0-9_]*(\\.[a-z][a-z0-9_]*)+","description":"For an application executor: its operation, like printer.start."},"op_input":{"type":"object","description":"The operation's input, like { printer_id }."},"goal":{"type":"string","maxLength":2000},"priority":{"type":"integer","minimum":-100,"maximum":100},"deadline":{"type":"string","description":"ISO time."},"resources":{"type":"array","items":{"type":"string","pattern":"^(robot|effector|printer|station|person):.+"},"description":"What it needs exclusively, like effector:bot-1:arm. Two tasks sharing one never run at once."},"depends_on":{"type":"array","items":{"type":"integer","minimum":0},"description":"Positions of EARLIER tasks in this list that must succeed first."}},"additionalProperties":false},"minItems":1,"maxItems":50},"on_failure":{"type":"string","enum":["abort","retry","ranger","person"]},"robot_id":{"type":"string","description":"Test keys default to zs_test_robot."},"on_event":{"type":"string","minLength":1,"maxLength":120},"cron":{"type":"string","maxLength":100}},"required":["name","goal"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"object":{"type":"string","enum":["template"]},"name":{"type":"string"},"on_event":{"type":"string"},"cron":{"type":"string"},"next_run":{"type":"string"}}}}}}}}},"/v1/needs":{"get":{"operationId":"needs_list","summary":"List what needs you","description":"Work that stopped and waits for a person: a task of a job whose failure policy is 'person'. Each item has the job's goal, the robot, why the run failed and its last events. Answer with needs.hint, needs.retry or needs.abort. Oldest first; an item leaves the list once it is answered or its job is cancelled.","x-zeroshot-action":"needs.list","x-zeroshot-mcp-tool":"zeroshot_needs_list","security":[{"session":[]},{"apiKey":["tasks:read"]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"object","properties":{"object":{"type":"string","enum":["need"]},"id":{"type":"string","format":"uuid","description":"The waiting task: what hint, retry and abort take."},"job_id":{"type":"string","format":"uuid"},"goal":{"type":"string","description":"What the job was asked to do."},"instruction":{"type":"string","description":"This task's own instruction."},"robot_id":{"type":"string"},"attempt":{"type":"integer"},"reason":{"type":"string","description":"Why the run that failed ended."},"failed_outcome":{"type":"string"},"since":{"type":"string"},"events":{"type":"array","description":"The last events of the failed run, oldest first.","items":{"type":"object","properties":{"seq":{"type":"integer"},"kind":{"type":"string"},"call":{"type":"object"},"result":{"type":"object"},"created":{"type":"string"}}}}}}}}}}}}}}},"/v1/needs/{id}/hint":{"post":{"operationId":"needs_hint","summary":"Give Ranger a hint","description":"Answers an item with a hint in plain words. The waiting task ends and goes back to the queue for Ranger with your hint attached to its instruction, keeping its place in the job. Returns the job. If it fails again it comes back to you.","x-zeroshot-action":"needs.hint","x-zeroshot-mcp-tool":"zeroshot_needs_hint","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The item id from needs.list."},"hint":{"type":"string","minLength":1,"maxLength":2000,"description":"What Ranger should know or do differently."},"remember":{"type":"boolean","description":"Also save the hint as a memory of your account (memory.list), so later runs can recall it. Default false."}},"required":["id","hint"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/needs/{id}/retry":{"post":{"operationId":"needs_retry","summary":"Retry what needs you","description":"Answers an item by sending the task back to the queue for Ranger exactly as it was. Returns the job.","x-zeroshot-action":"needs.retry","x-zeroshot-mcp-tool":"zeroshot_needs_retry","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The item id from needs.list."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/needs/{id}/abort":{"post":{"operationId":"needs_abort","summary":"Abort what needs you","description":"Answers an item by stopping the job: the waiting task and every unfinished task of the job are cancelled, and any credit held for them is given back. Returns the job.","x-zeroshot-action":"needs.abort","x-zeroshot-mcp-tool":"zeroshot_needs_abort","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The item id from needs.list."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/jobs/{id}/routine":{"post":{"operationId":"routine_save_from_job","summary":"Save a run as a routine","description":"Turns a job that succeeded into a saved routine (a job template) so it can run again: the tasks that finished it, their order and resources, and any hint a person gave. Give on_event to run it whenever that event is sent, and/or cron (five fields, UTC) to run it on a schedule. Only a job that succeeded can be saved; any other is refused with the reason. Saving the same job twice returns the first routine.","x-zeroshot-action":"routine.save_from_job","x-zeroshot-mcp-tool":"zeroshot_routine_save_from_job","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The job id from work.submit."},"name":{"type":"string","minLength":1,"maxLength":120},"on_event":{"type":"string","minLength":1,"maxLength":120},"cron":{"type":"string","maxLength":100}},"required":["id","name"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"object":{"type":"string","enum":["template"]},"name":{"type":"string"},"job_id":{"type":"string"},"already_saved":{"type":"boolean","description":"True when this job had been saved before."}}}}}}}}},"/v1/memories":{"get":{"operationId":"memory_list","summary":"List what the system remembers","description":"The memories of your account, newest first: what the system learned from runs, takeovers and hints, each with the task and job it came from. Give robot_id to see that robot's memories and the ones that hold for the whole account. Retired memories are left out unless include_retired is 'true'.","x-zeroshot-action":"memory.list","x-zeroshot-mcp-tool":"zeroshot_memory_list","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"robot_id","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":100}},{"name":"kind","in":"query","required":false,"schema":{"type":"string","enum":["run","takeover","hint","import"]}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"description":"Default 50."}},{"name":"include_retired","in":"query","required":false,"schema":{"type":"string","enum":["true","false"]}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"object","properties":{"object":{"type":"string","enum":["memory"]},"id":{"type":"string","format":"uuid"},"kind":{"type":"string","enum":["run","takeover","hint","import"],"description":"run, takeover, hint or import."},"text":{"type":"string"},"robot_id":{"type":"string","description":"Absent for a memory that holds for the whole account."},"source_task_id":{"type":"string"},"source_job_id":{"type":"string"},"created_at":{"type":"string"},"retired_at":{"type":"string"}}}}}}}}}}},"post":{"operationId":"memory_add","summary":"Teach the system something","description":"Saves a short note (1 to 2000 characters) the system should know from now on. Kind defaults to 'hint'; use 'import' for knowledge brought in. Give robot_id when it holds for one robot only. source_task_id and source_job_id must be yours. Saving the same text again returns the first memory. Do not save secrets or customer data.","x-zeroshot-action":"memory.add","x-zeroshot-mcp-tool":"zeroshot_memory_add","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","minLength":1,"maxLength":2000},"kind":{"type":"string","enum":["run","takeover","hint","import"]},"robot_id":{"type":"string","minLength":1,"maxLength":100},"source_task_id":{"type":"string","format":"uuid"},"source_job_id":{"type":"string","format":"uuid"}},"required":["text"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["memory"]},"id":{"type":"string","format":"uuid"},"kind":{"type":"string","enum":["run","takeover","hint","import"],"description":"run, takeover, hint or import."},"text":{"type":"string"},"robot_id":{"type":"string","description":"Absent for a memory that holds for the whole account."},"source_task_id":{"type":"string"},"source_job_id":{"type":"string"},"created_at":{"type":"string"},"retired_at":{"type":"string"}}}}}}}}},"/v1/memories/search":{"get":{"operationId":"memory_search","summary":"Search what the system remembers","description":"Full-text search over the active memories of your account, best match first. Plain words match any form of the word; use quotes for a phrase, 'or' between alternatives and a leading - to exclude.","x-zeroshot-action":"memory.search","x-zeroshot-mcp-tool":"zeroshot_memory_search","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":500,"description":"What to look for."}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":50,"description":"Default 10."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"object","properties":{"object":{"type":"string","enum":["memory"]},"id":{"type":"string","format":"uuid"},"kind":{"type":"string","enum":["run","takeover","hint","import"],"description":"run, takeover, hint or import."},"text":{"type":"string"},"robot_id":{"type":"string","description":"Absent for a memory that holds for the whole account."},"source_task_id":{"type":"string"},"source_job_id":{"type":"string"},"created_at":{"type":"string"},"retired_at":{"type":"string"}}}}}}}}}}}},"/v1/memories/{id}/retire":{"post":{"operationId":"memory_retire","summary":"Make the system forget a memory","description":"Retires a memory: it no longer shows in list or search and is no longer recalled. The record stays, marked retired. Retiring a retired memory changes nothing. Returns the memory.","x-zeroshot-action":"memory.retire","x-zeroshot-mcp-tool":"zeroshot_memory_retire","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The id from memory.list."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["memory"]},"id":{"type":"string","format":"uuid"},"kind":{"type":"string","enum":["run","takeover","hint","import"],"description":"run, takeover, hint or import."},"text":{"type":"string"},"robot_id":{"type":"string","description":"Absent for a memory that holds for the whole account."},"source_task_id":{"type":"string"},"source_job_id":{"type":"string"},"created_at":{"type":"string"},"retired_at":{"type":"string"}}}}}}}}},"/v1/memories/recall":{"get":{"operationId":"memory_recall","summary":"Recall what bears on a goal","description":"What the agent runner is given before a run: at most five short memories of your account that bear on the goal or situation you describe, best match first. Empty when nothing matches. Never another account's. The cloud records the recall in each dispatched run's log (stage context).","x-zeroshot-action":"memory.recall","x-zeroshot-mcp-tool":"zeroshot_memory_recall","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"context","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":2000,"description":"The goal or situation, in plain words."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"string"}}}}}}}}}},"/v1/applications":{"get":{"operationId":"applications_list","summary":"List applications","description":"The first-party application catalog, each with what it adds (tools, events, operation kinds), the scopes it asks for, and, if this account installed it, when and with which scopes. Applications marked 'coming' cannot be installed yet. A price is shown for information; installing never charges.","x-zeroshot-action":"applications.list","x-zeroshot-mcp-tool":"zeroshot_applications_list","security":[{"session":[]},{"apiKey":["account:read"]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"object","properties":{"object":{"type":"string","enum":["application"]},"id":{"type":"string"},"name":{"type":"string"},"publisher":{"type":"string"},"version":{"type":"string"},"summary":{"type":"string"},"availability":{"type":"string","enum":["available","coming"],"description":"'coming' applications are listed but cannot be installed yet."},"scopes":{"type":"array","items":{"type":"string"},"description":"What it asks to be allowed to do."},"tools":{"type":"array","items":{"type":"string"}},"events":{"type":"array","items":{"type":"string"}},"op_kinds":{"type":"array","items":{"type":"string"}},"executor":{"type":"string","description":"The Work executor its operations run on, app:<name>."},"templates":{"type":"array","items":{"type":"object"}},"pages":{"type":"array","items":{"type":"object"}},"human_ops":{"type":"object","description":"Human help that comes included, if any."},"price":{"type":"string","description":"A price id or 'contact'. Shown only; installing never charges."},"installed":{"type":"object","properties":{"status":{"type":"string","enum":["installed","removed"]},"manifest_version":{"type":"string"},"granted_scopes":{"type":"array","items":{"type":"string"}},"human_ops":{"type":"boolean","description":"Staff can see this account's needs-you items while this is installed."},"installed_by":{"type":"string"},"installed_at":{"type":"string"},"removed_at":{"type":"string"}}}}}}}}}}}}}},"/v1/applications/{id}/install":{"post":{"operationId":"applications_install","summary":"Install an application","description":"Installs a catalog application for this account and records which of the scopes it asks for you agree to give it. 'scopes' must be listed explicitly (an empty list gives it none) and may not include anything the application does not ask for. An application with a price is added to the organization plan's subscription (the plan must be active; only the owner or a live key may install it); one marked 'coming' or turnkey-only is refused. Give robot_id (and printer_id for Print Farm) to also create its job templates, like clear and restart on print.finished. Returns the application with its install record and the templates made.","x-zeroshot-action":"applications.install","x-zeroshot-mcp-tool":"zeroshot_applications_install","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","minLength":3,"maxLength":40,"description":"The application id from applications.list."},"scopes":{"type":"array","maxItems":20,"items":{"type":"string"},"description":"The scopes you grant, a subset of the application's scopes."},"robot_id":{"type":"string","description":"The robot its templates run on (test keys default to zs_test_robot)."},"printer_id":{"type":"string","description":"The printer its templates use (Print Farm)."}},"required":["id","scopes"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["application"]},"id":{"type":"string"},"name":{"type":"string"},"publisher":{"type":"string"},"version":{"type":"string"},"summary":{"type":"string"},"availability":{"type":"string","enum":["available","coming"],"description":"'coming' applications are listed but cannot be installed yet."},"scopes":{"type":"array","items":{"type":"string"},"description":"What it asks to be allowed to do."},"tools":{"type":"array","items":{"type":"string"}},"events":{"type":"array","items":{"type":"string"}},"op_kinds":{"type":"array","items":{"type":"string"}},"executor":{"type":"string","description":"The Work executor its operations run on, app:<name>."},"templates":{"type":"array","items":{"type":"object"}},"pages":{"type":"array","items":{"type":"object"}},"human_ops":{"type":"object","description":"Human help that comes included, if any."},"price":{"type":"string","description":"A price id or 'contact'. Shown only; installing never charges."},"installed":{"type":"object","properties":{"status":{"type":"string","enum":["installed","removed"]},"manifest_version":{"type":"string"},"granted_scopes":{"type":"array","items":{"type":"string"}},"human_ops":{"type":"boolean","description":"Staff can see this account's needs-you items while this is installed."},"installed_by":{"type":"string"},"installed_at":{"type":"string"},"removed_at":{"type":"string"}}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Error: plan_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_role, not_org_owner","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Error: billing_unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/applications/{id}/uninstall":{"post":{"operationId":"applications_uninstall","summary":"Uninstall an application","description":"Removes an installed application from this account. Its scopes are no longer granted, its job templates and their triggers are removed, it leaves the plan's subscription if it had a price (Stripe prorates), and, if it included human help, staff can no longer see this account's needs-you items.","x-zeroshot-action":"applications.uninstall","x-zeroshot-mcp-tool":"zeroshot_applications_uninstall","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","minLength":3,"maxLength":40,"description":"The application id from applications.list."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["application"]},"id":{"type":"string"},"name":{"type":"string"},"publisher":{"type":"string"},"version":{"type":"string"},"summary":{"type":"string"},"availability":{"type":"string","enum":["available","coming"],"description":"'coming' applications are listed but cannot be installed yet."},"scopes":{"type":"array","items":{"type":"string"},"description":"What it asks to be allowed to do."},"tools":{"type":"array","items":{"type":"string"}},"events":{"type":"array","items":{"type":"string"}},"op_kinds":{"type":"array","items":{"type":"string"}},"executor":{"type":"string","description":"The Work executor its operations run on, app:<name>."},"templates":{"type":"array","items":{"type":"object"}},"pages":{"type":"array","items":{"type":"object"}},"human_ops":{"type":"object","description":"Human help that comes included, if any."},"price":{"type":"string","description":"A price id or 'contact'. Shown only; installing never charges."},"installed":{"type":"object","properties":{"status":{"type":"string","enum":["installed","removed"]},"manifest_version":{"type":"string"},"granted_scopes":{"type":"array","items":{"type":"string"}},"human_ops":{"type":"boolean","description":"Staff can see this account's needs-you items while this is installed."},"installed_by":{"type":"string"},"installed_at":{"type":"string"},"removed_at":{"type":"string"}}}}}}}},"403":{"description":"Error: insufficient_role, not_org_owner","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Error: billing_unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/applications/{id}/events":{"post":{"operationId":"applications_emit","summary":"Send an application's event","description":"An installed application says something happened (Print Farm: print.finished, print.failed). Every job template triggered by that event submits a job, like clear and restart. Only events the application declares are taken. Returns the new job ids; none if nothing listens.","x-zeroshot-action":"applications.emit","x-zeroshot-mcp-tool":"zeroshot_applications_emit","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","minLength":3,"maxLength":40,"description":"The application id from applications.list."},"event":{"type":"string","minLength":3,"maxLength":120,"description":"Like print.finished."}},"required":["id","event"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"string"}}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/applications/{id}/lease":{"post":{"operationId":"applications_lease","summary":"Take the next operation for an application","description":"For the application's executor (the robot plugin or service that runs its operations): the next ready task of this application in this account, leased to the caller, or null when nothing is ready. Tasks wait for their dependencies and their resources (a printer is never run by two at once). The lease lasts lease_ttl_s: while the operation runs, keep it with applications.heartbeat (about every third of that), and stop if the heartbeat says it is lost, cancelled or ended. Report the result with applications.complete and the lease token.","x-zeroshot-action":"applications.lease","x-zeroshot-mcp-tool":"zeroshot_applications_lease","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","minLength":3,"maxLength":40,"description":"The application id from applications.list."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["app_task"]},"task_id":{"type":"string"},"job_id":{"type":"string"},"executor":{"type":"string"},"op":{"type":"string"},"input":{"type":"object"},"robot_id":{"type":"string"},"lease_token":{"type":"string"},"lease_ttl_s":{"type":"integer","description":"Seconds the lease lasts unless kept with applications.heartbeat."},"attempt":{"type":"integer"}}}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/applications/{id}/tasks/{task_id}/heartbeat":{"post":{"operationId":"applications_heartbeat","summary":"Keep an application operation's lease","description":"The executor that leased a task says it is still running it, which extends the lease by lease_ttl_s. Send it about every third of lease_ttl_s while the operation runs. status 'ok' means keep going; 'lost' (the lease expired or another executor took the task), 'cancelled' or 'ended' means stop now and do not complete it. Never charged.","x-zeroshot-action":"applications.heartbeat","x-zeroshot-mcp-tool":"zeroshot_applications_heartbeat","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","minLength":3,"maxLength":40,"description":"The application id from applications.list."},"task_id":{"type":"string","format":"uuid"},"lease_token":{"type":"string","format":"uuid"}},"required":["id","task_id","lease_token"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"task_id":{"type":"string"},"status":{"type":"string","enum":["ok","lost","cancelled","ended"]},"lease_ttl_s":{"type":"integer"}}}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/applications/{id}/tasks/{task_id}/complete":{"post":{"operationId":"applications_complete","summary":"Report how an application's operation ended","description":"The executor that leased a task says it succeeded or failed (with why). A failure follows the job's policy (retry, escalate, abort). Never charged. Safe to repeat; a lost lease is refused.","x-zeroshot-action":"applications.complete","x-zeroshot-mcp-tool":"zeroshot_applications_complete","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","minLength":3,"maxLength":40,"description":"The application id from applications.list."},"task_id":{"type":"string","format":"uuid"},"lease_token":{"type":"string","format":"uuid"},"outcome":{"type":"string","enum":["succeeded","failed"]},"reason":{"type":"string","maxLength":2000}},"required":["id","task_id","lease_token","outcome"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"task_id":{"type":"string"},"outcome":{"type":"string"},"again":{"type":"boolean"}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/applications/print-farm/ops/printer.start":{"post":{"operationId":"print_farm_printer_start","summary":"print-farm: printer.start","description":"Start a print on a printer. Queues a job with one task for print-farm's executor (app:print_farm), which runs it on the robot that hosts the application and reports back; read it with zeroshot_work_get. Only for accounts that installed print-farm. Never charged per task.","x-zeroshot-action":"print_farm.printer_start","x-zeroshot-mcp-tool":"zeroshot_print_farm_printer_start","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"printer_id":{"type":"string","description":"The printer, as the robot's Print Farm plugin names it."},"file_id":{"type":"string","description":"The file to print."},"robot_id":{"type":"string","description":"The robot that hosts print-farm. Test keys default to zs_test_robot."}},"required":["printer_id","file_id"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","description":"The job, as zeroshot_work_get shows it."}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found, robot_not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/applications/print-farm/ops/printer.pause":{"post":{"operationId":"print_farm_printer_pause","summary":"print-farm: printer.pause","description":"Pause the print running on a printer. Queues a job with one task for print-farm's executor (app:print_farm), which runs it on the robot that hosts the application and reports back; read it with zeroshot_work_get. Only for accounts that installed print-farm. Never charged per task.","x-zeroshot-action":"print_farm.printer_pause","x-zeroshot-mcp-tool":"zeroshot_print_farm_printer_pause","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"printer_id":{"type":"string","description":"The printer, as the robot's Print Farm plugin names it."},"robot_id":{"type":"string","description":"The robot that hosts print-farm. Test keys default to zs_test_robot."}},"required":["printer_id"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","description":"The job, as zeroshot_work_get shows it."}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found, robot_not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/applications/print-farm/ops/printer.status":{"post":{"operationId":"print_farm_printer_status","summary":"print-farm: printer.status","description":"Read a printer's status. Queues a job with one task for print-farm's executor (app:print_farm), which runs it on the robot that hosts the application and reports back; read it with zeroshot_work_get. Only for accounts that installed print-farm. Never charged per task.","x-zeroshot-action":"print_farm.printer_status","x-zeroshot-mcp-tool":"zeroshot_print_farm_printer_status","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"printer_id":{"type":"string","description":"The printer, as the robot's Print Farm plugin names it."},"robot_id":{"type":"string","description":"The robot that hosts print-farm. Test keys default to zs_test_robot."}},"required":["printer_id"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","description":"The job, as zeroshot_work_get shows it."}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found, robot_not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/applications/print-farm/ops/printer.check_bed":{"post":{"operationId":"print_farm_printer_check_bed","summary":"print-farm: printer.check_bed","description":"Check whether a printer's bed is clear. Queues a job with one task for print-farm's executor (app:print_farm), which runs it on the robot that hosts the application and reports back; read it with zeroshot_work_get. Only for accounts that installed print-farm. Never charged per task.","x-zeroshot-action":"print_farm.printer_check_bed","x-zeroshot-mcp-tool":"zeroshot_print_farm_printer_check_bed","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"printer_id":{"type":"string","description":"The printer, as the robot's Print Farm plugin names it."},"robot_id":{"type":"string","description":"The robot that hosts print-farm. Test keys default to zs_test_robot."}},"required":["printer_id"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","description":"The job, as zeroshot_work_get shows it."}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: not_found, robot_not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/controls":{"get":{"operationId":"controls_get","summary":"Read controls","description":"The controls of a robot (give robot_id) or of a task (give task_id, from work.get). For a robot: 'controls' is what was set on it and 'effective' the value each control has, from its default or the built-in default. For a task: its effective controls, its own override first, then its robot's default, then the built-in default; a retried task keeps the override of the task it replaced. Give one of robot_id and task_id. Test keys may leave both out to read zs_test_robot.","x-zeroshot-action":"controls.get","x-zeroshot-mcp-tool":"zeroshot_controls_get","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"robot_id","in":"query","required":false,"schema":{"type":"string","description":"A robot from zeroshot_robots_list."}},{"name":"task_id","in":"query","required":false,"schema":{"type":"string","format":"uuid","description":"A task id from work.get."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["controls"]},"robot_id":{"type":"string"},"task_id":{"type":"string"},"job_id":{"type":"string"},"controls":{"type":"object","description":"What was set on the robot (robot reads only)."},"effective":{"type":"object","description":"Every control as { value, source }, source being task, robot or default."}}}}}}}},"post":{"operationId":"controls_set","summary":"Set a robot's default controls","description":"Changes the default controls of a robot: what every task on it uses unless the task has its own override (controls.set_for_job). Send only the controls to change; the rest are kept. Name a control in 'clear' to unset it. recovery = retry needs recovery_retries. Returns the robot's controls. Needs a key that can manage the account, because these limits keep the robot safe.","x-zeroshot-action":"controls.set","x-zeroshot-mcp-tool":"zeroshot_controls_set","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"robot_id":{"type":"string","description":"A robot from zeroshot_robots_list. Test keys default to zs_test_robot."},"speed":{"type":"number","minimum":0.05,"maximum":1,"description":"Share of full speed, 0.05 to 1.0."},"reach":{"type":"object","description":"The box the gripper may stay in, in metres from the robot base: min and max as [x, y, z], each from -3 to 3, min below max.","properties":{"min":{"type":"array","items":{"type":"number"},"minItems":3,"maxItems":3},"max":{"type":"array","items":{"type":"number"},"minItems":3,"maxItems":3}},"required":["min","max"],"additionalProperties":false},"force_limit_n":{"type":"number","minimum":0,"maximum":200,"description":"Most force the robot may use, in newtons (above 0, up to 200)."},"done_criteria":{"type":"string","minLength":1,"maxLength":1000,"description":"What counts as done, in plain words."},"recovery":{"type":"string","enum":["recover","retry","person"],"description":"When a step fails: recover on its own, retry the task recovery_retries times, or hand to a person."},"recovery_retries":{"type":"integer","minimum":1,"maximum":10,"description":"How many retries; only with recovery = retry (required then)."},"give_up_active_s":{"type":"integer","minimum":1,"maximum":86400,"description":"Active seconds before the robot gives up."},"give_up_failed_tries":{"type":"integer","minimum":1,"maximum":100,"description":"Failed tries before the robot gives up."},"clear":{"type":"array","items":{"type":"string","enum":["speed","reach","force_limit_n","done_criteria","recovery","recovery_retries","give_up_active_s","give_up_failed_tries"]},"description":"Controls to unset, so they fall back to the next layer."}},"required":[],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["controls"]},"robot_id":{"type":"string"},"controls":{"type":"object"},"effective":{"type":"object","description":"Every control as { value, source }, source being task, robot or default."}}}}}}}}},"/v1/jobs/{id}/controls":{"post":{"operationId":"controls_set_for_job","summary":"Set controls for one job","description":"Overrides controls for the unfinished tasks of one job, over the robot's defaults. Send only the controls to change; name a control in 'clear' to drop the override. A task a retry or a hint adds later keeps the override. A job that is cancelled or already finished is refused with the reason. Returns how many tasks were changed; read the result with controls.get and a task id.","x-zeroshot-action":"controls.set_for_job","x-zeroshot-mcp-tool":"zeroshot_controls_set_for_job","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The job id from work.submit."},"speed":{"type":"number","minimum":0.05,"maximum":1,"description":"Share of full speed, 0.05 to 1.0."},"reach":{"type":"object","description":"The box the gripper may stay in, in metres from the robot base: min and max as [x, y, z], each from -3 to 3, min below max.","properties":{"min":{"type":"array","items":{"type":"number"},"minItems":3,"maxItems":3},"max":{"type":"array","items":{"type":"number"},"minItems":3,"maxItems":3}},"required":["min","max"],"additionalProperties":false},"force_limit_n":{"type":"number","minimum":0,"maximum":200,"description":"Most force the robot may use, in newtons (above 0, up to 200)."},"done_criteria":{"type":"string","minLength":1,"maxLength":1000,"description":"What counts as done, in plain words."},"recovery":{"type":"string","enum":["recover","retry","person"],"description":"When a step fails: recover on its own, retry the task recovery_retries times, or hand to a person."},"recovery_retries":{"type":"integer","minimum":1,"maximum":10,"description":"How many retries; only with recovery = retry (required then)."},"give_up_active_s":{"type":"integer","minimum":1,"maximum":86400,"description":"Active seconds before the robot gives up."},"give_up_failed_tries":{"type":"integer","minimum":1,"maximum":100,"description":"Failed tries before the robot gives up."},"clear":{"type":"array","items":{"type":"string","enum":["speed","reach","force_limit_n","done_criteria","recovery","recovery_retries","give_up_active_s","give_up_failed_tries"]},"description":"Controls to unset, so they fall back to the next layer."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["job_controls"]},"job_id":{"type":"string"},"tasks":{"type":"integer","description":"How many unfinished tasks now carry the override."}}}}}}}}},"/v1/controls/effective":{"get":{"operationId":"controls_effective","summary":"The controls a run gets","description":"The effective value of every control, each with where it came from (task, robot or default): for a task (task_id), its own override, then its robot's default, then the built-in one; for a robot alone (robot_id), its default then the built-in one. This is what the agent runner and the robot read before a run; the cloud records it in each dispatched run's log (stage context).","x-zeroshot-action":"controls.effective","x-zeroshot-mcp-tool":"zeroshot_controls_effective","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"robot_id","in":"query","required":false,"schema":{"type":"string","description":"A robot from zeroshot_robots_list."}},{"name":"task_id","in":"query","required":false,"schema":{"type":"string","format":"uuid","description":"A task id from work.get."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["effective_controls"]},"robot_id":{"type":"string"},"task_id":{"type":"string"},"effective":{"type":"object","description":"Every control as { value, source }, source being task, robot or default."}}}}}}}}},"/v1/routines":{"get":{"operationId":"routine_list","summary":"List saved routines","description":"The account's saved routines (in this key's mode), newest first, each with how many times it ran, how many of those runs succeeded and when it last ran. Retired routines are not listed. Run one with routine.run; save one with routine.save_from_job.","x-zeroshot-action":"routine.list","x-zeroshot-mcp-tool":"zeroshot_routine_list","security":[{"session":[]},{"apiKey":["tasks:read"]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"object","properties":{"object":{"type":"string","enum":["routine"]},"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"goal":{"type":"string"},"robot_id":{"type":"string"},"tasks":{"type":"integer","description":"How many tasks a run has."},"on_events":{"type":"array","items":{"type":"string"}},"crons":{"type":"array","items":{"type":"string"}},"run_count":{"type":"integer"},"success_count":{"type":"integer","description":"Runs whose every task succeeded."},"last_run_at":{"type":"string"},"created":{"type":"string"}}}}}}}}}}}},"/v1/routines/{id}/run":{"post":{"operationId":"routine_run","summary":"Run a saved routine now","description":"Queues a new job from the routine's template right away, on the robot it was saved for, and returns the job (read it with work.get). A routine that was retired or does not exist is refused with the reason.","x-zeroshot-action":"routine.run","x-zeroshot-mcp-tool":"zeroshot_routine_run","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The routine id from routine.list."}},"required":["id"],"additionalProperties":false}}}},"responses":{"201":{"description":"The result.","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/routines/{id}/retire":{"post":{"operationId":"routine_retire","summary":"Retire a saved routine","description":"Stops a routine: it leaves routine.list, cannot be run, and its event triggers and schedules are removed. Jobs it already ran are kept. Safe to repeat.","x-zeroshot-action":"routine.retire","x-zeroshot-mcp-tool":"zeroshot_routine_retire","security":[{"session":[]},{"apiKey":["tasks:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The routine id from routine.list."}},"required":["id"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["routine"]},"id":{"type":"string"},"retired":{"type":"boolean"}}}}}}}}},"/v1/robots/{id}/dispatch":{"get":{"operationId":"robots_get_dispatch","summary":"Does a robot accept tasks from the cloud?","description":"Reads a robot's switch for tasks the cloud starts. Off by default: a queued task waits until a person turns it on for that robot. Returns accept_remote.","x-zeroshot-action":"robots.get_dispatch","x-zeroshot-mcp-tool":"zeroshot_robots_get_dispatch","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":100,"description":"A live robot from zeroshot_robots_list."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["robot_dispatch"]},"robot_id":{"type":"string"},"accept_remote":{"type":"boolean","description":"True when tasks sent from the app, API or MCP may start this robot's arm."}}}}}}}},"post":{"operationId":"robots_set_dispatch","summary":"Let a robot accept tasks from the cloud, or stop it","description":"Turns the switch on or off for one robot. While on, queued live tasks for this robot start its harness without anyone at the arm: switch it on only for a robot you are happy to run unattended. The robot's own safety limits and its emergency stop apply either way. Needs access that can manage the account. Returns accept_remote.","x-zeroshot-action":"robots.set_dispatch","x-zeroshot-mcp-tool":"zeroshot_robots_set_dispatch","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":100,"description":"A live robot from zeroshot_robots_list."},"accept_remote":{"type":"boolean","description":"true to accept cloud tasks, false to stop."}},"required":["id","accept_remote"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["robot_dispatch"]},"robot_id":{"type":"string"},"accept_remote":{"type":"boolean","description":"True when tasks sent from the app, API or MCP may start this robot's arm."}}}}}}}}},"/v1/robots/{id}/loop":{"get":{"operationId":"robots_get_loop","summary":"Which agent loop runs a robot's tasks","description":"Reads which loop runs the tasks the cloud starts on this robot: `harness` (the robot's own harness, the default) or `cloud` (the cloud agent runner calls the robot's tools step by step). Returns loop.","x-zeroshot-action":"robots.get_loop","x-zeroshot-mcp-tool":"zeroshot_robots_get_loop","security":[{"session":[]},{"apiKey":["tasks:read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":100,"description":"A live robot from zeroshot_robots_list."}}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["robot_loop"]},"robot_id":{"type":"string"},"loop":{"type":"string","enum":["harness","cloud"],"description":"harness: the robot's own harness runs each task (the default). cloud: the cloud agent runner drives the robot step by step and judges success itself."}}}}}}}},"post":{"operationId":"robots_set_loop","summary":"Choose which agent loop runs a robot's tasks","description":"Sets the loop for one robot. `harness` (the default) hands each task to the robot's own harness. `cloud` lets the cloud agent runner drive the robot's tools step by step and settle each task on its own check; the robot needs its tools switched on for that. Either way, a task starts on the robot only while its accept-remote switch (zeroshot_robots_set_dispatch) is on. Only the account's owner can change it. `cloud` answers robot_dispatch_unavailable while no cloud runner is serving. Returns loop.","x-zeroshot-action":"robots.set_loop","x-zeroshot-mcp-tool":"zeroshot_robots_set_loop","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":100,"description":"A live robot from zeroshot_robots_list."},"loop":{"type":"string","enum":["harness","cloud"],"description":"harness or cloud."}},"required":["id","loop"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["robot_loop"]},"robot_id":{"type":"string"},"loop":{"type":"string","enum":["harness","cloud"],"description":"harness: the robot's own harness runs each task (the default). cloud: the cloud agent runner drives the robot step by step and judges success itself."}}}}}},"404":{"description":"Error: robot_not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Error: robot_dispatch_unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/staff/needs":{"get":{"operationId":"staff_needs_list","summary":"List Human Operations needs (staff)","description":"Staff only. Every open needs-you item (live mode) of every organization that has an installed application including human operations, oldest first, each with its org_id. Organizations without one are never shown.","x-zeroshot-action":"staff.needs_list","x-zeroshot-mcp-tool":"zeroshot_staff_needs_list","security":[{"session":[]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["list"]},"data":{"type":"array","items":{"type":"object"}}}}}}},"401":{"description":"Error: authentication_required, sign_in_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: staff_only","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/data-use":{"get":{"operationId":"data_use_get","summary":"Read data use","description":"Whether ZeroShot may learn from this organization's runs ('Improve ZeroShot'), where that comes from, and each robot that overrides it. Off until someone in the organization turns it on. Admins and the owner only.","x-zeroshot-action":"data_use.get","x-zeroshot-mcp-tool":"zeroshot_data_use_get","security":[{"session":[]},{"apiKey":["account:read"]}],"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["data_use"]},"improve_zeroshot":{"type":"boolean","description":"Whether ZeroShot may learn from this organization's runs."},"source":{"type":"string","enum":["org","default"],"description":"'default' until someone in the organization chooses."},"updated_at":{"type":"string"},"robots":{"type":"array","items":{"type":"object","properties":{"robot_id":{"type":"string"},"improve_zeroshot":{"type":"boolean"},"updated_at":{"type":"string"}}},"description":"Robots that override the organization's choice."}}}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, insufficient_role, not_org_member","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"data_use_set","summary":"Set data use","description":"Turn learning from this organization's runs on or off (improve_zeroshot true or false), or, with robot_id, override it for one robot (null clears the override so the robot follows the organization). Every change is recorded with who made it. Admins and the owner only; a test key cannot change it.","x-zeroshot-action":"data_use.set","x-zeroshot-mcp-tool":"zeroshot_data_use_set","security":[{"session":[]},{"apiKey":["account:write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"robot_id":{"type":"string","description":"A robot from zeroshot_robots_list; absent for the organization."},"improve_zeroshot":{"type":["boolean","null"],"description":"true or false; null only with robot_id, to clear its override."}},"required":["improve_zeroshot"],"additionalProperties":false}}}},"responses":{"200":{"description":"The result.","content":{"application/json":{"schema":{"type":"object","properties":{"object":{"type":"string","enum":["data_use"]},"improve_zeroshot":{"type":"boolean","description":"Whether ZeroShot may learn from this organization's runs."},"source":{"type":"string","enum":["org","default"],"description":"'default' until someone in the organization chooses."},"updated_at":{"type":"string"},"robots":{"type":"array","items":{"type":"object","properties":{"robot_id":{"type":"string"},"improve_zeroshot":{"type":"boolean"},"updated_at":{"type":"string"}}},"description":"Robots that override the organization's choice."}}}}}},"400":{"description":"Error: invalid_request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error: authentication_required","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error: insufficient_scope, insufficient_role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error: robot_not_found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}