Table of Contents
The Callback API allows to integrate callback functionality to your project. It has following URLs:
Initialize a callback: #
A method to initialize a callback. Uses the HTTP-POST method.
| POST | https://api.tenios.com/callback/init |
Request Parameter: #
| access_key String Mandatory | The api access key. It can be found in the menu item General Settings, section API in the customer portal. |
| callback_config_id String Mandatory | The callback config id. You find it at the Callback Configurations page of the TENIOS portal. |
| callback_number String Mandatory | This is the phone number which should receive a call. |
| agent_announcement String Optional | A text for a message to be read aloud to the agent. A model supporting multiple languages is used for voice generation. The voice appropriate for the detected language is automatically assigned. |
| dtmf_key_to_trigger_customer_call String Optinal | The DTMF key that should be pressed to start the call. |
| delay String Mandatory | Delay (seconds) before calling. |
Example for a successful requests: #
Request: #
{
"access_key": "XXXXX-XXXX-XXXXXX",
"callback_config_id": "XXXXX-XXXX-XXXXXX",
"callback_number": "+491234567890",
"delay": 30
}
API Response: #
HTTP Status Code: 200 (OK)
{
"id": 10
}
Request: #
{
"access_key": "XXXXX-XXXX-XXXXXX",
"callback_config_id": "XXXXX-XXXX-XXXXXX",
"callback_number": "+491234567890",
"agent_announcement" : "Customer Peter Müller is being called now, please press 1 to start the call.",
"dtmf_key_to_trigger_customer_call" : "1",
"delay": 30
}
API Response: #
HTTP Status Code: 200 (OK)
{
"id": 10
}
Example for invalid requests: #
Â
API Response: #
HTTP Status Code: 400 (Bad Request)
{
"error_code": "BAD_CREDENTIALS",
"error_message": "Bad credentials",
"fields": []
}
Status of an existing callback: #
A method to query the status of an existing callback. Uses the HTTP-GET method.
| POST | https://api.tenios.com/callback/status |
Request Parameter:
| access_key String Obligatorisch | The api access key. It can be found in the menu item General Settings, section API in the customer portal. |
| id String Obligatorisch | The id of a callback request. This id was sent in the response body of the related init callback request |
| REQUESTED | Callback requested. |
| ACCEPTED | Callback request accepted. |
| CALLING_A | PartnerA is being called. |
| CALL_A_FAILED | Call to partner A not successful. |
| CALLING_B | Partner B is being called. |
| CALL_B_FAILED | Call to partner B not successful. |
| CONNECTED | Call connected (between partner A and B) |
| DISCONNECTED | Call disconnected (after successful call between partner A and B) |
Example of a successful request: #
Request: #
{
"access_key": "XXXXX-XXXX-XXXXXX",
"id": 10
}
API Response: #
HTTP Status Code: 200 (OK)
{
"status": "REQUESTED"
}
Example of unsuccessful requests: #
