Skip to main content
POST
/
v1
/
documents
/
{docId}
/
agents
/
{agentId}
/
run
curl -X POST https://api.okrapdf.com/v1/documents/doc-abc123/agents/agent_abc123/run \
  -H "Authorization: Bearer $OKRA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "input": { "prompt": "Extract key fields" } }'

Overview

Runs a visible built-in or custom agent against one document.
docId
string
required
Document ID.
agentId
string
required
Agent ID.
input
object
Optional run input payload.
curl -X POST https://api.okrapdf.com/v1/documents/doc-abc123/agents/agent_abc123/run \
  -H "Authorization: Bearer $OKRA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "input": { "prompt": "Extract key fields" } }'