Number Ordering V1

Number Order operations

Create a number order

Creates a number order. Numbers in the order should have appeared in a number search within the last 24 hours.

You may send requested_numbers_with_metadata, requested_inexplicit_numbers, and/or requested_numbers.

Send requested_numbers_with_metadata when ordering specific numbers seen in recent search results. The metadata that you send is meant to satisfy local requirements associated with numbers purchased. If no local requirements exist, as is the case for US numbers, you can simply omit everything but the numbers themselves.

{
  "requested_numbers_with_metadata": [
    { "number": "+13035551111", "address_id": "1" },
    { "number": "+13035551112", "address_id": "1" },
    { "number": "+13035551113", "address_id": "2" }
  ]
}

Send requested_inexplicit_numbers when ordering numbers from inexplicit search results. You'll pass along the inexplicit search results of the numbers you wish to purchase, plus a quantity and, optionally, an address_id. The address_id is used to satisfy number ownership verification requirements in some localities. When provided, it must reference an address record on your account. That address will be passed along to the local numbering authorities when required.

{
  "requested_inexplicit_numbers": [
    "quantity": 100,
    "address_id": "123",
    "national_destination_code": "9",
    "country_iso": "FI",
    "region_name": "Helsinki",
    "region_type": "city"
  ]
}

We have kept requested_numbers available for backward compatibility and greater ease when ordering numbers without additional requirements:

{
  "requested_numbers": ["+13035551111", "+13035551112", "+13035551113"]
}
Request
Request Body schema: application/json
required

Number order to add

requested_numbers_with_metadata
Array of objects
requested_inexplicit_numbers
Array of objects
requested_numbers
Array of strings
connection_id
string

ID of connection to be associated with phone numbers in the order.

messaging_profile_id
string

ID of messaging profile to be associated with phone numbers in the order.

Responses
200

NumberOrder response

Response Schema: application/json
id
required
string
400

Bad request

401

Unauthorized

post/origination/number_orders
Request samples
application/json
{
  • "requested_numbers_with_metadata": [
    • { }
    ],
  • "requested_inexplicit_numbers": [
    • { }
    ],
  • "requested_numbers": [
    • "string"
    ],
  • "connection_id": "string",
  • "messaging_profile_id": "string"
}
Response samples
application/json
{
  • "id": "string"
}

Retrieve a number order

Retrieves the details of an existing number order.

Request
path Parameters
order_request_id
required
string

Order request id

Responses
200

Number Order Response

Response Schema: application/json
order_request_id
string

uuid.

numbers_count
number <double>

Count of requested numbers associated to the order.

date_created
string

Timestamp of resource creation.

date_due
string

Timestamp of due date for requirements if needed to be met.

requirements_met
boolean

True if all requirements are met for every phone number, false otherwise.

Array of objects (Requested Number)
Array of objects (Requested Inexplicit Numbers)
connection_id
string

ID of connection associated to phone numbers in the order.

401

Unauthorized

404

Resource not found

get/origination/number_orders/{order_request_id}
Request samples
Response samples
application/json
{
  • "order_request_id": "7e610e23-d1f2-4f90-b5b7-3ddd7b32ad7c",
  • "numbers_count": 1,
  • "date_created": "2018-02-08T18:49:22.998023Z",
  • "date_due": "2018-02-08T18:49:22.998023Z",
  • "requirements_met": true,
  • "requested_numbers": [
    • {
      • "number": "string",
      • "status": "success",
      • "allocated": true,
      • "customer_name": "string",
      • "customer_phone": "string",
      • "tax_id": "string",
      • "requirements_met": true,
      • "requirements": [
        • { }
        ],
      • "provided_documents": {
        • "address_proof_file_ids": [
          • "string"
          ],
        • "identification_file_ids": [
          • "string"
          ],
        • "reg_form_file_ids": [
          • "string"
          ]
        }
      }
    ],
  • "requested_inexplicit_numbers": [
    • {
      • "region_name": "string",
      • "region_type": "string",
      • "national_destination_code": "string",
      • "country_iso": "string",
      • "quantity": 0,
      • "allocated_telephone_numbers": [
        • "string"
        ],
      • "customer_name": "string",
      • "customer_phone": "string",
      • "tax_id": "string",
      • "requirements_met": true,
      • "requirements": [
        • { }
        ],
      • "provided_documents": {
        • "address_proof_file_ids": [
          • "string"
          ],
        • "identification_file_ids": [
          • "string"
          ],
        • "reg_form_file_ids": [
          • "string"
          ]
        }
      }
    ],
  • "connection_id": "string"
}