# dYdX Agent Gateway (pypi · dydx-agent-gateway)

Analytics-only MCP gateway to dYdX v4: auditable trader PnL, funding and OI detectors. No keys.

- Trust score: 82/100 (high trust)
- Change this week: +14
- Registry status: active
- Liveness: live
- Owner verified: no
- Last scored: 2026-10-01

## Components

- pypi · `dydx-agent-gateway`: 82/100 (this document), [markdown](https://verifymcp.io/servers/alekskram-dydx-agent-gateway/dydx-agent-gateway.md), [page](https://verifymcp.io/servers/alekskram-dydx-agent-gateway/dydx-agent-gateway)

## Channel facts

- Registry: `pypi`
- Package: `dydx-agent-gateway`
- Version: `0.3.2`
- Transport: `stdio`

## Trust breakdown

How this component scores in each security and reliability category. Every signal is checked automatically from public evidence about the published package, including repeated runs of it in an isolated sandbox, and we only credit what we can confirm. Scores are 0–100 per category. Scoring method: https://verifymcp.io/docs/scoring (what has changed: https://verifymcp.io/docs/scoring/changelog)

Scored 2026-10-01.

- **Supply Chain Security**: 100/100
  - No malware found by supply-chain analysis.
  - A known CVE affects ecdsa, but no fixed version has been published, so there is nothing to upgrade to.
  - Runs hatchling.build at install time, a recognised build step with no custom scripting around it.
  - 1 of 18 dependencies flagged as unhealthy.
- **Provenance & Transparency**: 97/100
  - Source repository is publicly reachable at the declared URL.
  - Cryptographically verified build provenance (signed, bound to alekskram/dydx-agent-gateway).
  - Clear OSI-approved license (MIT).
  - Actively maintained (last published 8 days ago).
  - Disclosure check failed: no security disclosure policy was found in the source repository.
- **Schema Quality & AI Usability**: 70/100
  - AI-judged instruction clarity (excellent).
  - Context-footprint check failed: tool/resource definitions use about 3613 tokens (~164/item across 22 items; 22 tools + 0 resources), over budget; trim descriptions and params.
  - Usage-examples check failed: none of the tools include examples.
- **Stability & Change Management**: 30/100
  - Stability observed for 9 of 30 days with no destabilising changes; credit accrues until the full window elapses.
- **Tool Coverage**: 71/100
  - 100% of tools have a non-trivial description (not blank, and not just the tool's name).
  - 0% of tool parameters carry a description.
  - Structured output schemas are declared (91% of tools); any adoption earns full credit.
- **Tool Safety**: 100/100
  - No prompt-injection markers were found in the server instructions, tool names or descriptions we captured.
  - We read all 22 captured tool definition(s), and no name or description among them implies an irreversible operation.
  - An AI judge read all 23 captured unit(s) of tool text and found none that tries to manipulate the model reading it.
- **Capabilities**: 100/100
  - Implements a current MCP spec version (2026-07-28).

## Install

### How do I install the dYdX Agent Gateway MCP server?

dYdX Agent Gateway runs locally as a PyPI package, launched with uvx dydx-agent-gateway. Ready-made configuration for Claude, Cursor, VS Code, Codex and 5 more is on this page, copied from each client's own documentation.

### Claude

```bash
claude mcp add alekskram-dydx-agent-gateway -- uvx dydx-agent-gateway
```

### Cursor

```json
{
  "mcpServers": {
    "alekskram-dydx-agent-gateway": {
      "command": "uvx",
      "args": [
        "dydx-agent-gateway"
      ]
    }
  }
}
```

### VS Code

```json
{
  "servers": {
    "alekskram-dydx-agent-gateway": {
      "command": "uvx",
      "args": [
        "dydx-agent-gateway"
      ]
    }
  }
}
```

### Codex

```bash
codex mcp add alekskram-dydx-agent-gateway -- uvx dydx-agent-gateway
```

### opencode

```json
{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "alekskram-dydx-agent-gateway": {
      "type": "local",
      "command": [
        "uvx",
        "dydx-agent-gateway"
      ],
      "enabled": true
    }
  }
}
```

### OpenClaw

```bash
openclaw mcp add alekskram-dydx-agent-gateway --command uvx --arg dydx-agent-gateway
```

### Hermes

```yaml
mcp_servers:
  alekskram-dydx-agent-gateway:
    command: "uvx"
    args: ["dydx-agent-gateway"]
```

### Netclaw

```json
{
  "McpServers": {
    "alekskram-dydx-agent-gateway": {
      "Transport": "stdio",
      "Command": "uvx",
      "Arguments": [
        "dydx-agent-gateway"
      ]
    }
  }
}
```

### Vellum

```bash
assistant mcp add alekskram-dydx-agent-gateway -t stdio -c uvx -a dydx-agent-gateway
```

### Other

```json
{
  "mcpServers": {
    "alekskram-dydx-agent-gateway": {
      "command": "uvx",
      "args": [
        "dydx-agent-gateway"
      ]
    }
  }
}
```

## Changelog

Every change recorded for this component, newest first. Days that predate change tracking, or that we cannot explain, say so: "we were watching and nothing happened" and "we were not watching" are different claims.

### 2026-10-01 (score 82, +1)

No change was recorded against any check on this day. Stability & Change Management went from 27 to 30. That category is still filling its 30-day observation window: 8 days of observed history at the previous scan, 9 at this one. The score rises as the window fills, whether or not the server changes.

### 2026-09-29 (score 81, +11)

- [security improvement] Provenance: unverified → pass
- [security] The attested source repository moved: alekskram/dydx-agent-gateway

### 2026-09-28 (score 70, 0)

- [functional] We updated how we score, so this day's move reflects our rubric, not a change to the server

### 2026-09-27 (score 70, +1)

No change was recorded against any check on this day. Stability & Change Management went from 13 to 17. That category is still filling its 30-day observation window: 4 days of observed history at the previous scan, 5 at this one. The score rises as the window fills, whether or not the server changes.

### 2026-09-25 (score 69, +1)

- [functional] We updated how we score, so this day's move reflects our rubric, not a change to the server

### 2026-09-23 (score 68, +1)

- [security regression] Tool safety: pass → unverified
- [security] Stability: Stability not yet verified: we do not have a sandbox capture of the MCP schema this version of the package serves yet.
- [functional regression] Capabilities: pass → unverified
- [functional regression] Tool coverage: 100 → unverified
- [functional improvement] Stability: unverified → 0.03
- [functional] First check of Schema quality: unverified
- [functional] Package version: 0.3.1 → 0.3.2

### 2026-09-22 (score 67)

First indexed and scored.

## MCP tools (22)

### `list_markets` (~168 tokens)

List Markets

All dYdX v4 perpetual markets: oracle price, 24h volume, open interest,
next funding rate. Sorted by 24h USD volume by default (or 'oi').
Each row: ticker, oraclePrice, volume24h_USD, openInterest_USD
(size x oracle price) and nextFundingRate_pct_1h (pct per hour).
Returns {"count_total", "count", "offset", "has_more", "next_offset",
"markets", "summary"}; only ACTIVE markets — delisted/settled ones are
excluded. Page with offset when has_more is true.
Example: list_markets(limit=20, sort="volume")

Input parameters:

- `limit` (integer)
- `offset` (integer)
- `sort` (string)

### `market_detail` (~179 tokens)

Market Detail

One perpetual market in depth: prices, 24h stats computed from candles
(the raw API priceChange field is unreliable), OI, funding.
Returns oraclePrice, openInterest, nextFundingRate_pct_1h (pct/hour),
volume24h_USD, change24h_pct_from_candles (24h pct change, computed
from 25 x 1h candles), trades24h, basis_pct (mark-vs-oracle deviation
in pct: (last candle close - oraclePrice) / oraclePrice x 100), and
the latest three 1h candles (t/open/close/usdVolume). An unknown or
delisted ticker raises an error (MCP isError) — settled markets are
not served.
Example: market_detail(ticker="BTC-USD")

Input parameters:

- `ticker` (string, required)

### `candles` (~145 tokens)

Candles

OHLCV candles with open interest for a market.
resolution: 1MIN|5MIN|15MIN|30MIN|1HOUR|4HOURS|1DAY.
Each candle: startedAt, open/high/low/close (price), baseTokenVolume
(base-coin size), usdVolume (USD), startingOpenInterest. Rows are
ordered oldest -> newest (the
indexer sends newest-first; we normalize). limit is capped at 1000.
Example: candles(ticker="ETH-USD", resolution="1HOUR", limit=100)

Input parameters:

- `limit` (integer)
- `resolution` (string)
- `ticker` (string, required)

### `recent_trades` (~76 tokens)

Recent Trades

Latest public trades of a market (price, side, size, type, time).
Newest first; limit capped at 100. side is BUY/SELL, size in base coin.
Example: recent_trades(ticker="BTC-USD", limit=30)

Input parameters:

- `limit` (integer)
- `ticker` (string, required)

### `trader_profile` (~144 tokens)

Trader Profile

Snapshot of any trader's subaccount: equity, open positions, and PnL
curve statistics (all-time window from up to 1000 history points).
Returns equity_now / totalPnl_now / totalPnl_delta_window (USD),
window_start / window_end, and open_positions (market, side, size,
entry, unrealizedPnl in USD). Pair with trader_pnl_stats for deeper
statistics.
Example: trader_profile(address="dydx1m9hg73dtn5ku8ulmj8rjmdqh0hk7uuhawc69cn")

Input parameters:

- `address` (string, required)
- `subaccount` (integer)

### `height` (~41 tokens)

Height

Current dYdX chain height and time — use for liveness checks.
Returns {"height": current block number, "time": block timestamp}.
Example: height()

### `funding_heatmap` (~203 tokens)

Funding Heatmap

All markets ranked by |next funding rate| (1h, annualized). Shows which
sides pay: positive = longs pay shorts. Rows carry OI so agents can
ignore micro-markets; raise min_oi_usd to filter noise.
Each row: ticker, funding_pct_1h (pct per hour), funding_pct_annualized
(1h rate x 24 x 365), oi_usd, oraclePrice, and exactly one of
longs_pay / shorts_pay = True. Zero-rate markets and markets below
min_oi_usd are skipped. Returns {"count_nonzero", "top", "summary",
"offset", "has_more"} — page with offset when has_more is true.
Example: funding_heatmap(limit=15, min_oi_usd=100000.0)

Input parameters:

- `limit` (integer)
- `min_oi_usd` (number)
- `offset` (integer)

### `market_ta` (~284 tokens)

Market Ta

Technical snapshot computed from dYdX candles: RSI(14), EMA20/EMA50
trend, ATR(14) volatility, Bollinger(20,2) position, MACD(12,26,9),
VWAP(20) and annualized realized vol. Pure local math — no external
TA library.
Key fields: price, trend_ema20_50 ("up"/"down"), rsi14 (0-100) and
rsi_zone (overbought >70 / oversold <30 / neutral), atr14 (absolute)
and atr_pct_of_price (pct), bollinger_pctB (0 = lower band, 1 = upper
band), macd_line/signal_line/macd_hist (classic 12/26/9; hist > 0 =
bullish momentum), vwap_20 (volume-weighted average price over the
last 20 candles: typical price (H+L+C)/3 weighted by usdVolume) and
realized_vol_annualized_pct (population std of log returns x
sqrt(candles-per-year), scaled by resolution). Needs >=55 candles;
returns {"error": ...} for thin markets.
Example: market_ta(ticker="BTC-USD", resolution="1HOUR")

Input parameters:

- `resolution` (string)
- `ticker` (string, required)

### `suggest_stops` (~216 tokens)

Suggest Stops

ATR-based risk plan: stop-loss, take-profit, breakeven trigger and
trailing level for a long/short entry. Agent-managed position helper.
Unknown ticker (no oracle price) raises an error (MCP isError);
returns {"error": ...} when no ATR is available (thin market).
All output prices are in market price units: stop_loss / take_profit
sit atr_mult_sl / atr_mult_tp x ATR(14) from entry (entry defaults to
the current oracle price); breakeven_after is the price at +1 ATR in
profit (then move SL to entry and trail by 1 ATR); risk_reward =
TP distance / SL distance.
Example: suggest_stops(ticker="BTC-USD", side="LONG", atr_mult_sl=1.5)

Input parameters:

- `atr_mult_sl` (number)
- `atr_mult_tp` (number)
- `entry`
- `resolution` (string)
- `side` (string, required)
- `ticker` (string, required)

### `fills_review` (~166 tokens)

Fills Review

Execution review from the latest fills: maker/taker split, per-market
distribution, traded volume, avg fill size. (Per-fill PnL is not exposed
by the indexer; use trader_pnl_stats for win-rate.)
Key fields: fills_sampled (count), maker_share_pct (0-100),
sampled_volume_USD, avg_fill_USD, top_markets (top 5 by fill count).
Returns {"summary": "no fills"} for accounts with no fills.
Example: fills_review(address="dydx1m9hg73dtn5ku8ulmj8rjmdqh0hk7uuhawc69cn")

Input parameters:

- `address` (string, required)
- `limit` (integer)
- `subaccount` (integer)

### `historical_funding` (~155 tokens)

Historical Funding

Raw 1h funding rate history of a market (as realized, not the
next-rate preview in market_detail): each point is the rate actually
paid that hour; annualized_pct = rate x 24 x 365 for scale. Default
168 points = 7 days. Points are ordered oldest -> newest (candles
convention); limit capped at 500.
Positive = longs paid shorts. An unknown or delisted ticker raises an
error (MCP isError) — call list_markets for the valid set (format:
'ETH-USD').
Example: historical_funding(ticker="ETH-USD", limit=168)

Input parameters:

- `limit` (integer)
- `ticker` (string, required)

### `raw_fills` (~186 tokens)

Raw Fills

Raw execution tape for a subaccount — every field the indexer
gives, unchanged — for agents doing their own execution-quality
math (the aggregated view lives in fills_review). Each fill: t
(createdAt), market, side, liquidity (MAKER/TAKER), type, price,
size (base coin), usd_notional (price x size), fee, and the
position context (positionSideBefore / positionSizeBefore /
entryPriceBefore). Newest first; limit capped at 1000. Addresses
come from discover_traders / leaderboard / list_traders.
Example: raw_fills(address="dydx1m9hg73dtn5ku8ulmj8rjmdqh0hk7uuhawc69cn")

Input parameters:

- `address` (string, required)
- `limit` (integer)
- `subaccount` (integer)

### `cvd` (~175 tokens)

Cvd

Cumulative Volume Delta from the latest public trades: running
sum of +size on BUY / -size on SELL, oldest -> newest within the
sample. Rising CVD = aggressive buying dominating. Volumes are in
the base coin. Returns cvd_final (net aggressive flow),
buy_volume / sell_volume, trade window bounds (t_first / t_last),
trades_sampled and cvd_series_last (the last 50 running values —
full series stays out of the response to keep it compact).
An unknown or delisted ticker raises an error (MCP isError) — call
list_markets for the valid set (format: 'ETH-USD').
Example: cvd(ticker="BTC-USD", trades_limit=500)

Input parameters:

- `ticker` (string, required)
- `trades_limit` (integer)

### `correlation` (~172 tokens)

Correlation

Pearson correlation of two markets' log returns over candles:
r in [-1, 1] plus beta(a|b) — the sensitivity of a to b (a moves
beta x b's move, both in log space). Candle series are JOINED by
startedAt (only candles with the same timestamp on both sides are
compared), so partially-overlapping histories pair correctly.
Both tickers are validated; call list_markets for the valid set
(format: 'ETH-USD'). Returns {"error": ...} when there is
insufficient or constant data.
Example: correlation(ticker_a="BTC-USD", ticker_b="ETH-USD")

Input parameters:

- `limit` (integer)
- `resolution` (string)
- `ticker_a` (string, required)
- `ticker_b` (string, required)

### `trader_pnl_stats` (~300 tokens)

Trader Pnl Stats

Deep PnL statistics from the equity curve: daily PnL, day-winrate,
max drawdown (deposit-adjusted), Sharpe-like daily ratio, and the
data-accuracy reconciliation residual (phantom-PnL detector).
NOTE: pass limit as keyword: trader_pnl_stats(addr, limit=500),
NOT positionally (second positional arg is subaccountNumber).
Key fields: day_winrate_pct (0-100), max_drawdown_pct (pct, net of
    deposits/withdrawals) with max_drawdown_usd (same drawdown in USD)
    and dd_pct_unreliable (true when the deposit-adjusted peak at the
    worst drawdown was near zero — trust the USD figure then),
    avg_daily_pnl / best_day / worst_day (USD per
UTC day), sharpe_like_daily, identity_max_residual_usd (expect < $1
on clean data). limit: history depth in points — 1000 ≈ 42 days
(default, fast), 5000 ≈ 7 months (slower, multi-page fetch).
Example: trader_pnl_stats(address="dydx1m9hg73dtn5ku8ulmj8rjmdqh0hk7uuhawc69cn", limit=5000)

Input parameters:

- `address` (string, required)
- `limit` (integer)
- `subaccount` (integer)

### `registry_stats` (~104 tokens)

Registry Stats

Live stats of our on-chain address registry (block scanner):
how many active addresses collected, scan height, freshness.
Returns addresses_total, scanned_up_to_height (last ingested dYdX
block), seen_last_24h (addresses seen in the last 24h) and the sqlite
path. On hosts where the optional scanner has not run, returns a
note instead — market/trader tools still work via the public indexer.
Example: registry_stats()

### `list_traders` (~145 tokens)

List Traders

Recently active trader addresses from the block-scanner registry
(high-frequency validator committers filtered out by max_hits).
Each row: address, hits (chain appearances), first_seen / last_seen,
last_height. Returns {"total", "count", "offset", "has_more",
"next_offset", "traders"}; traders == [] when the registry is not
built on this host. Page with offset when has_more is true.
Feed an address into trader_profile / trader_pnl_stats next.
Example: list_traders(limit=10, max_hits=100)

Input parameters:

- `limit` (integer)
- `max_hits` (integer)
- `offset` (integer)

### `discover_traders` (~95 tokens)

Discover Traders

Screener: funded, recently active traders discovered from the chain —
registry candidates probed for live equity. Start here, then analyze
each with trader_profile. Each row: address, equity (USD, >=
min_equity), registry_hits, last_seen.
Example: discover_traders(limit=5, min_equity=100.0)

Input parameters:

- `limit` (integer)
- `min_equity` (number)

Output parameters:

- `result` (array)

### `leaderboard` (~157 tokens)

Leaderboard

Verified trader leaderboard from our registry + PnL engine
(batch-computed). metric: pnl_window | pnl_total | equity | day_winrate.
Farmer flags mark likely rewards-farming bots (heuristic v0).
Each row (USD where monetary): address, equity, pnl_total, pnl_window,
day_winrate (pct 0-100), max_dd (pct), maker_share, avg_fill,
farmer_flag (bool), identity_residual. Requires a batch run — otherwise
returns {"error": "no leaderboard run yet — run leaderboard.py first"}.
Example: leaderboard(limit=20, metric="pnl_window")

Input parameters:

- `limit` (integer)
- `metric` (string)
- `offset` (integer)

### `latest_events` (~127 tokens)

Latest Events

Latest anomaly events from our detectors: funding_extreme,
oi_spike_no_price, equity_jump, liq_cascade_signature. Each row: ts,
kind, subject (ticker or address) and payload (dict of detector
numbers). Optional kind filter; offset pages past the newest slice
(events are pruned at 5000 — offset+limit beyond that returns []).
Subscribe via webhooks/Telegram (alerts).
Example: latest_events(limit=20, kind="funding_extreme")

Input parameters:

- `kind`
- `limit` (integer)
- `offset` (integer)

Output parameters:

- `result` (array)

### `market_digest` (~104 tokens)

Market Digest

One-call market briefing: latest detector events + funding extremes
(liquid markets only) + verified leaderboard top. The daily briefing
an agent (or human) needs before anything else.
Returns: events (up to 5, payload flattened into each row), funding
(top-5 funding rows, markets with >= $100k OI) and leaderboard_top
(top-3 by pnl_window: address, pnl_window, equity, day_winrate).
Example: market_digest()

### `usage_stats` (~58 tokens)

Usage Stats

Tool-call counters since deployment (traction/uptime metrics).
Returns calls_total, calls_24h, calls_7d and top_tools (top-5
(tool, count) pairs) recorded by this gateway instance.
Example: usage_stats()

## Diagnostics

Captured diagnostic sections: Provenance, Install scripts, Vulnerabilities, Dependencies. The full working is on the page: https://verifymcp.io/servers/alekskram-dydx-agent-gateway/dydx-agent-gateway#diagnostics

## Score history

- 2026-10-01: 82
- 2026-09-30: 81
- 2026-09-29: 81
- 2026-09-28: 70
- 2026-09-27: 70
- 2026-09-26: 69
- 2026-09-25: 69
- 2026-09-24: 68
- 2026-09-23: 68
- 2026-09-22: 67

## Common questions

### What is the dYdX Agent Gateway MCP server?

dYdX Agent Gateway is an MCP server listed in the public MCP registry as io.github.alekskram/dydx-agent-gateway. Analytics-only MCP gateway to dYdX v4: auditable trader PnL, funding and OI detectors. No keys. This page covers its PyPI package (dydx-agent-gateway).

### Is the dYdX Agent Gateway MCP server safe to use?

dYdX Agent Gateway scores 82 out of 100 on VerifyMCP. We recorded 2 known advisories against it as of 1 October 2026. Its build provenance is signed and verified. That is a record of what we were able to check automatically, not an endorsement. The category breakdown on this page shows every signal behind the number, including the ones we could not confirm.

### What tools does the dYdX Agent Gateway MCP server expose?

dYdX Agent Gateway exposes 22 tools: list_markets, market_detail, candles, recent_trades, trader_profile, and 17 more. Their descriptions and schemas cost roughly 3,400 tokens of context every time the server is loaded.

### Is the dYdX Agent Gateway MCP server still maintained?

dYdX Agent Gateway is still listed as active in the MCP registry. We last reached this channel on 1 October 2026. Those dates come from our own scans of the registry and the channel itself, not from anything the publisher announced.

### What licence is the dYdX Agent Gateway MCP server under?

dYdX Agent Gateway declares the MIT licence, which is OSI-approved. That covers the source only, and says nothing about the cost of any service it calls.

## Links

- PyPI project: https://pypi.org/project/dydx-agent-gateway/
- Socket report: https://socket.dev/pypi/package/dydx-agent-gateway
- Repository: https://github.com/alekskram/dydx-agent-gateway
- Changelog RSS feed: https://verifymcp.io/servers/alekskram-dydx-agent-gateway/dydx-agent-gateway.xml
- Changelog JSON feed: https://verifymcp.io/servers/alekskram-dydx-agent-gateway/dydx-agent-gateway.json
- HTML version of this page: https://verifymcp.io/servers/alekskram-dydx-agent-gateway/dydx-agent-gateway
