Get Rules Actions Count in a Connected Workflow

Purpose

To retrieve the count of actions configured for specific rules within a connected workflow. This API returns a breakdown of action types and their counts per rule condition.

Endpoints

  • GET /settings/connected_workflows/{connected_workflow_ID}/rules/actions/actions_count?ids={rule_ID1}, {rule_ID2}..

Request Details

Request URL

{api-domain}/crm/{version}/settings/connected_workflows/{connected_workflow_ID}/rules/actions/actions_count

Header

Authorization: Zoho-oauthtoken d92d4xxxxxxxxxxxxx15f52

Scope

ZohoCRM.settings.connected_workflows.READ
(or)
ZohoCRM.settings.connected_workflows.ALL
(or)
ZohoCRM.settings.ALL

Parameters
  • idsstring, mandatory

    Comma-separated list of rule IDs for which the action count must be retrieved.

Sample Request

Copiedcurl "https://www.zohoapis.com/crm/v8/settings/connected_workflows/4876876000019209017/rules/actions/actions_count?ids=4876876000019212197,4876876000019216341"
-H "Authorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxxxxxxx9be93.9b8xxxxxxxxxxxxxxxf" 
-X GET

Note

  • Connected workflows are supported in Standard, Professional, Enterprise, and Ultimate editions.
  • The user must have Manage Automations or Manage Connected Workflow permission enabled to access this API.

Response JSON

The response contains a rules array containing actions count for the specified rules Each rules object contains:

  • idstring

    Unique ID of the rule in the connected workflow.

  • conditionsJSON array

    Contains the count details of the condition blocks within each rule.

    • idstring

      Represents the unique ID of the condition block.

    • sequence_numberinteger

      Represents the order of the condition in rule execution.

    • instant_actionsJSON object

      Contains the action count for the specific condition.

      • actions_countJSON array

        Contains the breakdown of actions count by type.

        • typestring

          Represents the type of action. 
          Possible values are create_connected_record, field_updates, and email_notifications.

        • countinteger

          Represents the number of actions configured for the specified type.

Possible Errors

  • INVALID_DATAHTTP 400

    The given ID seems to be invalid
    Resolution: Provide a valid connected workflow ID in the request URL.

  • REQUIRED_PARAM_MISSINGHTTP 400

    A required parameter is missing in the request. 
    Resolution: The details object in the response contains information about the missing parameter. Ensure all required and dependent parameters are included. Refer to the Parameters section for details.

  • FEATURE_NOT_SUPPORTEDHTTP 400

    Your edition doesn't support this feature
    Resolution: Upgrade the account to Standard, Professional, Enterprise, or Ultimate edition and then retry the request.

  • INVALID_REQUEST_METHODHTTP 400

    The http request method type is not a valid one
    Resolution: This API supports only the GET method. Retry the request using the GET method.

  • OAUTH_SCOPE_MISMATCHHTTP 401

    Unauthorized
    Resolution: Client does not have the required OAUTH SCOPE. Create a new token with valid scope. Refer to the Scope section for more details.

  • AUTHENTICATION_FAILUREHTTP 401

    Authentication failed
    Resolution: Pass a valid access token along the request to authenticate.

  • NO_PERMISSIONHTTP 403

    Permission denied
    Resolution: Ensure that the user making the API call has the Manage Automation or Connected Workflow permission enabled in their CRM profile, and then retry the request.

  • INVALID_URL_PATTERNHTTP 404

    Please check if the URL trying to access is a correct one
    Resolution: The request URL specified is incorrect. Specify a valid request URL. Refer to request URL section for more details.

  • INTERNAL_ERRORHTTP 500

    Internal Server Error
    Resolution: Unexpected and unhandled exception in Server. Contact support team.

Sample Response

Copied{
    "rules": [
        {
            "id": "4876876000019212197",
            "conditions": [
                {
                    "sequence_number": 1,
                    "instant_actions": {
                        "actions_count": [
                            {
                                "count": 1,
                                "type": "field_updates"
                            },
                            {
                                "count": 1,
                                "type": "email_notifications"
                            },
                            {
                                "count": 1,
                                "type": "create_connected_record"
                            }
                        ]
                    },
                    "id": "4876876000019212198"
                }
            ]
        },
        {
            "id": "4876876000019216341",
            "conditions": [
                {
                    "sequence_number": 1,
                    "instant_actions": {
                        "actions_count": [
                            {
                                "count": 1,
                                "type": "email_notifications"
                            },
                            {
                                "count": 1,
                                "type": "create_connected_record"
                            }
                        ]
                    },
                    "id": "4876876000019216342"
                }
            ]
        }
    ]
}