API Reference

API Reference

PhoneBridge API Documentation
NAV

    Introduction

    Zoho CRM introduces the PhoneBridge API (Application Programming Interface) to integrate your PBX (Private Branch eXchange) system with Zoho CRM. Upon successful integration, the following functionalities will be enabled in your CRM account:


    • Call your leads and customers within Zoho CRM using ClicktoCall functionality.
    • Get automatic screen pop-ups for all incoming calls, , which enables to provide a personalized customer service.
    • View the caller details on your soft phone or desk phone while making calls inside CRM.
    • Incoming and outgoing call events will be automatically logged inside CRM.

    Getting Started

    API Endpoint

    https://www.zohoapis.com/crm/v2/phonebridge
      

    Before you get started with the PhoneBridge API, you need register yourself as PBX vendor and integrate your Zoho CRM Account.

    1. PBX Vendor Registration:

    You should register your Developer CRM Account under Setup > Developer Space. To register your PBX, please do the following:


    • OAuth Registration for Zoho CRM.
    • Define clicktocall and call control URLS.

    2. Integrating with Zoho CRM Account:

    To integrate any Zoho CRM Account, please do the following:


    • Enable PhoneBridge Integration for a particular CRM Account.
    • Enable clicktocall and call control for a particular user.
    • Notify Zoho CRM for incoming and outgoing calls.

    Understanding Authentication

    Example Request:

    curl -X GET -H "Authorization: Zoho-oauthtoken 
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"

    https://www.zohoapis.com/crm/v2/phonebridge

    curl uses the -H flag to pass the OAuth credentials. Replace the sample OAuthtoken with your actual token to test requests from your CRM account. Note that, the OAuthtoken is valid only for 60 minutes from the time of generation.

    Zoho CRM REST API supports OAuth protocol to enable users access data in a secured way.

    Before making API Calls, please make sure that you authenticate using OAuth, so that you have the permission to access the API service.

    The PhoneBridge API requires the following mandatory header:

    Authorization - OAuthtoken request header.

    Understanding HTTP Methods

    Method Description
    GET To retrieve data from the given server.
    POST To insert or upload any new resource to the server.
    PUT To update an existing resource. This replaces the target resource with the updated content.
    DELETE To delete a resource at a particular location.

    Each resource in Zoho CRM is accessed using standard HTTP methods such as GET, POST, PUT and DELETE, which are used to read, create, update and delete resources respectively. Please note that, all the response and requests will be in JSON format (JSON object).

    Understanding HTTP Status Codes

    Status Codes Meaning Description
    200 OK The API request is successful.
    204 NO CONTENT There is no content available for the request.
    400 BAD REQUEST The request is considered to be invalid.
    401 AUTHORIZATION ERROR Invalid authtoken provided.
    403 FORBIDDEN No permission to do the operation.
    404 NOT FOUND Invalid request.
    405 METHOD NOT ALLOWED The specified method is not allowed.
    500 INTERNAL SERVER ERROR Generic error that is encountered due to an unexpected server error.

    Zoho PhoneBridge API uses HTTP status codes to specify the success or failure of an API request.

    Enable/disable Integration

    
    

    Example Request:

    To enable Telephony integration,

    curl -X POST -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"

    https://www.zohoapis.com/crm/v2/phonebridge/integrate

    Example Response:

    StatusCode:HttpStatus.SC_OK(200)

    { "message": "(PBX Name) Integration is successful" "status": "success", "code": "SUCCESS", }

    Example Request:

    To disable Telephony integration,

    curl -X DELETE -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"

    https://www.zohoapis.com/crm/v2/phonebridge/integrate

    Example Response:

    StatusCode:HttpStatus.SC_OK(200)

    { "message": "(PBX Name)Integration has been successfully removed" "status": "success", "code": "SUCCESS", }

    Error Responses:

    StatusCode:HttpStatus.SC_FORBIDDEN(403):

    The following error response will be sent, if the telephony integration is not accessible for the current user's license.

    { "message": "PBX Integration is not available for your license type" "status": "error", "details": {}, "code": "NO_PERMISSION", }

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case of an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_FORBIDDEN(403):

    The following error response will be sent, if the requested user does not have enough permission to perform the PhoneBridge integration.

    { "message": "Requested user doesn't have enough privilege in Zoho CRM to enable PhoneBridge integration" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following response is sent, if the PhoneBridge registration information is not available for the PBX vendor name that is obtained from the OAuth Token object.

    { "message": "(PBX Name) is not registered" "status": "error", "details": {}, "code": "PBX_NOT_REGISTERED", }

    StatusCode:HttpStatus.SC_FORBIDDEN(403):

    The following error response is sent, if the same PBX integration has already been enabled for the account.

    { "message": "(PBX Name) has been already enabled for the Account" "status": "error", "details": {}, "code": "PBX_ALREADY_ENABLED", }

    StatusCode:HttpStatus.SC_FORBIDDEN(403):

    The following error response is sent, if a different PBX integration has been enabled for the account already.

    { "message": "Different PBX has been enabled for the Account" "status": "error", "details": {}, "code": "DIFFERENT_PBX_ALREADY_ENABLED", }

    Purpose

    To enable/disable the PBX vendor integration within CRM.

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/integrate

    Request Method

    POST - To enable integration

    DELETE- To disable integration

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.

    * - Mandatory parameters

    Enable/disable clicktocall & call control

    Example Request:

    To enable clicktocall and call control,

    curl -X POST -d "clicktocallurl=https://pbx.com/clicktocall" -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"

    https://www.zohoapis.com/crm/v2/phonebridge/clicktocallandcallcontrol

    Example Response:

    StatusCode:HttpStatus.SC_OK(200):

    The following response is sent when callcontrol is enabled for the account successfully.

    { "message": "(PBX Name) Call control notifications has been enabled for the account
    successfully"
    "status": "success", "code": "SUCCESS", }

    Example Request:

    To disable clicktocall and call control,

    curl "https://www.zohoapis.com/crm/v2/phonebridge/clicktocallandcallcontrol" -X DELETE -H "Authorization: Zoho-oauthtoken 1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"

    Example Response:

    StatusCode:HttpStatus.SC_OK(200):

    The following response is sent when callcontrol and clicktocall is disabled for the account.

    { "message": "(PBX Name) Call control notifications has been disabled for the account successfully" "status": "success", "code": "SUCCESS", }

    Error Responses:

    StatusCode:HttpStatus.SC_FORBIDDEN(403):

    The following error response will be sent if the telephony integration is not accessible for the current user's license.

    { "message": "PBX Integration is not available for your license type" "status": "error", "details": {}, "code": "NO_PERMISSION", }

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent in case there is an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_FORBIDDEN(403):

    The following error response will be sent, if the callcontrol parameters has been sent and the requested user does not have enough permission to perform the PhoneBridge integration.

    { "message": "Requested user doesn't have enough privilege to perform this process" "status": "error", "details": {}, "code": "NO_PERMISSION", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following response is sent, if the PhoneBridge registration information is not available for the PBX vendor name that is obtained from the OAuth Token object.

    { "message": "(PBX Name) is not registered" "status": "error", "details": {}, "code": "PBX_NOT_REGISTERED", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following error response is sent, if the PBX vendor integration information is not available.

    { "message": "(PBX Name) Integration is not enabled" "status": "error", "details": {}, "code": "PBX_NOT_INTEGRATED", }

    Purpose

    To enable or disable the clicktocall and call control functionality for the users. We will post the call details to the clicktocall API whenever a CRM user uses clicktocall button to initiate an outbound call from within Zoho CRM. Vendors can also send the call functionality URLs such as clicktocallurl, answerrul, hungupurl, muteurl, unmuteurl, holdurl, unholdurl, and keypressurl as parameters in this API. Please note that, these parameters has to be sent in URL format.

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/clicktocallandcallcontrol

    Request Method

    POST - To enable clicktocall and call control notifications

    DELETE - To disable clicktocall and call control notifications

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    clicktocallurl* To be used for the clicktocall functionality. It has to be sent in URL format as shown below:
    https://api.pbx.com/zoho/clicktocall
    answerurl To send a request to answer the call. It has to be sent in URL format as shown below:
    https://api.pbx.com/zoho/answerurl
    hungupurl To send a request to hungup the call. It has to be sent in URL format as shown below:
    https://api.pbx.com/zoho/hungupurl
    muteurl To send a request to mute the call. It has to be sent in URL format as shown below:
    https://api.pbx.com/zoho/muteurl
    unmuteurl To send a request to unmute the call. It has to be sent in URL format as shown below:
    https://api.pbx.com/zoho/unmuteurl
    holdurl To send a request to hold the call. It has to be sent in URL format as shown below:
    https://api.pbx.com/zoho/holdurl
    unholdurl To send a request to unhold the call. It has to be sent in URL format as shown below:
    https://api.pbx.com/zoho/unholdurl
    keypressurl To send the details about the keys/digits pressed during the call.It has to be sent in URL format as shown below:
    https://api.pbx.com/zoho/keypressurl
    userid If you want to enable clicktocall and call control for multiple users, you have to pass the userid parameter in your API request. Userid is the id of the CRM user who is making the outbound call. You can send multiple userids as a comma seperated string. Both incoming and outgoing notifications will be enabled for the mentioned users.
    authorizationparam authorization param contains the name and value pairs in JSON format. Example: {name:param/header name,value:token value}
    clicktocallparam

    It is a parameter in the JSON array format with name and value pairs. This param can be used when you want to send any custom parameters while calling the clicktocall API. You are allowed to send any number of names and value pairs using clicktocallparam.

    Example: [{name:pbxuserid,value:pbxuser1234}, {name:emailaddress,value:xyz@pbx.com}]
    callcontrolparam

    It is a parameter in the JSON array format with name and value pairs. This param can be used when you want to send any custom parameters while calling the callcontrol APIs. You are allowed to send any number of names and value pairs using callcontrolparam.

    Example: [{name:pbxuserid,value:pbxuser1234}, {name:emailaddress,value:xyz@pbx.com}]

    * - Mandatory parameters

    Incoming Call APIs

    Call received

    Example Request:

    curl -X POST -d "callrefid=<unique_id>&fromnumber=<caller_number>
    &tonumber=<callee_number>"
    -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/callreceived

    Example Response:

    { "data": [ { "Name": "EntityName", "Module": "ModuleName", "Id": "EntityId", "Company/Account": "Company/Account Name", "Email": "Email Address", "Phone": "PhoneNumber", "Mobile": "MobileNumber", "Department": "DepartmentName", "Url": "Entity Zoho CRM Url", "Potential": [ { "Name": "PotentialName", "Id": "PotentialId", "PotentialOwner": "Potential Owner Name", "ClosingDate": "Closing Date Value", "ExpectedRevenue": "Expected Revenue Value", "Stage": "Potential Stage", "Url": "Entity Zoho CRM Url", "Probability": "Probability Value", }, { "Name": "PotentialName", "Id": "PotentialId", "PotentialOwner": "Potential Owner Name", "ClosingDate": "Closing Date Value", "ExpectedRevenue": "Expected Revenue Value", "Stage": "Potential Stage", "Url": "Entity Zoho CRM Url", "Probability": "Probability Value", } ] } ] }

    Error Responses:

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case of an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following error response will be sent, if all the mandatory parameters are not sent in the API request.

    { "message": "One of the expected parameters is missing" "status": "error", "code": "REQUIRED_PARAM_MISSING", "details": {"param":"id"}, }

    Purpose

    To notify an inbound call when the destination phone rings

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/callreceived

    Request Method

    POST

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    callrefid* A unique caller id generated by the PBX vendor. The callrefid should be sent in the format shown below:
    callid123456
    fromnumber* Contact number of the Agent or Customer based on the call state. The fromnumber should be sent in the phone number format. For example: 0018885554567
    tonumber* Contact number of the Agent or Customer based on the call state. The tonumber should be sent in the phone number format. For example: 0018885556748
    userid It is the unique id of the CRM user.
    transfercallrefid This is the unique caller id of the transferred call.

    * - Mandatory parameters

    Call answered

    Example Request:

    curl -X POST -d "callrefid=<unique_id>&fromnumber=<caller_number>
    &tonumber=<callee_number>"
    -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/callanswered

    Example Response:

    { "data": [ { "Name": "TestLead", "Id": "EntityId", "Module": "ModuleName", } ] }

    Error Responses:

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case of an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following error response will be sent, if all the mandatory parameters are not sent in the API request.

    { "message": "One of the expected parameters is missing" "status": "error", "code": "REQUIRED_PARAM_MISSING", "details": {"param":"id"}, }

    Purpose

    To notify when a destination client/agent/phone answers the call

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/callanswered

    Request Method

    POST

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    callrefid* A unique caller id generated by the PBX vendor. The callrefid should be sent in the format shown below:
    callid123456
    fromnumber* Contact number of the Agent or Customer based on the call state. The fromnumber should be sent in the phone number format. For example: 0018885554567
    tonumber* Contact number of the Agent or Customer based on the call state. The tonumber should be sent in the phone number format. For example: 0018885556748
    userid It is the unique id of the CRM user.

    * - Mandatory parameters

    Call hungup

    Example Request:

    curl -X POST -d "callrefid=<unique_id>&fromnumber=<caller_number>
    &tonumber=<callee_number>&callstarttime=<time_call_initiated>
    &duration=<call_duration>&direction=<call_direction>"
    -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/callhungup

    Example Response:

    { "data": [ { "Name": "EntityName", "Id": "EntityId", "Module": "ModuleName", } ] }

    Error Responses:

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case of an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following error response will be sent, if all the mandatory parameters are not sent in the API request.

    { "message": "One of the expected parameters is missing" "status": "error", "code": "REQUIRED_PARAM_MISSING", "details": {"param":"id"}, }

    Purpose

    To notify when a call is hungup or has ended

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/callhungup

    Request Method

    POST

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    callrefid* A unique caller id generated by the PBX vendor. The callrefid should be sent in the format shown below:
    callid123456
    fromnumber* Contact number of the Agent or Customer based on the call state. The fromnumber should be sent in the phone number format. For example: 0018885554567
    tonumber* Contact number of the Agent or Customer based on the call state. The tonumber should be sent in the phone number format. For example: 0018885556748
    userid It is the unique id of the CRM user.
    callstarttime* The start time of the incoming call. The callstarttime should be in yyyy-MM-dd HH:mm:ss format. For example, 2016-09-20 15:09:10. Also, set GMT as your time zone.
    direction* Set the value as inbound.
    duration* Call recording duration in seconds.
    voiceurl URL of the audio file where the voicemessage s available.

    * - Mandatory parameters

    Call missed

    Example Request:

    curl -X POST -d "callrefid=<unique_id>&fromnumber=<caller_number>
    &tonumber=<callee_number>&callmissedtime=<time_call_missed>"
    -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/callmissed

    Example Response:

    { "data": [ { "Name": "EntityName", "Id": "EntityId", "Module": "ModuleName", } ] }

    Error Responses:

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case of an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400) :

    The following error response will be sent, if all the mandatory parameters are not sent in the API request.

    { "message": "One of the expected parameters is missing" "status": "error", "code": "REQUIRED_PARAM_MISSING", "details": {"param":"id"}, }

    Purpose

    To notify when a call is missed

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/callmissed

    Request Method

    POST

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    callrefid* A unique caller id generated by the PBX vendor. The callrefid should be sent in the format shown below:
    callid123456
    fromnumber* Contact number of the Agent or Customer based on the call state. The fromnumber should be sent in the phone number format. For example: 0018885554567
    tonumber* Contact number of the Agent or Customer based on the call state. The tonumber should be sent in the phone number format. For example: 0018885556748
    userid It is the unique id of the CRM user.
    callmissedtime* Time when the call is missed. (Date-Time Format: yyyy-MM-dd HH:mm:ss. For example, 2016-09-20 15:09:10). Also, set GMT as your time zone.
    voicemailurl voicemailurl has the file path of the voicemail i.e., URL of the audio file where the voice message is available.
    sequential

    To indicate whether there is a need to create a call activity. Call activity will be created in case if a call is missed.

    sequential = true
    If a user is unavailable, then the call will be forwarded to the next user. Sequential = true will be sent only if the call is forwarded to the next available user. Call activity will not be created if sequential = true

    sequential = false
    Call activity will be created, since the call has not been answered by any user.

    * - Mandatory parameters

    Outgoing Call APIs

    Call dialed

    Example Request:

    curl -X POST -d "callrefid=<unique_id>&fromnumber=<caller_number>
    &tonumber=<callee_number>&customerstatus=<customer_phone_status>"
    -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/calldialed

    Example Response:

    { "data": [ { "Name": "EntityName", "Module": "ModuleName", "Id": "EntityId", "Company/Account": "Company/Account Name", "Email": "Email Address", "Phone": "PhoneNumber", "Mobile": "MobileNumber", "Department": "DepartmentName", "Url": "Entity Zoho CRM Url", "Potential": [ { "Name": "PotentialName", "Id": "PotentialId", "PotentialOwner": "Potential Owner Name", "ClosingDate": "Closing Date Value", "ExpectedRevenue": "Expected Revenue Value", "Stage": "Potential Stage", "Url": "Entity Zoho CRM Url", "Probability": "Probability Value", }, { "Name": "PotentialName", "Id": "PotentialId", "PotentialOwner": "Potential Owner Name", "ClosingDate": "Closing Date Value", "ExpectedRevenue": "Expected Revenue Value", "Stage": "Potential Stage", "Url": "Entity Zoho CRM Url", "Probability": "Probability Value", } ] } ] }

    Error Responses:

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case of an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following error response will be sent, if all the mandatory parameters are not sent in the API request.

    { "message": "One of the expected parameters is missing" "status": "error", "code": "REQUIRED_PARAM_MISSING", "details": {"param":"id"}, }

    Purpose

    To notify an outbound call when the destination phone rings or is about to ring

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/calldialed

    Request Method

    POST

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    callrefid* A unique caller id generated by the PBX vendor. The callrefid should be sent in the format shown below:
    callid123456
    fromnumber* Contact number of the Agent or Customer based on the call state. The fromnumber should be sent in the phone number format. For example: 0018885554567
    tonumber* Contact number of the Agent or Customer based on the call state. The tonumber should be sent in the phone number format. For example: 0018885556748
    userid It is the unique id of the CRM user.
    agentstatus Status of the sales agent's phone number. The agentstatus can be any of the following:
    success - The agent has successfully connected the call.
    notavailable - The agent number is not available.
    rejected - The call has been rejected by the agent.
    noanswer - The call has ended without being answered by the agent.
    busy - Agent phone is busy.
    internationaldisabled- International connection is disabled.
    notenoughfunds - No sufficient funds to make the call.
    blocked - The call is blocked.
    customerstatus* Status of the call made to your customer. The customerstatus can be any of the following:
    success - The customer has successfully answered the call.
    inprogress - The call was answered and is in progress currently.
    notavailable - The customer is not available to answer the call.
    rejected - The customer has rejected the call.
    noanswer - The call has ended without being answered by the customer.
    busy - The caller has received a busy signal.
    blocked - The caller has been blocked
    invalid - The call made was invalid.

    * - Mandatory parameters

    Call hungup

    Example Request:

    curl -X POST -d "callrefid=<unique_id>&fromnumber=<caller_number>
    &tonumber=<callee_number>&callstarttime=<time_call_initiated>
    &duration=<call_duration>&direction=<call_direction>"
    -H "Authorization: Zoho-oauthtoken 1
    000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/callhungup

    Example Response:

    { "data": [ { "Name": "EntityName", "Id": "EntityId", "Module": "ModuleName", } ] }

    Error Responses:

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case of an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following error response will be sent, if all the mandatory parameters are not sent in the API request.

    { "message": "One of the expected parameters is missing" "status": "error", "code": "REQUIRED_PARAM_MISSING", "details": {"param":"id"}, }

    Purpose

    To notify when a call is hungup or has ended

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/callhungup

    Request Method

    POST

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    callrefid* A unique caller id generated by the PBX vendor. The callrefid should be sent in the format shown below:
    callid123456
    fromnumber* Contact number of the Agent or Customer based on the call state. The fromnumber should be sent in the phone number format. For example: 0018885554567
    tonumber* Contact number of the Agent or Customer based on the call state. The tonumber should be sent in the phone number format. For example: 0018885556748
    userid It is the unique id of the CRM user.
    callstarttime* The start time of the call. The callstarttime should be in yyyy-MM-dd HH:mm:ss format. For example, 2016-09-20 15:09:10. Also, set GMT as your time zone.
    direction* Set the value as outbound.
    duration* Call recording duration in seconds.
    voiceurl URL of the audio file where the voicemessage is available.
    desc Description of the incoming call.

    * - Mandatory parameters

    Outgoing using clicktocall APIs

    Call dialed

    Example Request:

    curl -X POST -d "callrefid=<unique_id>&fromnumber=<caller_number>
    &tonumber=<callee_number>&customerstatus=<customer_phone_status>"
    -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/calldialed

    Example Response:

    { "data": [ { "Name": "EntityName", "Module": "ModuleName", "Id": "EntityId", "Company/Account": "Company/Account Name", "Email": "Email Address", "Phone": "PhoneNumber", "Mobile": "MobileNumber", "Department": "DepartmentName", "Url": "Entity Zoho CRM Url", "Potential": [ { "Name": "PotentialName", "Id": "PotentialId", "PotentialOwner": "Potential Owner Name", "ClosingDate": "Closing Date Value", "ExpectedRevenue": "Expected Revenue Value", "Stage": "Potential Stage", "Url": "Entity Zoho CRM Url", "Probability": "Probability Value", }, { "Name": "PotentialName", "Id": "PotentialId", "PotentialOwner": "Potential Owner Name", "ClosingDate": "Closing Date Value", "ExpectedRevenue": "Expected Revenue Value", "Stage": "Potential Stage", "Url": "Entity Zoho CRM Url", "Probability": "Probability Value", } ] } ] }

    Error Responses:

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case of an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following error response will be sent, if all the mandatory parameters are not sent in the API request.

    { "message": "One of the expected parameters is missing" "status": "error", "code": "REQUIRED_PARAM_MISSING", "details": {"param":"id"}, }

    Purpose

    To notify an outbound call when the destination phone rings or is about to ring

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/calldialed

    Request Method

    POST

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    callrefid* A unique caller id generated by the PBX vendor. The callrefid should be sent in the format shown below:
    callid123456
    fromnumber* Contact number of the Agent or Customer based on the call state. The fromnumber should be sent in the phone number format. For example: 0018885554567
    tonumber* Contact number of the Agent or Customer based on the call state. The tonumber should be sent in the phone number format. For example: 0018885556748
    userid It is the unique id of the CRM user.
    agentstatus

    Status of the sales agent's phone number. The agentstatus can be any of the following:

    success
    The agent has successfully connected the call.
    notavailable
    The agent number is not available.
    rejected
    The call has been rejected by the agent.
    noanswer
    The call has ended without being answered by the agent.
    busy
    Agent phone is busy.
    internationaldisabled
    International connection is disabled.
    notenoughfund
    No sufficient funds to make the call.
    blocked
    The call is blocked.

    customerstatus* Status of the call made to your customer. The customerstatus can be any of the following:
    success
    The customer has successfully answered the call.
    inprogress
    The call was answered and is in progress currently.
    notavailable
    The customer is not available to answer the call.
    rejected
    The customer has rejected the call.
    noanswer
    The call has ended without being answered by the customer.
    busy
    The caller has received a busy signal.
    blocked
    The caller has been blocked
    invalid
    The call made was invalid.

    * - Mandatory parameters

    Call hungup

    Example Request:

    curl -X POST -d "callrefid=<unique_id>&fromnumber=<caller_number>
    &tonumber=<callee_number>&callstarttime=<time_call_initiated>
    &duration=<call_duration>&direction=<call_direction>"
    -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/callhungup

    Example Response:

    { "data": [ { "Name": "EntityName", "Id": "EntityId", "Module": "ModuleName", } ] }

    Error Responses:

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case of an exception while processing the request.

    { "message": "Internal server error" "status": "error", "details": {}, "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following error response will be sent, if all the mandatory parameters are not sent in the API request.

    { "message": "One of the expected parameters is missing" "status": "error", "code": "REQUIRED_PARAM_MISSING", "details": {"param":"id"}, }

    Purpose

    To notify when a call is hungup or has ended

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/callhungup

    Request Method

    POST

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    callrefid* A unique caller id generated by the PBX vendor. The callrefid should be sent in the format shown below:
    callid123456
    fromnumber* Contact number of the Agent or Customer based on the call state. The fromnumber should be sent in the phone number format. For example: 0018885554567
    tonumber* Contact number of the Agent or Customer based on the call state. The tonumber should be sent in the phone number format. For example: 0018885556748
    userid It is the unique id of the CRM user.
    callstarttime* The start time of the call. The callstarttime should be in yyyy-MM-dd HH:mm:ss format. For example, 2016-09-20 15:09:10. Also, set GMT as your time zone.
    direction* Set the value as outbound.
    duration* Call duration in seconds.
    voiceurl URL of the audio file where the voicemessage s available.
    desc Description of the call.

    * - Mandatory parameters

    Get Active Users List

    Users

    Example Request:

    curl -X GET -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/users

    Example Response:

    { "users": [ { "userid": "useridvalue", "username": "user full name",
    "email": "email address of the users" }, { "userid": "useridvalue", "username": "user full name",
    "email": "email address of the users" }
    ] }

    Error Responses:

    StatusCode:HttpStatus.SC_FORBIDDEN(403):

    The following error response will be sent, if the telephony integration is not accessible for the current user license.

    { "message": "PBX Integration is not available for your license type" "status": "error", "details": {}, "code": "NO_PERMISSION", }

    StatusCode:HttpStatus.SC_INTERNAL_SERVER_ERROR(500):

    The following error response will be sent, in case there is an exception while processing the request.

    { "message": "Internal server error" "status": "error", "code": "INTERNAL_ERROR", }

    StatusCode:HttpStatus.SC_FORBIDDEN(403):

    The following error response will be sent, if the callcontrol parameters has been sent and the requested user does not have enough permission to perform the PhoneBridge integration.

    { "message": "Requested user doesn't have enough privilege to perform this process" "status": "error", "details": {}, "code": "NO_PERMISSION", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following response is sent, if the PhoneBridge registration information is not available for the PBX vendor name that is obtained from the OAuth Token object.

    { "message": "(PBX Name) is not registered" "status": "error", "details": {}, "code": "PBX_NOT_REGISTERED", }

    StatusCode:HttpStatus.SC_BAD_REQUEST(400):

    The following error response is sent, if the PBX vendor integration information is not available.

    { "message": "(PBX Name) Integration is not enabled" "status": "error", "details": {}, "code": "PBX_NOT_INTEGRATED", }

    Purpose

    To retrieve all users specified in the API request.

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/users

    Request Method

    GET

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.

    * - Mandatory parameters

    Update Voice URL

    Example Request:

    curl -X POST -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"
    https://www.zohoapis.com/crm/v2/phonebridge/voiceurl

    Example Response:

    StatusCode:HttpStatus.SC_OK(200):

    { "status": "success", "code": "SUCCESS", }

    Purpose

    To update the voice URL. This API can be used in case if the PBX Vendor is not able to provide the voice URL in the callhungup or callmissed APIs.

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/voiceurl

    Request Method

    POST

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    callrefid* A unique caller id generated by the PBX vendor. The callrefid should be sent in the format shown below:
    callid123456
    voiceurl* File path of the voice URL.

    * - Mandatory parameters

    Get Caller Details

    Example Request:

    curl -X GET -H "Authorization: Zoho-oauthtoken
    1000.c4bc04089aef36cab0d01c672be67723.20119609a95474ee74ef77c17224ebd1"

    https://www.zohoapis.com/crm/v2/phonebridge/callerdetails

    Example Response:

    The following response is sent if the phonenumber relates to any of the Leads, Contacts or Accounts.
    StatusCode:HttpStatus.SC_OK(200):

    { "data": [ { "Name": "EntityName", "Module": "ModuleName", "Id": "EntityId", "Company/Account": "Company/Account Name", "Email": "Email Address", "Phone": "PhoneNumber", "Mobile": "MobileNumber", "Department": "DepartmentName", "Url": "Entity Zoho CRM Url", "Potential": [ { "Name": "PotentialName", "Id": "PotentialId", "PotentialOwner": "Potential Owner Name", "ClosingDate": "Closing Date Value", "ExpectedRevenue": "Expected Revenue Value", "Stage": "Potential Stage", "Url": "Entity Zoho CRM Url", "Probability": "Probability Value", }, { "Name": "PotentialName", "Id": "PotentialId", "PotentialOwner": "Potential Owner Name", "ClosingDate": "Closing Date Value", "ExpectedRevenue": "Expected Revenue Value", "Stage": "Potential Stage", "Url": "Entity Zoho CRM Url", "Probability": "Probability Value", } ] } ] }

    The following response is sent if the phonenumber does not relate to any of the Leads, Contacts or Accounts.
    StatusCode:HttpStatus.SC_NO_CONTENT(204):

    response: null

    Purpose

    To get the caller information. This API can be used in case if the PBX Vendor wants the caller information before the call is being redirected to the agent.

    Request URL

    https://www.zohoapis.com/crm/v2/phonebridge/callerdetails

    Request Method

    GET

    Parameters

    Parameter Description
    Zoho-oauthtoken OAuthToken* Encrypted alphanumeric string to authenticate your Zoho credentials.
    phonenumber* Phone number of the caller.

    * - Mandatory parameters

      • Related Articles

      • Using API Key - Serverless Functions

        Introduction A severless function within your CRM can be invoked from any third-party application or within the CRM using a webhook. However, generally most of the webhooks do not support OAuth2, save for a few of them. In that case, you can execute ...
      • API Names

        For each module, field and related list label in Zoho CRM, a unique name called api_name will be generated to use in APIs. These API names are generated internally while creating a custom module, field or related list label. This key "api_name" will ...
      • API Limits

        The Version 1.0 of Zoho CRM APIs are in the End-of-Life period and will be deprecated on Dec 31, 2018. We recommend you to check out the new and better API 2.0. The Zoho CRM API is available in all editions of Zoho CRM. To use the API, you'll require ...
      • API Dashboard

        ZOHO   CRM Features Pricing Customers Resources Developers Resources CRM Setup Using Zoho CRM Integrations Developer Guide API Dashboard Table of Contents The version 2 API dashboard The version 1 API dashboard [Related Topics] [Frequently Asked ...
      • API Dashboard

        ZOHO   CRM Features Pricing Customers Resources Developers Resources CRM Setup Using Zoho CRM Integrations Developer Guide API Dashboard The new API dashboard features an all new interface to view your usage statistics. The interface is made up of a ...