Use role-based metadata to preview, run, stream, and cancel multi-agent work modes. Instructions and model ids are optional; omit model to use CLI settings.
POST /api/orchestration/workflows/{id}/preview
POST /api/orchestration/workflows/{id}/runs
GET /api/orchestration/workflows/runs/{runId}/events
GET /api/orchestration/workflows/context
curl -H "Authorization: Bearer px_..." \
-H "content-type: application/json" \
-d '{"metadata":{"agents":[{"adapterId":"codex","role":"frontend"},{"adapterId":"codex","role":"backend"},{"adapterId":"codex","role":"review"}]}}' \
/api/orchestration/workflows/agent_team/preview