Skip to main content
POST
Add a phone number for a user.

Authorizations

Authorization
string
header
required

Pass the API key in the Authorization header, You need to put Token keyword before the API key. e.g. 'Authorization: Token '

Body

application/json

A number you own in Twilio. Hamsa checks the credentials against your Twilio account when you add it.

type
enum<string>
required

TWILIO for a number from your Twilio account.

Available options:
TWILIO
phoneNumber
string
required

The Twilio number in international format, for example +14155550100. Spaces are removed.

Minimum string length: 1
Example:

"+14155550100"

label
string
required

A name that identifies the number in Hamsa.

Minimum string length: 1
Example:

"Support line"

twilioAccountSid
string
required

Your Twilio Account SID (starts with AC).

Minimum string length: 1
Example:

"ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

twilioAuthToken
string
required

Your Twilio Auth Token.

Minimum string length: 1
Example:

"your_twilio_auth_token"

Response

Created

success
boolean
Example:

true

message
string
Example:

"Success"

data
object