canonical: https://jentic.com/apis/bitstamp.net/bitstamp

# Bitstamp API

The Bitstamp API exposes the public market data surface of the Bitstamp cryptocurrency exchange. It serves real-time and historical pricing for any supported currency pair, including current and hourly tickers, the live order book, recent trades, OHLC candle data, and the catalogue of tradable pairs and currencies. The endpoints are read-only market data routes useful for building dashboards, price feeds, signal generators, and trading bots that need authoritative Bitstamp prices without scraping the website.

## For AI agents

Fetch real-time crypto market data from Bitstamp - tickers, order books, recent trades, OHLC candles, and the list of available trading pairs and currencies. Read-only public market data, no order placement.

## Scope

Does not handle order placement, account balances, or fiat withdrawals - use for Bitstamp public market data only.

## Capabilities

- Retrieve the current ticker, including last price and 24h volume, for any Bitstamp currency pair
- Inspect the live order book to gauge bid-ask depth before sizing a trade
- Pull recent public trades to drive microstructure analytics on a Bitstamp pair
- Fetch OHLC candle data with configurable step and limit for backtesting
- Enumerate the supported trading pairs and underlying currencies on Bitstamp

## Use cases

### Real-Time Crypto Price Feed

Power a dashboard or alerting agent with live spot prices from Bitstamp. The /api/v2/ticker/{currency_pair}/ endpoint returns the latest bid, ask, last price, volume, and 24h high/low for any supported pair, so a service can poll on a fixed cadence and surface price moves to users. This is the simplest way to integrate authoritative Bitstamp pricing into a finance app or trading agent.

Example prompt: Call GET /api/v2/ticker/btcusd/ every 30 seconds and emit an alert when the last price moves more than 2% from the previous reading.

### Order Book Depth Analysis

Trading agents and market-making bots use the /api/v2/order_book/{currency_pair}/ endpoint to inspect resting bids and asks at each price level. The response captures liquidity depth, which agents use to estimate slippage before sizing an order or to detect imbalances that precede short-term moves. Combine with /api/v2/transactions/ for full microstructure context.

Example prompt: Call GET /api/v2/order_book/ethusd/, sum the first 10 levels of bids and asks, and report which side has more liquidity.

### Strategy Backtesting with OHLC Candles

Pull historical OHLC data from /api/v2/ohlc/{currency_pair}/ to backtest trading strategies on Bitstamp pairs. The endpoint accepts a step and limit so a backtester can request minute, hour, or day candles across an arbitrary window. Combined with /api/v2/trading-pairs-info/ this is enough to systematically evaluate strategies across the full Bitstamp universe.

Example prompt: Call GET /api/v2/ohlc/btcusd/?step=3600&limit=720 and compute a 30-day moving average from the close prices.

### Pair and Currency Discovery

Before subscribing to a price feed or routing an order, an automation needs to know which pairs Bitstamp actually trades and what minimums apply. /api/v2/trading-pairs-info/ returns the metadata for every pair (minimum order size, decimals, trading status) and /api/v2/currencies/ lists the assets themselves. This lets agents validate user-supplied symbols before any further calls.

Example prompt: Call GET /api/v2/trading-pairs-info/ and return the pair object whose name matches the user-supplied symbol, rejecting unsupported pairs.

### Agent Price Lookup via Jentic

An AI assistant answering 'what is BTC trading at?' uses Jentic to find the Bitstamp ticker operation, load its schema, and execute it without the developer having to wire HTTP calls. Jentic returns the ticker JSON directly so the agent can format the price for the user. The same pattern works for any of the seven Bitstamp public market data endpoints.

Example prompt: Use Jentic search for 'get the current BTC/USD price on Bitstamp', load the schema, then execute GET /api/v2/ticker/btcusd/ and return the last price.

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | /api/v2/ticker/{currency_pair}/ | Latest ticker for a pair |
| GET | /api/v2/order_book/{currency_pair}/ | Live order book |
| GET | /api/v2/transactions/{currency_pair}/ | Recent public trades |
| GET | /api/v2/ohlc/{currency_pair}/ | OHLC candle data |
| GET | /api/v2/trading-pairs-info/ | Trading pair metadata |
| GET | /api/v2/currencies/ | Supported currencies |

## Key resources

- **Ticker** — Current and hourly tickers for any supported currency pair
- **Order Book** — Live bids and asks at each price level for a pair
- **Transactions** — Recent public trades for a pair
- **OHLC** — Open/high/low/close candle data with configurable step and limit
- **Trading Pairs** — Metadata for every tradable pair: minimum order size, decimals, status
- **Currencies** — Catalogue of supported assets on Bitstamp

## Why Jentic

- **Setup:** Wiring the Bitstamp API by hand means handling the X-Auth and HMAC X-Auth-Signature headers for authenticated tiers, targeting the www.bitstamp.net host, and managing retries around market-data calls yourself. Through Jentic you install once, import Bitstamp from the API Directory, store any credentials once, and your agent calls it.
- **Permission scoping:** This Bitstamp spec covers public market data only, with the currency pair in the URL path (/api/v2/ticker/{currency_pair}/), so limit the agent to the operations it needs, such as reading a ticker, order book, or OHLC series. You choose the operations it may call, so nothing beyond those reads runs unless you add it.
- **Credential handling:** Any Bitstamp key and signing secret are stored once, encrypted, by your own Jentic One instance, which builds the signature and injects it at execution time. They never enter the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'get the current BTC/USD price on Bitstamp' or 'fetch the ETH order book', and Jentic returns the matching operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Bittrex** — Bittrex is another crypto exchange API with similar market data and trading endpoints.
- **BizToc** — BizToc supplies business and crypto news to overlay on Bitstamp price moves.
- **Blackfire.io** — Blackfire profiles the application that polls Bitstamp so price-feed services do not regress.

## FAQ

### What authentication does the Bitstamp API use?

The OpenAPI spec declares two security schemes: X-Auth (API key) and X-Auth-Signature (HMAC-SHA256 signature). The seven public market data endpoints in this spec are typically callable without auth, but Bitstamp accepts the same headers for authenticated rate tiers. Through Jentic, the X-Auth and signature secret are stored in the encrypted vault and the agent never sees the raw values.

### Can I place trades with the Bitstamp API as exposed in this spec?

No. This spec only covers public market data: tickers, order books, transactions, OHLC, trading pairs, and currencies. There are no order placement, balance, or withdrawal endpoints in the seven paths. For trading you need Bitstamp's private endpoints, which are out of scope here.

### What are the rate limits for the Bitstamp API?

Bitstamp publishes a global rate limit of 8000 requests per 10-minute window across the public API. The OpenAPI spec does not encode this directly, so build retries with exponential backoff and watch for HTTP 429 responses on the ticker, order book, and OHLC endpoints if you poll aggressively.

### How do I get OHLC candles with the Bitstamp API through Jentic?

Install with pip install jentic, then use Jentic search with 'get OHLC candles from Bitstamp'. Load the schema for GET /api/v2/ohlc/{currency_pair}/ and execute with currency_pair, step (in seconds), and limit. Jentic resolves the call without exposing any auth headers.

### Which trading pairs are available on Bitstamp?

Call GET /api/v2/trading-pairs-info/ to get the full list with metadata for each pair (name, minimum order, decimals, trading status). Use GET /api/v2/currencies/ to enumerate the underlying assets. Cache both responses since the catalogue changes infrequently.

### Is the Bitstamp API free?

The public market data endpoints in this spec are free to call within Bitstamp's rate limits. There is no per-call charge for tickers, order books, OHLC data, or pair metadata. Authenticated and trading endpoints follow Bitstamp's standard fee schedule, which is separate from the free read endpoints.

### Can I limit what my agent is allowed to do with the Bitstamp API?

Yes. Because Jentic One is self-hosted, your own rules decide which Bitstamp operations and credentials the agent may use, so you can allow just the reads it needs, such as GET /api/v2/ticker/{currency_pair}/ or GET /api/v2/order_book/{currency_pair}/, and withhold the rest. This spec covers public market data only, including tickers, order books, OHLC candles, trading pairs, and currencies, and nothing beyond the operations you grant will run. Any Bitstamp key and signing secret stay in your instance and never reach the agent's prompt or logs.
