Google opens Developer Knowledge API to CLI, agents and client libraries

Google has detailed an ecosystem around its Developer Knowledge API, an official programmatic source for Google developer documentation aimed at AI agents and developer tools. It includes a gcloud CLI surface, an agent skill, an APIs Explorer and client libraries in seven language ecosystems.
- Google's Developer Knowledge API serves official, Markdown-formatted documentation for Google Cloud, Firebase, Android and more.
- It offers semantic and keyword search, document chunking and grounded Q&A for AI agents and developer tools.
- The ecosystem includes a gcloud CLI surface, an agent skill, APIs Explorer and client libraries.
- Client libraries cover C#, Go, Java, Node.js and TypeScript, PHP, Python and Ruby.
- BatchGetDocuments can retrieve up to 20 documents in one API call.
An official documentation source for agents
According to Google, the Developer Knowledge API is its official, programmatic source of truth for developer documentation about Google Cloud, Firebase, Android and more. It is designed for modern AI agents, IDE extensions and automated workflows, and replaces brittle web-scraping with a structured API that serves fresh, Markdown-formatted documentation.
The API offers semantic and keyword search, intelligent document chunking and grounded Q&A. Google says this keeps agents and developer tools accurate and token-efficient. The company also states the API is indexed frequently, to give predictable retrieval and minimal lag between upstream updates and agent access.
gcloud CLI and the agent skill
The gcloud CLI surface brings documentation search, retrieval and grounded Q&A into the command line. Google says it comes pre-installed in Cloud Shell and works across standard Google Cloud SDK installations on Linux, macOS and Windows, with no extra plugins or configuration. The key commands are:
- answer-query: returns grounded answers in the terminal.
- documents search-chunks: searches document snippets and chunks across Google documentation.
- documents describe: retrieves metadata and content for a specific document.
Google also shows a way to troubleshoot by piping an error trace from a file straight into the answer-query command.
The Developer Knowledge agent skill links AI coding assistants to Google's documentation. Google says it reduces hallucinations caused by stale LLM training cutoffs. It follows a multi-step retrieval workflow: inspecting chunks with searchDocumentChunks first, then fetching full Markdown pages with documents.get, or using answerQuery for grounded answers. This is meant to optimize token and context usage.
The skill relies on the standard MCP integration across Google Antigravity, Claude Code, Cursor, GitHub Copilot and custom agentic frameworks. It tells the assistant how to use the Developer Knowledge MCP server, or fall back to the REST API via curl. Installation uses the command npx skills add google/skills --skill retrieving-developer-knowledge. Authentication can be configured with Application Default Credentials or an API key.
Client libraries and APIs Explorer
For production use, the client libraries let teams embed documentation retrieval, search and grounded answer generation into production systems, automated CI/CD pipelines and enterprise knowledge bots. They provide programmatic access to AnswerQuery, SearchDocumentChunks, GetDocument and BatchGetDocuments. BatchGetDocuments can retrieve up to 20 documents in a single API call.
Google lists support for Google Cloud Application Default Credentials, automatic retries and structured citation tracking. The libraries cover C#, Go, Java, Node.js and TypeScript, PHP, Python and Ruby, with native type definitions, builder patterns, error handling and asynchronous execution tailored to each ecosystem.
Google's example uses the Python library to let an agent fetch the latest release notes for a product such as Firestore, so its answers rest on data beyond its training cutoff.
The Google APIs Explorer for the Developer Knowledge API is an interactive, zero-code interface in Google's developer site. It is meant for experimenting with and verifying API requests and response structures.
What it means for developers
The release gives developers several entry points depending on their workflow. Those who already have the gcloud CLI can start querying official documentation right away. Those without it can give the agent skill to their AI coding assistant or agent to enable grounded retrieval. Teams building production software can use the client libraries. For agent builders on Google Cloud, the pitch from Google is a documented, regularly indexed alternative to scraping web pages or depending on what a model learned during training.
Google for Developers: Supercharge your development with the Google Developer Knowledge API ecosystem- Google Developers Blog


