Get the FREE Ultimate OpenClaw Setup Guide →

kroger

A FastMCP server that provides AI assistants like Claude with access to Kroger's grocery shopping functionality through the Model Context Protocol (MCP). This server enables AI assistants to find stores, search products, manage shopping carts, and access Kroger's comprehensive grocery data via the kroger-api python library.

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio cupofowls-kroger-mcp uvx kroger-mcp \
  --env KROGER_CLIENT_ID="your_client_id" \
  --env KROGER_REDIRECT_URI="http://localhost:8000/callback" \
  --env KROGER_CLIENT_SECRET="your_client_secret" \
  --env KROGER_USER_ZIP_CODE="10001"

How to use

The Kroger MCP Server exposes Kroger shopping capabilities to AI assistants via the Model Context Protocol (MCP). It leverages Kroger's API through the kroger-mcp package to provide tooling for locating stores, searching products, managing a local cart, and accessing Kroger data such as store details, product details, and departments. Tools are organized into location, product, cart, information, profile, and utility categories, with authentication required for cart actions and certain profile operations. This setup enables a constrained, local session that lets an AI assistant guide a user through store selection, product discovery, and cart management while respecting Kroger's authentication flow. To start, configure your Kroger API credentials in environment variables, then run the MCP server via uvx, uv, or another supported runner and connect your MCP-enabled agent (such as Claude) to the server’s endpoint.

How to install

Prerequisites:

  • Python environment (and optionally a virtual environment)
  • Kroger API credentials (CLIENT_ID, CLIENT_SECRET, and REDIRECT_URI)
  • Access to install uvx (or uv) and the kroger-mcp package via PyPI or repository

Option A: Install from PyPI and run with uvx (recommended)

  1. Install the package: uvx pip install kroger-mcp

    or

    pip install kroger-mcp
  2. Create a configuration JSON (example shown below) and save as claude_desk_config.json (or your preferred path used by Claude Desktop).
  3. Run the MCP server: uvx kroger-mcp

Option B: Install from source

  1. Clone the repository: git clone https://github.com/CupOfOwls/kroger-mcp cd kroger-mcp
  2. Install dependencies (via uv or pip): uv sync

    or

    pip install -e .
  3. Run the server: uv run kroger-mcp

Option C: Install with Python directly

  1. Ensure dependencies are installed: pip install kroger-mcp
  2. Run with Python: python server.py

Configuration example (as used by Claude Desktop): save as a JSON file and point Claude Desktop to load it as an MCP server: { "mcpServers": { "kroger": { "command": "uvx", "args": [ "kroger-mcp" ], "env": { "KROGER_CLIENT_ID": "your_client_id", "KROGER_CLIENT_SECRET": "your_client_secret", "KROGER_REDIRECT_URI": "http://localhost:8000/callback", "KROGER_USER_ZIP_CODE": "10001" } } } }

Additional notes

Environment variables: Set KROGER_CLIENT_ID, KROGER_CLIENT_SECRET, and KROGER_REDIRECT_URI to enable the OAuth flow. KROGER_USER_ZIP_CODE is optional and provides a default location for searches. The server maintains local cart tracking files (kroger_cart.json and kroger_order_history.json) since Kroger’s public API does not support viewing or modifying a real cart through MCP; actions like add_items_to_cart will only affect local storage unless the user has synchronized cart updates in the Kroger app. For development, using FastMCP CLI can help with live testing. If you encounter authentication issues, ensure the redirect URI matches the one registered in your Kroger developer console and that your client credentials are current.

Related MCP Servers

Sponsor this space

Reach thousands of developers