SEO APIs: what you can automate
·4 min read
An SEO API is an HTTP endpoint that returns search data or runs a site check, so a script or an AI agent can do the work instead of a person clicking through a dashboard. There are three kinds. Google's own APIs report how Google sees your site. Page audit APIs fetch a URL and tell you what is wrong with it. Data APIs sell keyword and backlink estimates. Pick by the question you need answered, because no single API covers all three.
Types of SEO API at a glance
| Kind | Examples | Answers | Data source |
|---|---|---|---|
| Google's own | Search Console API, PageSpeed Insights API, Indexing API | How Google reports your clicks, index status and speed | Google, for sites you verify |
| Page audit | Status, robots, canonical, schema and AI crawler checks | What a page returns right now and what to change | A live fetch of the URL |
| Keyword and backlink data | Volume, difficulty, cost per click, linking domains | What people search and who links where | Third-party estimates |
Most automation mixes them. A weekly job might pull Search Console clicks, audit the pages that dropped, and check keyword volume before writing anything new.
Google's own SEO APIs and what each one does
Google's APIs are the only source of what Google itself records about your site, and they are the first thing to automate.
Search Console API. It covers the reports you already use in the UI. Search Analytics returns clicks, impressions, CTR and position by query, page, country and device. The URL Inspection API returns Google's index status for one URL, capped at 2,000 queries per day and 600 per minute for each site, per Google's usage limits. That cap matters on a large site. Inspect the pages that changed, not the whole sitemap every night.
PageSpeed Insights API. One GET to https://www.googleapis.com/pagespeedonline/v5/runPagespeed?url=... returns a Lighthouse lab run. Google's getting started page says it works without a key, but a key is recommended for automated queries. The same page says Google plans to stop including Chrome UX Report field data in this API and points to the CrUX API instead. If your monitoring reads real-user Core Web Vitals from PSI, move that part now.
Indexing API. This is the one people misuse. Google's quickstart says it can only be used for pages with JobPosting or BroadcastEvent embedded in a VideoObject. Pinging it for blog posts or product pages does nothing useful. For ordinary pages, keep a clean sitemap and use internal links. If Bing matters to you, IndexNow is the push protocol that applies to any URL.
Page audit APIs vs keyword and backlink data APIs
A page audit API fetches your URL live and reports facts about the response. A data API returns estimates from someone else's crawl and clickstream. Treat the two differently.
Audit results are checkable. If an API says your page sends X-Robots-Tag: noindex, you can confirm it with curl, fix the header and run the check again. That makes audits a good fit for automation and for coding agents, since the loop has a clear end. Run, fix, deploy and run again until it comes back clean.
Keyword volume, difficulty and backlink counts are modeled numbers. They are useful for ranking a list of ideas against each other, but two providers will disagree, and none of them sees Google's own query data. Use them to decide what to write about. Use Search Console to see what actually happened.
What to automate and what to leave alone
Automate checks that run on every deploy or on a schedule and fail loudly:
- After each deploy, audit key templates for status codes, noindex, canonicals and robots.txt rules. A staging
Disallow: /that reaches production is the classic outage. - Weekly, pull Search Console clicks by page and flag pages that fell sharply.
- Monthly, run PSI or CrUX for your main templates instead of every URL.
Leave judgment calls to a person. Keyword choice, content rewrites and anything that edits copy on a live site should go through review, even when an agent drafts it. If you work inside Claude Code or Cursor, an MCP server is often easier than wiring REST calls yourself. SEO MCP servers covers that setup.
Run SEO checks through the seogeoaeo.ai API
Our REST API at https://seogeoaeo.ai/api/v1 runs every public tool with a workspace API key sent as Authorization: Bearer <key>. GET /api/v1/tools lists each tool with its credit price and JSON Schema input and needs no key. Running a tool is a POST to /api/v1/tools/<slug>/runs with an input object:
curl -X POST https://seogeoaeo.ai/api/v1/tools/indexing-checker/runs \
-H "Authorization: Bearer $SEOGEOAEO_API_KEY" \
-H "Content-Type: application/json" \
-d '{"input":{"url":"https://example.com"},"maxCredits":10,"idempotencyKey":"deploy-4812-home"}'The Indexing & Canonical Checker costs 8 credits per run. It checks status, robots.txt, meta robots, X-Robots-Tag, the canonical and its target, and snippet controls for Google and Bing. It does not confirm that Google has indexed the URL, since it cannot see Search Console, and it does not render JavaScript. The response is { "run": ... } with status, creditsCharged, result and improvementTips, which lists each change to make, ordered by priority, and how to verify it.
Two fields keep automation safe. maxCredits refuses the run with a 402 if the tool costs more than the number you pass. idempotencyKey, also accepted as an Idempotency-Key header, returns the original run on a retry instead of charging again, as long as the tool and input match and the run is still among the workspace's latest 1,000. Each key can make 120 requests a minute, and every error comes back as { "error": { "code", "message" } }.