mk-organization-1/ai-agent-openclaw/add-gmail

Claude Code and agent skill by mk-organization-1/ai-agent-openclaw

Trust tier 2
  • community
LLM review pending
Source check pending

Checking that the SKILL.md file is still in the repository.

Adds Gmail monitoring to OpenClaw using the googleapis library. Creates OAuth2 credentials, polls INBOX for unread messages matching a trigger pattern, drafts AI replies, and sends after approval. Use when you want OpenClaw to monitor and respond to emails. Requires a Google Cloud project with Gmail API enabled and OAuth2 credentials.

Install

npx vskill@latest install mk-organization-1/ai-agent-openclaw/add-gmail

SKILL.md

The same SKILL.md was published earlier as mk-organization-1/ai-agent-openclaw/add-gmail.

add-gmail

OpenClaw reads your inbox, understands emails, drafts responses, and sends after you approve.

Usage

/add-gmail

Files Created

src/channels/gmail.ts # GmailChannel using googleapis OAuth2
src/auth/gmail-oauth.ts # OAuth2 token flow and refresh logic

Files Modified

src/channels/index.ts # Register GmailChannel
src/config.ts # Add Gmail config fields
package.json # Add googleapis

Environment Variables

GMAIL_CLIENT_ID=your_oauth_client_id
GMAIL_CLIENT_SECRET=your_oauth_client_secret
GMAIL_REFRESH_TOKEN=your_refresh_token
GMAIL_ADDRESS=yourname@gmail.com
GMAIL_POLL_INTERVAL_MS=60000 # Default: 1 minute
GMAIL_TRIGGER_LABEL=openclaw # Only process emails with this label

Setup: Getting OAuth2 Credentials

  1. Go to Google Cloud Console
  2. Create project → Enable Gmail API
  3. OAuth2 credentials → Desktop App → Download JSON
  4. Run the auth helper: npx openclaw auth gmail
  5. Complete browser flow → refresh token saved automatically

Step-by-Step Walkthrough

  1. Run /add-gmail
  2. OpenClaw scaffolds the channel and auth helper
  3. Run npx openclaw auth gmail to get your refresh token
  4. Set env vars in .env
  5. Start OpenClaw — polls Gmail every minute
  6. Label emails openclaw in Gmail to trigger processing

Code Sample

typescript
// src/channels/gmail.ts (generated)
import { google } from 'googleapis';
import { Channel, Message } from '../types';
export class GmailChannel implements Channel {
private gmail;
constructor(auth: OAuth2Client) {
this.gmail = google.gmail({ version: 'v1', auth });
}
async *poll(): AsyncGenerator<Message> {
const res = await this.gmail.users.messages.list({
userId: 'me',
q: 'label:openclaw is:unread',
});
for (const m of res.data.messages ?? []) {
const full = await this.gmail.users.messages.get({ userId: 'me', id: m.id! });
yield parseGmailMessage(full.data);
}
}
}

Philosophy

The approval step before sending is intentional — email carries more weight than chat. OpenClaw drafts; you decide when to send.

Security

  • Security scanPassed, 100 of 100Pattern checks on the skill's files.
  • Model reviewNot runA model review is scheduled for the next rescan.

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
5

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Grok Build (Cursor)
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/mk-organization-1/ai-agent-openclaw/add-gmail/badge)](https://verified-skill.com/skills/mk-organization-1/ai-agent-openclaw/add-gmail)

Something wrong with this skill or its page? Tell us.