Skip to main content
Post

#PowerPlatformTip 142: Automate Outlook Categories

Automatically set categories on Outlook meetings with Power Automate, no premium. PATCH events via the Office 365 Outlook 'Send an HTTP request' action.

#PowerPlatformTip 142: Automate Outlook Categories

TL;DR: Auto-categorize Outlook meetings with a standard Power Automate flow that PATCHes events via the Office 365 Outlook ‘Send an HTTP request’ action, no premium.

Tired of manually categorizing your Outlook meetings? This tip shows how to use Power Automate to set categories for calendar events automatically, keeping you organized with almost no effort.

💡 Challenge

How do you make sure all important meetings in your Outlook calendar are consistently categorized without doing it by hand? Adding categories manually takes time and is easy to forget on a busy schedule, which leaves your calendar disorganized.

✅ Solution

Use a Power Automate flow with the standard Office 365 Outlook connector to find and update your calendar events automatically. Trigger it on a schedule or with a button; it loops through your meetings and applies a category, keeping everything organized without you thinking about it.

🔧 How It’s Done

1. Add a trigger

🔸 Start the flow with a manual button or a schedule.

2. Define the category

🔸 Use a Compose action that returns an array of category names, for example createArray('NewCategory'). The category must already exist in the mailbox’s master category list.

3. Get the events

🔸 Add Get calendar view of events (V3) and set its Start Time and End Time in UTC, for example 2026-10-22T00:00:00 through 2026-10-23T00:00:00.

4. Loop the events

🔸 Insert a “For each” loop to process every event found.

5. Send the PATCH request

🔸 Inside the loop, add “Send an HTTP request” (Office 365 Outlook connector), set the Method to PATCH and the URI to:

1
https://graph.microsoft.com/v1.0/me/events/@{items('For_each')?['id']}

🔸 In the Body, set the category:

1
2
3
{
  "categories": @{outputs('Compose_-_New_Category')}
}

Power Automate designer: the Office 365 Outlook Send an HTTP request action inside the For each loop, with Method PATCH, the Graph events URI containing the event id and the categories body The “Send an HTTP request” action of the Office 365 Outlook connector inside the loop: URI https://graph.microsoft.com/v1.0/me/events/ followed by the event id, Method PATCH, and the Body with the categories array taken from the Compose action.

6. Save and test

🔸 Run the flow and watch your meeting categories update automatically.

🎉 Result

Your flow now runs in the background, applying your category to all relevant meetings. Your calendar is instantly more organized and easier to filter, you can find specific types of meetings with a click, all without a premium license.

🌟 Key Advantages

🔸 Accessibility: uses only standard connectors, no premium Power Automate license required.

🔸 Time-saving: frees you from manually updating calendar entries.

🔸 Powerful customization: the Graph API through this action allows more advanced updates than standard actions permit.

🎥 Video Tutorial

🛠️ FAQ

1. Is this really not a premium feature? Correct. While the general “HTTP” connector is premium, the “Send an HTTP request” action inside the Office 365 Outlook connector is included with standard M365 licenses and is designed to call the Microsoft Graph API for Outlook.

2. How can I add a category without removing existing ones? Before your PATCH, add another “Send an HTTP request” (Outlook connector) with the GET method to the same URI (?$select=subject,categories keeps the response small) to read the event’s current categories. Then merge them with union() and use the result in the PATCH body:

1
union(coalesce(body('Send_an_HTTP_request_-_GET')?['categories'], json('[]')), createArray('NewCategory'))

Tested results: ["Blue category","Projects"] + ["Projects","NewCategory"] gives ["Blue category","Projects","NewCategory"] (no duplicate), an event with "categories": [] gives ["NewCategory"], and the coalesce(..., json('[]')) keeps the expression valid when the property is missing. Put the output into { "categories": @{outputs('Compose')} }.

3. Can I update other details besides the category? Yes. The PATCH method can update many event properties, for example, change the ‘showAs’ status (Free to Busy), modify the body, or update the subject by including those fields in the JSON body.

4. Which Graph paths does the Outlook “Send an HTTP request” action accept? Only mailbox paths. Anything else returns 400 with this message: “URI path is not a valid Graph endpoint, path is neither absolute nor relative or resource/object is not supported for this connector. Invalid resource, Allowed values: me,users. Invalid Object, Allowed values: messages,mailFolders,events,calendar,calendars,outlook,inferenceClassification.” Consequences seen in tests: /v1.0/me/calendarView?... is rejected (calendarView is not in the list), /v1.0/me/calendar/calendarView?startDateTime=...&endDateTime=...&$select=subject,categories,start&$top=2 works and pages with @odata.nextLink. Relative URIs such as /v1.0/me/mailFolders?$top=1 work too.

5. How do I read the categories that exist in the mailbox? GET https://graph.microsoft.com/v1.0/me/outlook/masterCategories through the same Outlook action returns value[] with id, displayName and color (a presetN value). Use the displayName values in your categories array; the colour is bound to the master category, not to the event.

6. Can I filter events by category or date before the loop? Yes, both ways work. In Graph: GET /v1.0/me/events?$filter=categories/any(c:c eq 'Projects')&$select=subject,categories&$top=50 and $filter=start/dateTime ge '2026-10-13T00:00:00' were accepted. In the standard action “Get calendar view of events (V3)” the parameters are calendarId, startDateTimeUtc, endDateTimeUtc (format 2017-01-01T08:00:00), plus optional $filter, $orderby, $top, $skip and search; $filter = isAllDay eq false with $orderby = start/dateTime asc ran fine. The calendar view expands recurring series into single instances, so the PATCH hits each occurrence by its own id.

This tip is by Marcel Lehmann, Microsoft MVP (Business Applications) and founder of the Power Platform Academy, which runs free live workshops (in German). See the next free workshop dates (in German). For companies that want this implemented for them, see KMUpower: Power Platform consulting & automation for SMEs (DACH).

This post is licensed under CC BY 4.0 by the author.

Microsoft and the Power Platform product names (for example Power Apps, Power Automate, Copilot Studio) are trademarks of the Microsoft group of companies. This is an independent website. It is not operated, sponsored or endorsed by Microsoft.