MarketingPlaybook14 min readPublished July 9, 2026

One citation-native API · 3 coverage tiers · weekly agent runs

Build a GEO Visibility Agent With MCP: The 2026 Playbook

This is the build tutorial: an MCP-wired agent that queries answer engines on a weekly cadence, classifies brand citations, scores them against a published visibility formula, and ships a report. The part nobody prints first: only one major answer engine has a citation-native public API, so the architecture is built around three honest confidence tiers.

DA
Digital Applied Team
Senior strategists · Published Jul 9, 2026
PublishedJul 9, 2026
Read time14 min
Sources9 primary sources
Citation-native public APIs
1/3
major answer engines
Perplexity only
Sonar request fee
$5–12
per 1,000 requests, by context size
Weekly prompt panel
100–200
prompts, disclosed methodology
MCP servers tracked
10K+
third-party registries, Apr 2026
+47% in 4 months

A GEO visibility agent is the automation layer under a question your rank tracker cannot answer: when a buyer asks ChatGPT, Perplexity, or Google AI Mode about your category, does the answer cite you? This playbook is the DIY build — an MCP-wired agent that runs a weekly prompt panel through the answer engines, classifies citations, scores them against a published formula, and reports the delta.

The strategy case is already made. We published the AI share-of-voice framework this agent automates — a weekly, disclosed-methodology panel of 100–200 prompts as the minimum viable measurement system — and the AISVS formula the agent should compute. This post assumes you have read both, or will click through. It re-explains neither.

What it adds is the piece none of those posts deliver: working architecture. Which APIs actually exist, which MCP servers to wire, how to schedule a run that does not depend on a laptop staying open, and what a week of API spend actually costs — line-item math included. If you would rather buy this as a managed product, Profound’s own agent, Aim, ships it as one — the build path below is for teams who want to own the pipeline.

Key takeaways
  1. 01
    Only Perplexity has a citation-native public API.The Sonar API returns a citations array plus per-source search_results metadata on every response. ChatGPT can be approximated through the OpenAI Responses API web-search tool; Google AI Mode has no public API at all as of July 9, 2026.
  2. 02
    Design around three coverage tiers, not one checklist.Tier 1: Perplexity, native API, high confidence. Tier 2: ChatGPT via the Responses API web-search proxy, medium confidence. Tier 3: Google AI Mode, Gemini-API proxy or browser automation only — report it as directional.
  3. 03
    MCP is the integration layer, not the product.The agent composes existing MCP servers — Perplexity ships an official one with four tools — over stdio locally or Streamable HTTP remotely. We’ve already covered building a server from scratch; this post only wires them together.
  4. 04
    Schedule for a weekly, laptop-independent cadence.Claude Code’s session-scoped cron tools die with the terminal. For production, pick GitHub Actions’ native schedule trigger (zero infra) or Claude Code Routines (cloud-hosted, 1-hour minimum interval, announced April 14, 2026).
  5. 05
    API spend is small; engineering time is the real cost.At a 150-prompt weekly panel, the sourced line items sum to roughly $3.26 per week plus OpenAI’s per-call web-search tool fee. The build-vs-buy decision hinges on maintenance hours, not the API bill.

01The ProblemThree engines, three structurally different engineering problems.

The macro shift is documented: Search Engine Land’s February 2026 GEO guide cites Gartner’s prediction that traditional search volume drops 25% in 2026, with Google AI Overviews reaching over two billion monthly users and ChatGPT serving 800 million weekly users. If buyers increasingly get answers instead of links, brand visibility inside those answers becomes a metric someone on your team owns — and it moves fast. In active categories we’ve measured 40–60% month-over-month citation drift, which is exactly why the framework post lands on a weekly panel rather than a quarterly audit.

Here is the part most tutorials skip. “Track ChatGPT, Perplexity, and Google AI Mode” reads like a uniform three-item checklist. It is not. It is three structurally different engineering problems with three different confidence levels, and any agent that pretends otherwise will produce numbers you cannot defend. The table below sets the scope for everything that follows.

Answer-engine coverage tiers for a DIY GEO visibility agent: which engines expose a public API, what you actually query, and the confidence label to attach in a weekly report.
EnginePublic API for the answer surface?What you actually queryConfidence label for your report
Tier 1 — native citation API
PerplexityYes — Sonar API, with a native citations array and per-source search_results metadata on every responseThe same answer-plus-sources product surface Perplexity serves, via sonar / sonar-pro modelsHigh — report as measured
Tier 2 — API proxy for the consumer surface
ChatGPTPartial — the Responses API web_search tool returns url_citation annotations plus a sources list, but it is the API’s search tool, not the consumer ChatGPT appOpenAI’s API-level web-search grounding — a citation-rich proxy for how ChatGPT cites, not an instrumented read of itMedium — label explicitly as a proxy
Tier 3 — no public API
Google AI ModeNo — no public, documented API returns the synthesized answer plus citations as of July 9, 2026Gemini API as an imperfect proxy, or browser automation against the real UI (fragile, terms-of-service risk)Low — directional only, disclose the method
Claude.aiNo — Anthropic exposes no consumer-search citation API eitherNothing programmatic that mirrors the consumer surface; exclude, or spot-check manuallyLow — exclude or manual sample

This is a disclosure most vendors avoid making. As we documented in our comparison of the AI visibility tools, incumbent products overwhelmingly rely on UI and browser simulation for the engines that lack an API — one vendor’s method is described outright as UI scraping to simulate real interactions. A DIY agent that states its tiers plainly is more credible than a dashboard that implies uniform API coverage, because the confidence labels travel with every number it reports.

02ArchitectureThe agent loop: four stages, one weekly pass.

The whole system is a scheduled pipeline with four stages. A scheduler fires once a week. A query layer pushes the prompt panel through each engine at its honest tier. A scoring layer classifies every response for brand mentions and citations, then computes the four AISVS sub-metrics. A report stage writes the weekly delta somewhere humans look. No stage is exotic; the discipline is in keeping the tiers labeled and the panel stable so week-over-week numbers stay comparable.

Stage 01
Scheduler
cron → weekly agent run

Fires the run on a fixed weekly slot so persistence math stays clean. GitHub Actions schedule:, Claude Code Routines, or Vercel Cron — the decision matrix is in Section 05.

Weekly, laptop-independent
Stage 02
Query layer
MCP tools + Responses API

Runs the 100–200 prompt panel through Perplexity’s official MCP server (Tier 1), the OpenAI Responses API web_search tool (Tier 2), and a disclosed Google AI Mode proxy (Tier 3). Persists raw responses plus citation arrays.

3 coverage tiers
Stage 03
Classify + score
bulk model → scoring model

A cheap model handles the high-volume yes/no work — brand mentioned, brand cited, position in the source list. A stronger model computes AISVS sub-metrics and writes the narrative summary.

AISVS sub-metrics
Stage 04
Weekly report
score + deltas + examples

One artifact per week: the composite score, the four sub-metrics, biggest gains and losses by prompt, and verbatim answer excerpts for the losses worth investigating.

Slack · email · dashboard

Why MCP for the query layer instead of hand-rolling each HTTP client? When Anthropic open-sourced the Model Context Protocol on November 25, 2024, it framed the protocol as the answer to what it called the M×N problem — M models times N tools means M×N bespoke integrations unless a shared standard sits between them — and shipped Python and TypeScript SDKs plus reference servers for Google Drive, Slack, GitHub, Git, Postgres, and Puppeteer on day one. For this agent the payoff is practical: the Perplexity integration is a maintained server you install, not a client you write, and every future engine that ships an MCP server slots into the same loop without touching the pipeline code.

One deliberate simplification: the model doing classification does not need to be the model orchestrating the loop. Treat stage 03 as plain API calls with structured outputs. Any capable model works — the pricing examples later in this post use Claude Haiku 4.5 for bulk classification and Claude Sonnet 5 for scoring, but that is an illustration, not a mandate. Pick whatever your stack already runs.

03MCP WiringThe citation-native component: Perplexity’s official server.

The flagship component is Perplexity’s official MCP server, published at perplexityai/modelcontextprotocol on GitHub. It exposes four tools: perplexity_search (the raw Search API), perplexity_ask (conversational, backed by sonar-pro), perplexity_research (sonar-deep-research), and perplexity_reason (sonar-reasoning-pro). It runs over stdio for local clients or HTTP (port 8080 by default) for shared cloud deployment, and needs a Perplexity API key. For the weekly sweep, perplexity_ask against the sonar models is the workhorse — every response carries the citations array your scorer consumes.

The protocol mechanics — JSON-RPC 2.0 message flow, tool registration, the stdio versus Streamable HTTP transport choice — are deliberately out of scope here: we’ve already covered building an MCP server from scratch, including the transport decision table. Two deployment facts do matter for this build. First, if you deploy the agent’s MCP servers remotely rather than as local stdio processes, the current 2025-11-25 spec requires OAuth 2.1 with PKCE and RFC 9728 protected-resource metadata — remote MCP is not unauthenticated by design, whatever older posts imply. Second, when tool calls misbehave during development, MCP Inspector is the debugger: its UI runs on port 6274 and its proxy on 6277.

Official server
Perplexity MCP tools
4

perplexity_search, perplexity_ask, perplexity_research, perplexity_reason. Stdio for local clients, HTTP on port 8080 for shared deployment. Requires a Perplexity API key.

github.com/perplexityai
Ecosystem
servers tracked, Apr 2026
10K+

Third-party registries counted roughly 10,000+ MCP servers by April 2026, up from ~6,800 at year-end 2025 — a registry-tracker figure, not an official spec metric, but a fair signal of integration surface.

+47% in 4 months
Debugging
MCP Inspector UI port
6274

@modelcontextprotocol/inspector runs its UI on 6274 and its proxy on 6277. Point it at your query layer to watch tool calls and citation payloads during development.

proxy: 6277
Security note from the spec
The MCP specification’s own security section is blunt: “Tools represent arbitrary code execution and must be treated with appropriate caution… descriptions of tool behavior such as annotations should be considered untrusted, unless obtained from a trusted server.” Pin your agent to official vendor servers, review what each tool can reach, and scope API keys to the minimum — a weekly reporting agent needs read access to search APIs, nothing more.

04The Honest PartThe ChatGPT proxy and the Google AI Mode wall.

Tier 2: ChatGPT, approximated. OpenAI’s Responses API web_search tool is the closest programmatic surface to how ChatGPT cites. Each response carries url_citation annotations — url, title, and start/end indexes marking exactly where in the answer text each citation applies — plus a broader sources field listing every URL the search consulted, which is wider than the inline citations shown. That index-level anchoring is genuinely useful for position scoring. But be precise about what it is: the API’s web-search grounding tool, not an instrumented read of the consumer ChatGPT app your buyers actually use. When a stakeholder asks “does ChatGPT recommend us,” this data answers a nearby question, and your report should say so in those words.

On cost, one binding caveat: OpenAI bills web-search invocations as a separate per-call tool fee on top of standard token pricing. The fee exists; the current rate lives on OpenAI’s pricing page and changes — verify it there before budgeting rather than trusting any hardcoded number, including one in a July 2026 blog post.

Tier 3: Google AI Mode, walled off. As of July 9, 2026, no public, documented API lets a developer route a query through AI Mode and retrieve the synthesized answer with its citations. That is not an oversight you can engineer around cleanly; 2026 industry coverage describes AI Mode as completely walled off from programmatic access. Your two imperfect options: query the Gemini API as a related-but-distinct proxy and label it as such, or run browser automation against the real AI Mode UI — which is fragile, breaks on redesigns, and carries terms-of-service risk you should evaluate deliberately. The commercial tools face the same wall; they just disclose it less prominently. Whichever path you choose, the weekly report marks AI Mode numbers as directional.

If you display citations
OpenAI’s web-search guide carries a compliance requirement worth knowing before you pipe this data into a client-facing dashboard: “When displaying web results or information contained in web results to end users, inline citations must be made clearly visible and clickable in your user interface.” An internal report is fine; a productized dashboard needs clickable source links.

Why does Perplexity sit alone in Tier 1? Because citations are its product, not a bolt-on — and that has been true since the Sonar API launched. The integration case was made early by Zoom, which wired Sonar Pro into its AI Companion for real-time, citation-backed answers.

"Perplexity opens Zoom to knowledge beyond its four walls."— Will Siegelin, Senior Product Manager of AI Products & Responsible AI, Zoom, on integrating the Sonar Pro API (January 2025)

05SchedulingFour schedulers, one weekly requirement.

The scheduling requirement is modest — one reliable trigger per week that does not depend on a laptop staying open — which is exactly why it is easy to over-build. Four realistic options, each with a sharp edge worth knowing before you commit.

Session-scoped
Claude Code scheduled tasks

Native /loop plus CronCreate, CronList, and CronDelete tools (v2.1.72+): standard 5-field cron, 1-minute granularity, capped at 50 tasks per session, recurring tasks auto-expire after 7 days — and everything dies when the session ends. Ideal for iterating on the agent; wrong for production.

Pick for development only
Cloud, repo-centric
Claude Code Routines

Research preview announced April 14, 2026: scheduled Claude Code jobs on Anthropic-managed cloud, triggered by cron (1-hour minimum interval), an API call, or a GitHub event — configured as a saved prompt, one or more repos, and MCP connectors. The natural always-on home for an agent that reasons during its run.

Pick for an always-on agentic run
Serverless cron
Vercel Cron Jobs

Included on all plans, capped at 100 cron jobs per project, billed as ordinary Function usage. The tier split matters: Hobby fires at most once per day inside a ±59-minute precision window; Pro and Enterprise get per-minute scheduling with per-minute precision. Fine for a weekly job if the pipeline already lives on Vercel.

Pick if the stack is on Vercel
Zero-infra
GitHub Actions schedule:

A native cron trigger in workflow YAML — stable, boring, no additional infrastructure, and effectively the cheapest possible option for a weekly run. The pipeline runs as a workflow job; secrets live in the repo’s encrypted store.

Pick for the cheapest weekly run

Our recommendation for a weekly GEO agent: GitHub Actions if the pipeline is a script that calls APIs and writes a report — the schedule trigger is free, versioned next to the code, and nobody has to keep a machine awake. Choose Claude Code Routines when the run itself is agentic — when you want the model reading the raw answers, deciding what changed, and drafting the narrative inside the scheduled job. Anthropic’s launch post describes the packaging plainly: a routine is a saved configuration of “a prompt, one or more repositories, and a set of connectors packaged once and run automatically.” Worth noting for completeness: Anthropic’s separate Managed Agents product added cron scheduling and credential vaults in public beta on June 9–10, 2026 — a more general-purpose hosted-agent home if your automation outgrows the repo-centric shape. The 1-hour minimum interval on Routines is irrelevant at a weekly cadence.

06Panel & ScoringWiring the panel to the published formula.

The prompt panel is not new methodology — it is the same 100–200-prompt, disclosed-methodology panel the framework post establishes, held stable week over week so drift measures the engines rather than your own churn. The agent’s job is mechanical: run every prompt through each tier’s query path, persist the raw answer text and citation arrays with a run timestamp, and never edit the panel mid-quarter without versioning it.

Scoring is where the wiring earns its keep. Each response passes through two model calls. The bulk pass is cheap classification — was the brand mentioned, was a brand domain cited, at what position in the source list, in what sentiment frame — a few hundred yes/no-shaped calls that a small model like Haiku 4.5 handles at $1 per million input tokens and $5 per million output. The scoring pass then aggregates those labels into the four published AISVS sub-metrics — Citation Rate weighted 0.35, Position Score 0.25, Answer Share 0.25, Persistence 0.15 — using the exact formula in the metric spec, which this post deliberately does not re-derive. Compute the composite per engine tier, then report tiers separately before any blended number: a high-confidence Perplexity score averaged with a directional AI Mode estimate is neither.

One pre-flight check before the first run, because it produces the most misleading failure mode this agent has: if your site blocks the AI crawlers in robots.txt, the agent will faithfully report zero citations for reasons that have nothing to do with content quality. Run the 100-point audit before your first agent run — it covers structured data, freshness, and crawler access as a one-time gate, distinct from the weekly loop. And if the weekly report keeps surfacing losses you do not have capacity to act on, that is the point where our agentic SEO service picks up the remediation side of the loop.

Pre-flight: crawler access
Before trusting week one’s numbers, confirm robots.txt allows GPTBot, ClaudeBot, and PerplexityBot. Blocked crawlers mean the engines cannot read your site at all — the agent will report zero citations, and no amount of content work changes that until the block is lifted.

07Cost & Build-vs-BuyThe weekly bill, line by line.

No public source publishes an all-in cost model for a DIY GEO tracking agent — vendor tools quote flat subscriptions precisely to avoid this line-item view. So here is ours, at a 150-prompt weekly panel, with the arithmetic shown so you can rerun it against your own panel size and the live pricing pages. Perplexity prices Sonar as a hybrid: tokens ($1 per million in and out on Sonar; $3 in / $15 out on Sonar Pro) plus a per-1,000-request fee that steps with search-context size ($5/$8/$12 on Sonar, $6/$10/$14 on Sonar Pro). The estimates below assume medium context, roughly 1,200 combined tokens per Sonar call, and a Sonar Pro deep-dive on a 30-prompt subset. All prices as retrieved July 9, 2026.

Estimated weekly API cost for a DIY GEO visibility agent at a 150-prompt panel, with per-line-item formulas: Perplexity Sonar and Sonar Pro, OpenAI Responses API web search, Claude Haiku 4.5 classification, Claude Sonnet 5 scoring, and scheduler cost.
Line itemCalls / week (150-prompt panel)Unit price (Jul 9, 2026)Weekly subtotal (math shown)
Query layer
Perplexity Sonar — broad sweep150 requests$8 per 1,000 requests (medium context) + $1/M tokens in and out150 × $0.008 = $1.20 + ~180K tokens × $1/M ≈ $0.18 → ≈ $1.38
Perplexity Sonar Pro — deep-dive subset30 requests$10 per 1,000 requests (medium) + $3/M in, $15/M out30 × $0.01 = $0.30 + (15K in × $3/M ≈ $0.05) + (30K out × $15/M = $0.45) → ≈ $0.80
OpenAI Responses API — web_search (ChatGPT proxy)150 callsPer-call tool fee (verify the live pricing page) + standard token pricing150 × current tool-call rate + tokens — fee-dependent
Scoring layer (example models)
Claude Haiku 4.5 — bulk classification~330 calls (all tiers’ answers)$1/M input · $5/M output tokens~495K in × $1/M ≈ $0.50 + ~66K out × $5/M ≈ $0.33 → ≈ $0.83
Claude Sonnet 5 — AISVS scoring + report1 aggregation run$2/M input · $10/M output (intro pricing through Aug 31, 2026; $3/$15 after)~100K in × $2/M = $0.20 + ~5K out × $10/M = $0.05 → ≈ $0.25
Infrastructure
Scheduler — GitHub Actions schedule:1 trigger$0 marginal$0
Total (sourced line items)$1.38 + $0.80 + $0.83 + $0.25 + $0 = ≈ $3.26/week + the OpenAI tool-call fee

Read the total honestly: at these assumptions the sourced API spend lands in the low single digits per week, and even doubling the panel and token estimates keeps it in the low tens of dollars once the OpenAI tool fee is added. The real cost is engineering time — building the pipeline, then maintaining it as vendor APIs, prices, and the Tier 3 workaround drift underneath you. That maintenance line is the honest build-vs-buy pivot: a subscription tool amortizes exactly that burden across its customer base.

Our projection for where this goes: the tier structure, not the prices, is the durable part of this post. Perplexity has committed to citation-native APIs as product strategy; OpenAI’s API surface keeps converging toward what the consumer app does; Google has every incentive to keep AI Mode walled while it monetizes the surface directly. Expect Tier 2 to firm up and Tier 3 to stay closed longer than anyone hopes — which means an agent designed around explicit confidence tiers degrades gracefully, while one that assumed uniform coverage breaks silently. When the weekly maintenance exceeds a couple of hours, buy: the tools roundup covers the managed options, and Profound’s Aim is the closest packaged equivalent of the loop described here.

08ConclusionShip the honest version.

The build, compressed

One native API, one proxy, one wall — design the agent around that truth.

The build itself is a week of focused work: Perplexity’s official MCP server as the citation-native core, the OpenAI Responses API web-search tool as a clearly-labeled ChatGPT proxy, a disclosed and hedged path for Google AI Mode, a two-model scoring pass that computes the published AISVS formula, and a GitHub Actions or Claude Code Routines trigger so the whole loop runs weekly without a human or a laptop in the loop.

What makes the output defensible is not the pipeline — it is the confidence tiers traveling with every number. A measured Perplexity citation rate, a proxied ChatGPT estimate, and a directional AI Mode signal are three different classes of evidence, and a report that labels them as such will survive scrutiny that a blended dashboard number will not.

Start with the pre-flight audit, run the panel for four weeks before drawing conclusions, and re-check every price in Section 07 against the live pages when you budget. The engines will keep moving; the agent’s job is to notice — on schedule, with its uncertainty printed on the label.

Own your AI search visibility

Weekly answer-engine visibility, measured honestly.

Our team designs and operates AI search visibility programs — prompt panels, citation scoring, weekly reporting agents, and the content remediation loop that turns the numbers into gains.

Free consultationExpert guidanceTailored solutions
What we work on

AI visibility engagements

  • Prompt-panel design with disclosed methodology
  • Citation-scoring agents wired over MCP
  • AISVS reporting — weekly, tiered by confidence
  • Answer-engine content remediation sprints
  • Build-vs-buy evaluation against managed tools
FAQ · GEO visibility agent

The questions we get every week.

It automates a weekly measurement loop for AI answer engines. On a fixed schedule it runs a stable panel of 100–200 buyer-intent prompts through each engine’s best available query path, persists the raw answers and citation data, classifies each response for brand mentions and citations, computes a composite visibility score against a published formula, and delivers a weekly report with deltas and examples. It replaces the manual spreadsheet version of AI share-of-voice tracking — same methodology, same panel size, no human running queries by hand. It does not create or optimize content; it measures whether the engines cite you, so the content work can be prioritized by evidence.
Related dispatches

Continue exploring AI search visibility.