#Connecting Microsoft Outlook email and calendar

1 messages · Page 1 of 1 (latest)

mild burrow
#

I'd like to get my Outlook email and calendar connected to one of my agents. Whats the best way to accomplish this?

stiff jettyBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> âś… Mark Solution

boreal beaconBOT
#

There isn’t a built-in “Outlook / Microsoft Graph mail+calendar” connector in core OpenClaw right now (Gmail has a dedicated flow, Outlook doesn’t yet). The two best patterns today are:

Option A (recommended): Power Automate / Logic Apps → OpenClaw Webhooks (push-based)

This is the quickest way to get “new mail / new event” into an agent for summaries, triage, reminders, etc.

  1. Enable Webhooks on your gateway (config):
  1. Expose an HTTPS endpoint that Microsoft can reach
    Power Automate’s “HTTP” action needs a reachable URL. Common setups:
  • Put your gateway behind Tailscale Serve/Funnel (supported path in other webhook docs), or
  • Use a tiny “bridge” (Azure Function / Cloudflare Worker) that receives the trigger and forwards it to your gateway’s /hooks/... endpoint over your private network.
  1. In Power Automate, create flows like:
  • “When a new email arrives (V3)” → HTTP POST to https://<your-gateway>/hooks/agent
  • “When an event is added, updated or deleted (V3)” → same
#

Important: OpenClaw webhooks require the token via a header (Authorization: Bearer … or x-openclaw-token: …). Query-string ?token= is rejected. (Also in the webhook docs.)

This gives you “connected” in the sense that Outlook activity can wake an agent and deliver summaries back into chat.

Option B (more powerful): Write a plugin/skill that talks to Microsoft Graph (pull + read/write)

If you want the agent to query your inbox/calendar on demand and send mail / create events, you’ll want a custom integration (Graph OAuth, token refresh, tools like outlook_list_messages, outlook_create_event, etc.).

Quick clarifier so I can point you at the best setup

  1. Is this Microsoft 365 work/school or Outlook.com personal?
  2. Do you need read-only summaries, or also send email / schedule meetings?
  3. Do you prefer push triggers (new mail/event instantly) or a daily digest (cron/summary)?

Reply with those and I’ll suggest the cleanest concrete wiring (including what to send in the webhook payload so the agent gets useful context without leaking your whole mailbox).

mild burrow
#
  1. microsoft 365 2. Send email and schedule meetings 3. Push triggers
boreal beaconBOT
#

For Microsoft 365 + push triggers + send mail + schedule meetings, the best “works today, minimal code” architecture is:

  1. Power Automate handles the Microsoft side (triggers + doing the actual send/create-event)
  2. OpenClaw handles the “brain” (summarize, decide, draft, extract attendees/times, etc.)
  3. They talk via OpenClaw Webhooks (inbound) and optionally a Power Automate HTTP endpoint (outbound)

OpenClaw doesn’t ship a first-party Outlook/Graph connector yet, so this is the most reliable path without writing a full Graph plugin.


1) Inbound (push): Outlook → Power Automate → OpenClaw Webhook

A. Enable OpenClaw hooks

Docs: https://docs.openclaw.ai/automation/webhook

Config example (JSON5):

#
{
  hooks: {
    enabled: true,
    token: "REPLACE_WITH_A_LONG_RANDOM_SECRET",
    path: "/hooks",
  },
}

Key detail: hook auth must be via header (Authorization: Bearer ... or x-openclaw-token). Query ?token= is rejected.

B. Power Automate flow: “When a new email arrives (V3)”

Add an HTTP action to POST to your gateway:

  • URL: https://<your-public-gateway>/hooks/agent
    (public can be via reverse proxy / tunnel; many people use Tailscale Funnel/Serve style setups, but any HTTPS ingress works)
#
  • Method: POST
  • Headers:
    • Authorization: Bearer <hooks.token>
    • Content-Type: application/json
  • Body (example):
{
  "name": "Outlook",
  "wakeMode": "now",
  "deliver": true,
  "channel": "discord",
  "to": "YOUR_DISCORD_CHANNEL_OR_THREAD_ID",
  "message": "New email\nFrom: @{triggerOutputs()?['body/from/emailAddress/address']}\nSubject: @{triggerOutputs()?['body/subject']}\nPreview: @{triggerOutputs()?['body/bodyPreview']}\n\nTask: Summarize in 3 bullets. Draft a reply. If it needs a meeting, propose times + attendees."
}
#

Do the same for calendar with the trigger “When an event is added, updated or deleted (V3)” and send a compact event payload.


2) Outbound (send/schedule): OpenClaw → Power Automate “HTTP request” → Outlook/Calendar

To actually send mail / create meetings automatically, you need something on the Microsoft side that can receive a command.

A. Create two Power Automate flows with trigger “When an HTTP request is received”

One flow for email, one for calendar:

  • Flow 1: POST /send-email → “Send an email (V2)”
  • Flow 2: POST /create-event → “Create event (V4)”

Each flow gives you a URL like https://prod-xx.westeurope.logic.azure.com:443/....

B. Let OpenClaw call those URLs

OpenClaw doesn’t currently have a “generic HTTP POST tool” built-in, so you have two practical options:

#
  • (Most common) make a tiny custom skill/plugin that does a curl -X POST ... to those Power Automate endpoints (and keep it locked down: only allow those URLs, keep secrets out of chat logs).
  • (More work, cleanest long-term) write an OpenClaw plugin that talks to Microsoft Graph directly (Mail.Send / Calendars.ReadWrite) and also manages push subscriptions. Plugin docs: https://docs.openclaw.ai/tools/plugin

If you tell me whether you’re comfortable writing a small script/plugin (or prefer no-code), I can suggest the least-painful version.


3) Two quick questions (so this doesn’t turn into a fragile setup)

  1. Where is your Gateway running (local Mac, VPS, etc.) and do you already have a public HTTPS URL to reach it?
  2. For outbound actions: do you want auto-send (agent can send/schedule) or approval required (agent drafts, you confirm)?
mild burrow
boreal beaconBOT
#

If you don’t want to write any code, the most reliable “M365-in / M365-out + push triggers” setup is to use Power Automate for all Microsoft actions, and use OpenClaw only for the reasoning/drafting — with Microsoft Teams as the “message bus” between them.

This avoids needing a custom Graph integration and avoids needing to expose your OpenClaw Gateway to the public internet.

Recommended no-code architecture (2 Power Automate flows + Teams)

Step 0) Get OpenClaw reachable in Teams

OpenClaw’s Teams support is plugin-based:

Yes, it’s a bit of setup, but it’s still “no code”, and once it’s done you can keep everything inside M365.

Flow A (inbound push): Outlook → Teams message to OpenClaw

Power Automate:

  • Trigger: When a new email arrives (V3) (and another one for calendar: When an event is added/updated/deleted)
#
  • Action: Post a message in a Teams channel (pick a dedicated channel like openclaw-inbox where the bot is installed)

Message template (keep it structured so the agent can parse it):

INBOX_EVENT
type: email
from: <sender>
subject: <subject>
messageId: <message id>
bodyPreview: <preview>

TASK:
Draft a reply. If a meeting is needed, propose time + attendees + agenda.
Return an ACTION JSON (see format).
#

Tip: In the OpenClaw Teams config you can set that channel to not require @mention so Power Automate posts will trigger the bot (Teams defaults to mention-gating). See the requireMention notes in the Teams doc.

Flow B (outbound execution): OpenClaw → Teams message → Power Automate sends/schedules

Power Automate:

  • Trigger: When a new channel message is posted (in the same channel, or a separate openclaw-actions channel)
  • Condition: message starts with something like ACTION_JSON:
  • Action: Parse JSON
  • Then:
    • If action == "send_email" → Send an email (V2)
    • If action == "create_event" → Create event (V4)

Have OpenClaw output something like:

ACTION_JSON:
{
#
  "action": "send_email",
  "to": ["person@company.com"],
  "subject": "Re: …",
  "body": "…"
}

and/or:

ACTION_JSON:
{
  "action": "create_event",
  "subject": "…",
  "start": "2026-03-01T14:00:00-05:00",
#
  "end": "2026-03-01T14:30:00-05:00",
  "attendees": ["a@company.com","b@company.com"],
  "body": "Agenda: …"
}

Strongly recommended: insert a Power Automate Approval step before actually sending email / creating meetings (so it drafts automatically, but you approve).


Why Teams is the key here (for no-code)

  • Power Automate can easily trigger on Outlook + post to Teams
  • Power Automate can trigger on Teams messages + execute Outlook actions
  • OpenClaw can participate in Teams as a bot (once configured)
  • This gives you a full loop without needing a custom HTTP service or plugin code
#

Quick question to tailor the exact steps

Do you have Microsoft Teams available in the same tenant (and are you allowed to install a custom/internal Teams app/bot)? If yes, I’ll outline the exact two flows (triggers + actions + conditions) and the safest ACTION_JSON schema to use. If no, the fallback is webhooks + a public HTTPS endpoint, but truly “no code” bi-directional control gets a lot harder.