Zoho: Update CRM modules
Zoho modules.updateModules: arguments, response, policy and SDK examples.
← Modules operations · Get started
Operation zoho.updatemodules
Provider route: PUT /crm/v8/settings/modules. 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["modules"]["updateModules"]>[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.modules.updateModules(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.modules.update_modules(arguments) result = await call.wait() return result.body_json()| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: not allowed |
body | object | Required within parent | Batch update request containing an array of module objects to update. Each module requires `id`; other fields are optional. Additional keys: not allowed |
body.modules | array | Required within parent | Array of module objects to update, with one to 100 unique entries. Each entry must include `id`; `singular_label`, `plural_label`, and `profiles` are optional. Maximum items: 100 Minimum items: 1 Unique items: true |
body.modules[] | object | Each item | Module update definition containing labels, module ID, and accessible profiles. Additional keys: not allowed |
body.modules[].id | string | Required within parent | Unique identifier of the module to update. Must be a valid existing module ID. Format: int64 |
body.modules[].plural_label | string | Optional | Plural display label for the module shown in the UI while referring to multiple records (for example, `Contacts` or `Deals`). Must contain only alphanumeric characters and underscores, with no consecutive underscores, and cannot be empty. Maximum length: 50 Minimum length: 1 |
body.modules[].profiles | array | Optional | Optional list of user profiles to add or remove from this module using delta semantics. Profiles without `_delete` are added; profiles with `_delete: null` are removed. Omit this to leave profile assignments unchanged.Each profile ID represents a permission set determining which users can view, create, edit, or delete records in this module. Maximum items: 203 Minimum items: 1 Unique items: true |
body.modules[].profiles[] | object | Each item | Profile identifier object. Additional keys: not allowed |
body.modules[].profiles[]._delete | null | Optional | Deletion marker. Set to `null` to remove this profile from the module’s access list. Omit to add or retain the profile. |
body.modules[].profiles[].id | string | Required within parent | Unique numeric identifier of the user profile. Format: int64 Maximum length: 19 Minimum length: 1 Pattern: ^[0-9]{1,19}$ |
body.modules[].singular_label | string | Optional | Singular display label for the module shown in the UI while referring to a single record (for example, `Contact` or `Deal`). Must contain only alphanumeric characters and underscores, with no consecutive underscores, and cannot be empty. Maximum length: 50 Minimum length: 1 |
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) | object | Alternative | Successful batch update response containing one result object per updated module, each confirming the update with a `SUCCESS` code. Additional keys: not allowed |
$ (anyOf 1).modules | array | Required within parent | Array of success results for each updated module in the batch, preserving request order. Maximum items: 100 Minimum items: 1 |
$ (anyOf 1).modules[] | object | Each item | Successful module update result Additional keys: not allowed |
$ (anyOf 1).modules[].code | string | Required within parent | Returns `SUCCESS` when the module updates without error. Known values: SUCCESS |
$ (anyOf 1).modules[].details | object | Required within parent | Details of the successfully updated module, containing its unique identifier. Additional keys: not allowed |
$ (anyOf 1).modules[].details.id | string | Required within parent | Unique identifier of the module that was successfully updated. Format: int64 Minimum length: 1 |
$ (anyOf 1).modules[].message | string | Required within parent | Confirmation text returned when the module update succeeds. Maximum length: 1000 Minimum length: 1 |
$ (anyOf 1).modules[].status | string | Required within parent | Status indicator for successful operation Known values: success |
$ (anyOf 2) | object | Alternative | Multi-status batch update response containing one result object per module in the request. Results preserve request order and include both successful and failed updates. Additional keys: not allowed |
$ (anyOf 2).modules | array | Required within parent | Array of per-module results for each entry in the request, preserving request order. Each element is either a success or an error variant. Maximum items: 100 Minimum items: 1 |
$ (anyOf 2).modules[] | JSON | Each item | Represents a single per-module result entry, which is either a success result or an error result. |
$ (anyOf 2).modules[] (anyOf 1) | object | Alternative | Successful module update result Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 1).code | string | Required within parent | Success code indicating that module was updated Known values: SUCCESS |
$ (anyOf 2).modules[] (anyOf 1).details | object | Required within parent | Success details containing the updated module ID Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 1).details.id | string | Required within parent | Unique identifier of the successfully updated module. Format: int64 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 1).message | string | Required within parent | Confirmation text returned for the module entry that succeeded. Maximum length: 1000 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 1).status | string | Required within parent | Fixed value `success`, indicating this module’s update succeeded in the partial batch. Known values: success |
$ (anyOf 2).modules[] (anyOf 2) | object | Alternative | Returned when a module update failed due to invalid data - type mismatch, unsupported enum value, or exceeded field length. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 2).code | string | Required within parent | Fixed value `INVALID_DATA`, indicating this module’s update failed because the submitted data was invalid. Known values: INVALID_DATA |
$ (anyOf 2).modules[] (anyOf 2).details | JSON | Required within parent | Represents the error details for the invalid field. |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 1) | object | Alternative | Identifies a field that received a value of the wrong data type, including the API name, JSONPath, and expected type. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 1).api_name | string | Required within parent | API name of the field that received a value of an incorrect data type. Maximum length: 50 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 1).expected_data_type | string | Optional | Expected data type for the field Maximum length: 50 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 1).json_path | string | Required within parent | JSONPath locating the field in the request body that contained the incorrect data type. Maximum length: 100 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 2) | object | Alternative | Identifies a parameter whose submitted value is not among the supported enum values, with the parameter name, index, and accepted values. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 2).index | JSON | Optional | |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 2).index (anyOf 1) | integer | Alternative | Zero-based index of the invalid parameter. Format: int32 Minimum: 0 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 2).index (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 2).param_name | string | Required within parent | Name of the invalid parameter Maximum length: 50 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 2).supported_values | array | Optional | List of valid values accepted for the parameter. Maximum items: 10 Minimum items: 1 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 2).supported_values[] | string | Each item | A valid value accepted for this parameter Maximum length: 50 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 3) | object | Alternative | Identifies a field whose submitted value exceeded the maximum allowed character length, with the API name, JSONPath, and the limit. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 3).api_name | string | Required within parent | API name of the field whose value exceeded the maximum allowed length. Maximum length: 50 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 3).json_path | string | Required within parent | JSONPath of the field in the request whose value exceeded the maximum allowed length. Maximum length: 100 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 3).maximum_length | JSON | Required within parent | |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 3).maximum_length (anyOf 1) | integer | Alternative | Maximum number of characters permitted for the field. Format: int32 Minimum: 1 |
$ (anyOf 2).modules[] (anyOf 2).details (anyOf 3).maximum_length (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
$ (anyOf 2).modules[] (anyOf 2).message | string | Required within parent | Explanation of the validation failure for the module entry that contained invalid data. Maximum length: 1000 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 2).status | string | Required within parent | Fixed value `error`, indicating the module update failed because the submitted data was invalid. Known values: error |
$ (anyOf 2).modules[] (anyOf 3) | object | Alternative | Returned when a module update failed because a mandatory field was absent from the request. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 3).code | string | Required within parent | Fixed value `MANDATORY_NOT_FOUND`, indicating the module update failed because a required field was absent from the request. Known values: MANDATORY_NOT_FOUND |
$ (anyOf 2).modules[] (anyOf 3).details | object | Required within parent | Details identifying the required field that was missing, including its API name and JSONPath location. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 3).details.api_name | string | Required within parent | API name of the required field that was not provided in the request. Maximum length: 50 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 3).details.json_path | string | Required within parent | JSONPath location in the request where the required field was expected. Maximum length: 100 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 3).message | string | Required within parent | Explanation of the missing required field that caused the module entry to fail. Maximum length: 1000 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 3).status | string | Required within parent | Fixed value `error`, indicating the module update failed because a mandatory field was missing. Known values: error |
$ (anyOf 2).modules[] (anyOf 4) | object | Alternative | Returned when a module update failed because the request attempted to modify a restricted or immutable field. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 4).code | string | Required within parent | Fixed value `NOT_ALLOWED`, indicating the module update failed because the request attempted to modify a field that cannot be changed. Known values: NOT_ALLOWED |
$ (anyOf 2).modules[] (anyOf 4).details | object | Required within parent | Details identifying the restricted field that was included in the request, by API name and JSONPath. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 4).details.api_name | string | Required within parent | API name of the field whose update is not permitted. Maximum length: 50 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 4).details.json_path | string | Required within parent | JSONPath location of the restricted field in the request. Maximum length: 100 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 4).message | string | Required within parent | Explanation of the disallowed field modification that caused the module entry to be rejected, identifying which field cannot be changed. Maximum length: 1000 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 4).status | string | Required within parent | Fixed value `error`, indicating the module update failed because a disallowed field modification was attempted. Known values: error |
$ (anyOf 2).modules[] (anyOf 5) | object | Alternative | Returned when a module update failed because the referenced module does not exist, the ID is invalid, or the operation is unsupported for this module type. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 5).code | string | Required within parent | Fixed value `INVALID_MODULE`, indicating the module reference is invalid, does not exist, or the operation is not supported for this module type. Known values: INVALID_MODULE |
$ (anyOf 2).modules[] (anyOf 5).details | object | Required within parent | Details identifying the field or reference that caused the invalid-module error, by API name and JSONPath. Additional keys: not allowed |
$ (anyOf 2).modules[] (anyOf 5).details.api_name | string | Required within parent | API name of the field or reference associated with the invalid module. Maximum length: 50 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 5).details.json_path | string | Required within parent | JSONPath to the invalid module reference in the request. Maximum length: 100 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 5).message | string | Required within parent | Explanation of why the module identifier was not recognized or could not be updated. Maximum length: 1000 Minimum length: 1 |
$ (anyOf 2).modules[] (anyOf 5).status | string | Required within parent | Fixed value `error`, indicating the module update failed because the module reference is invalid or the operation is unsupported for this module type. Known values: error |
Policy, approvals and errors
Section titled “Policy, approvals and errors”SDK function policy ID: zoho.updatemodules. Catalog operation: updateModules. 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.