email

Your Gmail - recent and unread mail, search, read one mail, a short inbox summary, drafts and replies; sending always asks first.

Tools

ToolTagsAsks first
inboxreadsno
searchreadsno
readreadsno
summarize_inboxreadsno
draftwritesno
reply_draftwritesno
sendsends, always_askyes
delete_draftdeletesyes

Asks first comes from autonomy in plugin.yaml. The core can raise it (see Approvals).

Limits

Your Gmail through Gmail's API (gmail.googleapis.com only).

Sign in under Settings, Integrations (provider gmail: Google Cloud Client ID + Secret, Gmail API enabled, scopes gmail.readonly, gmail.compose, gmail.send; Plugins Email). Everything read is outside content.

send is tagged always_ask: a high-risk card with the exact To/Cc/Subject/text, never auto, never by voice.

The email plugin runs in the core (src/email.rs) and talks only to gmail.googleapis.com (AGENT_GMAIL_API for tests). Sign-in is the gmail OAuth provider: Google, offline access, Client ID and Client Secret, its own GMAIL_* secrets (separate from Google Health's GOOGLE_*, so each signs in and out alone). Scopes: gmail.readonly, gmail.compose (drafts), gmail.send.

Tools: inbox, search (Gmail query words), read (one mail; text/plain part, else HTML made plain; attachments by name only), summarize_inbox (the core gathers sender, subject, date and snippet; the model writes the summary), draft and reply_draft (auto; undo deletes the draft), send (sends + always_ask).

Safety, in code:

Setup (one time):

  1. In the Google Cloud console, open the project (the Google Health one works), go to APIs and Services, Library, and enable the Gmail API.
  2. OAuth consent screen, Data access: add the scopes .../auth/gmail.readonly, .../auth/gmail.compose, .../auth/gmail.send. While the app is in testing, add your own Google account as a test user.
  3. Credentials: use an OAuth client (or make one) and add the redirect address shown in Settings, Integrations, Email.
  4. In the app: Settings, Integrations, Email: paste the Client ID and Client Secret, Connect Gmail, allow every box. If Google Health was set up before the Gmail scopes existed, this sign-in is separate; connecting again later asks for consent again (prompt=consent) so Google sends a fresh refresh token.