Skip to main content

Verify the verification code for a list of phone numbers

POST 
/porting_orders/:id/verification_codes/verify

Verifies the verification code for a list of phone numbers.

Request

Path Parameters

    id uuidrequired

    Porting Order id

Body

required

A list of phone numbers and their verification codes

    verification_codes

    object[]

    Possible values: <= 100

  • Array [

  • phone_number string
    code string
  • ]

Responses

200: Successful response

401: Unauthorized

404: Resource not found

422: Unprocessable entity. Check message field in response for details.

Request samples


curl -L 'https://api.telnyx.com/v2/porting_orders/:id/verification_codes/verify' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
-d '{
"verification_codes": [
{
"phone_number": "+61424000001",
"code": "12345"
},
{
"phone_number": "+61424000002",
"code": "54321"
}
]
}'

Response samples


{
"data": [
{
"id": "52090326-6533-4421-bcf4-bd0117cf3954",
"phone_number": "+61424000001",
"verified": true,
"porting_order_id": "f28e6ecc-29a8-430b-bd0b-d93055f70604",
"created_at": "2020-10-22T15:00:00.000Z",
"updated_at": "2020-10-22T15:00:00.000Z"
},
{
"id": "cf076b8e-645b-4040-8209-543c5909775f",
"phone_number": "+61424000002",
"verified": false,
"porting_order_id": "f28e6ecc-29a8-430b-bd0b-d93055f70604",
"created_at": "2020-10-22T15:00:00.000Z",
"updated_at": "2020-10-22T15:00:00.000Z"
}
]
}