API Reference
This page documents the HTTP API you use to build against Tietai: how a request reaches a service, how to authenticate, and the workflow engine endpoints for pipelines, executions, agents, the node catalog, connectors, LLM models and the copilot.
Every endpoint and field below was read from the gateway and service source. The examples are not captured from a live server: treat the response bodies as the shape, not as recorded output.
How requests reach a service
All traffic goes through the API gateway. A request has the form:
https://<api-host>/api/v1/<service>/<path>
The gateway maps <service> to a backend and rewrites the path. For the workflow engine the service name is hydra-platform, and /api/v1/hydra-platform/<path> is forwarded to the workflow engine as /api/<path>. So the workflow route /api/pipelines is public as:
https://<api-host>/api/v1/hydra-platform/pipelines
<api-host> is the API host of your deployment (the agent API tab in the product uses https://api.tiet.ai). Every workflow engine path in this page is shown relative to /api/v1/hydra-platform.
Other services use the same pattern with their own prefix. Bare prefixes such as /api/v1/pipelines, /api/v1/agents and /api/v1/llm-models go to the older agentic service, not to the workflow engine. FHIR is reached at /api/v1/fhir/<path>, which the gateway forwards to the FHIR service as /fhir/<path>. See FHIR interoperability.
Authentication
Send a Bearer token on every request:
Authorization: Bearer <token>
Two kinds of token are accepted by the gateway:
| Token | How the gateway recognizes it | Where you get it |
|---|---|---|
| User JWT | Contains dots | Signing in to the product |
| API token | No dots (a tia_m2m_... string) | Admin Console, Platform, API Tokens (see API tokens) |
X-Organization-ID is optional. The organization comes from the token. If you send the header, the gateway checks that the caller is a member of that organization and answers 403 with {"detail":"forbidden: not a member of the requested organization"} if not. An API token is bound to the organization that created it.
The workflow engine validates API tokens itself, and only on specific routes. In the source I read, those are POST /execute (scope pipeline:{id}:execute or pipelines:execute) and POST /v1/agents/{id}/invoke (scope agent:{id}:execute), plus the manifest, instance and deployment routes. Every other route in this page (pipelines, agents, executions, connectors, LLM models, copilot) expects a user JWT. An API token sent there gets 401 {"error":"unauthorized: invalid token"}.
Public paths
These workflow engine paths need no gateway authentication:
Path (under /api/v1/hydra-platform) | Note |
|---|---|
health | Health check |
node-catalog and everything below it | Node type metadata. The node-catalog/datasource/... routes still need a JWT, because the workflow engine enforces that itself |
v1/agents/ | The public agent invoke endpoint. The workflow engine checks the API key itself |
files/, uploaded-files/ | Generated report downloads and uploaded attachments |
A few other paths are public because their callers cannot hold a token and authenticate in their own way: voice-call and messaging webhooks, the patient 3D imaging share page (public/exhibit-shares/, where the share token in the path is the credential) and read-only imaging-viewer routes under conversations/.../exhibits/. They are not for general use.
Versioning
The version is the v1 in /api/v1/. The gateway configuration lists X-API-Version as a version header, but I found no code that reads it, so do not rely on it. Inside the workflow engine only the agent invoke and trace routes carry a v1 segment.
Rate limits
Two limits apply:
- Gateway: 600 requests per minute, counted per organization and client IP, by default. The organization's API security settings can change this: the Enable rate limiting switch on Security in the Admin Console turns the gateway limit off for the organization, and a stored
requests_per_minutevalue replaces 600 (the Admin Console has no field for that number). Over the limit you get429with{"detail":"Rate limit exceeded"}and the headersX-RateLimit-Limit,X-RateLimit-Remaining(0) andX-RateLimit-Reset. These headers appear only on the 429, not on normal responses. - Workflow engine: 100 requests per minute per authenticated user (per client IP when there is no user). Over the limit you get
429with aRetry-Afterheader and{"error":"rate limit exceeded","retry_after":60}.
I found no per-endpoint limits for agent chat, copilot or exports, and no concurrency limit on executions.
Errors
There is no single error envelope.
| Source | Format | Example |
|---|---|---|
| Gateway | {"detail": "..."} | {"detail":"Authentication required"} (401), {"detail":"Invalid or expired token"} (401) |
| Workflow engine, most pipeline, execution and auth errors | {"error": "..."} | {"error":"pipeline not found"} |
| Workflow engine, many agent, connector, tool and LLM model handlers | Plain text body | agent not found |
| Workflow engine, agent version conflicts | {"error": "...", "code": "...", ...} | {"code":"AGENT_DEPLOYED_IMMUTABLE", ...} |
Check the status code first, then read the body as JSON only if the Content-Type is application/json.
Pagination
Conventions differ by endpoint:
| Endpoint | Parameters | Default | Response keys |
|---|---|---|---|
GET /pipelines | page, page_size, or limit, offset (explicit limit/offset win) | page 1, size 10 | pipelines, total, page, page_size |
GET /executions | limit, offset | 10, 0 | entries, total, limit, offset, organization_id |
GET /agents, GET /connectors | limit, offset | 20, 0 | agents or connectors, total_count, limit, offset |
GET /llm-models | limit, offset | 20, 0 | items, total, skip (the offset), limit |
Pipelines
A pipeline is a graph of nodes and connections. Reading and listing need an authenticated user in an organization. Creating needs a write role (admin, editor, superuser, platform_manager, organization_admin, developer) or a write permission on pipelines. Deleting needs an admin-class role (admin, superuser, platform_manager, organization_admin) or a delete permission. I found no role check on PUT, deploy or undeploy beyond belonging to the organization that owns the pipeline.
| Method and path | Purpose | Success |
|---|---|---|
GET /pipelines | List pipelines of your organization | 200 |
POST /pipelines | Create a pipeline | 201 |
GET /pipelines/{id} | Get one pipeline | 200 |
PUT /pipelines/{id} | Partial update | 200 |
DELETE /pipelines/{id} | Delete | 204 |
POST /pipelines/{id}/deploy | Deploy to an environment | 200 |
POST /pipelines/{id}/undeploy | Set the status back to active | 200 |
GET /pipelines/{id}/executions | Executions of this pipeline | 200 |
GET /pipelines/{id}/history | Who changed this pipeline | 200 |
{id} must be a UUID, otherwise the answer is 400 {"error":"invalid uuid format"}.
Create a pipeline
Send the nodes, connections and variables at the top level. A nested definition object is also accepted; if both are present, the top-level lists win. The body must be JSON (or YAML). Any other content type returns 415.
curl -X POST "https://<api-host>/api/v1/hydra-platform/pipelines" \
-H "Authorization: Bearer <jwt>" \
-H "Content-Type: application/json" \
-d '{
"name": "Echo example",
"description": "Passes the input through and formats it as JSON",
"nodes": [
{"id": "in1", "type": "input", "label": "Input", "config": {}},
{"id": "out1", "type": "output", "label": "Output", "config": {"format": "json"}}
],
"connections": [
{"id": "c1", "source_node": "in1", "source_port": "output",
"target_node": "out1", "target_port": "input"}
],
"variables": {}
}'
| Field | Meaning | Default |
|---|---|---|
name | Required | |
description | Free text | empty |
version | Semver string | 1.0.0 |
nodes[] | At least one is required. Each has id, type, label, config (and optionally position, timeout in seconds, retry) | |
connections[] | id, source_node, source_port, target_node, target_port | |
variables | Either an object {"name": value} or an array of {name, type, value, description} |
Node type values and their ports and config come from the node catalog. The input and output nodes above use the ports and format field listed in the catalog.
The response is 201 with the pipeline: id, name, description, version (a string), status, created_at, updated_at, created_by, nodes, connections, variables and a definition object that repeats them. variables always comes back as an array. The server pins each node to a release, so the nodes in the answer carry extra fields such as version and schema_digest. GET /pipelines returns the same pipelines without the definition wrapper.
Failures:
| Status | Body | Cause |
|---|---|---|
| 400 | {"error":"name is required"} / {"error":"at least one node is required"} | Missing name or no nodes |
| 400 | {"error":"node release x@ is unavailable"} | type is not in the node registry. (PUT answers unknown node type: "x" instead.) |
| 403 | {"error":"forbidden: insufficient permissions"} | No write role |
| 415 | {"error":"unsupported media type"} | Wrong Content-Type |
List, get, update, delete
curl "https://<api-host>/api/v1/hydra-platform/pipelines?page=1&page_size=10" \
-H "Authorization: Bearer <jwt>"
{"pipelines": [ { "id": "...", "name": "...", "version": "1.0.0", "nodes": [], "connections": [], "variables": [] } ],
"total": 1, "page": 1, "page_size": 10}
PUT /pipelines/{id} only changes the fields you send (name, description, version, nodes, connections, variables, definition); the rest is kept. Unlike POST, variables must be the array form here. Unknown node types are rejected with 400. A cross-organization id answers 404 {"error":"pipeline not found"}.
DELETE returns 204 with no body. I found no check that blocks deleting a deployed pipeline.
Deploy and undeploy
curl -X POST ".../pipelines/<id>/deploy" -H "Authorization: Bearer <jwt>" \
-H "Content-Type: application/json" -d '{"environment": "<slug>"}'
An empty body deploys to the organization's default environment. An unknown or archived environment returns 422. The status becomes deployed:<environment slug>. Undeploy sets the status back to active. See Environments and promotion.
Execute a pipeline
POST /execute needs a user JWT with the pipeline:execute permission, or an API token with the scope pipeline:{pipeline_id}:execute or the organization-wide pipelines:execute.
| Field | Meaning | Default |
|---|---|---|
pipeline_id | Required | |
inputs | Object of input values. input is accepted as an alias. An explicit null returns 400 input is required | {} |
async | true returns immediately and runs in the background | false (runs inline) |
environment | Environment slug. The X-Hydra-Environment header is used if this is empty, otherwise the organization default | default environment |
test_mode | true or false overrides the pipeline's own test mode for this run | pipeline setting |
Mesh fields (segment_id, version, plan_id, run_id, envelope) are for distributed runs; see Run on mesh.
Synchronous (default)
curl -X POST "https://<api-host>/api/v1/hydra-platform/execute" \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{"pipeline_id": "<uuid>", "inputs": {"patient_id": "TEST-001"}}'
The call holds the connection until the run ends and answers 200:
{"execution_id": "...", "status": "completed", "outputs": {}, "node_results": {}}
outputs holds the final outputs and node_results one entry per node. A pipeline whose node failed is still a normal outcome: you get 200 with "status": "failed" and an error string. Only a run that could not start at all returns a 5xx.
Statuses the engine uses: pending, running, completed, partial, failed, cancelled, waiting.
A run that waits
If a node suspends the run (for example, it waits for an external event), the synchronous call answers 202 with status: "waiting", a wait_token and a resume_url (/api/execute/resume/<token>). Continue it with:
curl -X POST "https://<api-host>/api/v1/hydra-platform/execute/resume/<wait_token>" \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" -d '{"payload": {"approved": true}}'
The workflow engine itself does not authenticate this route (the token is the credential), but it is not on the gateway's public list, so through the gateway you still send a Bearer token. The resume_url that the workflow engine returns starts with /api/: replace that prefix with /api/v1/hydra-platform/ when you call through the gateway. An unknown or already-used token returns 404 {"error":"unknown or expired wait token"}.
Asynchronous
With "async": true the answer is 202 {"execution_id": "...", "status": "pending"}. Poll GET /executions/{execution_id}. Cancel with POST /executions/{execution_id}/cancel (only for async runs still held in memory).
Executions, retry, stats
| Method and path | Purpose |
|---|---|
GET /executions | History. Query: limit, offset, status, pipeline_id, from, to (RFC 3339), organization_id |
GET /executions/{id} | One execution: execution_id, pipeline_id, status, started_at, completed_at, result, node_results, error |
POST /executions/{id}/cancel | Cancel an async run |
POST /execute/retry | Re-run from a failed node |
GET /stats | Aggregates for your organization |
Users who are not admin only see their own runs.
Retry body (all three fields are required, else 400):
{"pipeline_id": "<uuid>", "execution_id": "<previous execution id>", "from_node_id": "<node id>"}
It reuses the stored outputs of the nodes upstream of from_node_id and returns 200 with the same shape as a synchronous run. It answers 404 previous execution not found if the execution is unknown, belongs to another pipeline or organization, and 409 if the pipeline's node types changed since the original run or the run cannot be replayed (for example, its inputs or results were too large to keep).
GET /stats returns total_executions, successful_executions, failed_executions, total, by_status, by_pipeline, average_duration, active_pipelines, running, success_rate and failed_today.
Step-by-step debugging
| Method and path | Purpose |
|---|---|
POST /execute/step | Start a session. Body {"pipeline_id": "...", "inputs": {}} |
POST /execute/step/{sessionId}/next | Run the next batch of nodes (no body) |
DELETE /execute/step/{sessionId}/cancel (or POST) | End the session, 204 |
Each response has session_id, step, total_steps, completed, batch_nodes and node_results. These errors are plain text, not JSON.
Agents
| Method and path | Purpose |
|---|---|
GET /agents | List your organization's agents |
GET /agents?base_templates=true | List catalog (base template) agents |
POST /agents | Create an agent, 201 |
GET /agents/{id}, PUT /agents/{id}, DELETE /agents/{id} | Read, update, delete |
POST /agents/{id}/deploy, POST /agents/{id}/undeploy | Deploy or undeploy |
POST /agents/{id}/instantiate | Create your own agent from a base template. Body {"project_id": "...", "name": "..."} (project_id required) |
POST /agents/{id}/chat | Run the agent (see below) |
GET, POST /agents/{id}/conversations | Conversations. Also /conversations/{cid}, /messages, /steps |
GET /agents/{id}/executions | Run history. Also /executions/{execId}/steps and /events |
GET /agents/{id}/versions | Version lifecycle (/versions/{v}, /versions/{v}/deploy) |
List filters: limit, offset, type, is_active (true or false), project_id. The organization comes from your token; org_id is only honored for an organization you belong to.
Base templates cannot be deployed or run. Calling deploy or chat on one returns 400 base templates cannot be deployed or run; POST /instantiate first and use the resulting agent. The one exception is chat on a utility agent that the product itself calls by slug: the server then runs your organization's own instance of it.
Create an agent
curl -X POST "https://<api-host>/api/v1/hydra-platform/agents" \
-H "Authorization: Bearer <jwt>" -H "Content-Type: application/json" \
-d '{
"name": "Discharge summary helper",
"agent_type": "conversational",
"description": "Drafts a discharge summary from a note",
"prompt_template": "You summarize clinical notes for {{specialty}}.",
"temperature": 20
}'
| Field | Meaning | Default |
|---|---|---|
name | Required | |
agent_type | conversational, task, hybrid or react | conversational |
prompt_template | System prompt. {{KEY}} tokens are filled from variables at run time | |
slug | Lowercase letters, digits and hyphens | |
temperature | Integer 0 to 100 | |
compliance_level | hipaa, fda, soc2, gdpr or none | |
| Other | model_config, max_tokens, streaming, use_memory, expose_as_inference, capabilities, tags, sub_agents, project_id, organization_id, version |
A deployed agent is frozen. A PUT that changes its configuration returns 409 with {"code":"AGENT_DEPLOYED_IMMUTABLE","error":"agent version ... is deployed and immutable; create a new version ... and deploy it"}. Name, description, tags and the active flag can still be edited. Create a draft with POST /agents/{id}/versions and deploy it.
Chat with an agent
POST /agents/{id}/chat with a user JWT. Body:
| Field | Meaning |
|---|---|
message | Required unless attachments is sent |
stream | true for server-sent events |
history | Earlier turns as {role, content} |
variables | Object of strings that fill {{KEY}} in the prompt |
thinking, attachments, response_language, grounding | Optional |
Without stream, the answer is one JSON object. reasoning_content, tool_calls, tool_trace, suggestions and the token counts are left out when empty or zero:
{"content": "...", "input_tokens": 120, "output_tokens": 80}
With "stream": true the response is text/event-stream. Every frame is a plain data: <json> line (there are no event: lines), and a : keepalive comment is sent every 15 seconds:
data: {"type":"step","event":"llm_call","data":{"round":0,"tools":2},"ts":1760000000000}
data: {"reasoning_content":"..."}
data: {"content":"Partial answer text"}
data: {"content":"","done":"true","input_tokens":120,"output_tokens":80,"final_content":"Full answer text"}
Read text from the content key of frames that do not have "done". An error ends the stream with {"type":"error","content":"...","done":"true"}.
Public invoke endpoint
This is the endpoint for calling an agent from your own application with an API key.
POST https://<api-host>/api/v1/hydra-platform/v1/agents/{agent_id}/invoke
curl -X POST "https://<api-host>/api/v1/hydra-platform/v1/agents/<agent_id>/invoke" \
-H "Authorization: Bearer <api-token>" \
-H "Content-Type: application/json" \
-d '{"message": "Summarize this note: ...", "variables": {"specialty": "cardiology"}, "stream": false}'
The body is the same as chat: message (or attachments), stream, variables, history. The response is the chat response above, or the event stream if stream is true. The agent must belong to the token's organization and be active.
The token needs the scope agent:<agent_id>:execute. The org-wide agents:execute or agents:*, the per-agent agent:<agent_id>:* and * also satisfy it. The workflow engine checks the token itself; the gateway passes the path through.
| Status | Body | Cause |
|---|---|---|
| 400 | message or attachments required | Empty body |
| 401 | Authorization header required / Invalid authorization header format | Missing or malformed header |
| 403 | Forbidden | Token invalid, revoked, expired, wrong scope or IP not allowed |
| 403 | Access denied / Agent is not active | Agent belongs to another organization, or is inactive |
| 404 | Agent not found | Unknown id |
| 503 | Service temporarily unavailable | The auth service could not be reached |
These bodies are plain text, not JSON. A revoked key gives 403, not 401.
Node catalog
Public, no token needed. Use it to find valid node type values, ports and config fields before you create a pipeline.
| Method and path | Purpose |
|---|---|
GET /node-catalog | All nodes. Optional category filter. Returns nodes, categories, total_count |
GET /node-catalog/search/{query} | Case-insensitive match on id, name, description or category. Returns query, results, count |
GET /node-catalog/{id} | One node: id, name, category, description, inputs, outputs, config, compliance and, where set, maturity, risk_tier |
curl "https://<api-host>/api/v1/hydra-platform/node-catalog/input"
Node pages in this site list the same data. For an id that is not in the registry, GET /node-catalog/{id} returns an inferred entry rather than 404, so a successful response does not prove the node exists. POST /pipelines is what rejects unknown types.
Connectors, tools and LLM models
All need a user JWT.
Connectors
| Method and path | Purpose |
|---|---|
GET /connectors/types | The connector types and whether each has a driver (Available) |
GET /connectors | List. Filters: connector_type, is_template, scope, project_id, limit, offset |
POST /connectors | Create, 201 |
GET, PUT, DELETE /connectors/{id} | Read, update, delete |
Create body:
| Field | Meaning |
|---|---|
name | Required |
connector_type | Required. One of the types from GET /connectors/types, for example hl7_fhir_r4, rest_api, postgres, s3, sftp, kafka |
configuration | Object. Its required fields depend on the type; the endpoint goes here, not in a top-level field |
credentials | Object of string values ({"token": "..."}). Stored separately from the configuration |
scope | organization (default) or project. project requires project_id |
description, tags, is_template, is_public, reason | Optional |
curl -X POST "https://<api-host>/api/v1/hydra-platform/connectors" \
-H "Authorization: Bearer <jwt>" -H "Content-Type: application/json" \
-d '{"name": "Demo FHIR server", "connector_type": "hl7_fhir_r4",
"configuration": {"base_url": "https://fhir.example.org/fhir", "auth_type": "none"}}'
For hl7_fhir_r4 only base_url is required; auth_type is one of none, bearer, api_key, basic, client_credentials, backend_jwt. Configuration that does not match the driver returns 400 config validation failed: .... See the connector directory.
Tools
GET /tools, POST /tools, GET, PUT, DELETE /tools/{id} and GET /tools/{id}/declarations exist. I did not verify the tool request body, so it is not documented here.
LLM models
GET /llm-models lists the organization's models (API keys are never returned; each item has has_api_key). Filters: provider, status, limit, offset. POST /llm-models takes name, provider, model_name and optional api_key, api_base_url, context_window, default_temperature, default_max_tokens, input_cost_per_1k, output_cost_per_1k and more. GET, PUT, DELETE /llm-models/{id}, POST /llm-models/{id}/set-default and POST /llm-models/{id}/test-connection also exist.
Copilot
All copilot routes need a user JWT and are POST unless noted.
| Path | Purpose |
|---|---|
copilot/chat | Chat. message is required; stream: true streams |
copilot/generate/pipeline, validate/pipeline, refine/pipeline, modify/pipeline, auto-configure/pipeline, configure/node, generate/pipeline-docs, generate/agent | Pipeline and agent authoring helpers |
copilot/pipeline-assistant, agent-assistant, graph-assistant, board-assistant | Assistants inside the builders |
copilot/route-agent, copilot/compose-pipeline | Body {"task": "...", "catalog": "..."}, both required. Returns {"raw": "..."} |
GET copilot/capabilities, GET copilot/health | Capabilities and health |
These routes answer 501 {"error":"not implemented","feature":"<name>", ...}: copilot/generate/code, generate/hl7-mapping, generate/fhir-queries, infer/schema and transformer-assistant. The older suggestions, analyze and insights routes no longer exist and return 404.
Environments, manifests and deployments
These routes exist for promoting work between environments: GET, POST /environments, GET, PATCH /environments/{slug}, GET, PUT /environments/routes, POST /environments/{slug}/deployments, GET /environments/{slug}/releases, /manifests, /deployments/pending, POST /deployments/receive and GET /instance. Reading needs a user JWT; creating, changing and deploying also need superuser or the manage:hydra.environment permission. Exceptions: manifests also accepts API tokens with manifests:read, manifests:write or manifests:publish, deployments/receive takes a token with deployments:write, and GET /instance is public in the workflow engine (through the gateway you still send a Bearer token). Those scopes are not in the list the API Tokens screen offers, so the only token you can mint from the product UI that satisfies them is one with the scope *. Request bodies are described in the environments page.
API tokens
An API token lets a program call the routes marked above without a user session.
Create a token
- Open the Admin Console and go to Platform, then API Tokens. The screen needs an organization administrator.
- Choose Create Token and fill in Name (required), Description, Scopes (required), Expires In (days) (1 to 365; leave empty for no expiration), Rate Limit (requests/minute) (0 means no limit) and Allowed IPs (optional) (empty allows any IP).
- Copy the token from the Token Created Successfully dialog. It is shown once and cannot be shown again; the server stores only a hash.
The token starts with tia_m2m_. The agent designer also has an API tab with Generate API Key, which creates a token scoped to agent:<id>:execute and shows ready-made curl, TypeScript and Python samples. Note that the streaming TypeScript and Python samples generated there test chunk.type === "content"; the server sends the text under a content key without a type, as shown above.
The scope check on the dev branch of the Go auth service accepts only permission-catalog keys, the scopes in the table below and spoke scopes. I found no rule there that admits a resource-scoped scope such as agent:<id>:execute, so a request from Generate API Key may be refused with UNKNOWN_SCOPE (400). I did not run it against a live auth service. If it is refused, create a token with agents:execute on the API Tokens screen and use that on the invoke endpoint. The same branch requires a token to carry an expiry of 1 to 90 days when it holds a gated permission key, and only a signed-in user (not another API token) can create a token.
The screen calls POST /api/v1/auth/api-tokens (with a user JWT) with name, description, scopes, expires_in_days, rate_limit and allowed_ips. The response has token, token_prefix, id, name and scopes.
Scopes
The scope list the auth service offers:
| Group | Scopes |
|---|---|
| Pipelines | pipelines:read, pipelines:write, pipelines:execute, pipelines:* |
| Executions | executions:read, executions:write |
| Agents | agents:read, agents:write, agents:execute, agents:* |
| Organization and users | organization:read, organization:write, organization:*, users:read, users:write |
| Templates | templates:read, templates:write |
| Graphs and subagents | graphs:read, graphs:write, graphs:execute, graphs:*, subagent:read, subagent:execute, subagent:* |
| Everything | * |
| Runtime (spoke and hub) | spoke:register, spoke:heartbeat, spoke:config, spoke:messages, spoke:logs, spoke:bootstrap, spoke:*, hub:admin, hub:* |
Resource-scoped forms such as agent:<uuid>:execute and pipeline:<uuid>:execute are also honored; the org-wide scope of the same type (agents:execute, pipelines:*) satisfies them. There are no fhir:read, fhir:write or workflows:run scopes.
Check that a token works
curl -X POST "https://<api-host>/api/v1/hydra-platform/execute" \
-H "Authorization: Bearer tia_m2m_..." -H "Content-Type: application/json" \
-d '{"pipeline_id": "<uuid>", "inputs": {}}'
A 200 or 202 means the token, scope and organization are right.
A token's Allowed IPs list is checked by the auth service against the address it sees. The gateway passes your address when it validates the token, but the workflow engine validates the token again without forwarding the caller's address, so I could not confirm how a restricted token behaves on workflow engine routes. Test a restricted token before you depend on it.
Troubleshooting
| You see | Cause and fix |
|---|---|
401 {"detail":"Authentication required"} | No Authorization: Bearer header on a non-public path |
401 {"detail":"Invalid or expired token"} | The JWT or API token is not valid. API tokens that were revoked or expired fail here |
401 {"error":"unauthorized: invalid token"} from the workflow engine | You sent an API token to a route that only accepts a user JWT (see the warning above) |
403 Forbidden on invoke or execute | The token lacks the required scope, is revoked or expired, or the caller IP is not in its allowed list |
403 {"detail":"forbidden: not a member of the requested organization"} | X-Organization-ID names an organization you do not belong to. Remove the header |
404 {"error":"pipeline not found"} | Wrong id, or the pipeline belongs to another organization |
429 | Rate limit. Wait for the reset (X-RateLimit-Reset from the gateway, Retry-After from the workflow engine) |
Sync call returns 200 with "status":"failed" | The pipeline ran and a node failed. Read error and node_results, fix, then call POST /execute/retry |
Something unclear? Send documentation feedback by email.