# Tanpin

> Tanpin is an open-source MCP server for e-commerce. Per-SKU inventory with demand forecasts, auto purchase orders and delivery ETAs. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** self-hosted, Web, API, CLI
- **Website:** https://huggingface.co/spaces/willykeenan/tanpin
- **Repository:** https://github.com/willykeenan/tanpin
- **MCP Registry name:** io.github.willykeenan/tanpin
- **Categories:** e-commerce, analytics and data
- **Listing updated:** 2026-11-16

## About

The design follows tanpin kanri, a Japanese retail practice of treating each item as its own business: a manager forms a hypothesis about tomorrow's demand, orders against it and checks the result against sales. The software encodes that loop. It forecasts each SKU from recent sales, weekday patterns, short-term trend and manager-entered notes about events, weather or promotions, then computes safety stock, a reorder point, economic order quantity, pack size, minimum order quantity and a cap on days of supply.

Purchase orders are grouped by supplier and can be emailed automatically, over SMTP or as .eml files, with a delivery ETA derived from lead time, cut-off hour and delivery windows. Dead and slow-moving items are flagged to delist, and ABC classification marks the few items that drive most revenue.

It is a single Node.js 22 program with no runtime dependencies, with a REST API described in OpenAPI, an stdio MCP server, a background daemon that re-forecasts every 15 minutes by default, a dashboard and SQLite storage. A read-only demo with sample convenience-store data runs on Hugging Face.

## Features

- **Per-SKU forecasts:** Combines recent sales, weekday factors, trend and manager hypotheses.
- **Automatic reorder:** Calculates safety stock, reorder point, order quantity and pack-size rounding.
- **Supplier purchase orders:** Groups orders by supplier and emails them or writes .eml files.
- **Delivery ETAs:** Uses lead time, cut-off hours and delivery windows.
- **Delist flags:** Marks dead and slow SKUs and classifies items A, B or C.
- **Signed webhooks and CSV:** Sends HMAC-signed webhooks and imports or exports products and movements.
- **Daemon and dashboard:** Runs scheduled cycles and serves a web interface.

## Good for

- Reorder a small store's items without a spreadsheet
- Let an agent check stock and raise purchase orders
- Spot slow-moving products worth delisting
- Estimate when a supplier delivery will arrive
- Feed stock changes to other systems through webhooks

## Install

### Claude Code (Terminal)

```sh
claude mcp add tanpin -- docker run -i --rm ghcr.io/willykeenan/tanpin:0.1.0
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "tanpin": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/willykeenan/tanpin:0.1.0"
      ]
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "tanpin": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/willykeenan/tanpin:0.1.0"
      ]
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "tanpin": {
      "type": "stdio",
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/willykeenan/tanpin:0.1.0"
      ]
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "tanpin": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/willykeenan/tanpin:0.1.0"
      ]
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "tanpin": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/willykeenan/tanpin:0.1.0"
      ]
    }
  }
}
```

## FAQ

### What does it need to run?

Node.js 22 or newer; it has no runtime dependencies.

### How do I try it?

Run npx github:willykeenan/tanpin serve and click Load demo data, or open the read-only Hugging Face demo.

### Where does data live?

In a local SQLite file, with a JSON fallback.

### Does it send supplier emails?

Yes over SMTP when configured; otherwise it writes .eml files to an outbox.

### Is Tanpin free?

Yes. Tanpin is open source, so you can use and self-host it for free.

### How do I add Tanpin to Claude Code?

Run this command in your terminal: claude mcp add tanpin -- docker run -i --rm ghcr.io/willykeenan/tanpin:0.1.0

### What are the best alternatives to Tanpin?

The closest alternatives to Tanpin are Agent-Native Analytics, Google Ads + Meta Ads + SEO/GEO MCP, Tapetide - Indian Stock Market MCP, World Monitor and O'So MCP Server for PrestaShop.

## Alternatives

- [Agent-Native Analytics](https://ai-powered.com/mcp/agent-native-analytics): Agent-Native Analytics is an open-source MCP server for analytics and data.
- [Google Ads + Meta Ads + SEO/GEO MCP](https://ai-powered.com/mcp/google-ads-meta-ads-seo-geo-mcp): Google Ads + Meta Ads + SEO/GEO MCP is a freemium MCP server for marketing and seo.
- [Tapetide - Indian Stock Market MCP](https://ai-powered.com/mcp/tapetide-indian-stock-market-mcp): Tapetide - Indian Stock Market MCP is a freemium MCP server for finance and payments.
- [World Monitor](https://ai-powered.com/mcp/world-monitor): World Monitor is a freemium MCP server for analytics and data.
- [O'So MCP Server for PrestaShop](https://ai-powered.com/mcp/o-so-mcp-server-for-prestashop): O'So MCP Server for PrestaShop is an open-source MCP server for e-commerce.
- [CompanyData](https://ai-powered.com/mcp/companydata): CompanyData is a paid MCP server for analytics and data.
- [SecureCloud](https://ai-powered.com/mcp/securecloud): SecureCloud is a free MCP server for security.
- [MadMax Trade Supply parts](https://ai-powered.com/mcp/madmax-trade-supply-parts): MadMax Trade Supply parts is a free MCP server for e-commerce.

---
Source: https://ai-powered.com/mcp/tanpin
