Genesis Arbitrage

Genesis Arbitrage · · 9 min read

What a crypto API is and what you can automate

In short

  • A crypto API is a programming interface your program uses to request market data and get a JSON response: the same spread you see in a site table, delivered as exchange_buy, exchange_sell and spread_pct fields.
  • An exchange API covers the data and account of one venue, a market data API merges many exchanges into one format, and an on-chain API reads the blockchain. Genesis API is a read-only market data API.
  • With an API, traders automate spread, funding and open interest monitoring, alerts, a signal log, dashboards and historical research.
  • Without experience, keep trade execution and withdrawals manual: data snapshots lag the exchange, and a bug in your code repeats on every cycle.

A crypto API is a programming interface your code uses to request crypto market data and get back an answer it can work with: prices, spreads between exchanges, funding rates, open interest. A person reads these numbers in a table; a program receives them as JSON fields and can compare them with a threshold, log them or send an alert right away. The general definition is in the glossary entry API.

Request and response

Working with an API is an exchange of two messages: your program sends a request to an address, and the server sends back a response. The shortest example is the Genesis API status check, which needs no key:

curl "https://api.genesisarbitrage.com/health"
{"ok":true}

curl is a command-line program for HTTP requests; curl --version tells you whether it is installed. Data requests need an API key, a string the server uses to identify your account and plan. An illustrative example: Spot – Spot pairs for the FUEL coin, with the key taken from the GENESIS_API_KEY environment variable:

URL="https://api.genesisarbitrage.com/v1/arbitrage/spot-spot"
curl "$URL?coin=FUEL" -H "X-API-Key: $GENESIS_API_KEY"
{
  "success": true,
  "data": [
    {
      "coin": "FUEL",
      "exchange_buy": "ByBit",
      "exchange_sell": "Gate",
      "price_buy": 0.0007029,
      "price_sell": 0.0007037,
      "spread_pct": 0.11,
      "withdraw_enabled_buy": true,
      "deposit_enabled_sell": true,
      …
    }
  ],
  "meta": {
    "count": 1,
    "updated_at": 1794675861,
    "freshness_sec": 60,
    "plan": "trial"
  }
}

The response holds one pair: buy FUEL on ByBit at 0.0007029 and sell it on Gate at 0.0007037. The spread is already computed in spread_pct: (0.0007037 − 0.0007029) / 0.0007029 × 100 ≈ 0.11%. The withdraw_enabled_buy and deposit_enabled_sell flags show that withdrawals from ByBit and deposits to Gate are open, and meta.updated_at tells you when the snapshot was built. The Spot – Spot table shows the same numbers, and every field is described in the Spot — Spot section of the docs.

The request address is built from a base URL, an endpoint path and parameters, while the key travels separately in the X-API-Key header. Lesson 2 takes each part of the request apart, covers status codes and reading JSON, and shows how to set the key variable.

This kind of exchange, a request followed by a response with a data snapshot, is called a REST API. You get new data by sending the request again: Genesis API refreshes its output every meta.freshness_sec seconds, from 60 on Trial down to 5 on Max. Exchanges also offer a second channel, WebSocket: the connection stays open and the server pushes trades and order book changes as they happen, as in Binance streams. Genesis API has no WebSocket.

Types of crypto APIs

Crypto APIs differ in where the data comes from and what you can do through them:

A comparison of six API types, REST versus WebSocket and a nine-point selection checklist are in the overview crypto API types and how to choose one.

What a trader can automate

Automate what you repeat by a fixed rule: open a table, compare a number with a threshold, write down the result. A program does this on a schedule and does not skip the night hours.

TaskWhat the program doesGenesis API data
Spread monitoringPairs above a threshold with open deposits and withdrawals/arbitrage/spot-spot, /arbitrage/spot-futures
FundingCompares exchange rates normalized to 8 hours/funding/rates, /funding/spread
Open interestCatches sharp OI changes over 5 minutes to 1 hour/market/open-interest
AlertsMessages you in Telegram when a condition is metAny data endpoint
LogSaves every pair it finds with a timestampThe response and meta.updated_at
DashboardShows your columns and thresholds on your own pageRequests from your server
Historical researchLooks for patterns in past data/funding/analytics/daily (Pro, Max)

Alerts are a common first project: the program polls an endpoint no more often than meta.freshness_sec and messages you when a spread or rate crosses your threshold. Without code, similar signals come from the Genesis Arbitrage Telegram Alerts on the site's Pro plan.

A log tests an idea before any money is at stake. An illustrative example: a bot records pairs with a spread of 1% or more every 30 seconds, which is 86,400 / 30 = 2,880 snapshots a day. They show how many pairs lasted longer than a minute and how many were gone by the next poll.

For history, Genesis API offers funding analytics, up to a year of daily settled-funding sums across 13 exchanges, and order book slippage history; both are on the Pro and Max plans. Genesis API has no historical candles: exchange APIs serve those, on Binance through GET /api/v3/klines with up to 1,000 candles per request (Binance docs). Your program builds the history of cross-exchange spreads itself, from the snapshots in its log.

What not to automate without experience

Two operations are costly when they go wrong: trade execution and withdrawals.

Trade execution

A bot that places orders through an exchange trading API makes mistakes as often as it runs: a bug in the entry condition with polling every 10 seconds produces 3,600 / 10 = 360 orders an hour. The data lags too: a Genesis API snapshot refreshes every 60 to 5 seconds depending on the plan, order books lag the exchange by 5–20 seconds, and the spread can close in that time. Genesis API does not place orders: it finds the pairs, and you open the trade on the exchange yourself.

Withdrawals

An exchange key with withdrawal permission allows anyone who gets hold of it to move funds off the account, so a leak of such a key can cost the whole balance. Bots that read data or trade do not need this permission. On Binance, a new API key cannot even trade by default: trading permission is enabled separately.

Site, exchange APIs or Genesis API

TaskBetter fitWhy
Browse pairs and chartsGenesis Arbitrage siteTables and filters, no code
Signals without programmingTelegram Alerts on the siteThresholds set in the interface
Your own rules across 20+ exchangesGenesis APISpreads computed, one format
Orders, balances, withdrawalsExchange APIOnly the exchange accepts orders
Every trade in real timeExchange WebSocketGenesis API serves snapshots every 60–5 s
Past candlesExchange APIGenesis API has no candles
Funding history across 13 exchangesGenesis API, Pro and MaxUp to a year of daily sums, one format

A practical setup to start with: Genesis API finds a pair, your bot sends an alert, and you check the exchange order book and open the trade yourself. Genesis API plans run from Trial at $20 a month (500K calls, 60 s freshness) to Max at $200 (10M calls, 5 s), and there is no free plan. Compare them on the Genesis API pricing page.

What you will need for the rest of the course

The lessons build on each other:

Try it yourself

  1. Send a request without a key

    Run curl "https://api.genesisarbitrage.com/health" in a terminal. The {"ok":true} response means the request arrived and the server answered in JSON.

  2. Match the table to the fields

    Open the Spot – Spot table and the Spot — Spot docs section. Find the fields for exchanges, prices, spread and transfer status: exchange_buy, price_sell, spread_pct, withdraw_enabled_buy.

  3. List your routine tasks

    Take three things you do every day and mark each one using the table above: site, Genesis API or exchange API.

  4. Find the endpoint for one task

    For a Genesis API task, find the endpoint in the documentation and write down the parameters you need, such as coin and min_spread. You will send that request in lesson 2.