Skip to main content
POST
/
api
/
v1
/
agents
/
{agentId}
/
invoke
Send a message to an agent and receive a reply.
curl --request POST \
  --url https://openapi.beeos.ai/api/v1/agents/{agentId}/invoke \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "message": "<string>",
  "context_id": "<string>",
  "timeout_ms": 123
}
'
{
  "success": true,
  "data": {
    "text": "<string>",
    "context_id": "<string>",
    "is_error": true
  }
}

Authorizations

Authorization
string
header
required

Pass a user JWT or an oag_ User API Key on the Authorization: Bearer <token> header.

Path Parameters

agentId
string
required
Maximum string length: 128

Body

application/json
message
string
required

The message to send to the agent.

context_id
string

Optional conversation context ID for multi-turn conversations.

timeout_ms
integer<int64>

Timeout in milliseconds (default 120000).

Response

Blocking: JSON envelope with agent reply. Streaming (Accept: text/event-stream): SSE stream.

success
boolean
required
data
object
required