Skip to main content

MCP server exposing FineRx drug-price data to AI agents (thin client over the FineRx public REST API).

Project description

FineRx MCP server

Give an AI assistant live access to FineRx drug-price data — the same catalog, package, price-comparison, and nearest-pharmacy data shown on the FineRx website — through the Model Context Protocol.

finerx-mcp is a thin client over the FineRx public REST API (/api/public/v1). It has no direct database access and inherits the public API's authentication and rate limits, so it adds zero extra attack surface.

Tools

Tool What it does
search_drugs(query, limit=10) Find drugs by name/alias → candidates with slugs + from-prices
get_drug(slug) A drug's stats + strength/form variants
compare_prices(ndc, quantity) Offer matrix (chain × savings program × price × observation date)
find_nearby_pharmacies(zip, chains?, limit=3) Nearest store locations per chain around a ZIP
get_dataset_info() Dataset coverage, freshness, and attribution/disclaimer terms

Every result embeds a one-line disclaimer and, wherever a price appears, an observedAt date. No tool ever returns hidden vendors or an operator reference price.

Prerequisites

Configuration

The server reads two environment variables:

Variable Required Default Notes
FINERX_API_KEY yes Your frx_live_... key
FINERX_API_BASE no https://finerxfinder.com/api/public/v1 Point at another host for local testing

Install & run

Run directly with uvx (no manual install needed):

FINERX_API_KEY=frx_live_xxxxxxxx uvx finerx-mcp

The server speaks MCP over stdio.

Claude Desktop

Add to your claude_desktop_config.json (macOS: ~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "finerx": {
      "command": "uvx",
      "args": ["finerx-mcp"],
      "env": {
        "FINERX_API_KEY": "frx_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
      }
    }
  }
}

Restart Claude Desktop; the FineRx tools appear in the tools menu.

Claude Code

claude mcp add finerx --env FINERX_API_KEY=frx_live_xxxx -- uvx finerx-mcp

Or add it to .mcp.json in your project:

{
  "mcpServers": {
    "finerx": {
      "command": "uvx",
      "args": ["finerx-mcp"],
      "env": { "FINERX_API_KEY": "frx_live_xxxxxxxx" }
    }
  }
}

Local development

Run against a local FineRx stack (e.g. the dev proxy on :8080):

export FINERX_API_KEY=frx_live_...        # a key you created via the CLI
export FINERX_API_BASE=http://localhost:8080/api/public/v1
uv run --project packages/finerx-mcp finerx-mcp

A smoke test that drives one tool call end-to-end lives at scripts/smoke_mcp.py in the FineRx repo.

Terms

Data is provided under the FineRx public API terms: attribution required ("Prices via FineRx"), prices are observed estimates (not guaranteed or insured prices) and may be out of date, and nothing here is medical advice. Pharmacy location coordinates are © OpenStreetMap contributors (ODbL).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

finerx_mcp-1.0.0.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

finerx_mcp-1.0.0-py3-none-any.whl (6.9 kB view details)

Uploaded Python 3

File details

Details for the file finerx_mcp-1.0.0.tar.gz.

File metadata

  • Download URL: finerx_mcp-1.0.0.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for finerx_mcp-1.0.0.tar.gz
Algorithm Hash digest
SHA256 c3b40d06d77b536c8205b2273df589e59fcc72ae9430c675e7c47e2f4a528357
MD5 b1a0d6944855b454e5f3d09cfc4b186d
BLAKE2b-256 7a3536547f4c6a145a35a24772bdb6ea47bd496a6d0cceddda5169fc9d6255df

See more details on using hashes here.

File details

Details for the file finerx_mcp-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: finerx_mcp-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 6.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for finerx_mcp-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 397e71fc829be6835f104485226339f1de66fd8b6d38eba48ef6b10ab056d7aa
MD5 d4cefe8b0e83a86248f3d498d9e44ad9
BLAKE2b-256 05e5ad211dda0b2e257f327c86f7c93c0bc32da31e9ebb639c88e6db56436fde

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page