Barfinex
Loading
All exchanges
Phemex

Phemex

Coming SoonCrypto — Derivatives
connectorType: "phemex"

High-performance crypto derivatives exchange

Connection Architecture

Phemex
WebSocket / REST
Connector
libs/exchange-phemex
Provider
:8081/api
Detector
Advisor
Studio

The connector feeds exchange data to Provider. Detector receives market data, Studio receives read views, and Advisor sees only signed candidate evidence.

Technologies

Transport
WebSocketREST
Authentication
API Key + Secret
Data Format
JSON

Best for

  • High-frequency and latency-sensitive algorithmic traders who need a low-latency matching engine.
  • Strategies combining perpetual futures with spot positions for delta-neutral or basis-trading approaches.
  • Traders diversifying execution across Bybit, OKX, and Phemex to reduce single-venue concentration risk.
  • Developers stress-testing order throughput who want an exchange built to institutional engineering standards.

Connect via code

1Environment variables (.env)

PHEMEX_API_KEY=your_key_here
PHEMEX_API_SECRET=your_secret_here

2Connector configuration

// config/config.provider.json
{
  "provider": {
    "connectors": [
      {
        "connectorType": "phemex",
        "enabled": true,
        "key": "${PHEMEX_API_KEY}",
        "secret": "${PHEMEX_API_SECRET}",
        "markets": [
          { "marketType": "spot", "symbols": [{ "name": "BTCUSDT" }] }
        ],
        "subscriptions": [
          { "type": "PROVIDER_MARKETDATA_CANDLE", "symbols": ["BTCUSDT"], "intervals": ["min1", "h1"], "active": true },
          { "type": "PROVIDER_MARKETDATA_TRADE", "symbols": ["BTCUSDT"], "active": true },
          { "type": "PROVIDER_MARKETDATA_ORDERBOOK", "symbols": ["BTCUSDT"], "active": true }
        ]
      }
    ]
  }
}

3Verify and query data

Public verification
1. Configure credentials in the private Provider environment.
2. Verify connector status in the internal Studio/Provider console.
3. Use Barfinex public pages to inspect market data.

Operator Provider commands and tokens remain in internal runbooks only.

Available via Barfinex API

/api/candles/phemex/...
/api/trades/phemex/...
/api/orderbook/phemex/...
/api/account/phemex/...
/api/symbols/phemex/...
/api/assets/phemex/...

Studio graphical setup — in development, coming in the next release.

Important

Phemex uses separate API key permissions for trading, read-only data, and withdrawals — create a trading-only key to limit exposure.
Perpetual contract symbols on Phemex use an uppercase format (e.g., BTCUSD for inverse, BTCUSDT for linear) — confirm the symbol convention before configuring subscriptions.
The testnet environment is available at testnet.phemex.com with separate credentials; use it to validate your strategy configuration before going live.
Rate limits differ between REST and WebSocket endpoints; real-time data streaming via WebSocket is preferred for order-book subscriptions.
Supported Markets
SpotFutures
Connect in Studio(soon)
Exchange Website

Let’s Get in Touch

Have questions or want to explore Barfinex? Send us a message.