Skip to main content
Glama
aravindtri

Amazon Price Tracker MCP

by aravindtri
README.md
# Amazon Price Tracker MCP

MCP server for tracking Amazon product prices via [camelcamelcamel.com](https://camelcamelcamel.com).
Uses headless Chromium (Playwright) to bypass Cloudflare protection — no visible windows, runs as a background daemon.

## Tools

| Tool | Description |
|------|-------------|
| `get_product_price` | Get price history for an Amazon product. Input: URL, short link, or ASIN |
| `resolve_short_link` | Resolve a.co / amzn.to short links to full Amazon URLs |
| `extract_asin` | Extract the ASIN from any Amazon URL format |

## Quick Install

```bash
git clone https://github.com/aravindtri/amazon-price-tracker-mcp.git
cd amazon-price-tracker-mcp
npm install
npx playwright install chromium
npm run build
```

## MCP Client Configuration

### VS Code Copilot

Add to `C:\Users\%USERNAME%\AppData\Roaming\Code\User\mcp.json`:

```json
{
  "servers": {
    "amazon-price-tracker": {
      "type": "stdio",
      "command": "node",
      "args": ["C:\\Workspace\\AmazonPriceTrackerMCP\\dist\\index.js"]
    }
  }
}
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "amazon-price-tracker": {
      "command": "node",
      "args": ["C:/Workspace/AmazonPriceTrackerMCP/dist/index.js"]
    }
  }
}
```

## Usage

```
Input: https://www.amazon.com/dp/B08N5WRWNW
Input: https://a.co/d/0aNbqzsI  
Input: B08N5WRWNW
```

Returns product name, category, manufacturer, model, and price summary:
- Current, lowest ever, highest ever, average prices
- Separate tracking for Amazon, 3rd Party New, and 3rd Party Used

## How It Works

1. Extracts ASIN from Amazon URLs (supports `/dp/`, `/gp/product/`, short links)
2. Resolves short links by following redirects in headless Chrome
3. Loads `camelcamelcamel.com/product/{ASIN}` in headless Chromium
4. Cloudflare challenge auto-resolves (real Chrome engine)
5. Parses the rendered HTML for price data using cheerio
6. Browser stays alive for 5 minutes idle, then auto-closes

No API key required. No manual cookie setup.

TDQS

A3.7/5.0

Scored across 3 tools

Disambiguation2/5

The primary tool get_product_price accepts all input formats directly, including short links and URLs, making the auxiliary tools unnecessary in many cases. resolve_short_link and extract_asin both extract ASINs from links, with only slight differences in input flexibility, so agents may struggle to choose the right tool for a given URL. This overlapping functionality creates ambiguity in tool selection.

Naming Consistency5/5

All three tools follow a consistent verb_noun pattern with lowercase snake_case: get_product_price, resolve_short_link, extract_asin. This makes the API predictable and easy to navigate.

Tool Count4/5

Three tools is a minimal but reasonable number for a price-tracking server. However, since get_product_price already handles all input formats, the two preprocessing tools appear somewhat redundant, making the count slightly higher than necessary.

Completeness4/5

The server covers the core operation of retrieving price history and current pricing for a given product. It lacks batch lookup or search features, but for its narrow purpose of single-product tracking, it provides a complete workflow.

Maintenance

ActivityStale
ResponsivenessNo issues