Cowdidocs
API ReferenceCurrent account mobile number change

Confirm the new number

Verifies the OTP sent to the new number, completing the change.

POST
/v1/user/accounts/current/phone/changes/{mobileNumberChangeId}/confirm

Path Parameters

mobileNumberChangeId*string
Formatuuid

Request Body

application/json

Request body for confirming an OTP

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/user/accounts/current/phone/changes/497f6eca-6276-4993-bfeb-53cbbbba6f08/confirm" \  -H "Content-Type: application/json" \  -d '{    "otp_code": "123456"  }'
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "url": "string",  "status": "INITIALIZING",  "authorization_channel": "OLD_MOBILE",  "created_at": "2019-08-24T14:15:22Z",  "authorized_at": "2019-08-24T14:15:22Z",  "completed_at": "2019-08-24T14:15:22Z",  "authorize_url": "string",  "confirm_url": "string",  "resource_id": "string"}
{  "code": "BAD_REQUEST",  "description": "Bad Request"}
{  "code": "UNAUTHORISED",  "description": "Unauthorised"}
{  "code": "WAITING_LIST",  "description": "User is in the waiting list"}
{  "code": "TOO_MANY_REQUESTS",  "description": "Too Many Requests"}
{  "code": "INTERNAL_SERVER_ERROR",  "description": "Internal Server Error"}