About Firebase Docs MCP Server Setup
Firebase Docs MCP Server Setup is a sample project for indexing Firebase documentation and serving it to MCP clients. It includes a Go indexer, a stdio server, and a Genkit client for testing.
Key features
- 01Indexes Firebase documentation files
- 02Stores indexed data in SQLite
- 03Serves document search over stdio
- 04Includes a Genkit MCP test client
Use cases
- 01Search indexed Firebase documentation
- 02Test document lookup with MCP Inspector
- 03Try the tool through Genkit DevUI
MCP support
The MCP server exposes the `find-firebase-doc` tool over stdio, using the indexed documentation database. A Genkit MCP client and MCP Inspector are described for testing.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
From the project READMEFirebase Docs MCP Server Setup
Directory Layout
docs-mcp
This corresponds to the indexer for Firebaes docs. This is a Go project that goes and indexes the Firebase documents contained within the listed filepaths.
docs-mcp-server
This is the model context protocol server that serves content over a stdio transport.
genkit-mcp-tester
This is a genkit implementation of an MCP client to test using the docs-mcp-server.
How to use
Start with indexing
-
Set the API Key. We are using the Gemini embedding model for the documents so getting an API key from AI Studio is required. To set the API key, call
export genaikey="APIKEY"in your terminal -
Ensure that the output directory is empty. We are writing files to your home directory in a folder called
.indexResp. As go fetches documents from the Firebase documentation site, it writes the files to disk in markdown format and also indexes them in a SQL lite database in this directory. If indexing fails, it performes a retry strategy to reindex the documents into a markdown format. -
From the
docs-mcpfolder, callgo run .This will start the indexing process on the files listed near line 291 in themain.gofile.
Test the indexer
-
Set the API Key. We are using the Gemini embedding model for the documents so getting an API key from AI Studio is required. To set the API key, call
export genaikey="APIKEY"in your terminal -
Switch into the
docs-mcp-serverfolder. -
Copy the indexed database to the local
docs-mcp-serverfolder. This can be done by callingcp $HOME/.indexResp/db.sqlite . -
Install the dependencies and build the project.
npm ciand thennpm run build. Once the project is built, you can then test the project by callingnpm run build && npx @modelcontextprotocol/inspector node build/index.js. This starts the inspector and should print a URL for you to view the STDIO server with. -
Click on Connect in the inspector view, and then click on tools -> List Tools -> find-firebase-doc and then type in for your request that you would want to use. NOTE: The author has had trouble using the terminal built into VSCode for running this step, so if you run into a similar issue, try the system terminal.
Use Genkit for testing
-
Set the API key in the code by changing this line in embedding.ts from :
const genAiKey = process.env.genaikey || "";toconst genAiKey = process.env.genaikey || "MYAPIKEY"; -
Switch into the
genkit-mcp-testerdirectory. -
Copy the indexed database to the local
genkit-mcp-testerfolder. This can be done by callingcp $HOME/.indexResp/db.sqlite . -
Install the dependencies and build the project.
npm ciand thennpm run build. Once the project is built, you can then test the project by callingnpx genkit start -- npx tsx --watch src/index.ts. This starts the Genkit DevUI where you can interact with the flow and tool directly. Open the DevUI, generally http://localhost:4000 and visit the Tools ->find-firebase-doc/find-firebase-doctool and make a request here. You can see that the request is then returning the results we see in the modelcontextprotocol/inspector.
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.