Sign inGet Started

List number rates

GET
/v1/billing/rates/numbers
for await (const rate of bird.billingRates.numbers({ country_code: "US" })) {
  console.log(rate);
}
Response200
{
  "data": [
    {
      "country_code": "US",
      "number_type": "mobile",
      "pricing": {
        "setup_price": {
          "amount": "0.00995",
          "currency_code": "USD"
        },
        "recurring_price": {
          "amount": "0.00995",
          "currency_code": "USD"
        },
        "recurring_period": {
          "unit": "month",
          "count": 1
        },
        "intervals_per_charge": 12
      }
    }
  ],
  "next_cursor": "eyJ2IjoxLCJzIjoiXCIyMDI2LTA1LTI1VDE0OjAzOjEwWlwiIiwiaSI6IjAxOTJmM2IxLTRjN2UtN2EyYi05ZDYxLThmM2E1YzJlN2I0MCJ9",
  "prev_cursor": null,
  "refresh_cursor": "eyJ2IjoxLCJzIjoiXCIyMDI2LTA1LTI1VDE2OjQyOjAxWlwiIiwiaSI6IjAxOTJmM2IxLTllMDQtN2NkMy1iODE3LTJhNmY0ZDFjOGUwOSJ9"
}

Returns what a phone number costs your organization to acquire, per country and number type: the one-off setup fee where one applies and the recurring price a new number is subscribed at. Rates are net of tax, in your organization's billing currency, with your agreed prices applied. Only countries and number types you can order at a price are listed. A number you already hold can carry its own price; read it on the number. Returns 412 when your organization has no billing currency yet, a retryable 503 when the rates cannot be read, and a 500 with RatesNotRepresentable when a price cannot be shown on this card, which retrying does not fix; a page is never returned with rates missing. Requires the rates permission in the workspace, or the organization's org:billing permission, with which the workspace can be left out. Without a credential the response is Bird's default rates, in currency; a credential that does not authenticate returns 401, never default rates.

Query Parameters

sortstring

Field to sort by. Rates are ordered by country, then number type.

Possible values: country_code

orderstring

Sort direction. Defaults to asc, which sorts alphabetically or from oldest to newest, depending on the selected sort field.

Possible values: asc, desc

limitinteger

Maximum number of items to return per page.

starting_afterstring

Cursor from the next_cursor field of a previous list response. Returns items immediately after the cursor position in the current sort order.

ending_beforestring

Cursor from the prev_cursor or refresh_cursor field of a previous list response. Returns items immediately before the cursor position in the current sort order. prev_cursor returns the preceding page. refresh_cursor anchors at the first row of that response, which on a newest-first sort is how to fetch the items that have appeared since.

country_codestring

Return only rates for numbers in this country.

number_typestring

Return only rates for numbers of this type.

Possible values (may grow over time): mobile, local, national, short_code, short_code_fteu, toll_free, uifn

currencystring

The currency of the rates when the request carries no credential, USD when left out. With a credential the rates are in the organization's billing currency, and a different currency returns 422.

Response Payload

data
array of object
required
Show child attributes
data.country_code
string
required

The country of the number.

data.number_type
string
required

Physical type of a phone number. A uifn is a universal international freephone number (+800): it belongs to no country, so its country_code is XX, and it receives voice calls only. New number types may be added over time, so treat unrecognized values as supported types rather than errors.

Possible values (may grow over time): mobile, local, national, short_code, short_code_fteu, toll_free, uifn

data.pricing
object
required

What your organization pays for a new number, net of tax, in your billing currency. The fields have the meaning of the same fields on an available number's pricing.

Show child attributes
data.pricing.setup_price
nullable object
required

One-off setup fee, net of tax. Its amount is "0" when the published fee is zero. null when no setup fee applies to this country and number type.

Show child attributes
data.pricing.recurring_price
object
required

What your organization is charged for the number per recurring_period, net of tax, after your agreed prices are applied.

Show child attributes
data.pricing.recurring_period
object
required

The period recurring_price covers.

Show child attributes
data.pricing.recurring_period.unit
string
required

The calendar unit the period is counted in.

Possible values: day, month, year

data.pricing.recurring_period.count
integer
required

Number of units in the period.

data.pricing.intervals_per_charge
integer
required

How many recurring_periods one charge bills at once. Your organization is charged recurring_price multiplied by this at purchase and at each renewal.

next_cursor
nullable string
required

Cursor for the next page. Pass back as starting_after to advance forward. null when no next page exists.

prev_cursor
nullable string
required

Cursor for the previous page. Pass back as ending_before to step backward. null when no previous page exists.

refresh_cursor
nullable string
required

Refresh anchor, the first row of this response. Pass back as ending_before to fetch what precedes it in the current sort order. On a newest-first sort those are the items that have appeared since; on any other sort they are the items that sort earlier, so refreshing such a list means re-fetching it instead. Non-null whenever data is non-empty; null only on an empty page. Distinct from prev_cursor.

Continue with the documentation, guides and examples for this topic.