Skip to main content
Glama

Discontinued Oct 2026: the SpotGPU API has been shut down. This package no longer works.

spotgpu-mcp

MCP (Model Context Protocol) server for SpotGPU spot GPU rental prices.

Exposes one tool: spot_price → GET /v1/spot (Vast + RunPod best + alts).

Credits ≠ rental. SpotGPU API credits pay for price lookups.
usd_per_hr is the upstream provider rental price, not a SpotGPU fee.

Install / run

Requires Python 3.10+ and a SpotGPU API key.

Get an API key (free trial, 25 credits)

curl -X POST https://spotgpu-api.fly.dev/v1/keys

No auth, no email. The response contains api_key (shown once — store it) with 25 trial credits (1 credit per successful lookup). Limit: 3 keys per IP per 24h. Put it in SPOTGPU_API_KEY in your MCP client config. Check your balance:

curl -H "Authorization: Bearer $SPOTGPU_API_KEY" https://spotgpu-api.fly.dev/v1/account

Out of credits (HTTP 402)

When credits run out the API returns 402 insufficient_credits and the tool error points to the top-up page. Buy a credit pack ($5 / 500, $10 / 1000, $50 / 5000) at https://spotgpu-api.fly.dev/topup, or POST /v1/checkout with {"pack_id": "credits_500"} and your Bearer key to get a Stripe Checkout URL. A 401 tool error includes the signup curl above.

One-shot (PyPI)

uvx spotgpu-mcp

Local (this monorepo package)

cd packages/mcp-spotgpu
uv sync   # or: pip install -e .
export SPOTGPU_API_KEY=sk_…
spotgpu-mcp

Env:

Variable

Required

Default

SPOTGPU_API_KEY

yes

—

SPOTGPU_BASE_URL

no

https://spotgpu-api.fly.dev

Never hardcode keys. The server speaks MCP on stdio only (do not print to stdout).

Related MCP server: flopsindex-mcp

Claude Desktop

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "spotgpu": {
      "command": "uvx",
      "args": ["spotgpu-mcp"],
      "env": {
        "SPOTGPU_API_KEY": "sk_…"
      }
    }
  }
}

Local editable install instead of uvx:

{
  "mcpServers": {
    "spotgpu": {
      "command": "uv",
      "args": ["run", "--directory", "/path/to/spotgpu/packages/mcp-spotgpu", "spotgpu-mcp"],
      "env": {
        "SPOTGPU_API_KEY": "sk_…"
      }
    }
  }
}

Cursor

Add to .cursor/mcp.json (or user MCP config):

{
  "mcpServers": {
    "spotgpu": {
      "command": "uvx",
      "args": ["spotgpu-mcp"],
      "env": {
        "SPOTGPU_API_KEY": "sk_…"
      }
    }
  }
}

Tool: spot_price

Param

Type

Default

Notes

gpu

string

required

e.g. RTX_4090

qty

int

1

≥ 1

markets

string

"vast,runpod"

comma-separated

fresh

bool

false

maps to fresh=1

On success returns JSON text of the API body (best.usd_per_hr, alts, …).

Attribution

Requests send X-SpotGPU-Client: mcp-spotgpu.

Published

Available Tools

1 tool
spot_priceA

Get SpotGPU spot rental prices (best + alts) for a GPU type.

Returns JSON from GET /v1/spot including best.usd_per_hr (upstream provider rental price, not a SpotGPU fee). Credits are for API calls, not GPU rental.

Args: gpu: GPU type, e.g. RTX_4090, RTX_3090, RTX_A6000 qty: Number of GPUs (>= 1). Default 1. markets: Comma-separated markets. Default "vast,runpod". fresh: If true, bypass cache (query fresh=1). Default false.

Inputs: gpu (required), qty, fresh, markets. Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4/5.0

    Scored across 1 tool

    Disambiguation5/5

    With only a single tool in the set, there is nothing to confuse it with; an agent cannot misselect between alternatives. Its purpose (fetch spot rental prices) is unambiguous.

    Naming Consistency4/5

    The lone name spot_price is clear lowercase snake_case, matching the convention used by the parameters (gpu, qty, markets, fresh). There is no cross-tool inconsistency to evaluate, though it is a noun phrase rather than a verb_noun action name.

    Tool Count2/5

    A one-tool surface is very thin even for a narrowly scoped pricing service; common companion needs (listing supported GPU types, markets, or making a booking) are absent. It works only for the single exact lookup it was built for.

    Completeness2/5

    The domain (GPU spot rental) realistically includes discovering GPU types/markets and possibly reserving capacity, none of which exist here. An agent can retrieve prices but hits a dead end for anything else, with no fallback operations.

    Maintenance

    ActivitySlowing
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      C
      maintenance
      Provides public price indices for GPU rentals (spot, on-demand, DePIN) with verify URLs, enabling agents and users to query and verify compute economics rates.
      5
      1
      Apache 2.0
    • A
      license
      Not graded
      quality
      B
      maintenance
      Ranks current RunPod GPU offers by price and freshness for AI infrastructure agents, with a free sample tool and a paid rank tool. Supports x402/USDC-on-Base payments: an unauthenticated call returns the real 402 challenge for a wallet-capable agent to pay and retry.
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Enables agents to query live cloud GPU pricing, stock availability, and up to 12 months of price history across 30+ hyperscalers, neoclouds, and marketplaces, including comparisons of cheapest listed versus cheapest in-stock offers. All tools are read-only, with provider listings and GPU catalogs available at no cost.
      8
      81 npm
      MIT