Hello everyone!
Welcome to Kaizen! In this post, we will discuss Record Locking Configuration APIs in Zoho CRM.
What is Record Locking?
Record Locking refers to the restrictions that you can apply to records of a module to prevent further changes to the data. You can either lock records manually or set conditions to lock them automatically.
You can add record locking configuration to a module through the module builder. Go to Setup > Customization > Modules and Fields > {Module} > Record Locking Configuration. Record Locking is supported for Leads, Accounts, Contacts, Deals, Tasks, Cases, Solutions, Vendors, Price Books, Quotes, Sales Orders, Purchase Orders, Invoices and Custom modules.
Record Locking Configuration in UIThese options are available in record locking configuration:
- You can lock all profile records or give exception to some profiles.
- You can lock the activities you choose. The Edit option is limited by default. You can also limit delete action, adding tags, changing owner, sending emails or using custom buttons.
- You can have the option of editing certain fields even when the record is locked.
Automatic record locking
Automatic record locking refers to the locking of records based on certain conditions. For instance, consider that a deal with a seller is in the closed won stage, and you want to prevent further changes to the deal record. You can achieve this using the record locking feature.
You can configure record locking for deals module to automatically lock a record when it reaches the closed won stage. You can specify rules for locking records. There can be up to five rules per module.
Manual Record Locking
Manual record locking is the intentional locking of a record by a user. To do this, the user's profile should have adequate permission. Profile permissions can be set in Setup > Users and Control > Security Control> Profiles > {Profile Name} > Module Permissions > Tools > Lock.
Record Locking Configuration APIs
Record locking configuration APIs allows you to set up the configuration needed to lock the records in modules manually or automatically via APIs.
The fields in Record Locking Configuration APIs are:
Name | Date Type | Description |
locked_for | String | Represents whether records are locked for all profiles or some profiles. Possible value : all_profiles_except_excluded_profile or all_profiles |
lock_excluded_profiles | String | Represents the profiles that are restricted from locking when locked_for value is all_profiles_except_excluded_profile |
excluded_fields | JSON Array | Represents the fields that are excluded from record locking |
feature_type | String | Represents feature type, its value is record_locking for this case |
locking_rules | JSON Array | Represents the details of rules added to lock the records in the module automatically. This array includes the name, id and criteria of locking rules. The field lock_existing_records indicates whether the existing record must be locked or not. |
restricted_actions | JSON Array | Specifies the actions that are restricted for locked records. Possible values: update, delete, tags, change_owner |
lock_for_portal_users | Boolean | Indicates whether locked records are restricted for portal users. |
restricted_communications | JSON Array | Specifies types of communication that are restricted for locked records. Possible value: send_mail |
system_defined | Boolean | Indicates whether the record configurations are system defined. |
lock_type | String | Represents the type of the record locking configuration - manual, automatic, both |
restricted_custom_buttons | JSON Array | Represents the name and id of custom buttons that are restricted for locked records. |
Using this API, you can configure record locking for the supported modules.
Request URL:
{api-domain}/crm/{version}/settings/record_locking_configurations?module={module_API_name}
HTTP Method: POST
Let us consider the case of locking a deal automatically when it is in the closed won stage.
Request URL to configure record locking for deals module:
{api-domain}/crm/v5/settings/record_locking_configurations?module=Deals
The below request body locks the records from editing for all profiles when the Deal Stage is Closed Won (lockings_rules). The key lock_existing_records specify whether the rule should be applied for existing records. The record is locked for all profiles (locked_for) and the only field that is excluded from locking is the description field (excluded_fields). The record will be locked for portal users (lock_for_portal_users). Edit action is restricted for the lock record (restricted_actions).
Request body:
{ "record_locking_configurations": [ { "locked_for": "all_profiles", "excluded_fields": [ { "api_name": "Description" } ], "feature_type": "record_locking", "locking_rules": [ { "name": "Closed Won", "lock_existing_records": true, "criteria": { "comparator": "equal", "field": { "api_name": "Stage" }, "value": "Closed Won" } } ], "restricted_actions": [ "update" ], "lock_for_portal_users": true, "restricted_communications": null, "system_defined": false, "lock_type": "automatic", "restricted_custom_buttons": null, "lock_excluded_profiles": null } ] } |
From the response of this API you will get the id of the record locking configuration.
The criteria JSON object inside the locking_rules JSON array consists of the comparator, field and value of the fields that form the locking rule of the configuration. If you want to give multiple conditions in one locking rule, you can use group_operator and group keys. The possible values for group_operator are AND, OR. For example, consider that you want to add a locking rule for Closed Lost deals which includes deals with Stage Closed Lost and Closed - Lost to Competition. This can be achieved by giving the locking_rules as shown below:
. . "locking_rules": [ { "name": "Closed Lost", "lock_existing_records": true, "criteria": { "group_operator": "OR", "group": [ { "comparator": "equal", "field": { "api_name": "Stage" }, "value": "Closed Lost" }, { "comparator": "equal", "field": { "api_name": "Stage" }, "value": "Closed-Lost to Competition" } ] } } ] . . |
Use this API to retrieve the details of record locking configuration for a particular module.
Request URL:
{api-domain}/crm/{version}/settings/record_locking_configurations?module={module_API_name}
HTTP Method: GET
Request URL to retrieve the record locking configuration for deals module:
{api-domain}/crm/v5/settings/record_locking_configurations?module=Deals
{ "record_locking_configurations": [ { "created_time": "2023-10-23T03:25:06-04:00", "locked_for": "all_profiles", "excluded_fields": [ { "api_name": "Description", "id": "5843104000000002587" } ], "created_by": { "name": "Patricia Boyle", "id": "5843104000000424672" }, "feature_type": "record_locking", "locking_rules": [ { "name": "Closed Won", "id": "5843104000001068052",//Locking rule ID "lock_existing_records": true, "criteria": { "comparator": "equal", "field": { "api_name": "Stage", "id": "5843104000000002565"// ID of Stage in fields API }, "value": "Closed Won" } } ], "restricted_actions": [ "update" ], "lock_for_portal_users": true, "modified_time": "2023-10-23T03:42:00-04:00", "restricted_communications": null, "system_defined": false, "modified_by": { "name": "John Smith", "id": "5843104000000424001" }, "id": "5843104000001068044", "lock_type": "automatic", "restricted_custom_buttons": null, "lock_excluded_profiles": null } ] } |
Consider that you want to edit the above record locking configuration in deals module. You want to enable manual locking and also add a new rule to lock deals in stage closed lost. This can be done using the Update Record Locking Configuration API.
Request URL:
{api-domain}/crm/{version}/settings/record_locking_configurations?module={module_API_name}
OR
{api-domain}/crm/{version}/settings/record_locking_configurations/{record_locking_config_id}?module={module_API_name}
HTTP Method: PUT
Note that you should mention the ID of the record locking configuration inside the request body if you are using the endpoint that does not have the ID.
When you specify a valid locking rule ID (obtained from Get Record Locking Configuration API) in the input body, the corresponding locking rule will be updated. When ID is not mentioned it will be considered as a new rule.
In addition to adding or modifying existing locking rules in a specific record locking configuration, you can also delete locking rules using Update Record Locking API. When "_delete" key with value true is given in the input body, the locking rule will be deleted.
Example for deleting a record locking rule using update record locking configuration API
Request URL: {api-domain}/crm/v5/settings/record_locking_configurations?module=Deals
HTTP Method: PUT
{ "record_locking_configurations": [ { "locking_rules": [ { "id": 5843104000001068052,//ID of record locking rule "_delete": true } ], "id": "5843104000001068044"//ID of the record locking configuration } ] } |
You can use this API to delete Record Locking Configuration for a module. Please note that deleting the record locking configuration of a module unlocks all the locked records of that module.
Request URL:
{api-domain}/crm/{version}/settings/record_locking_configurations/{record_locking_config_id}?module={module_API_name}
HTTP Method:DELETE
Request URL to delete the record locking configuration for deals module:
{api-domain}/crm/v5/settings/record_locking_configurations?module=Deals
We hope you found this post on the Record Locking Configuration APIs useful. In next week's Kaizen we will cover Record Locking APIs that enable users to access locking details for locked records, to lock/unlock manually, and to edit the locked reason for manually locked records.
If you have any questions, write to us at support@zohocrm.com or let us know in the comment section. For more such posts that are part of our Kaizen series, please refer to our Kaizen collection here.
Cheers!
Recent Topics
Zoho CRM Sales Targets for Individual Salespeople
Our organistion has salespeople that are allocated to different regions and have different annual sales targets as a result. I am building an CRM analytics dashboard for the sales team, which will display a target meter for the logged in salesperson.
All new Address Field in Zoho CRM: maintain structured and accurate address inputs
The address field will be available exclusively for IN DC users. We'll keep you updated on the DC-specific rollout soon. It's currently available for all new sign-ups and for existing Zoho CRM orgs which are in the Professional edition. Managing addresses
Transfer all Related Data to new Account Owner
Currently when I change the account Owner I only see the option to change only the open deals But I want the new account owner to take over all the related modules and all the deal stages Is it not possible right now? Am I missing something? Do I really
Can i connect 2 instagram accounts to 1 brand?
Can i connect 2 instagram accounts to 1 brand? Or Do i need to create 2 brands for that? also under what subscription package will this apply?
How to Calculate MTTR (Mean Time to Resolve)
We want to calculate MTTR (Mean Time to Resolve) in our Zoho Analytics report under Tickets. Currently, we are using the following fields: Ticket ID Ticket Created Time Ticket Closed Time Ticket On Hold Time We are planning to calculate MTTR (in days)
How to export project tasks, including the comments
Hi, how can I export the project tasks, whereby I can also see the comments associated to a specific task? The use-case is that often we use comments to discuss or update a task related ideas. I would like to export the tasks, where we can also see the
How to Install Zoho Workdrive Desktop Sync for Ubuntu?
Hi. I am newbie to Linux / Ubuntu. I downloaded a tar.gz file from Workdrive for installing the Workdrive Desktop Sync tool. Can someone give me step by step guide on how to install this on Ubuntu? I am using Ubuntu 19.04. Regards Senthil
Introducing Version-3 APIs - Explore New APIs & Enhancements
Happy to announce the release of Version 3 (V3) APIs with an easy to use interface, new APIs, and more examples to help you understand and access the APIs better. V3 APIs can be accessed through our new link, where you can explore our complete documentation,
Does Zoho Sheet Supports https://n8n.io ?
Does Zoho Sheet Supports https://n8n.io ? If not, can we take this as an idea and deploy in future please? Thanks
Bigin Android app update: User management
Hello everyone! In the most recent Bigin Android app update, we have brought in support for the 'Users and Controls' section. You can now manage the users in your organization within the mobile app. There are three tabs in the 'Users and Controls' section:
Share records with your customers and let them track their statuses in real time.
Greetings, I hope everyone is doing well! We're excited to introduce the external sharing feature for pipeline records. This new enhancement enables you to share pipeline records with your customers via a shareable link and thereby track the status of
Live webinar: Discover Zoho Show: A complete walkthrough
Hello everyone, We’re excited to invite you to our upcoming live webinar, Discover Zoho Show: A Complete Walkthrough. Whether you’re just getting started with Show or eager to explore advanced capabilities, this session will show you useful tips and features
Deal Stage component/widget/whatever it is... event
Deal Stages I am trying to access the event and value of this component. I can do it by changing the Stage field but users can also change a Deal Stage via this component and I need to be able to capture both values. Clicking on 'Verbal' for instance,
Create advanced slideshows with hybrid reports using Zoho Projects Plus
Are your quarterly meetings coming up? It’s time to pull up metrics, generate reports, and juggle between slides yet again. While this may be easier for smaller projects, large organizations that run multiple projects may experience the pressure when
Add an option to disable ZIA suggestions
Currently, ZIA in Zoho Inventory automatically provides suggestions, such as sending order confirmation emails. However, there is no way to disable this feature. In our case, orders are automatically created by customers, and we’ve built a custom workflow
Email Integration - Zoho CRM - OAuth and IMAP
Hello, We are attempting to integrate our Microsoft 365 email with Zoho CRM. We are using the documentation at Email Configuration for IMAP and POP3 (zoho.com) We use Microsoft 365 and per their recommendations (and requirements) for secure email we have
Formula field with IF statement based on picklist field and string output to copy/paste in multi-line field via function
Hello there, I am working on a formula field based on a 3-item picklist field (i.e. *empty value*, 'Progress payment', 'Letter of credit'). Depending on the picked item, the formula field shall give a specific multi-line string (say 'XXX' in case of 'Progress
CRM x WorkDrive: File storage for new CRM signups is now powered by WorkDrive
Availability Editions: All DCs: All Release plan: Released for new signups in all DCs. It will be enabled for existing users in a phased manner in the upcoming months. Help documentation: Documents in Zoho CRM Manage folders in Documents tab Manage files
Zoho CRMの流入元について
Zoho CRMとZoho formsを連携し、 formsで作成したフォームをサイトに埋め込み運用中です。 UTMパラメータの取得をformsを行い、Zoho CRMの見込み客タブにカスタム項目で反映される状況になっています。 広告に関してはUTMパラメータで取得できているため問題ないのですが、オーガニック流入でフォーム送信の場合も計測したいです。メールやGoogle、Yahoo、directなどの流入元のチャネルが反映されるようにしたいのですが、どのように設定したら良いでしょうか。 また、
Error While Sign in on Zoho Work Drive
Dear Team, I hope this email finds you well. I have recently created a Zoho account and started using it. But while I am trying to log in to Zoho work drive it won't log me in its crashing every time I try it. I have tried it on android app, phone browser
Choosing a portal option and the "Unified customer portal"?
I am trialling Zoho to replace various existing systems, one of which is a customer portal. Our portal allows clients to add and edit bookings, complete forms, manage their subscriptions and edit some CRM info. I am trying to understand how I might best
Elevate your CX delivery using CommandCenter 2.0: Simplified builder; seamless orchestration
Most businesses want to create memorable customer experiences—but they often find it hard to keep them smooth, especially as they grow. To achieve a state of flow across their processes, teams often stitch together a series of automations using Workflow
Unified Directory : How to Access ?
I signed in to Zoho One this morning and was met with the pop up about the upgraded directory (yay!) I watched the video and pressed "Get Started" ... and it took me back to the standard interface. How do I actually access the new portal/directory ?
Translation support expanded for Modules, Subforms and Related Lists
Hello Everyone! The translation feature enables organizations to translate certain values in their CRM interface into different languages. Previously, the only values that could be translated were picklist values and field names. However, we have extended
Unified task view
Possible to enable the unified task view in Trident, that is currently available in Mail?
Bigin, more powerful than ever on iOS 26, iPadOS 26, macOS Tahoe, and watchOS 26.
Hot on the heels of Apple’s latest OS updates, we’ve rolled out several enhancements and features designed to help you get the most from your Apple devices. Enjoy a refined user experience with smoother navigation and a more content-focused Liquid Glass
Importing data into Assets
So we have a module in Zoho CRM called customers equipments. It links to customers modules, accounts (if needed) and products. I made a sample export and created extra fields in zoho fsm assets module. The import fails. Could not find a matching parent
Allow instruction field in Job Sheets
Hello, I would like to know if it is possible to have an instruction field (multi line text) in a job sheet or if there is a workaround to be able to do it. Currently we are pretty limited in terms of fields in job sheets which makes it a bit of a struggle
Streamlining Work Order Automation with Zoho Projects, Writer & WorkDrive
Hello Community, Here is the first post in 'Integration & Automation' Series. Use Case :: Create, Merge, Sign & Store Documents in Zoho WorkDrive. Scenario :: You have a standard Work Order template created in Zoho Writer. When a task status is chosen
The dimensions of multilingual power
Hola, saludos de Zoho Desk. Bonjour, salutations de Zoho Desk. Hallo, Grüße von Zoho Desk. Ciao, saluti da Zoho Desk. Olá, saudações da Zoho Desk. வணக்கம், Zoho Desk இலிருந்து வாழ்த்துகள். 你好,来自 Zoho Desk 的问候。 مرحباً، تحيات من Zoho Desk. नमस्ते, Zoho
Multi-line address lines
How can I enter and migrate the following 123 state street Suite 2 Into a contact address. For Salesforce imports, a CR between the information works. The ZOHO migration tool just ignores it. Plus, I can't seem to even enter it on the standard entry screen.
Accessing Zoho Forms
Hi all, We're having trouble giving me access to our company's Zoho Forms account. I can log in to a Forms account that I can see was set up a year ago, but can't see any shared forms. I can log into Zoho CRM and see our company information there without
Archiving Contacts
How do I archive a list of contacts, or individual contacts?
Cost of good field
Is there a way we can have cost of good sold as a field added to the back end of the invoicing procedure and available in reports?
How to add image to items list in Invoice or Estimate?
Hello! I have just started using Zoho Invoice to create estimates and, possibly to switch from our current CRM/ERP Vendor to Zoho. I have a small company that is installing CCTV systems and Alarm systems. My question is, can I add images of my "items" to item list in Zoho Invoice and Estimates and their description? I would like to show my clients the image of items in our estimates so they can decide if they like these items. And I tell you, often they choose more expensive products just because
Issue with the Permission to Zoho Form
I am getting an error by signing in to zoho form as it is stated that i don't have permission to access this is admin account
CRM templates
Hello everyone, In my company we use Zoho campaigns where we set up all newsletters and we use Zoho CRM for transactional emails. I have created some templates in Zoho campaigns but from my understanding i cannot use those in Zoho CRM, right?
Meet Canvas' Grid component: Your easiest way to build responsive record templates
Visual design can be exciting—until you're knee-deep in the details. Whether it's aligning text boxes to prevent overlaps, fixing negative space, or simply making sure the right data stands out, just ironing out inconsistencies takes a lot of moving parts.
Addin Support in Zoho Sheet
Is there any addin support available in zoho sheet as like google marketplace to enhance productivity by connecting with other apps, providing AI data analysis, streamlining business processes, and more?
Where to integrate Price Book and Product List Price
Hello, We sync zoho crm all modules with all data to zoho analytics. In zoho crm, we have "Price Books" and "Products" modules, where each product is assigned to a few price books with different list prices. From zoho crm, I am able to export a dataset
Next Page