funding-arb-screener
Fetches perpetual-futures funding rates, funding intervals, mark prices, and 24-hour turnover from Binance, and uses them in cross-venue spread, annualized carry, and break-even calculations.
Fetches perpetual-futures funding rates, funding intervals, mark prices, and 24-hour turnover from OKX, and uses them in cross-venue spread, annualized carry, and break-even calculations.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@funding-arb-screener compare BTC/USDT funding rates across all venues and show the best spread"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
funding-arb-screener
Perpetual-futures funding rates from five exchanges, in one call — with the delta-neutral spread, the annualized carry and the break-even time already worked out.
Funding is the one payment in crypto that repeats every few hours and is easy to miss. A pair paying 0.01% every eight hours is not "0.01%" — it is 10.95% a year, and the same pair on a different venue may be paying 0.008%, which is a real, market-neutral spread you can hold with two opposing positions and no directional risk. Finding that spread by hand means five tabs, five symbols spellings and a calculator.
This server does it in one request. Ask for BTC/USDT and get back every venue
that trades it, its current rate, the interval that rate applies to, the
annualized equivalent, the mark price and 24-hour turnover — plus which venue
you should sell and which you should buy, what that pair of legs is worth per
year, and how many funding periods it takes just to pay the trading fees.
get_funding_rates("BTC/USDT") → 5 venues + the best spread
scan_funding_opportunities() → the whole market, ranked
get_funding_history("BTC/USDT","bybit") → is this rate normal, or a squeeze?
list_venues() → which exchanges are answeringWorks with no API key — every venue endpoint used here is public.
One tool, five venues. Exchanges are a parameter, never a different repo.
Fails soft. A venue that is down returns a named failure next to the data from the venues that are up. You never get an empty result because one exchange had a bad minute.
Documented in English, Spanish and Russian, including the tool descriptions the model reads. Set
MCP_LOCALE.
Why a spread, and not just a rate
A funding rate on its own tells you what the crowd is doing. The spread between two venues tells you what you can do:
Sell the perpetual on the venue with the highest rate.
Buy the same perpetual on the venue with the lowest rate.
Both legs are the same asset, so price moves cancel. Each funding tick, you receive on the short leg and pay on the long leg; the difference is yours.
Two numbers decide whether that is worth the trouble, and this server returns both for every symbol:
Field | Meaning |
| The net carry if the current rates held for a year, in percent. |
| How many funding periods of edge it takes to cover the round-trip fees. |
| The same thing in days, using the two legs' intervals. |
| How much higher the short leg's mark price is, in basis points. Positive is good: you sell higher and buy lower. |
The break-even assumes four fee touches — two legs, opened and closed — at
4 × fee_bps. The default fee_bps=5.5 is a taker fee on either side; pass
your own.
Related MCP server: funding-arb
Install
pip install mcp-funding-arb-screenerOr from this repository:
git clone https://github.com/tordagaz-ops/funding-arb-screener
cd funding-arb-screener
python -m venv .venv
.venv\Scripts\activate # Windows
source .venv/bin/activate # macOS / Linux
pip install -e ".[dev]"The package needs Python 3.10+ and installs mcp and httpx. Nothing else.
Run
python -m mcp_funding_arb # stdio, for a desktop client
MCP_TRANSPORT=http python -m mcp_funding_arb # http on port 8000
MCP_TRANSPORT=sse python -m mcp_funding_arb # sse on port 8000A client configuration looks like this:
{
"mcpServers": {
"funding-arb-screener": {
"command": "python",
"args": ["-m", "mcp_funding_arb"],
"env": { "MCP_LOCALE": "en" }
}
}
}Deploy to Render (free)
The repository ships a render.yaml Blueprint, so the server runs on a public
HTTPS URL with no API key, no card and no Docker step.
Open the Render dashboard and press New -> Blueprint (https://dashboard.render.com/blueprints).
Connect GitHub and give Render access to this repository.
Select the repository and press Apply. Render reads
render.yaml: buildpip install ., startpython -m mcp_funding_arb, health check/health.When the first build finishes (2-4 minutes), open the URL Render shows:
https://funding-arb-screener.onrender.com.
That page is the human view of the server: it lists every tool. The MCP endpoint is
https://funding-arb-screener.onrender.com/mcp (Streamable HTTP), so a client entry looks like:
{"mcpServers": {"funding-arb-screener": {"url": "https://funding-arb-screener.onrender.com/mcp"}}}curl https://funding-arb-screener.onrender.com/health answers with the tool count, which is the
quickest way to prove the deployment is alive.
Free-plan notes: the instance sleeps after 15 minutes without traffic, so the next
request takes about 50 seconds; 512 MB is enough for this server. If you rename the
service or attach a domain, also update MCP_PUBLIC_HOST in render.yaml, or the
Host check answers 421.
The four tools
get_funding_rates
One symbol, every venue that lists it.
Parameter | Type | Default | Notes |
| string | — |
|
| list or string | all five |
|
| number |
| Per-leg taker fee used for break-even. |
{
"symbol": "BTC/USDT",
"venue_count": 5,
"spread": { "short_venue": "okx", "long_venue": "gate", "spread_annualized_pct": 4.37,
"breakeven_days": 18.4, "price_gap_bps": 0.67 },
"venues": [
{ "venue": "okx", "funding_rate": 8.74e-05, "funding_interval_hours": 8.0,
"annualized_pct": 9.57, "mark_price": 60816.9, "turnover_24h": 9.32e9 }
],
"failed_venues": {}
}Measured on a September evening, five venues answered BTC/USDT in 1.4
seconds — Bybit 7.42%/yr, Binance 8.73%, OKX 9.57%, Bitget 5.80%, Gate 5.20%,
for a 4.37% spread with a 0.67 bps price gap and an 18-day break-even.
scan_funding_opportunities
The whole market, or a shortlist you name.
Parameter | Type | Default | Notes |
| list or string | — | Narrow the scan to these pairs. |
| list or string | all five | Limit the fleet. |
| number |
| Drop rows below this carry. |
| number |
| Drop illiquid pairs. |
| integer |
| Rows returned, 1–50. |
| integer |
| Symbols kept after ranking by turnover, 2–200. |
| string |
|
|
Measured: 1,233 symbols in 2.5 seconds. The scan ranks every venue's whole
book by 24-hour turnover, keeps the top shortlist, then fetches funding for
just those symbols on just the venues that list them — two phases, no symbol
fan-out into the void.
get_funding_history
Was that rate real, or one crowded hour?
Parameter | Type | Default | Notes |
| string | — | |
| string |
| One venue: history is per exchange. |
| integer |
| 1–200 settlements. |
Returns the samples plus mean_rate, median_rate, stdev_rate,
positive_share, annualized_mean_pct and cumulative_pct — what you would
have paid or received over the window, and how reliable the sign is. Measured on
a 30-point Bybit window: mean 2.28e-05 per 8 h (2.50%/yr), positive 73.3% of the
time.
list_venues
Which exchanges are answering right now. probe=false returns the configured
list without touching the network — useful as a health check for your own
monitoring. probe=true (default) asks each venue for BTC/USDT and reports
latency and error code per venue.
Failure model
Every tool returns a dict. Nothing raises at the caller, and a partial answer is preferred to no answer:
{
"error": "no_data",
"message": "No exchange returned a quote for FOO/USDT.",
"failed_venues": { "bybit": "unknown_symbol", "okx": "timeout" }
}Code | Meaning |
| The symbol arrived blank. |
| Not a recognisable pair. |
| A valid pair, but no venue lists it. |
| You asked for an exchange this server does not carry. |
| Fewer than two venues: there is no spread to compute. |
| Bad argument, named. |
| A venue did not answer in 3.5 s. |
| The venue answered with an error or nonsense. |
Timeouts are per venue and per attempt: 3.5 s, two attempts, with a 1–5 s ticker cache in front. A call therefore has a ceiling of about 6 s even when everything is on fire, and partial results come back inside it.
Exchanges
Venue | Symbol form | Funding endpoint | Interval source |
Bybit |
|
|
|
Binance |
|
| 8 h, or |
OKX |
|
| derived from two settlement stamps |
Bitget |
|
| 8 h default |
Gate.io |
|
| 8 h |
Every adapter speaks the venue's own dialect: Bybit reports errors inside an HTTP 200 body, numbers arrive as strings almost everywhere, Binance returns a bare object instead of a one-element list, and Gate's market-wide ticker endpoint never answers at all — which is why Gate is queried contract by contract, four at a time, and why a whole-market scan gives it a short list rather than the universe.
About that 7,788% row
Some venues fund hourly and others every eight hours. Annualizing each leg on
its own clock is the correct way to compare who pays what per year, but it
means a 1-hour squeeze on one venue against an 8-hour rate on another can
produce a five-digit annualized figure that no one will ever collect. Read the
row, not the rank: short_interval_hours and long_interval_hours are always
returned, breakeven_days tells you how fast the edge turns into money, and
min_turnover_24h keeps the thin pairs out. Funding rates are also the most
volatile number in a perpetual; the annualized figure is a snapshot, not a
promise.
Localization
MCP_LOCALE selects the language of tool titles, descriptions, parameter
documentation and every error message:
MCP_LOCALE=es python -m mcp_funding_arb
MCP_LOCALE=ru python -m mcp_funding_arben is the default and is also what an unknown value falls back to. Symbol
names, venue names and numeric fields are never translated, so a client can
switch language mid-conversation without touching its parsing.
Tests
pytest # everything: 184 tests
pytest -m "not live" # offline only: unit + protocol, no network
pytest -m live # only the tests that talk to real exchangesThe suite has five layers, each with a job:
Unit — funding arithmetic, each venue's wire format, the scan's two-phase plumbing, all through
httpx.MockTransport. No network, no sleep.Tool level — the four tools driven through a real MCP client session, so the schema, the annotations and the JSON on the wire are checked, not just the Python.
End to end — the server started as a subprocess and spoken to in raw JSON-RPC over stdio, the way a real client does it.
Live — the five exchanges, marked so a laptop without a connection can skip them instead of failing.
Hosting —
tests/test_hosting.pytakes the port a platform assigns,/health, the landing page, and MCP over HTTP.
Free, and donations welcome
This server is free: every tool can be called without payment, registration or an API key. If it saves you time or money, you can send a donation -- it goes straight to the developer, with no platform in between.
Network | Asset | Address |
Base | USDC / ETH |
|
Ethereum | ETH |
|
Nothing in the code is gated on donations: no telemetry, no licence check, no expiring demo. The whole source is MIT-licensed.
Licence
MIT. See LICENSE.
Available Tools
4 toolsget_funding_historySummarise a pair's funding historyARead-only
Return the funding-rate history of one pair on one exchange with summary statistics: mean, median, standard deviation, share of positive periods, best and worst period, cumulative funding over the window and the annualized mean. Use it to check whether a funding edge is persistent or a single print before trusting a scan result. Example: symbol='ETH/USDT', venue='binance', points=50.
Inputs: symbol (required), venue, points. Returns: object
get_funding_ratesCompare funding rates across exchangesARead-only
Return the current perpetual funding rate for one pair on five exchanges at once, plus the arbitrage view: which venue to short and which to long, the spread per funding period, the annualized spread assuming the current rates persist, the mark-price gap between the legs and how many funding periods it takes just to repay round-trip taker fees. Also reports funding interval, next funding time, mark and index price and 24h turnover per venue. Examples: symbol='BTC/USDT'; symbol='ETHUSDT', fee_bps=4.
Inputs: symbol (required), venues, fee_bps. Returns: object
list_venuesList exchanges and check their healthARead-only
List the exchanges this server reads and, with probe=true, run a live health check that reports latency, the number of contracts seen and whether the venue supports a whole-market scan. Call it before a scan to know which venues to expect an answer from. Example: probe=true.
Inputs: probe. Returns: object
scan_funding_opportunitiesRank pairs by funding-rate spreadARead-only
Scan the perpetual market across five exchanges and rank pairs by the funding-rate difference between venues — the classic delta-neutral funding arbitrage signal. One call replaces thousands of REST requests: the server pulls whole-market snapshots in one request per exchange, shortlists the most liquid pairs, then fills in the exchanges that publish rates per instrument. Filter by annualized edge and 24h turnover to drop illiquid contracts whose rates are noise. Example: min_annualized_pct=20, min_turnover_24h=5000000, limit=15.
Inputs: sort, limit, venues, symbols, +3 more. Returns: object
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 4 tools
Each tool occupies a distinct axis: get_funding_rates is a single-pair, cross-venue snapshot with the arb view, scan_funding_opportunities is a market-wide ranked screen, get_funding_history is a per-pair/per-venue time series, and list_venues is venue metadata plus health check. Descriptions explicitly contrast them (e.g. history is framed as the persistence check on a scan result), leaving no plausible misselection.
All four names are snake_case verb_noun: get_funding_rates, scan_funding_opportunities, get_funding_history, list_venues. The verbs (get/scan/list) map predictably to the action, and nouns match the domain objects.
Four tools is well-scoped for a focused screener: one per workflow step (discover venues, scan market, inspect a pair, verify persistence), with no redundant wrappers. Nothing feels padded or missing at the tool-count level.
The surface covers the full screener workflow from venue discovery through scan, single-pair drill-down, and historical validation, with fee_bps exposed for customization. Minor gaps: no direct way to retrieve per-venue fee schedules or contract specs (fees must be supplied manually), and no batch multi-pair history call, but agents can work around both.
Maintenance
Related MCP Connectors
Perp DEX funding arbitrage, funding rates, prices and open interest across 25+ venues. Read-only.
Cross-exchange perpetual funding rate arbitrage and carry scanner across 8 crypto exchanges.
Live perp funding rates across 6 venues (Hyperliquid, Binance, Bybit, Lighter...) and arbitrage.
Read-only perp funding, OI and positioning across 4 onchain venues. Not financial advice.
Related MCP Servers
AlicenseNot gradedqualityDmaintenanceReal-time crypto spread, funding rates, and cash & carry yields across Binance and OKX for AI assistants.MIT- AlicenseNot gradedqualityDmaintenanceScans funding rate arbitrage opportunities across perpetual exchanges (Hyperliquid, Binance, Bybit, OKX) and returns cross-venue spreads and annualized yields. Uses x402 micropayments for pay-per-call access.MIT
- AlicenseNot gradedqualityDmaintenanceLive perpetual funding rates across Binance, Bybit, OKX with open interest and predicted next rate, pay-per-call via x402 micropayments (USDC on Base).MIT

app.arbitron/mcpofficial
AlicenseNot gradedqualityBmaintenanceProvides read-only crypto perpetual futures market data from Arbitron's tracked venues, including current funding rates, funding history, venue spreads, backtested spreads, and listings calendar, through MCP tools for AI assistants.2MIT