Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add instructions/bakissation/mcp-google-multi/claude-mdgit clone --depth 1 https://github.com/bakissation/mcp-google-multiWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/bakissation/mcp-google-multi/claude-md)<a href="https://agentmods.dev/instructions/bakissation/mcp-google-multi/claude-md"><img src="https://agentmods.dev/badge/instructions/bakissation/mcp-google-multi/claude-md.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.02948 | $0.02948 |
| Opus 5 | $0.01474 | $0.01474 |
| Sonnet 5 | $0.00590 | $0.00590 |
| Haiku 4.5 | $0.00295 | $0.00295 |
Grade A, and why
mcp-google-multi CLAUDE.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 112 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Working on mcp-google-multi
Conventions for AI assistants modifying this codebase. v5 is local, stdio, user-OAuth only. User-facing rationale for the big mechanisms (discover-first, fan-out, trimming, write-control, escape hatch) lives in docs/features.md; implementation rationale too long for a code comment (Windows rename retry, GET/HEAD body stripping, admin-scope gating) lives in docs/internals.md. Keep both in sync when behavior changes — comments stay one-line and point there.
Project shape
src/index.ts— entry.buildRegistry()registers every enabled service (the curatedSERVICEStable plusGENERATED_SERVICES, gates insrc/services.ts, all filtered byGOOGLE_TOOLSETS), fails fast ifregistry.services()is empty (BEFORE meta tools register — escape tools would mask an empty service set), thenregisterDiscoverTools()+registerEscapeTools()+registerAccountTools();main()installs the registry's customtools/listhandler and runs the stdio MCP server, or theauth/migrate-tokens/config checkCLI commands.src/registry.ts—ToolRegistrywraps the MCP server: records{name, service, cud, description, inputShape, meta}per tool, derivescud(read/create/update/delete) from the tool name viainferCud, enforces write-control by wrapping every CUD handler, injects computed annotations (readOnlyHint/destructiveHint), and owns discover-first visibility: all tools register eagerly (always callable — graceful dispatch), but the customtools/listhandler only advertises meta tools +reveal()ed services.installListHandler()must run after registration, before connect. Service files still callserver.registerTool(...)—serveris now aToolRegistry.src/discover.ts—registerDiscoverTools(): one eager{service}_discovermeta-tool per service; returns the catalog (registry.catalog), reveals the service, triggerstools/list_changed. Never emittool_referencecontent blocks or top-leveldefer_loadingfields — strict SDK clients reject/strip them (verified against SDK 1.29).src/toolsets.ts—GOOGLE_TOOLSETSparsing (all| CSV of service names).src/discovery-client.ts— runtime Google API Discovery:loadMethodIndex(api)fetcheshttps://www.googleapis.com/discovery/v1/apis/{id}/{version}/reston demand, disk-caches 7 days (DISCOVERY_CACHE_PATH), stale-if-offline;cudFromMethod(HTTP verb → cud, POST read-verbs like batchGet → read),expandPath({param} + {+param} templates),searchMethods. Deps injectable for tests — never hit the network in unit tests.src/tools/google-api.ts—registerEscapeTools(): eagergoogle_api_search+google_api_call. The call tool enforces write-control ITSELF (its registry cud is read, so the wrapper doesn't gate it) viaisAllowedon the method's derived cud — keep that check when touching this file.src/fanout.ts— cross-account fan-out:parseAccountSelector("*"| CSV | single),runFanout(bounded 5, per-account isolation, merged{results, partial}envelope with parsed payloads — never embed raw JSON strings),fanoutAccountField(union schema: enum+*| CSV regex). Wired inregistry.ts: read tools only, never meta (google_api_callinfers cud=read but executes writes), neverFANOUT_EXCLUDE(read tools that write local files). Fan-out wraps the raw handler INNERMOST so compaction runs once on the merged envelope.src/tools/accounts-tool.ts— eageraccount_listmeta tool +deriveAccountHealth(pure, deps-injectable). Reads the token store directly — NEVERgetClient(would attach refresh listeners).readTokenthrows on decrypt failure (only returns null when missing) — keep the per-account try/catch. Never output token values.src/trim.ts— response trimming:compactResult(registry re-serializes every JSON text output compactly;GOOGLE_TRIM=offopts out — compaction only, never the caps),capText(paging caps with truncated/totalChars),sliceClean(permanent caps — drops a trailing lone surrogate). Fat readers own their caps:drive_readmaxChars/offset, gmail reads 50k body cap +fullparam,calendar_list_eventsANDcalendar_list_instanceslist-modeformatEvent(e, {full:false}). New fat-payload tools should reuse these helpers.src/write-control.ts—resolvePolicy()(env → policy) +isAllowed()(deny-by-default verdict) +config checkrendering.src/token-store.ts— encrypted token store (AES-256-GCM, key fromMASTER_KEY);readToken/writeToken/updateToken. Themigrate-tokensCLI lives insrc/migrate-tokens.ts.src/auth.ts— OAuth flow + scope tiers (BASE_SCOPESalways,OPTIONAL_SCOPE_BUNDLESenv-gated,ADMIN_SCOPESper-account).src/client.ts—getClient(account): fresh OAuth2Client per call from the encrypted token; itstokenslistener re-encrypts on refresh (updateToken).src/accounts.ts— parsesGOOGLE_ACCOUNTS; token dir defaults to~/.config/mcp-google-multi/tokens(overrideTOKEN_STORE_PATH).src/tools/_errors.ts—mapGoogleErrortyped taxonomy +handleGoogleApiErrorresult wrapper; each service file defines its ownhandle<Service>Errorshim over it (optionally with a service-specific 403 hint).src/tools/_coerce.ts—coerceArray/coerceJson/coerceBooleanfor string-encoded client args.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 6d ago First seen · 112 lines · 2,948 tokens per session scan A b36d366afcc9
mcp-google-multi CLAUDE.md is an instructions file published in the GitHub repository bakissation/mcp-google-multi (10 stars, last pushed yesterday), licensed MIT. It adds 2,948 tokens to every session, about $0.0147 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other instructions, from other repositories
google_workspace_mcp general.instructions.md
Instructions for taylorwilsdon/google_workspace_mcp, covering 📄 project context, 🎯 review goals & priorities, 🚦 low‑value feedback to skip, 🧭 review structure template and ✅ gmail.sendmessage – input schema issue.
google-mcp CLAUDE.md
Claude Code instructions for quinnjr/google-mcp, covering claude.md, commands, architecture, entry & server and auth.
gws-mcp-server CLAUDE.md
Claude Code instructions for conorbronsdon/gws-mcp-server, covering gws-mcp-server, architecture, key constraints, development and testing.
artist-mcp CLAUDE.md
Claude Code instructions for ManudotaORG/artist-mcp, covering artist-mcp, verify on release; promote only to ship, layout and things that bite.
elnora-google-workspace AGENTS.md
AGENTS.md instructions for Elnora-AI/elnora-google-workspace, covering agents.md — using the gw google workspace cli, first run (setup), invoking the cli, auth (do not reinvent) and safety rules (must follow).
artist-mcp AGENTS.md
AGENTS.md instructions for ManudotaORG/artist-mcp: Read the closest AGENTS.md to the code you are changing. This file is the repository root and deliberately holds almost nothing: the two apps have little in common beyond the language.