curl -X POST https://api.okrapdf.com/v1/collections/col-abc123/agents/agent_abc123/run \
-H "Authorization: Bearer $OKRA_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "input": { "prompt": "Compare revenue across documents" } }'
Agents
Run Collection Agent
Run an agent against a collection.
POST
/
v1
/
collections
/
{colId}
/
agents
/
{agentId}
/
run
curl -X POST https://api.okrapdf.com/v1/collections/col-abc123/agents/agent_abc123/run \
-H "Authorization: Bearer $OKRA_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "input": { "prompt": "Compare revenue across documents" } }'
Overview
Runs a visible built-in or custom agent across a collection.string
required
Collection ID.
string
required
Agent ID.
object
Optional run input payload.
curl -X POST https://api.okrapdf.com/v1/collections/col-abc123/agents/agent_abc123/run \
-H "Authorization: Bearer $OKRA_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "input": { "prompt": "Compare revenue across documents" } }'