NAV
shell php

Introduction

Welcome to Sipalto API documentation! This API allows you to easily connect, access, and interact with our services. Whether you're building something new or integrating with an existing system, our endpoints are designed to be clear, consistent, and developer-friendly.

Let's get started!

If you have any issues please contact us via our contact channels.

BASE URL: https://app-api.sipalto.com

Authentication

Request example:

curl --location 'https://app-api.sipalto.com/auth/login' \
--form 'username="demo"' \
--form 'password="demo"'
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://app-api.sipalto.com/auth/login',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS => array('username' => 'demo','password' => 'demo'),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

The above request returns JSON structured like this:

{
    "access_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwOi8vbG9jYWxob3N0OjgwMDgvYXV0aC9sb2dpbiIsImlhdCI6MTc0ODQzNDA4MywiZXhwIjoxNzQ4NDM3NjgzLCJuYmYiOjE3NDg0MzQwODMsImp0aSI6Ik5aOXB6OWlPcGpVNnEyWEUiLCJzdWIiOiI2NzAiLCJwcnYiOiIyM2JkNWM4OTQ5ZjYwMGFkYjM5ZTcwMWM0MDA4NzJkYjdhNTk3NmY3In0.x0j7uh902Lr1F4q0rti9oCXo7cke1buHt_dlGpL8mfc",
    "token_type": "bearer",
    "user": {
        "id": 670,
        "username": "demo",
        "password": "xxxxxxxxxxx",
        "updated_at": "2022-04-20T11:41:37.000000Z",
        "created_at": "2022-04-20T11:41:37.000000Z",
        "user_group": 2,
        "te_code": "demo"
    },
    "node": "node.sipalto.com",
    "expires_in": 86400
}

This is the very first endpoint to use for a squence of requests, here is where you can authenticate with the API.

This endpoint authenticates a user and provides a bearer token <access_token> valid for 24 hours.

HTTP Request

POST /auth/login

Body Payload

Parameter Required Type Description
username true string Username provided by Sipalto.
password true string Password provided by Sipalto.

Phonebooks

Get All Global Contacts

Request example:

curl --location 'https://app-api.sipalto.com/phone-books/get-global-contacts' \
--header 'Authorization: Bearer <access_token>'
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://app-api.sipalto.com/phone-books/get-global-contacts',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'GET',
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer <access_token>'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

The above request returns JSON structured like this:

{
    "success": true,
    "response": [
        {
            "id": "11111",
            "name": "Domino's Pizza",
            "phone1": "01491833000",
            "phone2": "07591524881",
            "phone3": "07591524882"
        },
        {
            "id": "22222",
            "name": "McDonald's",
            "phone1": "01491835522",
            "phone2": "",
            "phone3": ""
        }
    ]
}

This endpoint retrieves all global contacts.

Headers

Authorization: Bearer <access_token>

HTTP Request

GET https://app-api.sipalto.com/phone-books/get-global-contacts

Body Payload

Parameter Required Type Description

None

Add a Global Contact

Request example:

curl --location 'https://app-api.sipalto.com/phone-books/add-global-contact' \
--header 'Authorization: Bearer <access_token>' \
--form 'name="John Smith"' \
--form 'phone1="07852902011"' \
--form 'phone2="07730885627 "'
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://app-api.sipalto.com/phone-books/add-global-contact',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS => array('name' => 'John Smith','phone1' => '07852902011','phone2' => '07730885627'),
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer <access_token>'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

The above request returns JSON structured like this:

{
    "success": true,
    "response": "OK"
}

This endpoint adds a new record to global contacts.

Headers

Authorization: Bearer <access_token>

HTTP Request

POST https://app-api.sipalto.com/phone-books/add-global-contact

Body Payload

Parameter Required Type Description
name true string Name of the record (Person/Company)
phone1 true string Main phone number
phone2 false string Second phone number
phone3 false string Third phone number

Update a Global Contact

In this example we are updating the name of the contact

Request example:

curl --location 'https://app-api.sipalto.com/phone-books/update-global-contact/33333' \
--header 'Authorization: Bearer <access_token>' \
--form 'name="Julia Smith"' \
--form 'phone1="07852902011"' \
--form 'phone2="07730885627 "'
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://app-api.sipalto.com/phone-books/update-global-contact/33333',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS => array('name' => 'Julia Smith','phone1' => '07852902011','phone2' => '07730885627'),
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer <access_token>'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

The above request returns JSON structured like this:

{
    "success": true,
    "response": "OK"
}

This endpoint updates an existing record on global contacts.

Headers

Authorization: Bearer <access_token>

HTTP Request

POST https://app-api.sipalto.com/phone-books/update-global-contact/<ID>

URL Params

Parameter Description
ID The ID of the record/contact to update, can be obtained from get-global-contacts response

Body Payload

Parameter Required Type Description
name true string Name of the record (Person/Company)
phone1 true string Main phone number
phone2 false string Second phone number
phone3 false string Third phone number

Delete a Global Contact

In this example we are deleting Julia Smith's contact

Request example:

curl --location 'https://app-api.sipalto.com/phone-books/delete-global-contact/33333' \
--header 'Authorization: Bearer <access_token>'
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://app-api.sipalto.com/phone-books/delete-global-contact/33333',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'GET',
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer <access_token>'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

The above request returns JSON structured like this:

{
    "success": true,
    "response": "OK"
}

This endpoint deletes a contact from global contacts.

HTTP Request

GET https://app-api.sipalto.com/phone-books/delete-global-contact/<ID>

URL Parameters

Parameter Description
ID The ID of the record/contact to delete, can be obtained from get-global-contacts response

Call History

Get Answered Calls

Request example:

curl --location 'https://app-api.sipalto.com/call-history/get-answered-calls' \
--header 'Authorization: Bearer <access_token>' \
--form 'start="2025-10-08 00:00"' \
--form 'end="2025-10-08 23:59"' \
--form 'phone_number="1009"'
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://app-api.sipalto.com/call-history/get-answered-calls',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS => array('start' => '2025-10-08 00:00','end' => '2025-10-08 23:59','phone_number' => '1009'),
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer <access_token>'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

The above request returns JSON structured like this:

{
  "success": true,
  "response": {
    "SIPALTO-THE-ANL-ND2-1759926851.58197": {
        "call_id": "SIPALTO-THE-ANL-ND2-1759926851.58197",
        "caller": "07086202666",
        "callee": "1009",
        "direction": "IN",
        "disposition": "ANSWERED",
        "date": "2025-10-08 13:34:11",
        "duration": "41"
    },
    "SIPALTO-THE-ANL-ND2-1759927614.60572": {
        "call_id": "SIPALTO-THE-ANL-ND2-1759927614.60572",
        "caller": "1009",
        "callee": "07086202666",
        "direction": "OUT",
        "disposition": "ANSWERED",
        "date": "2025-10-08 13:46:54",
        "duration": "10"
    },
    "SIPALTO-THE-ANL-ND2-1759927635.60659": {
        "call_id": "SIPALTO-THE-ANL-ND2-1759927635.60659",
        "caller": "1009",
        "callee": "1007",
        "direction": "LOCAL",
        "disposition": "ANSWERED",
        "date": "2025-10-08 13:47:15",
        "duration": "14"
    },
  }
}

This retrieves a list of answered calls for a specific phone number in a date range.

Headers

Authorization: Bearer <access_token>

HTTP Request

POST https://app-api.sipalto.com/call-history/get-answered-calls

Body Payload

Parameter Required Type Description
start true string Range start date (YYYY-MM-DD HH:ii)
end true string Range end date (YYYY-MM-DD HH:ii)
phone_number true string Phone number to search calls for

Response Fields

Field Type Description
call_id string Call ID.
caller string The phone number or identifier of the person or system that initiated the call.
callee string The phone number or extension of the person or system that received the call.
direction string Indicates whether the call was inbound ("IN") or outbound ("OUT") or local ("LOCAL").
disposition string The final status of the call (e.g., "ANSWERED", "NO ANSWER", "BUSY", "FAILED").
date string The timestamp when the call started, in YYYY-MM-DD HH:ii:SS format.
duration string The total duration of the call in seconds.

Get Call Recording

Request example:

curl --location 'https://app-api.sipalto.com/call-history/get-call-recording' \
--header 'Authorization: Bearer <access_token>' \
--form 'call_id="SIPALTO-THE-ANL-ND2-1759927635.60659"'
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://app-api.sipalto.com/call-history/get-call-recording',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS => array('call_id' => 'SIPALTO-THE-ANL-ND2-1759927635.60659'),
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer <access_token>'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

The above request returns an audio/wav

This retrieves the recording for the given call

Headers

Authorization: Bearer <access_token>

HTTP Request

POST https://app-api.sipalto.com/call-history/get-call-recording

Body Payload

Parameter Required Type Description
call_id true string Call ID

Get Call Transcription

Request example:

curl --location 'https://app-api.sipalto.com/call-history/get-call-transcription' \
--header 'Authorization: Bearer <access_token>' \
--form 'call_id="SIPALTO-THE-ANL-ND2-1759927635.60659"'
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://app-api.sipalto.com/call-history/get-call-transcription',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS => array('call_id' => 'SIPALTO-THE-ANL-ND2-1759927635.60659'),
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer <access_token>'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

The above request returns JSON structured like this:

{
  "success": true,
  "response": [
    {
        "uniqueid": "SIP-NODE-04-1759929221.139294",
        "speaker": "0",
        "start": "6880.00",
        "end": "105460.00",
        "text": "Hello?. Hello, how can I help you?. Nothing. Thank you. Thanks. Bye. Bye.",
        "reid": "20891435"
    },
    {
        "uniqueid": "SIP-NODE-04-1759929221.139294",
        "speaker": "0",
        "start": "6880.00",
        "end": "9280.00",
        "text": "Hello?",
        "reid": "20891501"
    },
    {
        "uniqueid": "SIP-NODE-04-1759929221.139294",
        "speaker": "1",
        "start": "9680.00",
        "end": "14560.00",
        "text": " Hello, how can I help you?",
        "reid": "20891501"
    },
    {
        "uniqueid": "SIP-NODE-04-1759929221.139294",
        "speaker": "0",
        "start": "14720.00",
        "end": "17280.00",
        "text": " Nothing.",
        "reid": "20891501"
    },
    {
        "uniqueid": "SIP-NODE-04-1759929221.139294",
        "speaker": "1",
        "start": "17280.00",
        "end": "21200.00",
        "text": "Thank you.",
        "reid": "20891501"
    },
    {
        "uniqueid": "SIP-NODE-04-1759929221.139294",
        "speaker": "0",
        "start": "21760.00",
        "end": "33420.00",
        "text": "Thanks.",
        "reid": "20891501"
    },
    {
        "uniqueid": "SIP-NODE-04-1759929221.139294",
        "speaker": "1",
        "start": "49660.00",
        "end": "97060.00",
        "text": "Bye.",
        "reid": "20891501"
    },
    {
        "uniqueid": "SIP-NODE-04-1759929221.139294",
        "speaker": "0",
        "start": "102980.00",
        "end": "105460.00",
        "text": "Bye.",
        "reid": "20891501"
    },
  ]    
}

This retrieves the transcription for the given call

Headers

Authorization: Bearer <access_token>

HTTP Request

POST https://app-api.sipalto.com/call-history/get-call-transcription

Body Payload

Parameter Required Type Description
call_id true string Call ID

Response Fields

Field Type Description
uniqueid string Call ID.
speaker string The speaker label (e.g., "0", "1") identifying which participant is speaking. Speaker detection is based on voice diarization.
start string Start time of the speech segment.
end string End time of the speech segment.
text string The actual transcribed text spoken by the identified speaker during this time window.
reid string Internal reference ID.

Notes

Errors

The Sipalto API uses the following error codes:

Error Code Meaning
400 Bad Request -- Your request is invalid.
401 Unauthorized -- Your access_token is invalid.
403 Forbidden -- Permission Denied.
404 Not Found -- Specific request could not be found.
405 Method Not Allowed -- Wrong method used.
406 Not Acceptable -- Wrong format.
429 Too Many Requests -- You're requesting too many times.
500 Internal Server Error -- We had a problem with our server. Try again later.
503 Service Unavailable -- We're temporarily offline for maintenance. Please try again later.