> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nicecall.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Create realtime session

> Create realtime session with the Nicecall API.

Create a short-lived browser voice session from your backend. Use the returned URL and token with the [Realtime Voice SDK](https://docs.nicecall.ai/ai-assistants/realtime-sdk.md).

**assistant\_id** `string` *required*

UUID of the assistant in your Nicecall account.

**variables** `object`

Optional prompt context with up to 50 keys and scalar values.

**external\_identifier** `string`

Optional identifier from your application.

```bash theme={null}
curl --request POST 'https://app.nicecall.ai/api/user/realtime/session' \
  --header 'Authorization: Bearer YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{"assistant_id":"9c1f8e2a-4d3b-4a17-9f6e-2b5c8d0a7e31"}'
```

The response includes `url`, `token`, and `expires_in` in seconds. Send the browser only the session credentials it needs. Limit creation to 10 requests per minute per API key and 10 concurrent sessions per account, including widget sessions.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.