Update Scoring Rule Status
Purpose
To activate or deactivate an existing scoring rule configured for a Zoho CRM module.
Endpoints
- PUT /settings/automation/scoring_rules/{rule_ID}/actions/activate
- DELETE /settings/automation/scoring_rules/{rule_ID}/actions/activate
Request Details
Request URL
{api-domain}/crm/{version}/settings/automation/scoring_rules/{rule_ID}/actions/activate
Header
Authorization: Zoho-oauthtoken d92d4xxxxxxxxxxxxx15f52
Scope
ZohoCRM.settings.scoring_rules.ALL
(or)
ZohoCRM.settings.scoring_rules.{operation_type}
Possible operation types
ALL - Full access to scoring rules
UPDATE - Update scoring rules
Note
The HTTP request method for activating a scoring rule is PUT, and DELETE is used to deactivate a rule.
Sample Request
Copiedcurl "https://www.zohoapis.com/crm/v8/settings/automation/scoring_rules/4876876000000965528/actions/activate"
-H "Authorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxxxxxxx9be93.9b8xxxxxxxxxxxxxxxf"
-X PUT
Possible Errors
- INVALID_REQUEST_METHODHTTP 400
The request method is incorrect.
Resolution: Use the HTTP PUT method to activate a scoring rule, or HTTP DELETE method to deactivate one. Any other request method will result in this error. - ACTIVE_STATE_LIMIT_EXCEEDEDHTTP 400
You have exceeded the number of active rules possible for your account.
Resolution: Limit the number of active rules to be within the permissible limit. Refer to the limits table for more details. - OAUTH_SCOPE_MISMATCHHTTP 401
The access token you have used to make this API call does not have the required scope.
Resolution: Generate a new access token with the required scopes for this API. Refer to the Scope section at the beginning of this page for the list of required scopes. - NO_PERMISSIONHTTP 403
Permission denied to update scoring rule.
Resolution: The user does not have permission to update scoring rules status. Contact your system administrator. - INVALID_URL_PATTERNHTTP 404
The request URL is incorrect.
Resolution: Specify a valid request URL. Refer to the request URL section at the beginning of this page for more details. - INTERNAL_ERRORHTTP 500
Unexpected and unhandled exception in the server.
Resolution: Contact the support team at support@zohocrm.com.
Sample Response
CopiedFor activation request:
{
"scoring_rules": [
{
"code": "SUCCESS",
"details": {
"id": "4876876000000965528"
},
"message": "scoring rule activated successfully",
"status": "success"
}
]
}
For deactivation request:
{
"scoring_rules": [
{
"code": "SUCCESS",
"details": {
"id": "4876876000000965528"
},
"message": "scoring rule deactivated successfully",
"status": "success"
}
]
}