Introduction

Welcome to the Ubity API documentation. The Ubity API allows you to initiate calls, send text messages (SMS), retrieve call recordings, get a user's phone presence status, and a whole lot more.

Sample code is available in Shell in the dark area to the right.


Authentication

To interact with the Ubity API, you will need an API key. You can request an API key by writing to Ubity Support.

The Ubity API expects an API key to be included in all API requests to the server as part of the GET or POST parameters.


  1. All requests …


Continue reading

Requesting, headers and encoding (and version)

Most endpoints support both GET and POST.

You may specify the encoding the API should use to return data.

The header to use is "Accept" and must contains a version information.

Accept: application/json;version=0

(version must be present, but is usualy reserved for the futur, therefore, some endpoints …


Continue reading

Calls

Initiate An Outgoing Call

Initiate an outgoing call on behalf of a user. The user who initiates the call is called first, and upon answering that call, is connected to the other party. The initial call will contain the other party's phone number as the CallerID number.

GET or POST …


Continue reading

Queue calls

Trigger/schedule a call to a queue

Initiate an call and place it in a queue.

GET or POST https://api.ubity.com/call

Parameter Description
key Your Ubity API key
queue The queue you want the call to be placed in
number The phone number to call (ie. '5551112222' …

Continue reading

Extensions

Get extensions list

This endpoint allows your application to get a list of your company's users, or extensions, as well as their current phone presence status (free, oncall).

GET or POST https://api.ubity.com/extensions?key=KKKK

Parameter Description
key Your Ubity API key
% curl -H "Accept: application/json …

Continue reading

Text Messages (SMS)

This endpoint delivers a text message (SMS) to a mobile phone number.

POST /sms

GET /sms/send

Parameter Description
key Your Ubity API key
from_number Phone number of the sender (ie. 5551112222)
to_number Phone number of the recipient (ie. 5551113333)
message Body of the message
curl -H "Accept: application/json …

Continue reading

Call Recordings

Get recordings list

This endpoint allows you to get a list of your call recordings and their duration in seconds (or null for directories). The recordings are listed by year, month, day, call direction.

The legacy behaviour of that endpoint (when you request without any header) is to give you …


Continue reading

Event Callbacks

Event Callbacks are used to notify your application whenever particular events occur on the Ubity telephony/UC platform. Ultimately, these events can range from a user making or receiving a call,

At the moment, these are the events that your application can subscribe to:

  • CallInitiated event
  • CallAnswered event
  • CallEnded event …

Continue reading