MessageBird API
numbers
17
Node
Javascript
Python beta
Ruby beta
Shell
curl
The numbers API requires you to accept the latest Terms of Service (ToS) in order to use it.

Please click here to accept.
We hope you enjoy documentation for the MessageBird numbers API on StdLib! This API can be used via the command line (shell), Node, Ruby, Python or as a generic HTTP call in any language. Check the code examples on the right associated with each API method for how to use this API in your language of choice.
API Description
Find available phone numbers, initialize your first number, claim additional numbers, and list your claimed numbers.
# Claiming and Viewing MessageBird Numbers with StdLib This service allows you to look at available MessageBird telephone numbers, claim available numbers, and check which numbers you've previously claimed. ### Claiming Your First Phone Number After accepting the MessageBird terms of service by clicking above, you can see a selection of available telephone numbers by calling the `available` function. You can do this directly from your browser, or from the command line using the StdLib [command line tools](https://github.com/stdlib/lib) as follows: ``` $ lib messagebird.numbers.available ``` You can also request numbers from a specific country as `lib messagebird.numbers.available --country <US, CA>`. Choose one, then call the `initialize` function from your command line as: ``` $ lib messagebird.numbers.initialize --number <available phone number> ``` Congratulations! You've just claimed your first phone number. From your command line, you can see your claimed number by running: ``` $ lib messagebird.numbers.list ``` From here, you can use your claimed phone number to send text messages with the [sms](https://stdlib.com/@messagebird/lib/sms) API and set other StdLib functions as handlers for incoming text messages with the [handlers](https://stdlib.com/@messagebird/lib/handlers) API. ### Messaging Limits and Claiming Additional Numbers There is currently a limit of 500 sent messages per number per day. You can claim additional numbers for 99¢ each by calling the `numbers.claim` API endpoint. This will allow you to send more messages.
Find available phone numbers on the MessageBird platform. You can initialize your account with one of these numbers, or claim a new one at any time.
Authenticated   |   Pricing  ·  Free   |   Limit  ·  no rate limit
Unauthenticated   |   Forbidden  ·  Requires ToS
Parameters
country
string
The ISO Alpha-2 Country Code of the country the number belongs to (e.g. US, CA)
optional, default value is
"US"
optional, current value set to
enter a test value
Claims an available phone number. If you do not have a phone number yet, you should use "initialize" instead. Intended to be used after checking available numbers with the "available" method.
Authenticated   |   Pricing  ·  $0.99 per request   |   Limit  ·  no rate limit
Unauthenticated   |   Forbidden  ·  Requires ToS
Parameters
number
required
string
The phone number you would like to claim
current value set to
enter a test value
Initializes your first telephone number. Should be used before the "claim" method if you have not yet claimed a number. Intended to be used after checking available numbers with the "available" method.
Authenticated   |   Pricing  ·  Free   |   Limit  ·  no rate limit
Unauthenticated   |   Forbidden  ·  Requires ToS
Parameters
number
string
The phone number you would like to claim
optional, default value is
null
optional, current value set to
enter a test value
Lists your claimed phone numbers. Use this method to find numbers you can use for the "sms" API.
Authenticated   |   Pricing  ·  Free   |   Limit  ·  no rate limit
Unauthenticated   |   Forbidden  ·  Requires ToS
Made with by the MessageBird team with the help of StdLib.