Skip to main content

Microsoft Graph API integration for OpenClaw agents - manage email, calendar, and tasks

Project description

OfficeClaw

OfficeClaw

Microsoft Graph API integration for OpenClaw agents — manage email, calendar, and tasks.

PyPI Python License

Overview

Officeclaw is an OpenClaw skill that enables AI agents to interact with personal Microsoft accounts through the Microsoft Graph API. Agents can read/write emails, manage calendar events, and handle tasks — all through natural language commands.

What Can Officeclaw Do?

  • 📧 Email — Read inbox, send emails, mark read/unread, archive
  • 📅 Calendar — View events, create meetings, manage appointments
  • Tasks — Manage Microsoft To Do lists, create/complete tasks

Quick Start

Installation

pip install officeclaw

Setup

  1. Create Azure App Registration (one-time setup)

    See docs/setup.md for detailed instructions.

  2. Configure credentials

    # Create .env file
    cp .env.template .env
    
    # Edit with your Azure app credentials
    OFFICECLAW_CLIENT_ID=your-client-id
    OFFICECLAW_CLIENT_SECRET=your-client-secret
    
  3. Authenticate

    officeclaw auth login
    

Usage

# List recent emails
officeclaw mail list --limit 10

# View calendar
officeclaw calendar list --start 2026-02-01 --end 2026-02-28

# List task lists
officeclaw tasks list-lists

# Create a task
officeclaw tasks create --list-id <id> --title "Review report"

# JSON output (for agents)
officeclaw --json mail list

For OpenClaw Agents

Once installed, OpenClaw agents can use Officeclaw through natural language:

User: "Show me today's calendar"
Agent: [Uses Officeclaw]
       You have 3 events today:
       - 9:00 AM: Team standup
       - 2:00 PM: Client call
       - 4:00 PM: Project review

User: "Add 'finish report' to my tasks"
Agent: [Uses Officeclaw]
       ✓ Task created: finish report

See skill/SKILL.md for the full skill manifest.

Commands

Authentication

Command Description
officeclaw auth login Authenticate with Microsoft
officeclaw auth logout Clear stored tokens
officeclaw auth status Show authentication status

Email

Command Description
officeclaw mail list List messages
officeclaw mail get <id> Get message details
officeclaw mail send --to <email> --subject <subj> --body <body> Send email

Calendar

Command Description
officeclaw calendar list --start <date> --end <date> List events
officeclaw calendar create --subject <subj> --start <dt> --end <dt> Create event

Tasks

Command Description
officeclaw tasks list-lists List task lists
officeclaw tasks list --list-id <id> List tasks
officeclaw tasks create --list-id <id> --title <title> Create task
officeclaw tasks complete --list-id <id> --task-id <id> Complete task
officeclaw tasks reopen --list-id <id> --task-id <id> Reopen task

Configuration

Environment variables (or .env file):

Variable Required Description
OFFICECLAW_CLIENT_ID Yes Azure app client ID
OFFICECLAW_CLIENT_SECRET Yes Azure app client secret
OFFICECLAW_REDIRECT_URI No Redirect URI (default: http://localhost:8000/callback)
OFFICECLAW_TENANT_ID No Tenant ID (default: consumers)

Security

  • Tokens stored securely — System keyring (macOS Keychain, Windows Credential Manager) or encrypted file
  • No data storage — Officeclaw passes data through, never stores emails/events
  • No telemetry — No usage data collected

See SECURITY.md for full security documentation.

Development

# Clone and install
git clone https://github.com/danielithomas/officeclaw.git
cd officeclaw
pip install -e ".[dev]"

# Run tests
pytest

# Lint
ruff check src/ tests/
black --check src/ tests/

License

Apache License 2.0 — see LICENSE

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

officeclaw-1.0.0.tar.gz (1.6 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

officeclaw-1.0.0-py3-none-any.whl (31.8 kB view details)

Uploaded Python 3

File details

Details for the file officeclaw-1.0.0.tar.gz.

File metadata

  • Download URL: officeclaw-1.0.0.tar.gz
  • Upload date:
  • Size: 1.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for officeclaw-1.0.0.tar.gz
Algorithm Hash digest
SHA256 1f21e55d1d9b361d796d267237a2a4b0ee3b2c972eae87c9b99bd53336facd82
MD5 e07b133f105b66310153ea7da84a3676
BLAKE2b-256 b18130226b4d86f564dd975bcf89015aca7cbb32cdd8d12409f61bcc40d6d36b

See more details on using hashes here.

Provenance

The following attestation bundles were made for officeclaw-1.0.0.tar.gz:

Publisher: publish.yml on danielithomas/officeclaw

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file officeclaw-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: officeclaw-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 31.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for officeclaw-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4c4faa44ea10c16fd0ff96b80a16a95a8963c1c85db9d4a91812d3fa04a45e1d
MD5 4ec0f9f3ecbb1dda4ebc34415c9a85cb
BLAKE2b-256 7d8ff4ba58e91b3962e9b9eeac13a7f58495df5f7182160672491c222ba52c64

See more details on using hashes here.

Provenance

The following attestation bundles were made for officeclaw-1.0.0-py3-none-any.whl:

Publisher: publish.yml on danielithomas/officeclaw

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page