Skip to main content
POST
/
v1
/
agents
/
{agentId}
/
messages
/
send
Send a message to an agent (A2A, non-streaming)
curl --request POST \
  --url https://{host}/v2/workspaces/slug:agent-factory/webhooks/v1/agents/{agentId}/messages/send \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "message": {
    "message_id": "msg-test-2",
    "role": "user",
    "parts": [
      {
        "text": "What is 2+2? Reply with just the number."
      }
    ]
  }
}
'
{
  "error": {},
  "task": {
    "id": "<string>",
    "contextId": "<string>",
    "status": {
      "state": "working",
      "timestamp": "<string>",
      "message": {}
    },
    "output": {
      "messages": [
        {
          "message_id": "<string>",
          "role": "user",
          "contextId": "<string>",
          "taskId": "<string>",
          "parts": [
            {}
          ]
        }
      ]
    },
    "usage": {},
    "tool_calls": [
      {
        "name": "<string>",
        "arguments": {},
        "status": "<string>"
      }
    ]
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.prisme.ai/llms.txt

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

Authorizations

Authorization
string
header
required

User session JWT or instance API key (iak_*). Send as Authorization: Bearer <token>.

Headers

x-draft-mode
boolean

When true, the call exercises the agent's live (draft) config instead of published_config. Reserved for owners/writers.

Path Parameters

agentId
string
required
Maximum string length: 64

Body

application/json
message
object
required

A2A v0.3 flat message envelope.

Response

Completed task with the agent's reply.

error
object
task
object