Skip to main content
POST
/
number_reservations
/
{number_reservation_id}
/
actions
/
extend
JavaScript
import Telnyx from 'telnyx';

const client = new Telnyx({
  apiKey: 'My API Key',
});

const response = await client.numberReservations.actions.extend('number_reservation_id');

console.log(response.data);
{
  "data": {
    "id": "12ade33a-21c0-473b-b055-b3c836e1c292",
    "record_type": "number_reservation",
    "phone_numbers": [
      {
        "id": "12ade33a-21c0-473b-b055-b3c836e1c292",
        "record_type": "reserved_phone_number",
        "phone_number": "+19705555098",
        "status": "pending",
        "created_at": "2018-01-01T00:00:00.000000Z",
        "updated_at": "2018-01-01T00:00:00.000000Z",
        "expired_at": "2018-01-01T00:00:00.000000Z",
        "errors": ""
      }
    ],
    "status": "pending",
    "customer_reference": "MY REF 001",
    "created_at": "2018-01-01T00:00:00.000000Z",
    "updated_at": "2018-01-01T00:00:00.000000Z"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

number_reservation_id
string
required

The number reservation ID.

Response

Successful response with details about a number reservation.

data
object
Example:
{
"id": "12ade33a-21c0-473b-b055-b3c836e1c292",
"record_type": "number_reservation",
"phone_numbers": [
{
"id": "12ade33a-21c0-473b-b055-b3c836e1c292",
"record_type": "reserved_phone_number",
"phone_number": "+19705555098",
"status": "pending",
"created_at": "2018-01-01T00:00:00.000000Z",
"updated_at": "2018-01-01T00:00:00.000000Z",
"expired_at": "2018-01-01T00:00:00.000000Z",
"errors": ""
}
],
"status": "pending",
"customer_reference": "MY REF 001",
"created_at": "2018-01-01T00:00:00.000000Z",
"updated_at": "2018-01-01T00:00:00.000000Z"
}