Update record by ID in Zoho Creator v2.1
Table of Contents
Note: This task is applicable to all services except Zoho Creator.
Overview
The zoho.creator.v2_1.updateRecordById task updates an existing record in a specified Zoho Creator report using the record’s unique ID and the provided input field values.
Note: This integration task is based on the Zoho Creator - Update Record by ID API.
Syntax
<response> = zoho.creator.v2_1.updateRecordById(<owner_name>, <app_link_name>, <report_link_name>, <record_id>, <input_values>, <configuration>, <connection>);
where,
| Parameter | Data type | Description |
|---|---|---|
| <response> | KEY-VALUE | The response returned by Zoho Creator. Note: This task internally invokes the Zoho Creator API (v2.1) Get Record endpoint. Therefore, the response returned by this task is identical to the API response, including the code, message, and data (record ID or error details). All API-level limits and validations also apply. |
| <owner_name> | TEXT | Specifies the owner of the Zoho Creator application in which the record will be updated Note:
|
| <app_link_name> | TEXT | Link name of the application containing the record to be updated. Note:
|
| <report_link_name> | TEXT | Link name of the report that contains the record to be updated. Note:
|
| <record_id> | TEXT | Unique ID of the record that needs to be updated. Note: You can use the zoho.creator.getRecords task to fetch the record ID. |
| <input_values> | KEY-VALUE | The updated field values for the record, provided as a KEY-VALUE collection where each key represents a field’s link name and each value represents the new data to be stored in that field. Note:
|
| <configuration> | KEY-VALUE | Specifies optional configuration parameters supported by the Update Record by ID API, such as environment, workflow control, or response message customization. Note: To skip this parameter, provide an empty map as its value. |
| <connection> | TEXT | Link name of the connection created and connected to your Zoho Creator account. Note:
|
Optional parameter details (<configuration>)
The following keys can be included within the <configuration> parameter in the updateRecordById task. These options allow you to specify environment, redirection, message handling, or workflow execution behavior.
| Parameter | Data type | Description |
|---|---|---|
| environment | TEXT | Specifies the environment where the record should be created. Accepted values: "development" or "stage". Note: The value is case-sensitive. |
| tasks | BOOLEAN | When this key is included in the configuration with the value true, the response will include details of the form, report, page, or URL to which the target form is configured to redirect after a successful submission. Redirection can be configured using the direct to form property or a workflow redirection action. The response will include the following keys:
|
| message | BOOLEAN | When the value is true, the response will contain "message":"Data Added Successfully" or the message that's configured for the target form's show message property, or the message that's configured as part of a show message workflow action. When the value is false or does not include this message key, the response will contain "message":"Data Added Successfully" |
| skip_workflow | LIST | Prevents the associated workflows from being executed on the creation of a record. You can choose to skip form workflows and/or schedules. When more than one type of workflow is mentioned, the parameter values should be supplied as "comma" separated values in a list. Possible values: form_workflow, schedules, all Note:
|
Example
// Create a KEY-VALUE variable to hold the input record values data_map = Map(); data_map.put("Task_Name", "Priority Task"); data_map.put("Task_Description", "I need help configuring my new toaster");
// Create an empty KEY-VALUE variable or null to skip the other_params parameter optional_params = Map(); workflows = List(); workflows.add("form_workflow"); workflows.add("schedules"); optional_params.put("environment", "stage"); optional_params.put("tasks",true); optional_params.put("skip_workflow",workflows); optional_params.put("message",true);
response = zoho.creator.v2_1.updateRecordById("Shawn", "Task_Management", "All_Tasks", "60210000000020007", data_map, optional_params, "creator_oauth_connection");
Response format
Success response
- The success response will be returned in the following format:
{
"code": 3000,
"data": {
"Email": "jason@zylker.com",
"Single_Line": "Single Line of Text",
"ID": "3888833000000114027"
},
"message": "Data Updated Successfully!",
"tasks": {
"openurl": {
"type": "Same window",
"url": "http://www.zylker.com"
}
}
}
Failure response
- The failure response for incorrect or non-existent application name will be returned in the following format:
{
"code": 2892,
"message": "No application named <application_name> found. Please check and try again."
}- The failure response for incorrect owner name will be returned in the following format:
{
"code": 1110,
"message": "No workspace named <owner_name> found. Please enter a valid workspace value."
}- The failure response for incorrect or non-existent report name will be returned in the following format
{
"code": 2894,
"message": "No report named <report_link_name> found. Please check and try again."
}Things to know
This task is subject to the general API limits and data validation rules:
- You can update up to 200 records per request.
- A maximum of 50 requests per minute is allowed per IP address.
- Field-level restrictions apply (for example, you cannot set values for system fields such as Auto Number, Formula, File Upload, Signature, etc.).
- All form validation rules, mandatory fields, and data type constraints still apply when records are created via the API.
For a full list of limits and supported field types, refer to Zoho Creator API v2.1