POST/v1/threads/{thread_id}/runs

Runs

Execute an Assistant against a Thread. Stream events or poll for completion.

Request
HTTP
POST
URL
/v1/threads/{thread_id}/runs
Auth
api_key
Try it
curl https://api.fightclub.pro/v1/threads/thread_abc/runs \
  -H "Authorization: Bearer $FC_API_KEY" \
  -d '{"assistant_id":"asst_xyz","stream":true}'

Parameters

NameTypeDescription
assistant_id*stringWhich assistant to run.
streambooleanStream run events as SSE.

Response fields

NameTypeDescription
idstringRun ID (run_*).
statusstringqueued | in_progress | completed | failed | cancelled.

Errors

  • 401invalid_api_key, Missing or revoked key.
  • 404assistant_not_found, No such assistant.

See the full error reference.

Examples