Sessions

Stop Session

Stop a connected session.

Home/Docs/Stop Session

Endpoint

Stop a connected session.

Request
POST /sessions/{sessionId}/stop

Authentication

Every request must include a Bearer token in the Authorization header. Missing or invalid API keys return 401 Unauthorized.

Header
Authorization: Bearer YOUR_API_KEY

Path Parameters

FieldTypeRequiredDescription
sessionIdstringYesSession unique identifier

Response

FieldTypeDescription
uniqueSessionIdstringSession unique identifier
sessionNamestringHuman-readable session name
phoneNumberstringAssociated phone number
statusstringCurrent status: STARTING, CONNECTED, STOPPED, QR_REQUIRED, or ERROR
createdAtstringISO 8601 creation timestamp
updatedAtstringISO 8601 last-update timestamp

Examples

cURL
curl -X POST "https://api.example.com/sessions/{sessionId}/stop" \
  -H "Authorization: Bearer YOUR_API_KEY"
Response
{
  "uniqueSessionId": "a1b2c3d4-...",
  "sessionName": "Sales Primary",
  "phoneNumber": "+6281224560101",
  "status": "STOPPED",
  "createdAt": "2026-04-10T12:00:00.000Z",
  "updatedAt": "2026-04-15T10:05:00.000Z"
}

Notes

  • The session must be CONNECTED before stop.