Call Records (CDR)

Call Detail Records

A call detail record is a data record produced by a telephone exchange.
The record contains various attributes of the call, such as time, duration, completion status, source number, and destination number.

A detailed list of call logs can be retrieved using the below method.

curl --request GET \
  --url https://api.servetel.in/v1/call/records \
  --header 'accept: application/json' \
  --header 'authorization: Bearer yourtokenhere'

Query Parameters

Variable nameDescriptionData Type
from_dateDate from where records need to be fetched
Format: Y-m-d H:i:s
String
to_dateDate till where records need to be fetched
Format: Y-m-d H:i:s
String
pagePage numberString
limitNumber of records to be fetchedString
agentsArray of agents containing values in below format:
agent||id.
Array
departmentUnique IDs of departmentsArray
ivrUnique IDs of IVRsArray
call_typeType of the call.
[ c = answered, m = missed ]
String
calleridCaller ID of the client
[clients number]
String
destinationServetel number where incoming call is directedString
directionDirection of the call (inbound/outbound)String
durationTotal duration of the callString
operatorMathematical operator to be used for duration filter

Allowed filters:
[>, <, >=, <=, !=]
String
servicesComma (,) separated servicesString

📘

Note:

Names of the agents/department/ivr/broadcast will take values in lowercase

{
	"count": 1,
	"limit": 20,
	"size": 20,
	"page": 1,
	"results": [{
		"id": 1,
		"call_id": "123456789.987654321",
		"uuid": "5e3c0abcdefghty",
		"direction": "inbound",
		"description": "Call answered by Test Agent 1 (919876543210)",
		"detailed_description": null,
		"status": "answered",
		"blocked_number_id": null,
		"recording_url": "https://recording_path/123/123_recording_id.mp3",
		"service": "Agent: Test Agent 1",
		"date": "2020-01-01",
		"time": "11:59:59",
		"end_stamp": "2020-01-01 11:59:59",
		"broadcast_id": null,
		"dtmf_input": null,
		"call_duration": 1,
		"answered_seconds": 1,
		"minutes_consumed": 1,
		"charges": 0,
		"department_name": null,
		"agent_number": "+919876543210",
		"agent_name": "Test Agent 1",
		"client_number": "+919874563210",
		"did_number": "+911204000000",
		"reason": null,
		"hangup_cause": "Normal clearing",
		"notes": null,
		"contact_details": {
			"field_0": "+919874563210",
			"field_1": "Test Client"
		},
		"missed_agents": [{
			"name": "Test Agent 2",
			"number": "+919874561230"
		}],
		"call_flow": [{
			"type": "init",
			"value": "123456789.987654321",
			"time": "1577879999"
		}]
	}]
}