Variables API

A CRM Variable can have unique set of values and can be widely used as merge fields in Email templates, Mail merge templates, and Inventory templates. You can also use them as reusable authentication parameters in APIs.

Get Variables Data

Purpose

To retrieve all the available variables through an API request.

Request URL

https://www.zohoapis.com/crm/v2/settings/variables

Request Method

GET

Scope

scope=ZohoCRM.settings.variables.{operation_type}

 
Possible operation types
ALL - Full access to variable data
READ - Get variable data
Note:

Group ID/group API name is mandatory in case of fetching specific variable data.

Sample Request

Copiedcurl "https://www.zohoapis.com/crm/v2/settings/variables"
-X GET
-H "Authorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxxxxxxx9be93.9b8xxxxxxxxxxxxxxxf"
      

Sample Response

Copied{
    "variables": [
       {
            "api_name": "Variable1",
            "name": "Variable1",
            "description": "This denotes variable 1 description",
            "id": "40000000047003",
            "type": "text",
            "variable_group": {
                "api_name": "Group1",
                "id": "40000000047001"
            },
            "value": "This denotes variable one value"
        },
       {
            "api_name": "Variable2",
            "name": "Variable2",
            "description": "This denotes variable 2 description",
            "id": "40000000047007",
            "type": "integer",
            "variable_group": {
                "api_name": "Group2",
                "id": "40000000047005"
            },
            "value": "2"
        },
       {
            "api_name": "VariableSix",
            "name": "Variable6",
            "description": "On the sea shore",
            "id": "40000000044005",
            "type": "text",
            "variable_group": {
                "api_name": "MyCustsdomGroup",
                "id": "40000000044003"
            },
            "value": "She sells sea shells"
        }
    ]
}