feat(email): add email-joke agent with Gmail OAuth and IMAP support#561
Merged
zbigniewsobiecki merged 1 commit intodevfrom Feb 26, 2026
Merged
feat(email): add email-joke agent with Gmail OAuth and IMAP support#561zbigniewsobiecki merged 1 commit intodevfrom
zbigniewsobiecki merged 1 commit intodevfrom
Conversation
## Email-Joke Agent - New agent type for responding to emails with humorous replies - Agent definition in YAML with prompts and gadget configuration - Reads unread emails, sends joke replies, marks as read ## Email Integration - Gmail OAuth support with browser-based authentication flow - IMAP/SMTP support for any email provider - Credential management per integration role (imap_host, smtp_port, etc.) - Email wizard UI for setup with multi-step flow - CLI commands: email integration-set, joke-config, oauth, verify ## Database Schema - Migration 0018: Gmail OAuth token storage - Migration 0019: Make repo column optional (for email-only projects) - Updated ProjectConfigRaw and ProjectRow types ## UI Improvements - Email wizard component with Gmail OAuth and IMAP configuration - OAuth callback route for Gmail authentication - Project forms now support optional repo field - EmailJokeConfig component for sender email filtering ## Code Quality Fixes - Added error handling to markEmailAsSeen() in email client - Fixed duplicate comment in email/client.ts - Added parseEmailJokeTriggers() helper with proper type safety - Updated triggerConfig schema to allow null senderEmail - Added guards for email-only projects in setup-webhooks tool - Refactored CLI joke-config to reduce cognitive complexity ## Tests - Added tests for EmailJokeTriggerConfigSchema - Added tests for parseEmailJokeTriggers and resolveEmailJokeTriggerConfig - Added tests for markEmailAsSeen gadget function Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds a new email-joke agent that can respond to emails with humorous replies, along with comprehensive email integration infrastructure including Gmail OAuth and IMAP/SMTP support.
Key Features
Email-Joke Agent: New agent type for responding to emails with jokes
Email Integration Infrastructure
CLI Commands
cascade email integration-set- Configure email integrationcascade email joke-config- Configure sender email filtercascade email oauth- Gmail OAuth authenticationcascade email verify- Verify IMAP connectionDatabase Migrations
Code Quality Improvements
markEmailAsSeen()in email clientparseEmailJokeTriggers()helper with proper type safetyTests Added
EmailJokeTriggerConfigSchemaparseEmailJokeTriggersandresolveEmailJokeTriggerConfigmarkEmailAsSeengadget functionTest plan
npm test- all 3330 tests passnpm run typecheck- no type errorsnpm run lint- no lint errors🤖 Generated with Claude Code