Skip to main content
POST
create session token

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Configuration for the session to be created. Supply personaConfig.personaId to use a persona you've already created (stateful), or the set avatarId/voiceId/llmId/systemPrompt to configure the persona at run time (ephemeral).

The returned token is valid for one hour and bound to this exact config.

Server-side SDKs in a secure context can skip this exchange and start a session directly by calling POST /v1/engine/session with their API key and the same configuration in the request body.

clientLabel
string

The client label for the session

personaConfig
object

Persona configuration. An avatar-only config (avatarId without voiceId and without enableAudioPassthrough: true) is only accepted together with a LiveKit, Agora or ElevenLabs Agent integration environment; on the default Anam WebRTC transport send an ephemeral config with voiceId and llmId (llmId "CUSTOMER_CLIENT_V1" for a client-side LLM) or set enableAudioPassthrough to true. Otherwise the request fails with 400 avatar_only_requires_integration.

environment
object

Optional engine routing or transport integration environment. The integration type may be supplied explicitly or inferred from the LiveKit, Agora, or ElevenLabs Agent settings.

sessionOptions
object

Response

Successfully started session

Short-lived credential used by a client to connect to a live persona. Valid for one hour.

sessionToken
string

Signed JWT the client passes to the Anam SDK to open a WebRTC connection.

Last modified on September 4, 2026