I started creating a script to perform certain automation inside a CRM.
The record I want to pull is within a user created “Policies” module.
whenever I use the get function and info the variable assigned to it I get a return of {"status":"failure"}
but the script does not give me an error.
This issue, however, only occurs when getting any records from the Policies module. I can get any record from the Leads and the Deals modules and it returns the record info as expected.
Some things I have tried to debug this issue include:
- Using a different browser
- restarting my machine
- checking and double checking that the module API name is correct (it is “Policies”)
- trying different records in the module to see if it is a specific record (no change)
- running the script in a complete different instance of Zoho CRM (I work on 4) which also has a “Policies” module (and it works with no issues) which means its something in this ZohoOne instance.
- checking my connection’s Scopes to make sure its not an auth issue. (here are my current scopes: ZohoCRM.modules.ALL, ZohoCRM.Files.CREATE, ZohoCRM.Files.READ).
I am truly hoping I’m making a stupid mistake and its easily fixable as I need to get work done.
void automation.Test(Int policyid, int dealid, int leadid)
{
policy = zoho.crm.getRecordById("Policies",policyid);
info policy;
deal = zoho.crm.getRecordById("Deals",dealid);
info deal;
lead = zoho.crm.getRecordById("Leads", leadid);
info lead;
}
the above code is the test script I set up to show what’s happening.
I should expect to see 3 info statements in the console displaying the 3 json maps containing the record fields and the data connected to them.
instead I see the first statement as {“status”:”failure”} and the last two returning the data as expected.
the attached image excludes the info for the leads and deals records for prifacy purposes but they are there and working.
Henro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.