Clone Assignment Rule Entries
Purpose
To clone the rule entries of an existing assignment rule.
Use the Get Assignment Rules API to fetch assignment rule IDs available in your organization.
Endpoints
- PUT /settings/automation/assignment_rules/{assignment_rule_ID}/actions/clone_entries
Request Details
Request URL
{api-domain}/crm/{version}/settings/automation/assignment_rules/{assignment_rule_ID}/actions/clone_entries
Header
Authorization: Zoho-oauthtoken d92d4xxxxxxxxxxxxx15f52
Scope
ZohoCRM.settings.assignment_rules.UPDATE
Parameter
- modulestring, mandatory
Specify the module in which you want to clone the assignment rule's rule entries, such as Leads or Contacts. Use Get Modules Metadata API to fetch module API names.
Sample Request
Copiedcurl "https://www.zohoapis.com/crm/v8/settings/automation/assignment_rules/5276164000003551117/actions/clone_entries?module=Leads"
-X PUT
-H "Authorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxxxxxxx9be93.9b8xxxxxxxxxxxxxxxf"
-d "@cloneRuleEntries.json"Input JSON
- assignment_rulesJSON array, mandatory
Specify the details of the rule entries to be cloned from an existing Assignment Rule.
- rule_entriesJSON array, mandatory
Specify the rule entries to be cloned. Use the Get Assignment Rules API to retrieve the rule entry IDs.
- idstring, mandatory
Specify the unique ID of the rule entry to be cloned. Use the Get Assignment Rules API to retrieve the rule entry ID.
Sample Input
Copied{
"assignment_rules": [
{
"rule_entries": [
{
"criteria": { //updating the criteria
"comparator": "contains",
"field": {
"api_name": "Email",
"id": "2276164000000000563"
},
"type": "value",
"value": "pate.a@mail.com"//updating the value
},
"followup_actions": null, //updating it as null
"id": "2276164000003551119"
}
]
}
]Possible Errors
- INVALID_DATAHTTP 400
The ID provided is invalid
Resolution: Specify a valid assignment rule ID. Use the Get Assignment Rules API to fetch the assignment rule IDs available in your organization. - INVALID_MODULEHTTP 400
The module specified in the query parameter is invalid
Resolution: Refer to the Get Modules Metadata API to identify the correct module API name. - REQUIRED_PARAM_MISSINGHTTP 400
A required parameter is missing
Resolution: Specify the module parameter and its corresponding value. Use the Get Assignment Rules API to know the supported module API names. - MANDATORY_NOT_FOUNDHTTP 400
Mandatory field is missing
Resolution: Specify all mandatory fields to proceed with cloning the Assignment Rule entries. Refer to the Input JSON section to know the required fields. - NO_PERMISSIONHTTP 400
No permission to count the available Assignment rules
Resolution: You do not have permission to count the Assignment rules in the module. Contact your administrator to enable the required permissions. - INVALID_REQUEST_METHODHTTP 400
The http request method type is not a valid one
Resolution: You have specified an invalid HTTP method to access the API URL.
Specify a valid request method. Refer to the Endpoint section. - OAUTH_SCOPE_MISMATCHHTTP 401
Unauthorized
Resolution: The client does not have a valid scope to clone rule entries of an existing Assignment Rule. Create a new token with valid scope. Refer to Scope section. - AUTHENTICATION_FAILUREHTTP 401
Authentication failed
Resolution: Pass the access token in the request header of the API call. - 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 the Request URL section. - INTERNAL_ERRORHTTP 500
Internal Server Error
Resolution: Unexpected and unhandled exception in the server. Contact support team.
Sample Response
Copied{
"assignment_rules": [
{
"code": "SUCCESS",
"details": {
"rule_entries": [
{
"id": "5276164000004312011"
}
],
"id": "5276164000003551117"
},
"message": "Assignment rule UPDATED successfully",
"status": "success"
}
]
}