end_call
POST
/v1/sessions/{session_id}/voice/{voice_connection_id}/end
const url = 'https://app.everruns.com/api/v1/sessions/example/voice/example/end';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"reason":"User hung up after refund confirmed."}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://app.everruns.com/api/v1/sessions/example/voice/example/end \ --header 'Content-Type: application/json' \ --data '{ "reason": "User hung up after refund confirmed." }'End the in-flight voice call.
Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” session_id
required
string
voice_connection_id
required
string
Request Body required
Section titled “Request Body required ” Media type application/json
Request body for voice end.
object
reason
Free-text reason recorded with the session-ended event. Useful for operator forensics.
string | null
Example
User hung up after refund confirmed.Responses
Section titled “ Responses ”Realtime voice connection ended
Media type application/json
Response body for voice end.
object
status
required
Current lifecycle status.
string
voice_connection_id
required
Prefixed public identifier of the voice connection that was ended.
string
Example generated
{ "status": "example", "voice_connection_id": "example"}