I am creating a plug function for my Zobot codeless bot and the below code on executing/saving throws the following error:
Message : Argument type mismatches for the integration function 'zoho.crm.searchrecords' at index 3
Plugs Code
=========
response = Map();
// Check if the email address exists in the Leads module
leads = zoho.crm.searchRecords("Leads","(Email:equals:"+emailAddress+")",Map(),"zohocrm");
if (leads.size() > 0) {
info "Email address exists in Leads module.";
// Perform further actions or logic if required
} else {
// Check if the email address exists in the Contacts module
contacts = zoho.crm.searchRecords("Contacts", "(Email:equals:" + emailAddress + ")",Map(),"zohocrm");
if (contacts.size() > 0) {
info "Email address exists in Contacts module.";
// Perform further actions or logic if required
} else {
info "Email address does not exist in Leads or Contacts module.";
// Perform further actions or logic if required
}
}
======================================================================================
What am I doing wrong? I am initializing the "emailAddress" variable here but ideally expecting it to be retrieved from the input/button card.