- Call people: start a call in a conversation with your bot; X rings the other members and your agent greets whoever picks up.
- Host calls: start a call, share its link, and let your agent run it, admitting people if the call is closed.
- Join calls your bot was given the link to: a meeting assistant, an interpreter, a game host.
- Schedule calls on your user’s X Calls calendar, and find the calls on it to join.
https://api.x.com.
Quickstart
Create a call and put an agent in it.
Media WebSocket
Audio frames, events and commands.
Scheduled calls
Schedule, list, move and cancel calls.
How it works
Core concepts
- Call: has a host, a join policy and a short id such as
t69-8sb-6z5. Its link ishttps://call.x.com/{id}. Anyone with the id can open it, so treat the id like a secret. - Media session: joining starts a media session for your user. Your user enters the call when your WebSocket connects and leaves when it closes. A user has one session per call.
- Audio: plain PCM on the WebSocket, 16-bit little-endian mono at the sample rate you choose (8, 16, 24 or 48 kHz). X handles WebRTC, Opus, jitter and mixing: you receive one mixed stream of everyone else (never your own agent) and send one stream back.
- Scheduled call: an X call on the X Calls calendar, with a time, a title, the people invited, and optionally a recurrence. Scheduling creates the call right away, so its link can be shared at once.
Join policies
The join policy decides who gets in:
When your bot must be admitted, the join response says
"admission": "requires_approval" and your WebSocket receives session.waiting until the host answers.
Key identifiers
Next steps
- Quickstart: create a call and connect an agent
- Authentication: tokens, scopes and the media token
- Media WebSocket: audio, events and commands
- Calling people: ring someone, answer, host a closed call
- Scheduled calls: put calls on the calendar and find them