Introduction #
This document aims to provide end users with a comprehensive understanding of the functionality of Call Log API V2. It outlines the key features and demonstrates how to effectively filter data using parameters such as start date, end date, and phone number. The goal is to ensure users can leverage the API to its full potential for efficient data retrieval.
Overview #
The Call Log API enables users to access detailed records of all inbound and outbound calls. This API allows for efficient tracking of call data, providing insights into call durations, timestamps, audio link of a recorded call and related customer information.
Objectives #
The goal of this API is to give support agents the ability to:
- View the call logs for the last 30 days (with count).
- Filter and view older call history based on a specified date range (maximum of one month).
Functional Requirements #
1. View Recent Call Interactions #
- Description: Support agents get access to a contact’s past 30 days of interactions as well as the total number of interactions. Call-specific information will be included in every contact.
- Data Fields:
- Agent Full Name: Full Name of an agent who received/made the call
- Agent Extension: Call Extension of an agent
- Trunk: Trunk used to make the call
- Call Date: Date and time the call was made or received.
- Duration: Length of the call in seconds.
- Phone Number: Phone number of the caller of inbound call or recipient of outbound call.
- Disposition: Disposition of a call
- Recording Link: A audio link of a recorded call
- Wrap-up: Wrap-up of the call.
- User Interface:
- Support agents will have the ability to filter and view older call history interactions. They can specify a date range and phone number with a maximum limit of one month.
- The interactions will be displayed in chronological order, with the most recent calls at the top.
- This information will be displayed in a section within the contact’s profile or a dedicated “Call History” tab in Getdesk.
2. Access through API #
- Description: The feature should be accessible through an API that interacts with the CRM system, allowing other applications or services to request and retrieve call details.
- Supported HTTP request method: GET
API Link:
- API Endpoints:
CallLogAPI
:GET /CallLogAPI?phone_number=xxx&token=xxxx
: Retrieves the last 30 days call interactions for a contact.GET /CallLogAPI?start_date=YYYY-MM-DD&end_date=YYYY-MM-DD&token=xxxx&phone_number=xxxx
: Retrieves call interactions within the specified date range.
CallLogCountAPI
:GET /CallLogCountAPI?phone_number=xxx&token=xxxx
: Retrieves the last 30 days inbound and outbound call count for a contact.GET /CallLogCountAPI?start_date=YYYY-MM-DD&end_date=YYYY-MM-DD&token=xxxx&phone_number=xxxx
: Retrieves inbound and outbound call count of phone single or multiple hone number within the specified date range.
- Mandatory Fields :
- phone_number: The phone number of the customer.
- In case of
CallLogCountAPI
, you can send single phone number or multiple phone numbers separated by comma. eg phone_number : 98xxxxxxx8,98xxxxxxx7 - In case of
CallLogAPI
, you can send single phone number
- In case of
- token: A token will be provided by Voxcrow
- phone_number: The phone number of the customer.
- Optional Fields (For both
CallLogAPI
andCallLogCountAPI
):start_date :
starting date of the call log of specific contact with contact_idend_date
: end date of the call log of specific contact with contact_id- note: Higher date range could impact response time. For now, the date range can be set to a maximum of 1 month.
- These fields are optional but should be provided together if date filter is needed
- Datetime should be in 24 hour format
- Response Format:
- The API should return data in JSON format with all required fields.
- If no interactions are found within the specified date range, the API should return an appropriate message.
- Responses:
- Status code: 405 – Invalid request method
- Status code: 401 – Unauthorized due to invalid token
- Status code: 400 – Token not provided
- Status code: 500 – Internal sever error
- Status code: 200 – Call logs data received
- Security:
- Ensure API security measures are in place, such as authentication and authorization.
- Access to call history data should be limited to authorized users only.
Non-Functional Requirements #
1. Performance #
- The feature should retrieve the last 30 days of interactions in under 6 seconds.
- Filtering by date should take less than 12 seconds to return results.
2. Scalability #
- The feature should support a large number of contacts and interactions without degrading performance.
3. Security #
- Ensure compliance with data privacy laws and regulations.
- Implement robust authentication and authorization mechanisms.
Response of CallLogAPI: #
[ { "agent_fullname": "Franklin", "phone_number": "9811789678", "agent_extension": "2003", "trunk": "+97712970852", "calldate": "2024-05-06 11:21:23", "duration": 16, "disposition": "NO ANSWER", "call_type": "outbound", "recording_link": "yourcompany.getdesk.net/records/2024/05/06/out-9801103967-2003-20240503-112122-1714973763.1108.wav", "wrapup_name": "", "wrapup_note": null }, ... ]
Response of CallLogCountAPI: #
[ { "total_calls": 59, "phone_number": "9811789678", "inbound_calls": "1", "outbound_calls": "58" } ]
Conclusion #
The feature to view call details and history in a CRM through an API will enhance the support agent’s ability to provide effective customer service. By accessing recent and historical call data, agents can better understand customer needs and respond accordingly.