Campaign Ops MCP
Governs changes to Google Ads campaigns on the user's behalf: it reads account spend, search terms and ad copy, and proposes, dry-runs (validate_only), human-approves, applies, verifies and rolls back changes to budgets, negative keywords and ad copy, with policy limits, Fair Housing screening, drift detection and a tamper-evident audit log.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Campaign Ops MCP
Lets AI agents change Google Ads campaigns safely. Every change is proposed, checked, dry-run, approved by a person, applied, verified and reversible, with Fair Housing guardrails and a tamper-evident audit log.

Why this exists
Google's official Google Ads MCP server is read-only. Its tools search an account, describe resources and list accounts. Reading is the easy part.
Once an agent can change budgets, negative keywords or ad copy, it needs the same controls a careful media buyer uses: limits, a second pair of eyes, a record of every decision, and an undo. Campaign Ops is that control layer, built as an MCP server that any MCP client can use.
Related MCP server: AdRails
How a change flows
flowchart LR
A[AI agent] -->|propose_change| B{Policy checks<br/>and dry run}
B -->|fails| X[Blocked, with reasons]
B -->|passes| C[Waiting for approval]
C -->|a person approves:<br/>chat prompt or console| D[Approved]
C -->|a person rejects| R[Rejected]
D -->|apply_change| E{Re-check: kill switch,<br/>limits, cooldown,<br/>live value unchanged}
E -->|no| F[Refused or conflict]
E -->|yes| G[Apply]
G --> H{Read back<br/>and verify}
H --> I[Applied and verified]
I -->|request_rollback| BGuardrails
Guardrail | What it does |
No self-approval | There is no approve tool. Only a person can approve, through an approval prompt in the chat app (MCP elicitation) or the local approval console. |
Scopes |
|
Budget limits | Step limits per change (+30% / -50% by default), a per-campaign range, and an account-wide daily cap. |
Fair Housing screening | Ad copy that states a preference or limitation (for example "adults only" or "perfect for couples") is blocked. Coded or age-signaling language is flagged for review. |
Protected searches stay visible | Negative keywords that would exclude protected groups are always blocked. A naive optimizer would cut "wheelchair accessible apartments" for having zero conversions. Campaign Ops refuses, and says why. |
Collateral-damage check | Negatives that would also block converting searches are flagged, or blocked above a threshold. |
Brand protection | Negatives that would block searches for your own community name are blocked. |
Dry run | Every proposal is validated by the platform without being applied (the Google Ads API calls this |
Drift detection | If someone changed the live value after the proposal, nothing is overwritten. The result is a conflict, and the agent re-proposes from fresh data. |
Approval binding | An approval is tied to a hash of the exact change. Editing the stored proposal afterwards is detected and refused. |
Expiry | Proposals expire after 24 hours and approvals after 60 minutes. |
Rate limits and cooldowns | Caps changes per hour and per day, and spaces out repeat changes to the same target. One open proposal per target. |
Kill switch | One click in the console pauses every change. An environment variable can force it on, overriding everything. |
Verification | After writing, the account is read back and compared with the expected state. |
Rollback is a proposal | An undo goes through the same checks and approval. Undoing a Fair Housing fix is blocked, because it would restore the violation. |
Tamper-evident audit log | Every event is written to a hash-chained log. Editing or deleting any line breaks the chain, and the tool reports exactly where. |
Quick start
Requires Node.js 22 or newer (any current LTS) and Git.
git clone https://github.com/debashishkumarbora/campaign-ops-mcp.git
cd campaign-ops-mcp
npm install
npm test # 28 tests: guardrails, lifecycle, console security, MCP over stdio
npm run demo # a narrated run through every guardrailEverything runs against a sandbox account with synthetic data. No Google account is needed yet.
Call the tools yourself
npm run build
npm run inspectThis opens MCP Inspector in your browser. Click Connect, open Tools, and run run_diagnostics with account_id set to 123-456-7890.
The approval console
npm run consoleThis opens the console in your browser with your key. Proposals appear within a few seconds of the agent making them. You can approve, reject with a note, undo applied changes in one click, pause all changes, and watch the audit chain.
The console listens on 127.0.0.1 only, requires a key the AI never sees, checks the Host header (DNS rebinding), refuses cross-site requests, escapes everything the AI writes, and runs under a strict Content Security Policy.
Connect an AI client
Campaign Ops runs as a local (stdio) MCP server. Point your MCP client at the built entry file:
{
"mcpServers": {
"campaign-ops": {
"command": "node",
"args": ["/full/path/to/campaign-ops-mcp/dist/src/index.js"]
}
}
}On Windows, use a path like E:\\campaign-ops-mcp\\dist\\src\\index.js. Then ask: "Run a health check on my ad account and propose fixes." The server also ships two prompts, account_health_check and fix_wasted_spend.
Tools
Tool | What it does | Scope |
| Accounts this server can reach, and their mode | read |
| Spend, leads, cost per lead, budget use, impression share lost to budget | read |
| What people searched before clicking, with cost and conversions | read |
| Ad copy with a Fair Housing screening result per ad | read |
| Ranked findings with ready-to-propose changes, plus searches that must not be excluded | read |
| Screens draft copy before proposing: Fair Housing, character limits, punctuation | read |
| The guardrails in force and the kill switch state | read |
| Proposal status, every check, and the next step | read |
| Recent audit entries and chain integrity | read |
| The only way to request a change. Runs every check and the dry run | propose |
| Creates an undo proposal for an applied change | propose |
| Applies an approved change, re-checking everything first, then verifies | execute |
Configuration
Copy .env.example to .env to change settings, and edit policy.json to change limits. Fair Housing checks are always on and cannot be switched off in configuration.
Variable | Default | Meaning |
|
|
|
|
| Console port on 127.0.0.1. |
| generated | Fixed console key (16+ characters) |
|
|
|
|
| Where state lives |
|
| Alternative policy file |
npm run reset rebuilds the sandbox and clears proposals and the audit log.
Threat model
Defends against
An agent approving its own changes: no approve tool exists, and both approval channels are human-only.
Prompt-injected text in a proposal attacking the reviewer: all AI-written text is escaped, a strict CSP blocks scripts, and
frame-ancestors 'none'blocks clickjacking.Other web pages in your browser calling the console: key required, Host header checked, JSON-only same-origin POSTs.
Stale or silently edited approvals: binding hash, expiry and drift checks.
Runaway loops: rate limits, cooldowns, one open proposal per target, and the kill switch.
Quiet history edits: the hash-chained audit log.
Out of scope
A compromised computer, or an MCP client that fakes the approval prompt.
An agent that also has file access to the data folder. Do not give the same agent a filesystem tool for this folder.
Legal review. The Fair Housing checks are a screening aid, not legal advice.
A note on Fair Housing
Section 804(c) of the Fair Housing Act prohibits housing ads that state a preference, limitation or discrimination based on race, color, religion, sex, disability, familial status or national origin. Many states and cities protect more, such as source of income. The screening rules flag common risk patterns so a person looks before anything ships. They cannot prove that copy is compliant.
Roadmap
Milestone 1: governance engine, sandbox account, approval console, 28 tests
Milestone 2: approval card inside the chat with MCP Apps
Milestone 3: Google Ads test-account backend (real API calls, no ads served, no spend)
Milestone 4: public sandbox as a remote MCP server on Cloudflare Workers
Milestone 5: daily autopilot that runs diagnostics and queues proposals for approval
Milestone 6: evaluation suite that scores agent runs for safe behavior
Project structure
src/
index.ts MCP server entry (stdio)
server.ts Tools, prompts, approval prompt, wait-for-approval
governance/
engine.ts Proposal lifecycle: propose, approve, apply, verify, rollback
changes.ts Per-change logic: state, checks, risk, diff, inverse
fairHousing.ts Ad copy screening and protected-term detection
diagnostics.ts Findings and suggested changes
audit.ts Hash-chained audit log
backends/
backend.ts The ad platform interface
sandbox.ts, seed.ts Synthetic account with planted problems
console/server.ts Approval console HTTP server
console-ui/ Console page (plain HTML, CSS, JS)
scripts/ demo, console, reset, test runner
test/ node:test suitesLicense
MIT. Built by Debashish Kumar Bora.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Manage Google, Microsoft, ChatGPT and Meta Ads safely: previewed, confirmed, logged changes.
Human-in-the-loop review and approval for AI agents. Audit trail, approval policies, native MCP.
- AdCopilotDeprecatedcloud.adcopilot
Google Ads, GA4, Search Console and Tag Manager for AI assistants. Every change is proposed first.
Your Google, Meta, Microsoft, TikTok and LinkedIn ads in your AI. Changes wait for your OK.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceLets AI agents query Google Ads freely while routing every write through a passkey-approved, rule-checked, audited change workflow. It issues per-agent keys, validates proposals against configurable guardrails, and applies approved changes atomically.Apache 2.0
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to read and safely modify Google Ads campaigns, budgets, statuses, end dates, and negative keywords by diffing a reviewed desired-state file against live account state under policy-defined caps and single-use plan IDs. A scheduled guard can pause campaigns on spend thresholds while credentials and keys remain local.797 PyPIApache 2.0
- AlicenseNot gradedqualityCmaintenanceEnables Claude and other models to read a Google Ads account and safely create, edit, pause, and budget campaigns, ad groups, ads, keywords, and bids. Every write is previewed through Google's validateOnly, approved by a person, and protected by server-side spending limits and an audit log.MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to propose changes, obtain human or policy approval, and safely apply them with drift checks, idempotency, verified completion, compensation, and a tamper-evident ledger.37 npmMIT