Skip to main content
POST
Start a session with the Effective agent

Authorizations

Authorization
string
header
required

Effective API key. Send Authorization: Bearer sk-eai-...

Headers

Idempotency-Key
string

Client-chosen key for safe retries: 1-128 letters, digits, -, _, . or :. Use a new random UUID for each intended operation and the same key when retrying it. Do not put customer data or credentials in the key.

Required string length: 1 - 128
Pattern: ^[A-Za-z0-9\-_.:]+$

Body

application/json
title
string

Name shown for the session in Effective. Defaults to "API session".

Required string length: 1 - 120
message
string

First message. When present the agent starts on it right away; otherwise the session waits for POST /sessions/{id}/messages.

Required string length: 1 - 20000
agentId
string

The ID returned when you save an agent. Supply either agentId or appId.

Pattern: ^agent_[0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}$
agentVersion
string

Pin this saved agent version. Requires agentId. Omit to pin the latest version when the session starts.

Pattern: ^[1-9][0-9]{0,8}$
appId
string

Run the current published agent for this app. Requires App Run permission.

Maximum string length: 63
Pattern: ^app-[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$
missionControlId
string<uuid>

Mission Control context for an app session. Requires appId and access to that Mission Control.

scope
object

Research context for the first message, in the same shape answers take. The agent may also consult other sources you can access. Requires message.

Response

Session started.

id
string<uuid>
required

Session UUID, e.g. 00000000-0000-4000-8000-000000000001.

Example:

"00000000-0000-4000-8000-000000000001"

status
enum<string>
required

running while the agent is working on a message; idle otherwise.

Available options:
idle,
running
message
object | null
required

The first message, when one was sent. Follow it with GET /sessions/{id}/messages/{messageId}.