$ ls ./menu

© 2025 ESSA MAMDANI

LIVE
Fable 5.1 vs Gemini 3.8 Flash vs Muse Spark 1.3 vs GPT-6 Astra: AI Models Early September 2026GPT-6 Astra Safety: The Most Powerful Model Needs New GuardrailsGPT-6 Astra Turns AI Agents Into Digital CoworkersGPT-6 Astra and AGI: How Close Are We, Really?GPT-6 Astra: The Frontier Model That Changes the Agent EquationMuse Spark 1.3: Meta’s Frontier Coding AgentFable 5.1 vs Gemini 3.8 Flash vs Muse Spark 1.3 vs GPT-6 Astra: AI Models Early September 2026GPT-6 Astra Safety: The Most Powerful Model Needs New GuardrailsGPT-6 Astra Turns AI Agents Into Digital CoworkersGPT-6 Astra and AGI: How Close Are We, Really?GPT-6 Astra: The Frontier Model That Changes the Agent EquationMuse Spark 1.3: Meta’s Frontier Coding AgentFable 5.1 vs Gemini 3.8 Flash vs Muse Spark 1.3 vs GPT-6 Astra: AI Models Early September 2026GPT-6 Astra Safety: The Most Powerful Model Needs New GuardrailsGPT-6 Astra Turns AI Agents Into Digital CoworkersGPT-6 Astra and AGI: How Close Are We, Really?GPT-6 Astra: The Frontier Model That Changes the Agent EquationMuse Spark 1.3: Meta’s Frontier Coding AgentFable 5.1 vs Gemini 3.8 Flash vs Muse Spark 1.3 vs GPT-6 Astra: AI Models Early September 2026GPT-6 Astra Safety: The Most Powerful Model Needs New GuardrailsGPT-6 Astra Turns AI Agents Into Digital CoworkersGPT-6 Astra and AGI: How Close Are We, Really?GPT-6 Astra: The Frontier Model That Changes the Agent EquationMuse Spark 1.3: Meta’s Frontier Coding Agent
cd ../blog
9 min read
AI Engineering & Developer Tools

Google Developer Knowledge API and MCP: A Grounded Documentation Guide

> A verified developer guide to Google’s Developer Knowledge API and MCP server: setup, retrieval architecture, quotas, authentication, security, debugging, and production patterns.

ShareXLinkedIn

🎧 Listen — ~9 min

Ready · Google Developer Knowledge API a

0:00 / 9:00
Google Developer Knowledge API and MCP: A Grounded Documentation Guide
Verified by Essa Mamdani

Direct answer

Google’s Developer Knowledge API and its remote Model Context Protocol (MCP) server give AI-powered development tools a machine-readable way to search and retrieve Google’s public developer documentation. The service now goes beyond its February 2026 public preview: Google’s release notes mark the API and MCP server generally available on April 16, 2026, while August updates added relevance scores to document chunks and new gcloud commands.

For developers, the practical use is a grounded documentation layer for Firebase, Android, Google Cloud, Maps, Flutter, and other supported Google sources. An agent can search current documentation, retrieve the source page, or ask a grounded question instead of relying only on model training data. It does not grant access to private project resources and it does not replace authorization for tools that change infrastructure.

What Google shipped

The original Google Developers Blog announcement described the Developer Knowledge API as a canonical, machine-readable gateway to official documentation. Its API exposes search-and-retrieve workflows, while the companion remote MCP server makes those capabilities available to compatible AI clients.

The current documentation lists three MCP tools:

ToolUseBest fit
search_documentsFind relevant pages and snippetsDiscovery and citation candidates
get_documentsRetrieve full content for selected parentsGrounding an implementation step
answer_queryReturn a synthesized answer from the corpusDirect documentation questions

Visual 1 — Capability map. The table is an editorial comparison based on Google’s current MCP reference: tool reference.

The API is useful because it separates retrieval from generation. A client can first search for evidence, fetch the relevant document, and then ask a model to explain or transform that source. For high-risk changes, keep the retrieved URL and document metadata in the review record rather than treating the generated answer as the only artifact.

Architecture: retrieval is not authorization

The cleanest design places Google’s knowledge service between the coding agent and authoritative documentation, not between the agent and your production control plane.

diagram

Visual 2 — Grounded documentation flow. This original diagram shows the trust boundary: the Developer Knowledge service supplies documentation context, while your own review, authorization, tests, and deployment controls remain responsible for side effects. It complements the site’s broader MCP Apps integration guide and zero-trust AI agent security guide.

That distinction matters. A retrieved page can explain how to create a Cloud Run service, but the MCP server does not approve your deployment, validate your IAM policy, or decide whether a production change is safe. Treat documentation retrieval as read-only context.

Set up the API for a small integration

Google’s quickstart requires a Google Cloud project, the Developer Knowledge API enabled in that project, and an API key restricted to that API. The official guide says no specific IAM role is required to enable or use the API, but the key should still be restricted and rotated according to your organization’s credential policy.

Enable the service, create a restricted key, and store it outside source control:

bash
1gcloud services enable developerknowledge.googleapis.com --project="$PROJECT_ID"
2export DEVELOPERKNOWLEDGE_API_KEY="..."

The REST API supports a grounded answer request:

bash
1curl -sS -X POST \
2  "https://developerknowledge.googleapis.com/v1:answerQuery?key=${DEVELOPERKNOWLEDGE_API_KEY}" \
3  -H "Content-Type: application/json" \
4  -d '{"query":"How do I create a BigQuery dataset?"}'

For a retrieval-first workflow, search document chunks:

bash
1curl -sS \
2  "https://developerknowledge.googleapis.com/v1/documents:searchDocumentChunks?query=BigQuery&key=${DEVELOPERKNOWLEDGE_API_KEY}"

The search response includes a parent document resource. Use that parent with the document retrieval endpoint to obtain the full Markdown content. Do not copy a parent value from a blog post or hard-code one from a previous result: Google’s current quickstart explicitly treats it as a value returned by search.

Google’s official quickstart is the source of truth for endpoint paths and request examples. Its page was updated July 17, 2026, so re-check the reference before pinning an SDK wrapper around the REST surface.

Connect an MCP-capable coding agent

The remote endpoint is:

text
1https://developerknowledge.googleapis.com/mcp

Google documents OAuth and API-key authentication. OAuth is generally the better fit for an interactive developer assistant because it avoids spreading a long-lived API key across multiple clients. An API key can be appropriate for a controlled service integration when it is restricted to the Developer Knowledge API and protected by the host environment.

A simplified API-key configuration pattern looks like this; exact property names vary by client:

json
1{
2  "mcpServers": {
3    "google-developer-knowledge": {
4      "httpUrl": "https://developerknowledge.googleapis.com/mcp",
5      "headers": {
6        "x-goog-api-key": "${DEVELOPERKNOWLEDGE_API_KEY}"
7      }
8    }
9  }
10}

Use the client’s documented secret-variable mechanism rather than assuming it will expand ${...} in every settings file. Google Antigravity has an installation flow, while other MCP clients require a manually edited configuration. The MCP connection guide includes the current OAuth, API-key, and verification steps.

Freshness, quota, and current API behavior

The February announcement promised re-indexing within 24 hours during preview. The current service has changed materially since then: Google’s release notes say the API and MCP server reached GA in April, and the corpus now includes additional domains such as cloud.google.com, dart.dev, docs.flutter.dev, and mapsplatform.google.com.

As of the August 21 release notes, v1 DocumentChunk messages include a relevance_score between 0.0 and 1.0. That score can help a client rank evidence, but it is not a truth score. A high-relevance document can still be the wrong version or the wrong product. Keep URL, title, update time, and the relevant excerpt together when generating code.

Default quotas documented by Google are:

OperationDefault limit
AnswerQuery50 requests per day per project
GetDocument and BatchGetDocuments combined100 requests per minute per project
SearchDocumentChunks100 requests per minute per project

Visual 3 — Operational limits. This comparison is transcribed from Google’s quota and limits page, last updated August 4, 2026. Cache retrieved documents where policy permits, debounce repeated agent searches, and reserve answer_query for cases where a synthesized response is worth its lower daily allowance.

A production retrieval pattern

A reliable coding assistant should use a two-stage evidence pipeline:

  1. Normalize the developer’s question and remove secrets, credentials, and unrelated repository content.
  2. Call search_documents or SearchDocumentChunks.
  3. Filter results by approved source domain, product, version, and update time.
  4. Retrieve the full document for the selected parent.
  5. Ask the model to answer with the source URL and clearly mark unsupported assumptions.
  6. Run tests, static analysis, and human review before any write or deployment action.

This pattern is especially useful for fast-moving SDKs. If a model proposes a deprecated method, the agent can be instructed to search the official corpus and show the current replacement. If the retrieved documentation does not answer the question, the correct result is uncertainty—not a confident implementation invented from memory.

For teams managing many capabilities, discovery and execution should remain separate. The site’s Agentic Resource Discovery guide covers the same boundary from the catalog perspective: finding a capability must not silently grant it permission to act.

Security checklist

  • Restrict API keys to the Developer Knowledge API and keep them out of repositories, prompts, and logs.
  • Prefer OAuth for interactive clients where the host supports it.
  • Treat documentation text, snippets, and tool descriptions as untrusted model input; they can contain stale guidance or prompt-injection content.
  • Allowlist source domains and inspect redirects before passing retrieved content into an agent with other tools.
  • Keep documentation retrieval read-only. Put IAM, approvals, input validation, and deployment policy in your own systems.
  • Record source URLs, timestamps, document parents, and relevant excerpts for important generated changes.
  • Apply timeouts, response-size limits, and rate limits around the remote MCP connection.
  • Test fallback behavior when the server is unavailable, quota is exhausted, or a host does not support MCP.

Common errors and debugging

The API key is rejected. Confirm that the service is enabled in the same project that owns the key, that the key restriction includes Developer Knowledge API, and that the request uses the documented authentication form. Wait briefly after enabling the API if it does not appear in the restriction picker.

The agent returns a snippet but not the page. Search results are intentionally chunked. Pass the returned parent to get_documents or the corresponding REST retrieval method; do not expect search_documents alone to return every surrounding section.

The answer is plausible but unsupported. Switch from answer_query to search plus full-document retrieval, require citations in the agent’s output, and compare the result with the current source page. A relevance score helps ranking; it does not replace review.

The MCP client cannot connect. Check the endpoint, authentication mode, project header requirements, timeout, and whether the client supports remote MCP over the configured transport. Start with Google’s client-specific setup instructions before changing the server URL.

FAQ

Is the Developer Knowledge API free?

Google’s current public documentation describes quotas and public availability but does not establish a permanent pricing promise in the sources reviewed for this guide. Check the Google Cloud console and current product terms before designing around a production cost assumption.

Does it search all of Google?

No. It searches the supported Google developer documentation corpus. The corpus has expanded over time, and Google publishes the supported domains and release changes in its Developer Knowledge documentation.

Should every coding agent use it?

No. It is most valuable for assistants that routinely work with Google APIs and SDKs. For unrelated stacks, use the owning vendor’s authoritative documentation source. A smaller, relevant context is usually better than connecting every available MCP server.

Can it deploy my application?

Not by itself. The service retrieves documentation and can provide grounded answers. Your own deployment tools, credentials, policy checks, approvals, and CI/CD system control actual changes.

Conclusion

The Developer Knowledge API is a useful pattern for keeping AI coding assistance aligned with live platform documentation. Google’s move from preview to GA, broader corpus, grounded answers, MCP access, and relevance metadata make it more than a documentation mirror. The safe architecture is still conservative: retrieve authoritative context, preserve citations, validate the generated change, and keep all consequential actions behind independent authorization.

For a first experiment, connect the MCP server to a development-only client, ask it to retrieve one Firebase or Google Cloud page, and compare the cited answer with the source. Then add caching, domain filtering, quota handling, and review gates before allowing the assistant to influence a production workflow.

Sources and visual credits

Visual credits: Visual 1 is an original comparison table based on Google’s MCP reference. Visual 2 is an original Mermaid diagram based on Google’s API, MCP, and quickstart documentation. Visual 3 is an original quota comparison based on Google’s quota page. No third-party screenshots or copyrighted product imagery are used.

Keep reading

#Google Developer Knowledge API#MCP#Google Cloud#AI Coding Agents#Developer Tools
ShareXLinkedIn

⚡ Daily AI Model Drop — Get Kimi K3 benchmarks before Twitter

Join 2,400+ AI engineers. 1 email/day, no spam, unsubscribe anytime

Comments