SalesIQ/Deluge script for Plugs not working

SalesIQ/Deluge script for Plugs not working

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();
emailAddress = "abc@abc.com";
// 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.





                            Zoho Desk Resources

                            • Desk Community Learning Series


                            • Digest


                            • Functions


                            • Meetups


                            • Kbase


                            • Resources


                            • Glossary


                            • Desk Marketplace


                            • MVP Corner


                            • Word of the Day



                                Zoho Marketing Automation


                                        Manage your brands on social media



                                              Zoho TeamInbox Resources

                                                Zoho DataPrep Resources



                                                  Zoho CRM Plus Resources

                                                    Zoho Books Resources


                                                      Zoho Subscriptions Resources

                                                        Zoho Projects Resources


                                                          Zoho Sprints Resources


                                                            Qntrl Resources


                                                              Zoho Creator Resources


                                                                Zoho WorkDrive Resources



                                                                  Zoho Campaigns Resources

                                                                    Zoho CRM Resources

                                                                    • CRM Community Learning Series

                                                                      CRM Community Learning Series


                                                                    • Tips

                                                                      Tips

                                                                    • Functions

                                                                      Functions

                                                                    • Meetups

                                                                      Meetups

                                                                    • Kbase

                                                                      Kbase

                                                                    • Resources

                                                                      Resources

                                                                    • Digest

                                                                      Digest

                                                                    • CRM Marketplace

                                                                      CRM Marketplace

                                                                    • MVP Corner

                                                                      MVP Corner

                                                                    





                                                                    




                                                                        Design. Discuss. Deliver.

                                                                        Create visually engaging stories with Zoho Show.

                                                                        Get Started Now