Post to Channel and Mention User based on Users Drop-Down Field
I am making a custom app in Connect which has a Users drop-down field, displaying the users' email addresses. My aim is to have a workflow which posts a message in a channel and mentions the user chosen in the drop-down field.
I have successfully been able to post the message in the desired channel and create a mention with the following code:
- message_text = toString(("Scheduling {@" + userID + "} No" + input.Student_Name) + " this week.");
- message = zoho.cliq.postToChannel("scheduling",message_text);
I'm a bit new to Zoho and Deluge, and what I am having trouble with is how to get the user's Zoho User ID based on the email address from the Users drop-down in the form so that I can store it in the variable userID and correctly mention that user. Is there a quick and easy way to do this? Do I need to get the user data from a URL such as
https://cliq.zoho.com/api/v2/users and then look it up from there?
Any help would be appreciated. Thank you!