type: custom

customType: model-snapshot

provider: anthropic

modelApi: anthropic-messages


type: message

role: user

type: text

text:
[cron:3c0c2c17-0faa-41cb-bd7b-068b2a259b28 chad-email-smart] Smart email check for chad@cfrfl.com:

1. Query ms-365 for unread emails (isRead eq false) from last 30 minutes
2. Compare with previously seen emails (track IDs in memory)
3. If NEW unread emails found:
   - Categorize each (urgent/action/fyi/newsletter)
   - Draft responses in Chad's voice for action items
   - Send summary notification with categories and drafts
4. If no new emails, reply HEARTBEAT_OK (silent)

Use file /home/crogers2287/memory/last-email-check.json to track seen email IDs.
Only report when there's something actionable. Be efficient.
Current time: Tuesday, February 3rd, 2026 — 9:03 AM (UTC)


role: assistant

read

type: toolCall

api: anthropic-messages

stopReason: toolUse


exec

command: curl -s -X GET "https://graph.microsoft.com/v1.0/me/messages?\$filter=isRead%20eq%20false%20and%20receivedDateTime%20ge%202026-02-03T08:33:00Z&\$select=id,subject,sender,receivedDateTime,bodyPreview,importance&\$orderby=receivedDateTime%20desc&\$top=20" -H "Authorization: Bearer $(clawdbot secret get MS365_TOKEN 2>/dev/null || echo '')" 2>/dev/null | jq -r '.value // []' 2>/dev/null || echo '[]'


stopReason: stop