Place a call
Dials `to` from one of your lines. The audio goes through the WebRTC session given in `session_id`, whose data channel then reports `call.state` events. One call at a time per line and per session. An unknown session (`404`) or a busy line (`409`) is refused before anything is created. When the line cannot dial, the call is still created and returned (`201`) already `ended`, with `end_reason` `failed` or `line_offline`. Sending the same `client_ref` again returns the first call (`200`) instead of dialing twice.
Dials to from one of your lines. The audio goes through the WebRTC session given in session_id, whose data
channel then reports call.state events. One call at a time per line and per session.
An unknown session (404) or a busy line (409) is refused before anything is created. When the line cannot
dial, the call is still created and returned (201) already ended, with end_reason failed or
line_offline. Sending the same client_ref again returns the first call (200) instead of dialing twice.
AuthorizationBearer <token>Your API key, 06l_…. For servers only.
application/json- body
line_id*LineId^line_[0-9a-z]{26}$to*PhoneNumberE.164, e.g. +33612345678.
^\+[1-9][0-9]{6,14}$session_id*SessionIdA WebRTC session, from POST /v1/webrtc/sessions.
^rtc_[0-9a-z]{26}$client_ref?ClientRefYour own identifier, 255 bytes at most. Sending the same client_ref twice returns the first result instead of acting twice.
length <= 255Already placed with this client_ref; the first call is returned.
application/json- response
id*CallId^call_[0-9a-z]{26}$line_id*LineId^line_[0-9a-z]{26}$direction*string"outbound""inbound"from*stringYour line when outbound. When inbound, the caller as the network gives it: usually E.164, empty when the caller hides the number.
to*PhoneNumberE.164, e.g. +33612345678.
^\+[1-9][0-9]{6,14}$state*stringdialing → ringing → active → ended. Incoming calls start at ringing.
"dialing""ringing""active""ended"end_reason?string"hangup""remote_hangup""no_answer""busy""failed""line_offline"client_ref?ClientRefYour own identifier, 255 bytes at most. Sending the same client_ref twice returns the first result instead of acting twice.
length <= 255created_by*Who did it. user from the 06 Line dashboard, api_key from your code, agent for what the network sent you, system for 06 Line itself.
started_at*TimestampRFC 3339, UTC.
date-timeanswered_at?TimestampRFC 3339, UTC.
date-timeended_at?TimestampRFC 3339, UTC.
date-timeduration_s?integerTalk time, from answered_at to ended_at.
curl -X POST 'https://api.06line.com/v1/calls' \ -H 'Content-Type: application/json' \ -d '{ "line_id": "line_01jbq5a3x9e2k7m4t6v8r0c1yb", "to": "+33698765432", "session_id": "rtc_01jbq9h7r3m5x1k8t2v6c4d0ya"}'{ "id": "call_01jbq7e4m2x8k5t1v9r3c6d0yb", "line_id": "line_01jbq5a3x9e2k7m4t6v8r0c1yb", "direction": "outbound", "from": "+33612345678", "to": "+33698765432", "state": "dialing", "created_by": { "type": "user", "id": "usr_01jbq3m5k7x9t1v3r5c7d9e1fb" }, "started_at": "2026-10-21T15:12:03Z"}Close a WebRTC session DELETE
Closes the peer connection and hangs up its call, if any (`end_reason: hangup`). Closing the peer connection from the browser has the same effect. An ephemeral key restricted to a line closes only the sessions opened with that restriction.
Answer a call POST
Answers a ringing incoming call, announced by `call.incoming` on a session's data channel. The audio goes through `session_id`. The call comes back still `ringing`: it turns `active` with the `call.state` that follows, once the line picked up. Every session the call rang then hears `call.state`.