cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
tijsko
New Member

How to exclude certain domains with a trigger?

I have built a simpel flow so that when a new email arrives and an auto reply will be send.

Now I am trying to figure out how to exclude certain domains from triggering this actions. I understand the right expression could do this but I a not too familiar with those.

 

Could someone help me formulate one that roughly means: if a mail is from gmail.com nothing will happen?

1 ACCEPTED SOLUTION

Accepted Solutions
ScottShearer
Super User
Super User

@tijsko 

The best way would be to use a trigger condition (filter).  You can have more than 1 trigger filter.

For the Flow to run, the trigger filter expression must evaluate to true.

To create the filter, go to the settings for the trigger.

See my example below:

image.png

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott

View solution in original post

2 REPLIES 2
ScottShearer
Super User
Super User

@tijsko 

The best way would be to use a trigger condition (filter).  You can have more than 1 trigger filter.

For the Flow to run, the trigger filter expression must evaluate to true.

To create the filter, go to the settings for the trigger.

See my example below:

image.png

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott
tijsko
New Member

That seems to have done the trick, thanks!

Just for copy purposes:

@not(contains(triggerOutputs()?['body/from'],'gmail.com'))

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (3,670)