Change Phone Number

Change client phone number. Old number becomes unavailable, all future messages are sent to the new number.

POST/api/v1/change_phone

Request Headers

HeaderValueRequired
X-API-KeystringYes
Content-Typeapplication/jsonYes

Request Body

NameTypeRequiredDescription
old_phonestringYesCurrent client phone number
new_phonestringYesNew phone number in international format

Response Body

json
{"status":"accepted","event_id":"550e8400-e29b-41d4-a716-446655440000"}

Examples

bash
curl -X POST /api/v1/change_phone \
  -H "Content-Type: application/json" \
  -H "X-API-Key: YOUR_API_KEY" \
  -d '{
    "old_phone": "12345678901",
    "new_phone": "12345678902"
  }'
CodeMessageDescription
202AcceptedMessage accepted into processing queue
401UnauthorizedInvalid or missing X-API-Key
429Rate LimitToo many requests
500Internal ErrorServer-side error

Sending Messages