merchant-center-mcp
merchant-center-mcp
MCP server for Google Merchant Center diagnostics via the Merchant API v1 (gRPC): account info, feed/datasource status, and catalog reports via Merchant Center Query Language (MCQL). Read-only — no tool can modify a live catalog.
Tools (4)
Tool | What it does |
| Basic account info (name, ID, language, timezone, test flag) |
| Feeds configured on the account (primary, supplemental, local inventory...) |
| Run an MCQL query against any Reports API view ( |
| Shortcut over |
⚠️ Reports API scope note: it only works on standalone accounts or individual sub-accounts, not on "advanced" (aggregator/MCA) accounts.
⚠️ MCQL limitation: the repeated field item_issues can't be filtered in
a WHERE clause. get_product_issues works around this by pulling
product_view and filtering client-side in Python (capped at 5000 scanned
rows by default).
Setup
Create a Google Cloud project (or reuse one) and enable the Merchant API.
Create an OAuth 2.0 Client ID of type "Desktop app" and download it as
client_secret.json.If the app is in "Testing" mode, add your Google account as a test user.
Install dependencies:
python3 -m venv .venv source .venv/bin/activate pip install -r requirements.txtRun the OAuth flow once:
CLIENT_SECRET_PATH=~/.config/merchant-center-mcp/client_secret.json python3 setup_auth.pyThis opens a browser — log in and grant access. The token is saved to
~/.config/merchant-center-mcp/token.jsonby default (setTOKEN_OUTto use a different path for a second account).
MCP client configuration
{
"mcpServers": {
"merchant-center": {
"command": "/path/to/.venv/bin/python3",
"args": ["/path/to/merchant-center-mcp/server.py"]
}
}
}Env var | Default | Purpose |
|
| Path to the token file generated by |
For a second account, point a second server instance at the token file you
generated with TOKEN_OUT=~/.config/merchant-center-mcp/token_other.json.
Security
All tools carry the MCP spec's Tool Annotations (
readOnlyHint=true,destructiveHint=false,idempotentHint=true,openWorldHint=true) — accurate, since this server never writes anything.Execution errors propagate as real MCP protocol errors (
isError=true), never as a JSON payload disguised as a success response.
Notes
Gone in favor of Merchant API v1: the Content API for Shopping it replaces was sunset in 2026. If you're still targeting the old API, this server won't help — migrate first.
search_report/get_product_issuespaginate through the gRPC response stream and stop oncelimitrows are collected — they don't fetch the whole result set up front.
License
MIT — see LICENSE.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/YerayRodri/merchant-center-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server