Post to Bot from CRM Custom Function

Post to Bot from CRM Custom Function

I'm trying to post text to a bot with the code below (from zCRM). It works fine when using "Save & Execute" but will not run when triggered with a workflow.

Scenario:
User creates a quote and a Bot informs user of the Shipping cost.

Any idea why the code will not run when the custom function is triggered within a workflow rule?

My code snippet is:

//Compose msg to post to cliq
msg = "Shipping estimate for Quote #" + quoteNum + "  $" + finalShipping;
mp = Map();
mp.put("text",msg);
mp.put("broadcast","false");  //have also tried true here
resp = zoho.cliq.postToBot("devbot",mp);



      • Sticky Posts

      • Automating Employee Birthday Notifications in Zoho Cliq

        Have you ever missed a birthday and felt like the office Grinch? Fear not, the Cliq Developer Platform has got your back! With Zoho Cliq's Schedulers, you can be the office party-cipant who never forgets a single cake, balloon, or awkward rendition of
      • Accelerate Github code reviews with Zoho Cliq Platform's link handlers

        Code reviews are critical, and they can get buried in conversations or lost when using multiple tools. With the Cliq Platform's link handlers, let's transform shared Github pull request links into interactive, real-time code reviews on channels. Share
      • App Spotlight : PagerDuty for Zoho Cliq

        App Spotlight brings you hand-picked apps to enhance the power of your Zoho apps and tools. Visit the Zoho Marketplace to explore all of our apps, integrations, and extensions. In today's fast-paced world, seizing every moment is essential for operational
      • Automate your status with Cliq Schedulers

        Imagine enjoying your favorite homemade meal during a peaceful lunch break, when suddenly there's a PING! A notification pops up and ruins your moment of zen. Even worse, you might be in a vital product development sprint, only to be derailed by a "quick
      • Bulk user onboarding for Cliq Channels in a jiffy

        As developers, we frequently switch between coding, debugging, and optimizing tasks. The last thing we want is to be burdened by manual user management. Adding users one by one to a channel is tedious and prone to errors, taking up more time than we could