Hi,
I would like to create a flow that connect to O365 Outlook Calendar and do the followings:
- Whenever a new meeting is received.
- Check if that meeting is back-to-back with existing meeting which is prior or after the new meeting, meaning: there is no gap between the new meeting with meeting before or after it.
- If it is back-to-back then decline the new meeting with message "You have to leave gap between meetings"
How can I do this with Power Automate?
Thanks,
Solved! Go to Solution.
Hi @khanhmekong
You could try to use Filter Query to get those events whose start time is greater than or equal to the start of the day of the start time of the newly-created event.
Filter Query:
Start/DateTime ge '@{startOfDay(triggerOutputs()?['body/start'])}'
For more info about filter query:
OData comparison operator reference - Azure Cognitive Search | Microsoft Docs
Best Regards,
Community Support Team _ Kira Xie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @khanhmekong
You could try the flow as below:
The dynamic content 'value' for 'Apply to each' is from 'Get events'.
The dynamic content for the left side 'Start time' and 'End time' is from 'Get events'.
The dynamic content for the right side 'Start time' and 'End time' is from 'When a new event is created'.
If you still have the problem, please feel free to let me know.
Best Regards,
Community Support Team _ Kira Xie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @v-yiwenxie-msft ,
Thank you for the flow, I think it can do what we need.
I have question about step 'Get events': Could you guide me how to filter only events of the booking day? Because I think we don't need to get all events of the calendar.
Hi @khanhmekong
You could try to use Filter Query to get those events whose start time is greater than or equal to the start of the day of the start time of the newly-created event.
Filter Query:
Start/DateTime ge '@{startOfDay(triggerOutputs()?['body/start'])}'
For more info about filter query:
OData comparison operator reference - Azure Cognitive Search | Microsoft Docs
Best Regards,
Community Support Team _ Kira Xie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Learn to digitize and optimize business processes and connect all your applications to share data in real time.
Read the latest about new experiences and capabilities in the Power Automate product blog.
User | Count |
---|---|
26 | |
26 | |
25 | |
20 | |
16 |
User | Count |
---|---|
54 | |
46 | |
33 | |
32 | |
30 |