Skip to main content
POST
/
api
/
v2
/
agents
/
context
/
run
Context Agent Run
curl --request POST \
  --url https://app.octavehq.com/api/v2/agents/context/run \
  --header 'Content-Type: application/json' \
  --header 'api_key: <api-key>' \
  --data '
{
  "agentOId": "agent_abc123",
  "runtimeContext": "How do you help with HIPAA compliance?",
  "additionalContext": {
    "person": {
      "firstName": "John",
      "lastName": "Doe",
      "title": "CISO",
      "email": "john.doe@healthcare.com"
    },
    "company": {
      "name": "Healthcare Corp",
      "domain": "healthcare.com"
    },
    "details": "Large healthcare provider in California"
  }
}
'
{
  "_metadata": {
    "requestId": "requestId",
    "timestamp": "2021-01-01T00:00:00.000Z",
    "usage": 0,
    "message": "message"
  },
  "found": true,
  "data": {
    "documents": [
      {
        "id": "<string>",
        "name": "<string>",
        "data": {},
        "score": 5,
        "reasoning": "<string>"
      }
    ],
    "reasoning": "<string>"
  },
  "message": "Additional information"
}

Documentation Index

Fetch the complete documentation index at: https://docs.octavehq.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

api_key
string
header
required

Body

application/json

Context agent input (query + context)

Context agent input with query and optional context

agentOId
string
required

Agent OId for preset context configuration

Example:

"agent_abc123"

query
string

Question or task to fetch context for

Minimum string length: 1
additionalContext
object

Optional person/company/details to enhance search

runtimeContext
string

Runtime context string — used as the query if 'query' is not provided. Consistent with other agent type APIs (email, content, enrich, etc.).

Minimum string length: 1

Response

Context agent run successful

_metadata
object
required
found
boolean
required

Whether the operation was successful

Example:

true

data
object
required
message
string | null

Message

Example:

"Additional information"