Zoho: Assignment Rules
Zoho assignmentRules.getAssignmentRules: arguments, response, policy and SDK examples.
← Assignment rules operations · Get started
Operation zoho.getassignmentrules
Provider route: GET /crm/v8/settings/automation/assignment_rules. Alter supplies the connection’s credentials and routing.
Call through Alter
Section titled “Call through Alter”Install @alter-ai/sdk @alter-ai/zoho with npm, or alter-sdk-zoho with pip. Supply your connected customer’s grant ID and the arguments described below.
import { App } from "@alter-ai/sdk";import { ZohoIntegration } from "@alter-ai/zoho";
async function execute(input: Parameters<ZohoIntegration["assignmentRules"]["getAssignmentRules"]>[0]) { const app = new App({ apiKey: process.env.ALTER_API_KEY! }); try { const provider = new ZohoIntegration(app, { grantId: process.env.PROVIDER_GRANT_ID! }); const call = await provider.assignmentRules.getAssignmentRules(input); const result = await call.wait(); return result.bodyJson(); } finally { await app.close(); }}import osfrom alter_sdk import Appfrom alter_sdk_zoho import ZohoIntegration
async def execute(arguments): async with App(api_key=os.environ["ALTER_API_KEY"]) as app: provider = ZohoIntegration(app, {"grant_id": os.environ["PROVIDER_GRANT_ID"]}) call = await provider.assignment_rules.get_assignment_rules(arguments) result = await call.wait() return result.body_json()| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: not allowed |
query | object | Optional | Additional keys: not allowed |
query.module | string | Optional | Maximum length: 100 |
query.include_inner_details | string | Optional | One of: created_by.zuid, modified_by.zuid |
Response
Section titled “Response”Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | Model | Alternative | Expand Assignment Rules — response body — Get all Assignment Rules success response |
$ (anyOf 2) | null | Alternative |
Referenced models: Assignment Rules — response body — Get all Assignment Rules success response
Schemas
Section titled “Schemas”Assignment Rules — response body — Get all Assignment Rules success response
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Get all Assignment Rules success response. Additional keys: not allowed |
assignment_rules | array | Optional | Represents the list of all Assignment Rules. Maximum items: 200 Minimum items: 1 |
assignment_rules[] | Model | Each item | Expand Assignment Rules — response body — Get all Assignment Rules success response assignment rules item |
Referenced models: Assignment Rules — response body — Get all Assignment Rules success response assignment rules item
Assignment Rules — response body — Get all Assignment Rules success response assignment rules item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Details of the Assignment Rule. Additional keys: not allowed |
api_name | string | Required within parent | Represents the API name of the rule. Maximum length: 100 Minimum length: 1 |
created_by | Model | Required within parent | Expand Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module |
created_time | string | Required within parent | Represents the date and time of Assignment Rule creation. Format: date-time Maximum length: 255 |
default_assignee | Model | Required within parent | Expand Assignment Rules — response body — Get all Assignment Rules success response assignment rules item default assignee Defines the details of the fall back user to whom the records will be assigned when owner couldn't be assigned by any of the rule entries defined. (Required) |
description | JSON | Required within parent | |
description (anyOf 1) | string | Alternative | Purpose of the Assignment Rule. Maximum length: 250 |
description (anyOf 2) | null | Alternative | Purpose of the Assignment Rule. Maximum length: 250 |
id | string | Required within parent | ID of the resource. Maximum length: 19 Minimum length: 1 Pattern: ^[1-9][0-9]{0,18}$ |
modified_by | Model | Required within parent | Expand Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module |
modified_time | string | Required within parent | Represents the date and time of Assignment Rule recent modification. Format: date-time Maximum length: 255 |
module | Model | Optional | Expand Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module |
name | string | Required within parent | Represents the name to be displayed for the Assignment Rule. Maximum length: 100 Minimum length: 1 |
Referenced models: Assignment Rules — response body — Get all Assignment Rules success response assignment rules item default assignee, Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module
Assignment Rules — response body — Get all Assignment Rules success response assignment rules item default assignee
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Details of the fallback user for record assignment in cases where the owner cannot be assigned through rule entries. Additional keys: not allowed |
id | JSON | Optional | Represents the iD of the default assignee. is deprecated. |
id (anyOf 1) | string | Alternative | ID of the resource. Maximum length: 19 Minimum length: 1 Pattern: ^[1-9][0-9]{0,18}$ |
id (anyOf 2) | string | Alternative | To define "logged in user" as fallback user for the given Assignment Rule, set ${CURRENTUSER} as value for this field. Known values: ${CURRENTUSER} |
name | string | Optional | Represents the display name of the default assignee. Maximum length: 255 |
resource | JSON | Optional | Represents the resource returned for the Assignment Rule operation. |
resource (anyOf 1) | Model | Alternative | Expand Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module Defines the details of the default assignee |
resource (anyOf 2) | JSON | Alternative | Defines the details of the default assignee. Additional keys: not allowed |
resource (anyOf 2).api_name | string | Optional | To define "logged in user" as fallback user for the given Assignment Rule, set ${CURRENTUSER} as value for this field. Possible values: **${CURRENTUSER}** - Represents ${currentuser}. Known values: ${CURRENTUSER} |
resource (anyOf 2).name | string | Optional | Logged in user reference display name. Maximum length: 255 |
type | string | Optional | Defines the type of the default assignee. Possible values: **user** - Represents user. Known values: user |
Referenced models: Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module
Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Resource details. Additional keys: allowed |
_details | Model | Optional | Expand Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module details |
api_name | string | Optional | Represents the API name of the resource. Maximum length: 255 |
id | string | Required within parent | ID of the resource. Id of the resource Maximum length: 19 Minimum length: 1 Pattern: ^[1-9][0-9]{0,18}$ |
name | string | Required within parent | Represents the display name of the resource. Maximum length: 255 |
zuid | string | Optional | Zuid of the user resource Format: int32 Maximum length: 19 |
Referenced models: Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module details
Assignment Rules — response body — Get all Assignment Rules success response assignment rules item module details
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | null | Alternative | _Details Schema. Additional keys: allowed |
$ (anyOf 2) | object | Alternative | _Details Schema. Additional keys: allowed |
Policy, approvals and errors
Section titled “Policy, approvals and errors”SDK function policy ID: zoho.getassignmentrules. Catalog operation: getAssignmentRules. Rules can name either ID; function rules distinguish managed calls and conservatively cover raw calls sharing the route. Existing grant permissions and policy rules apply. wait() returns an immediate result or waits for a required approval; it never approves the request itself. Persist the approval ID to resume after a restart.
Provider errors retain their response; JSON decoding raises ProviderAPIError for provider failures. ManagedOperationError identifies contract/input/retention errors. See error handling and provider-specific behavior. Sensitive input may be refused before approval storage. A decoding error never resubmits a write.
No-content response statuses: [204]