Create Records in Zoho Creator v2.1
Table of Contents
Overview
The zoho.creator.v2_1.createRecords task creates new records in a specified Zoho Creator form with the given input field values.
Syntax
<response> = zoho.creator.v2_1.createRecords(<owner_name>, <app_link_name>, <form_link_name>, <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) Add 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 records will be created. Note: Name of the application owner can be fetched in the following ways:
|
| <app_link_name> | TEXT | Link name of the application in which the records will be created. Note: Link name of the application can be fetched in the following ways:
|
| <form_link_name> | TEXT | Link name of the form in which the records will be created. Note:
|
| <input_values> | LIST | To create more than one record, supply the input data as a LIST of KEY-VALUE collections. Data stored in each KEY-VALUE element of the LIST will be created as a record. The keys of these elements must be the field link names and values must be their corresponding input values. Note: You can add up to 200 records at once using this task. Refer to the Zoho Creator Add Records API document for the rules and validations that your input data need to satisfy. |
| <configuration> | KEY-VALUE | Specifies optional configuration parameters supported by the Add Records API, such as environment, redirection, or workflow settings. Note: To skip this parameter, pass an empty map or null. Example: configuration = Map(); |
| <connection> | TEXT | Link name of the connection created and connected to your Zoho Creator account. Note:
|
Optional parameters for <configuration>
The following keys can be included within the <configuration> parameter in the createRecord task. These options let you specify additional settings such as environment, redirection behavior, or workflow control.
Each of these parameters can be added to the configuration map that is passed to the task.
| Value | Data type | Description |
| environment | TEXT | Specifies the environment where the record should be created. Accepted values: "development" or "stage". Note: The value here is case sensitive and should be used as such. |
| 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.
|
| 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: If this parameter is not supplied by default, all associated workflows will be triggered. Blueprints and approvals will be triggered on the creation of records and cannot be skipped. |
Example
A company uses a Zoho Creator app named Task Management to handle internal tasks requested by customers. When multiple customer requests come in at once, the support team needs to create multiple task records in a single operation.
// Create a LIST variable to hold the multiple record values
data_list = List();
data1 = Map();
data1.put("Task_Name", "Priority Task");
data1.put("Task_Description", "I need help configuring my new account");
data2 = Map();
data2.put("Task_Name", "Non Priority Task"); }
data2.put("Task_Description", "I need help configuring my new device");
data_list.add(data1);
data_list.add(data2);
// 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);
// Create records
response = zoho.creator.v2_1.createRecords("Shawn","Task_Management","Tasks",data_list ,optional_params,"creator_oauth_connection");
Response Format
Success Response
- The success response will be returned in the following format:
"result": [
{
"code": 3000,
"data": {
"Email": "jason@zylker.com",
"Phone_Number": "+16103948336",
"ID": "3888833000000121319"
},
"message": "Data Added Successfully!",
"tasks": {
"openurl": {
"type": "Same window",
"url": "#Report:All_Orders"
}
}
},
{
"code": 3000,
"data": {
"Email": "p.boyle@zylker.com",
"Phone_Number": "+12096173907",
"ID": "3888833000000121339"
},
"message": "Data Added Successfully!",
"tasks": {
"openurl": {
"type": "Same window",
"url": "#Report:All_Orders"
}
}
}
],
"code": 3000
}
Failure Response
- The failure response for incorrect or non-existent application name will be returned in the following format
- The failure response for incorrect owner name will be returned in the following format
- The failure response for incorrect or non-existent form name will be returned in the following format
Things to Know
This task is subject to the general API limits and data validation rules:
- You can create 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