Skip to main content
Skip table of contents

The list of calls

The list of calls

History of all calls on all added intercoms. A call can have the following statuses:

ring - a call is in progress, but not yet answered.

answered - a call is currently active with an ongoing conversation.

ended - a call has been successfully completed.

missed - a missed call.

GET /api/v1/intercom/calls

Parameters

int per_page, Number of elements in one pagination page.


int page, Pagination page number


int intercom, The identifier of the intercom, for filtering calls by a specific intercom


array types, Filtering by call type. Possible values: missed_intercom_call, answered_intercom_call


int camera, Filtering by camera, the response will only contain those calls that are associated with this camera

200 OK

Successful response

JSON
{
    "data": [
        {
            "id": 5546,
            "status": "ended",
            "created_at": "2022-02-04 15:53:04",
            "intercom": {
                "id": 158,
                "title": "test",
                "is_online": false,
                "department": 1,
                "address": "Original cameras, Other cameras",
                "camera": {
                    "id": 832,
                    "group_id": 124,
                    "status": "inactive",
                    "type": "media_server_v2",
                    "start_at": "",
                    "created_at": "2022-02-18 15:03:58",
                    "billing_id": null,
                    "pretty_name": "intercom 1",
                    "lat": null,
                    "lng": null,
                    "azimuth": null,
                    "is_archive_recording": true,
                    "is_bridge": false,
                    "is_favorite": false,
                    "user_status": "active",
                    "name": "intercom 1"
                },
                "created_at": "2021-11-18T11:22:30.000000Z",
                "updated_at": "2022-02-21T15:48:56.000000Z"
            },
            "started_at": "2022-02-04 15:53:07",
            "ended_at": "2022-02-04 15:54:02"
        },
        {
            "id": 2220,
            "status": "missed",
            "created_at": "2021-12-03 14:22:16",
            "intercom": {
                "id": 158,
                "title": "test",
                "is_online": false,
                "department": 1,
                "address": "Original cameras, Other cameras",
                "camera": {
                    "id": 832,
                    "group_id": 124,
                    "status": "inactive",
                    "type": "media_server_v2",
                    "start_at": "",
                    "created_at": "2022-02-18 15:03:58",
                    "billing_id": null,
                    "pretty_name": "intercom 1",
                    "lat": null,
                    "lng": null,
                    "azimuth": null,
                    "services": {
                        "ptz": false,
                        "motion_detect": false
                    },
                    "is_archive_recording": true,
                    "is_bridge": false,
                    "is_favorite": false,
                    "user_status": "active",
                    "name": "intercom 1"
                },
                "created_at": "2021-11-18T11:22:30.000000Z",
                "updated_at": "2022-02-21T15:48:56.000000Z"
            },
            "started_at": null,
            "ended_at": null
        }
    ],
    "links": {
        "first": "https://vms.local/api/v1/intercom/calls?page=1",
        "last": "https://vms.local/api/v1/intercom/calls?page=12",
        "prev": null,
        "next": "https://vms.local/api/v1/intercom/calls?page=2"
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 12,
        "links": [
            {
                "url": null,
                "label": "pagination.previous",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=1",
                "label": "1",
                "active": true
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=2",
                "label": "2",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=3",
                "label": "3",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=4",
                "label": "4",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=5",
                "label": "5",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=6",
                "label": "6",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=7",
                "label": "7",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=8",
                "label": "8",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=9",
                "label": "9",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=10",
                "label": "10",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=11",
                "label": "11",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=12",
                "label": "12",
                "active": false
            },
            {
                "url": "https://vms.local/api/v1/intercom/calls?page=2",
                "label": "pagination.next",
                "active": false
            }
        ],
        "path": "https://vms.local/api/v1/intercom/calls",
        "per_page": 15,
        "to": 15,
        "total": 168
    }
}

401 Unauthorized

Authorization token not sent or not valid

422 Unprocessable Entity

Returns a JSON object with an error.

JSON
{
    "message": "There will be no informative message here",
    "errors": {
        "any_key": [
            "The cause of the error will be described here"
        ]
    }
}
cURL
BASH
curl -k --request POST \
	--url 'https://your-domain/api/v1/intercom/calls' \
	--header 'Content-Type: application/json' \
	--header 'Accept: application/json' \
	--data '{
    "per_page": 0,
    "page": 0,
    "intercom": 0,
    "types": [],
    "camera": 0
}'
PHP
PHP
$data = array (
  'per_page' => 0,
  'page' => 0,
  'intercom' => 0,
  'types' => 
  array (
  ),
  'camera' => 0,
);
$context = stream_context_create([
	'ssl'=>['verify_peer' => false],
	'http' => [
		'method' => 'GET',
		'header' => "Content-Type: application/json\r
Accept: application/json",
		'content'=>json_encode($data)
	]
]);
$result = file_get_contents('https://your-domain/api/v1/intercom/calls', false, $context);
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.