canonical: https://jentic.com/apis/bitfinex.com/bitfinex

# Bitfinex API

Jentic publishes the only available OpenAPI specification for Bitfinex API, keeping it validated and agent-ready. Bitfinex is a long-running cryptocurrency exchange offering spot, margin, and derivatives trading along with peer-to-peer funding. The v2 REST API splits into a public surface for tickers, order books, trades, candles, and platform status, and an authenticated surface for orders, positions, wallets, ledger, deposits, withdrawals, and movements. Authentication signs each request with three headers: bfx-apikey, bfx-nonce, and bfx-signature, the latter being an HMAC SHA-384 of the request payload.

## For AI agents

Stream Bitfinex public market data and place authenticated trades, manage wallets, and query positions on the v2 REST API. 33 endpoints, three-header HMAC authentication.

## Scope

Does not handle fiat banking outside Bitfinex-supported rails, custody at other venues, or tax reporting - use for trading, market data, and wallet operations on Bitfinex only.

## Capabilities

- Read live ticker, order book, trades, and candles for any Bitfinex symbol from the public endpoints
- Place, cancel, and inspect orders on the authenticated trading surface
- Read open positions, wallet balances, ledger entries, and movement history
- Submit deposits and withdrawals through the authenticated funding endpoints
- Check platform status before sending an order to detect a maintenance window
- Pull derivatives status for funding rate and mark price tracking

## Use cases

### Algorithmic spot trading on Bitfinex v2

Quant teams build a trading loop that consumes public ticker and candle data, decides on a position, and then submits authenticated orders. The Bitfinex v2 REST API supports the full loop: public tickers and candles for the signal layer, and authenticated order placement for execution. The three-header HMAC authentication scheme is the only operational complexity beyond the standard order schema.

Example prompt: Read the latest ticker for tBTCUSD, then submit a market buy order for 0.01 BTC and confirm it appears in the open orders list

### Wallet and ledger reconciliation

Finance teams reconcile their internal accounts against Bitfinex by pulling wallet balances, ledger entries, deposits, withdrawals, and movements on a daily cadence. The authenticated funding endpoints return the same records the web UI exposes, and the response schema is stable enough to feed a downstream accounting pipeline. Reconciliation jobs typically run once per UTC day and back-fill from the previous run's cursor.

Example prompt: Pull yesterday's ledger entries and movements for the funding wallet, sum by currency, and compare against the internal accounting balance

### Market data ingestion for research

Research teams ingest Bitfinex tickers, order books, trades, and candles into a research warehouse to model microstructure and pricing. The public surface returns this data without authentication, so an ingestion job can run from any environment without managing exchange keys. Bitfinex's symbol convention prefixes trading pairs with t (e.g. tBTCUSD) and funding pairs with f.

Example prompt: Pull 1-minute candles for tBTCUSD over the last 24 hours and write them to the research warehouse partitioned by symbol

### Agent integration via Jentic for crypto operations

An AI agent that needs to act on a user's Bitfinex account calls Jentic with a high-level intent like 'get my crypto wallet balances' or 'place a market order on Bitfinex'. Jentic returns the matching authenticated operation with its input schema, and injects the bfx-apikey, bfx-nonce, and bfx-signature headers at execution time. The agent never sees the secret used to compute the signature.

Example prompt: Search Jentic for 'place a bitfinex market order', load the order submission schema, and execute a 0.01 BTC buy on the user's account

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | /platform/status | Return the platform's operational status (1=online, 0=maintenance) |
| GET | /ticker/{symbol} | Return the latest ticker for a trading or funding symbol |
| GET | /tickers | Return tickers for several symbols in a single call |
| GET | /trades/{symbol}/hist | Return historical trades for a symbol |
| GET | /book/{symbol}/{precision} | Return the order book for a symbol at a chosen precision |
| GET | /candles/{candle}/{section} | Return OHLC candles for a symbol over a chosen time window |
| GET | /status/deriv | Return the current derivative platform status |

## Key resources

- **Public Market Data** — Tickers, order books, recent trades, candles, and platform status - no authentication
- **Authenticated Trading** — Place, cancel, and inspect orders against the user's account
- **Authenticated Wallets** — Read balances across exchange, margin, and funding wallets
- **Authenticated Funding** — Manage peer-to-peer funding offers, deposits, and withdrawals
- **Authenticated Ledger and Movements** — Read ledger entries, deposits, withdrawals, and movement history

## Why Jentic

- **Setup:** Wiring the Bitfinex API by hand means computing the bfx-nonce and HMAC SHA-384 bfx-signature for each authenticated request, choosing between the api-pub and api hosts, and handling retries yourself. Through Jentic you install once, import Bitfinex from the API Directory, store the key and secret once, and your agent calls it.
- **Permission scoping:** Bitfinex market-data endpoints put the symbol in the URL path (/ticker/{symbol}), but trading targets travel in the request body, so limit the agent to the operations it needs, such as reading a ticker or order book. You choose the operations it may call, so order placement or wallet actions are not included unless you add them.
- **Credential handling:** Your Bitfinex key and secret are stored once, encrypted, by your own Jentic One instance, which computes the nonce and signature and injects them at execution time. They never enter the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'get a Bitfinex ticker' or 'read an order book', and Jentic returns the matching operation with its input and response schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Binance API** — Larger global crypto exchange with similar spot, margin, and derivatives surfaces.
- **Kraken API** — US-friendly exchange with comparable REST trading and market data endpoints.
- **Gemini API** — Regulated US exchange with REST trading and market data.
- **Bitstamp API** — Older European exchange useful for cross-venue arbitrage feeds.

## FAQ

### Why is there no official OpenAPI spec for Bitfinex API?

Bitfinex does not publish an OpenAPI specification. Jentic generates and maintains this spec so that AI agents and developers can call Bitfinex API via structured tooling. It is validated against the live API and kept up to date. Get started with Jentic One, the self-hosted execution layer.

### What authentication does the Bitfinex API use?

Authenticated calls require three headers: bfx-apikey (the public API key), bfx-nonce (a strictly increasing counter), and bfx-signature (an HMAC SHA-384 of the request payload signed with the API secret). Through Jentic the secret is held in the vault and the signature is computed at execution time.

### Can I place a market order with the Bitfinex API?

Yes. Bitfinex v2 supports market and limit orders against any listed trading symbol. Submit the order on the authenticated surface together with the three signature headers - Bitfinex returns the order id and status in the response.

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

Bitfinex enforces per-route limits (typically 10-90 requests per minute on public endpoints and tighter limits on authenticated routes). Excess calls return a 429 Too Many Requests. Bitfinex strongly recommends WebSockets for high-frequency market data; the REST surface is best for periodic polls and order management.

### How do I check my Bitfinex balance through Jentic?

Run pip install jentic, search Jentic for 'get my crypto wallet balance', load the authenticated wallets operation, and execute. Jentic computes the HMAC signature from the vaulted secret so the agent never holds the API key.

### Are Bitfinex public market data endpoints free?

Yes. The /platform/status, /ticker, /tickers, /trades, /book, and /candles endpoints do not require authentication and are free to call within the published rate limits. Authenticated trading and wallet endpoints require an active Bitfinex account and a generated API key pair.

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

Yes. Jentic One is self-hosted by you, so your own rules decide which Bitfinex operations and credentials the agent may use. You can allow read-only market-data calls such as fetching a ticker at /ticker/{symbol} or an order book while excluding the authenticated surface, so order placement and wallet actions are only available if you add them. Because trading targets travel in the request body rather than the URL, scoping is done at the operation level, and your instance holds the encrypted key and secret and injects the signature at execution time.
