Email Triage Guide

Let PILOT prioritize your inbox and draft replies using AI.

Overview

PILOT's email triage connects to your Microsoft 365 mailbox via OAuth and uses AI to:

Connect Your Email

Before using the email triage API, connect your Microsoft 365 account:

  1. Navigate to https://app.withpilot.ai/email/connect in your browser
  2. Authenticate with your Microsoft account
  3. Grant PILOT permission to read and send emails on your behalf
  4. Verify the connection: GET /email/status
# Check email connection status
curl -H "Authorization: Bearer pk_live_YOUR_KEY" \
  https://app.withpilot.ai/email/status

Triage Your Inbox

Get an AI-prioritized view of your inbox with suggested actions:

# Get email triage
curl -H "Authorization: Bearer pk_live_YOUR_KEY" \
  https://app.withpilot.ai/api/v1/email/triage

Response:

[
  {
    "message_id": "msg_abc123",
    "from": "cto@bigcorp.de",
    "subject": "Partnership proposal — askSOPia integration",
    "urgency": "high",
    "suggested_action": "reply",
    "summary": "CTO of BigCorp wants to discuss integrating askSOPia...",
    "ai_draft_available": true
  },
  {
    "message_id": "msg_def456",
    "from": "newsletter@saas-weekly.com",
    "subject": "This Week in SaaS",
    "urgency": "low",
    "suggested_action": "archive",
    "summary": "Weekly newsletter — no action items."
  }
]

Urgency Levels

LevelMeaning
criticalRequires immediate attention — time-sensitive, from VIP contacts
highImportant and should be addressed today
mediumRelevant but can wait — informational or non-urgent requests
lowNewsletters, notifications, FYI — safe to batch-process

Suggested Actions

ActionMeaning
replyThis email needs a response. AI draft is available.
delegateBetter handled by someone on your team
archiveNo action needed — safe to archive
deferNot urgent now, but revisit later

Draft a Reply

Generate an AI-drafted reply for any email. The AI uses your knowledge graph context to personalize the response:

curl -X POST https://app.withpilot.ai/api/v1/email/draft-reply \
  -H "Authorization: Bearer pk_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "message_id": "msg_abc123",
    "tone": "professional"
  }'

Available Tones

Send a Reply

Once you've reviewed (and optionally edited) a draft, send it:

curl -X POST https://app.withpilot.ai/api/v1/email/send-reply \
  -H "Authorization: Bearer pk_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "message_id": "msg_abc123",
    "body": "Thanks for reaching out about the integration..."
  }'

Batch Operations

Process multiple emails at once for low-priority items:

Batch Archive

curl -X POST https://app.withpilot.ai/api/v1/email/batch/archive \
  -H "Authorization: Bearer pk_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "message_ids": ["msg_def456", "msg_ghi789"] }'

Batch Mark as Read

curl -X POST https://app.withpilot.ai/api/v1/email/batch/read \
  -H "Authorization: Bearer pk_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "message_ids": ["msg_def456", "msg_ghi789"] }'

Delegate an Email

Forward an email to a team member with your comment. PILOT tracks the delegation:

curl -X POST https://app.withpilot.ai/api/v1/email/delegate \
  -H "Authorization: Bearer pk_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "message_id": "msg_abc123",
    "to_address": "colleague@company.com",
    "comment": "Can you handle the technical evaluation?"
  }'

Track delegations via GET /api/v1/delegations.

Get Thread Summary

For long email threads, get an AI-generated summary:

curl -H "Authorization: Bearer pk_live_YOUR_KEY" \
  https://app.withpilot.ai/api/v1/email/thread/conversation_abc123

Find Unanswered Emails

List emails that have been waiting for a reply beyond your configured threshold:

curl -H "Authorization: Bearer pk_live_YOUR_KEY" \
  https://app.withpilot.ai/api/v1/email/unanswered
Tip: Combine the triage and batch endpoints to build a daily email workflow: triage first, batch-archive the noise, then focus on the emails that actually matter.

Related Endpoints