Bad request 404 / ZDK.Apps.CRM.Functions.execute

Bad request 404 / ZDK.Apps.CRM.Functions.execute

Hello team, I have a question, I have created a function to be able to copy information from one field to another. This is invoked as client script, in:

Page Details

Category: module
Page: Detail Page(Standard)
Module: Leads
Layout: Standard

event details
Event Type: Page Event
Event: onLoad


  1. var id = String($Page.record_id);
  2. var parameters = '{"id":';
  3. parameters= parameters.concat(id);
  4. parameters= parameters.concat('}"');


  5.   var response = ZDK.Apps.CRM.Functions.execute("copy_branch", parameters);
-------------------------------------------------- ----------------------------
Function String copy_branch(string id)

Source code

  1. resLeads = zoho.crm.getRecordById("Leads",id);
  2. Branch = resLeads.get("Branch");
  3. data = Map();
  4. data.put("Branch_scheduling",Branch);
  5. result = zoho.crm.updateRecord("Leads",id,data);
  6. info result;
  7. return "";
-------------------------------------------------- --------------------------------------

When you load a lead, the client script is triggered, which calls the
copy_branch function, but I get as a response


HTTP Status 400 – Bad Request


What's the wrong?, can you give a hand please?

    Access your files securely from anywhere

        Zoho Developer Community




                                  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 Campaigns Resources


                                                                          Zoho CRM Resources

                                                                          • CRM Community Learning Series

                                                                            CRM Community Learning Series


                                                                          • Kaizen

                                                                            Kaizen

                                                                          • 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