Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Send email to Managers based on Assets results

Ste404
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
December 19, 2023

Hi there,

I have an automation that extracts users in Assets who has a contract end date within 7 days.

I want to send an email to each persons manager to say they are due to end.

So if I have 5 people with 5 managers there will be 5 emails sent.

I have a lookup objects to extract the information.

I know I need to do a branch somehow but I tried a smart value and that works for the name but when I do {{lookupObjects.user.manager}} I get all 5 manager names in each email.

How should I structure this loop?

thanks

2 answers

2 votes
Mark Segall
Community Champion
December 19, 2023

Hi @Ste404 - If I'm understanding correctly, you're triggering this on a schedule, correct?  From there, instead of performing a Lookup Objects, I'd add a "Branch on AQL" component and use whatever AQL you have for the Lookup Objects.  This will force it to iterate through the results rather than trying to deal with an aggregate of objects. 

0 votes
Joseph Chung Yin
Community Champion
December 19, 2023

@Ste404 -

I agreed with Mark's solution on this question.  Question for you is how are you tracking the contract will end in 7 days?  Is the end date information tracked in your Assets object as attribute + user's manager info as an attribute?

Please advise.

Best, Joseph Chung Yin

Jira/JSM Functional Lead, Global Technology Applications Team

Viasat Inc.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events