Power of Automation: Automatically send an email to all portal users with today's list of Open tasks.

Power of Automation: Automatically send an email to all portal users with today's list of Open tasks.

Hello Everyone,


A Custom Function is a user-written set of code to achieve a specific requirement. Set the required conditions needed as to when to trigger using the Workflow rules (be it Tasks / Project) and associate the custom function to it.


Requirement:-


One of our customers wanted to email all the portal users with their list of daily Tasks which are in open status along with details like Project name, Task name, Task URL, start date, due date, status. Sample email notification screenshot is attached for reference.

All you need to do is schedule the frequency for how often the below custom function should be executed. Here is the help document to know more about Schedule Functions.


Custom function code:-


projectParam = Map();

projectParam.put("status", "active");

getAllProjects = invokeurl
[

url : projectsEndpoint +portalId+"/projects/"

type : GET

parameters : projectParam

connection : "XXXXXXX"

];

if(getAllProjects.containKey("projects"))
{

projects = getAllProjects.get("projects");

usersParam = Map();

usersParam.put("user_type", "active");

getAllUsers = invokeurl
[

url : projectsEndpoint+portalId+"/users/"

type : GET

parameters : usersParam

connection : "XXXXXXX"

];

if(getAllUsers.containKey("users"))
{

users = getAllUsers.get("users");

for each user in users

{

userId = user.get("id");

taskParam = Map();

taskParam.put("status", "open");

taskParam.put("owner", userId);

taskParam.put("time", "today");

getAllTasks = invokeurl
[

url : projectsEndpoint + portalId+"/mytasks/"

type : GET

parameters : taskParam

connection : "XXXXXXX"

];

if(getAllTasks!="")

{

tasks = getAllTasks.get("tasks");

taskRow = "";

for each  task in tasks

{

taskRow = taskRow + "<tr> <td>" + task.get("project").get("name") + "</td> <td>" + task.get("name") + "</td> <td>" + task.get("link").get("self").get("url") + "</td>  <td>" + task.get("start_date") + "</td> <td>" + task.get("end_date") + "</td> <td>" + task.get("status").get("name") + "</td> </tr>";

}

sendmail

[

from :zoho.loginuserid

to : user.get("email")

subject :"Today's tasks"

message :"<html> <style> table, th, td { border:1px solid black; border-collapse: collapse; } </style> <body> <h2>Today's Tasks</h2> <table style=\"width:100%\"> <tr> <th>Project Name</th> <th>Task Name</th> <th>Task URL</th>  <th>Start date</th><th>Due date</th>  <th>Status</th></tr> " + taskRow + " </table> </body> </html>"

]

info taskRow;

}

}

}

}


Make sure to replace XXXXXXX with the Zoho Projects connection link name with scope ZohoProjects.Tasks.READ, ZohoProjects.portal.READ, ZohoProjects.Users.READ. Check this link to learn how to create the connection.  Please find the screenshot of sample schedule function attached for reference. 


We hope you found this post useful. If you have any questions, feel free to share them in the comments below.


    Zoho Desk Resources

    • Desk Community Learning Series


    • Digest


    • Functions


    • Meetups


    • Kbase


    • Resources


    • Glossary


    • Desk Marketplace


    • MVP Corner


    • Word of the Day


      • Sticky Posts

      • Project Billing with the Staff Hours Method in Zoho Projects

        The Staff Hours Billing Method in Zoho Projects allows you to bill your clients based on the actual time spent by each team member on a project, at the rate set for each user. This is useful for projects where different skill sets are needed and service
      • Tip 37: Time Log Restriction in Zoho Projects

        Timesheet in Zoho Projects helps you big time in entering log hours for the tasks and issues and approving them. Now, with the new Time Log Restriction option, you can set daily and weekly log hour limits. You can restrict users from entering extra log hours than the permissible limit. The limits are restricted to 24 hours per day and 168 hours per week by default based on business hours. To customize, navigate to Task & Timesheet settings under Portal Configuration in Zoho Projects setup and enable
      • Organize and Track Phases with Phase Custom Views

        Phase Custom Views let you filter and display phases based on specific criteria. This helps you focus on what’s most relevant for you and your team. Filter phases using criteria such as budget, status, and more. Share views with specific users or teams
      • Create Your Own Issue Management System

        Effective issue management is a cornerstone of project success. Every bug or issue, no matter how small, needs to be tracked and resolved in time to maintain project momentum. In this post, we’ll explore how an issue management system in Zoho Projects
      • Time Log Reminder

        Tracking the time spent on tasks and issues is one of the most important functions of a timesheet. However, users may forget to update the time logs because they have their own goals to achieve. But, time logs must be updated at regular intervals to keep

      Zoho CRM Plus Resources

        Zoho Books Resources


          Zoho Subscriptions Resources

            Zoho Projects Resources


              Zoho Sprints Resources


                Zoho Orchestly 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




                          Zoho Writer Writer

                          Get Started. Write Away!

                          Writer is a powerful online word processor, designed for collaborative work.

                            Zoho CRM コンテンツ






                              ご検討中の方

                                • Recent Topics

                                • Zoho Writer page break in a merge repeating region always adds an unwanted blank page

                                  Hi I'm merging a Zoho CRM record to a Zoho Writer document with a repeating region to display subform records on their own page within the document. When I try to insert a page break in a repeating region, the resulting merge always adds an unwanted blank
                                • Introducing bot filtering for accurate analytics

                                  Dear Zoho Campaigns Users, We're happy to introduce bot filtering to enhance the accuracy of your email campaign analytics. This new feature is designed to help you filter out bot-generated opens and clicks, which will ensure your campaign reports reflect
                                • Zoho Mail POP & IMAP Server Details

                                  Hello all! We have been receiving a number of requests regarding the errors while configuring or using Zoho Mail account in POP/ IMAP clients. The server details vary based on your account type and the Datacenter in which your account is setup. Ensure
                                • Company domain with Zoho Mail as support email in Zoho Desk

                                  Hello, We are a Zoho One customer. We just converted to Zoho Mail from Google Workspace Mail yesterday. We have a domain name for our company. With Gmail, we were able to forward our info@company.com email to Zoho Desk. Customer would then be able to
                                • Best way to organize Zoho Desk with CRM products

                                  I'm having a bit of trouble finding out how I'm supposed to organize our Zoho Desk (departments vs teams vs products) and how to use it. We want to use the KnowledgeBase, Community, and Tickets sections. Here's a general overview of our company to get
                                • Settings Icon No Longer in ZOHO Desk?

                                  In ZOHO desk, there has been a gear icon for settings. as of yesterday, it is no longer there. I showed up briefly this morning but is gone again.  Anybody else experiecing this? 
                                • Emoji Support in Bigin CRM

                                  We request the implementation of emoji support across Bigin CRM. This feature should allow users to seamlessly use emojis in text fields, headlines, and deals. It would enhance communication, improve the visual appeal of records, and bring more personalization
                                • Does Zoho Learn integrate with Zoho Connect,People,Workdrive,Project,Desk?

                                  Can we propose Zoho LEarn as a centralised Knowledge Portal tool that can get synched with the other Zoho products and serve as a central Knowledge repository?
                                • Workdrive API Get list of Sub Folders not working

                                  Hello Workdrive API "et list of Sub Folders" not working. Can you please check this. https://workdrive.zoho.com/apidocs/v1/teamfolder/getteamfolderfolders
                                • is there a way to add tag in the "form rule" so that the email workflow can be automated through zoho begin for that perticular response?

                                  I have a form rule; based on which the response like a program to be sent via begin workflow. How do i do that?
                                • Email address with + char is incorrectly invalid

                                  cannot enter contact with email address containing +, i. e. valid+email@example.com. this is a perfectly valid email address by but fails Zoho Campaigns validation. https://en.wikipedia.org/wiki/Email_address#Local-part
                                • Update Regarding Zoho Finance Applications' Domains For API Users

                                  Hi users, Until now, both the Zoho Finance apps and their APIs shared a common domain. We've recently introduced separate domains for APIs. You can now start using the new domains for API calls. The old domains will not work for API users starting April
                                • Zia powered by GPT is already available for MExico?

                                  Hi there! Is Zia powered by GPT is already available for MExico? I have Zoho ONE membership is Zia powered by GPT compatible with my membership? What's the specs? Do I have to get Chat GPT Plus plan? Thanks!
                                • Adding a Download field to a form

                                  I want to set up a form on my website so that people can download a pdf file once they have submitted their email details. It has been really easy to set up the template but I cannot locate a field with the function. I can see file upload, but not download. This is the main task I want to add to my website as part of the "sales funnel" so hope there is the option.
                                • Campaign Edit - Vertical Align Text to Center

                                  I have a layout in one of my campaigns that is using the split box with a picture on the left and text on the right. I can't find where I can vertically align the content of these boxes. It's forcing my text to be at the top vs centered. Am I missing
                                • Introducing Dark Mode / Light Mode : A New Look For Your CRM

                                  Hello Users, We are excited to announce a highly anticipated feature - the launch of Day, Night and Auto Mode implementation in Zoho CRM's NextGen user interface! This feature is designed to provide a visually appealing and comfortable experience for
                                • is it possible to pull the landing page and email campaign from Zoho app to Zoho marketing? Can I get all the benefits that exclusive app that offers in ZMA?

                                  There is a exclusive Zoho apps for landing page design, email campaign, and same features are there within ZMA as well for to setup landing page and email campaign. can ZMA offer all or limited features of those apps? I request please provide demo and
                                • Enable 2FA / MFA in Bigin

                                  Hi, Our company started using Bigin. I (sysadmin) want to require MFA for Bigin as some users also have integrated their calender and mailbox into Bigin and regardless of that, in general, MFA logins are preferred in our company as it strengthens our
                                • Forwarding Zoho Desk Support Email to a different e- mail

                                  Hello, I am using ZohoDesk and I have a Zoho Desk Support e-mail setup. I would like to know if there is a way to forward the e- mail inbound to this Zoho Desk Support e- mail to a different e- mail?  Thanks!
                                • We are being overbilled by Zoho and they refuse to correct it

                                  We are being overbilled for CRM Ultimate Add-on. Zoho has acknowledged that they know this, but refuses to address and issue billing credits for the amounts we have been overpaying. Our company has been downsizing (unfortunately) and in the past 3 months
                                • is there a better way to routinely export my project timesheets?

                                  Hi there, I am somewhat happy with how Zoho books handles time.  One thing that is missing is more user driven control over my data.  I have a workflow where I constantly need to give customers feeds of work done.  So I pick a project, and would ideally
                                • Does the ability exist to make tax on the customer profile mandatory?

                                  I am reaching out to inquire about the possibility of making the "Customer Tax" field mandatory when creating a new customer in Zoho. We want to ensure that all customers have their tax information recorded to maintain compliance with our internal processes.
                                • Triggering rules on lead conversion

                                  There is no field on the Rule list for rule conversion to trigger an alert on liead conversion to a potential. I assigned a rule to file on any creation or update of a lead. The lead was changed a lead to a potential but no rule was fired. Rajesh Bhadra
                                • How do you remove a user from SalesIQ?

                                  I have a user in Sales IQ who needs to be removed (she's no longer involved with sales and chat) but I can't find any way to remove her. How do I do that?
                                • Integrate SalesIQ with tiendanube.com

                                  Tiendanube.com is the leading e-commerce platform designed to help businesses create and manage online stores. It provides tools for entrepreneurs and companies to set up, customize, and operate their online shops with ease. Tiendanube is particularly
                                • How to reset Zoho Commerce

                                  Hi, we are preparing a new onlineshop connected to commerce and books for going live in the next days. Now we want to delete all tests and transactions we made within the development process. And also add a new tax rule which is not possible at the moment
                                • Free webinar: ‌Zoho Vault in 2024—A live Q&A with our experts

                                  Hi everyone! 2024 has been a pivotal year for us, taking our journey from a basic team password manager in 2013 to a full-featured security platform offering password management, single sign-on (SSO), and soon, passkey management. Our team has been tirelessly
                                • Kaizen #167 - Configuration and Initialization of Zoho CRM Python SDK (V7) for different client types

                                  Hello everyone! Welcome back to another week of Kaizen! Zoho CRM Python SDK allows developers to integrate Python applications with Zoho CRM. In today's Kaizen post, we will explore how to initialize and configure the SDK for both self-clients and server-based
                                • Zoho Forms - Dynamic Prefill Setup Question

                                  Hello, I'm very excited about this feature. So much I'm learning about webhooks. However, it seems that the webhooks I can obtain from Zoho Flow and Zoho CRM come with already parts in the URL that are put as invalid by the GET Webhook URL. Do I need
                                • How to get a list of Team Folders associated to a Project from the API?

                                  I've tried the below, based on another article and was unsuccessful. response = invokeurl [ url :"https://projectsapi.zoho.com/api/v3/portal/" + _portalID + "/projects/" + _projectResID + "/folders" type :GET connection:"zohoprojects" ]; info response;
                                • Email Alert attachments unavailable for Vendor Payments

                                  I have several vendors with country specific compliance requirements to support the payment of their invoices. I've created Vendor Payment templates to meet their requirements and I setup an automation workflow that gets triggered when the invoice is
                                • How to create Sepa Direct Debit XML file: solution and code

                                  Even though Books provides a payment integration for Stripe and Gocardless (in Europe) there are customers that want to use the Sepa services of their own bank. Mainly because Stripe and Gocardless are quite expensive. In that case they would need a Sepa
                                • Exporting Project Tasks

                                  I can export the gantt chart to a nice PDF in colour, but we want just the task list in a nice colour layout. Is there a way to export it to PDF without the gantt? It would be perfect to give to clients.
                                • bug reporting with the count of linked Desk tickets

                                  I am aware that when viewing an individual bug, you are able to see a count of the Desk tickets that are linked to the bug on the right hand side. However, I cannot see a way of reporting this figure from a list of bugs. Our use case is that we would
                                • Unable to send e-mails to an specific address

                                  Hello. I'm having problems sending e-mails to my shipping company. user@shippingcompanydomain.com INVALID_ADDRESS, ERROR_CODE :550, ERROR_CODE :5.1.1 <user@shippingcompanydomain.com>: Recipient address rejected: User unknown in virtual mailbox table Reporting-MTA:
                                • Blueprint transition help needed

                                  I have 5 approvers. For a stage to be passed to the next stage, I require any 3 out of these 5 approvers to make the approval. There is no particular sequence of approval, at any one time, any one can approve. As long as 3 approvers approve, the stage
                                • Year-End Wrap: Out-of-Office Made Easy with Zoho Mail

                                  As we wrap up 2024, now is the perfect moment to take control of your email routine and gear up yourself for a productive and successful new year. We have curated a series of weekly tips to help you master your email management starting today. Watch out
                                • Creator Simplified #9: Automatically Sending Uploaded Files as Email Attachments

                                  Hey Creators, Welcome back to the Creator Simplified series! Today, we’ll explore how to automate file uploads as email attachments in Zoho Creator—a handy feature that saves time and reduces manual effort in your business processes. Use Case: In a typical
                                • Zoho Books Community Meetup: Learn, Grow, Network!

                                  Hello users! We are excited to announce a series of upcoming Zoho User Group meetups and would love for you to join us! This is a great opportunity for you to connect with other users, share experiences, and learn more about how to make the most of our
                                • Bar chart from Deal Stage Snapshot table not showing right amounts

                                  Hi, since we needed to track the changes of our deal pipeline over time, I added a new data source and selected 'Snapshots' to start the sync. At first I thought it was working just fine, after a few days I realized that something was wrong with the amounts
                                • Next Page