Skip to main content

Concepts

Key concepts and terminology used in Cadenza.

Venue

A venue represents a cryptocurrency exchange (e.g., Binance, OKX, Bybit). Each venue has its own:

  • Trading pairs and instruments
  • API rate limits
  • Order types supported
  • Fee structures
BINANCE, OKX, BYBIT

Instrument

An instrument represents a tradeable asset pair on a specific venue. Instruments are identified by a composite ID:

{VENUE}:{SYMBOL}

Examples:

  • BINANCE:BTC/USDT - Bitcoin/USDT on Binance
  • OKX:ETH/USDT - Ethereum/USDT on OKX

Instrument Properties

PropertyDescription
instrumentIdUnique identifier (VENUE:SYMBOL)
venueExchange name
symbolTrading pair (e.g., BTC/USDT)
baseAssetBase currency (e.g., BTC)
quoteAssetQuote currency (e.g., USDT)
statusTrading status (active/inactive)

Trading Account

A trading account represents your connected exchange account with API credentials. You can have multiple trading accounts per venue (e.g., different Binance sub-accounts).

Trading Account Properties

PropertyDescription
tradingAccountIdUnique identifier (UUID)
venueExchange name
statusConnection status
createdAtWhen the account was connected

Trade Order

A trade order represents a buy or sell order submitted through Cadenza.

Order Properties

PropertyDescription
tradeOrderIdUnique identifier (UUID)
tradingAccountIdAssociated trading account
instrumentIdTrading pair
orderSideBUY or SELL
orderTypeLIMIT or MARKET
quantityOrder size
limitPricePrice for limit orders
statusOrder status

Order Status Flow

PENDING → OPEN → FILLED
↘ PARTIALLY_FILLED → FILLED
↘ CANCELLED
→ REJECTED
StatusDescription
PENDINGOrder submitted, awaiting exchange confirmation
OPENOrder active on exchange order book
PARTIALLY_FILLEDOrder partially executed
FILLEDOrder fully executed
CANCELLEDOrder cancelled by user or system
REJECTEDOrder rejected by exchange

Portfolio

A portfolio represents the asset balances in a trading account.

Portfolio Properties

PropertyDescription
assetAsset symbol (e.g., BTC, USDT)
freeAvailable balance for trading
lockedBalance locked in open orders
totalTotal balance (free + locked)

Order Book

An order book shows the current buy (bid) and sell (ask) orders for an instrument.

PropertyDescription
bidsBuy orders sorted by price (highest first)
asksSell orders sorted by price (lowest first)
timestampOrder book snapshot time

Each level contains:

  • price - Order price
  • quantity - Order size at this price

Credential

A credential represents exchange API keys stored securely in Cadenza.

PropertyDescription
credentialIdUnique identifier
venueExchange name
apiKeyPublic API key (partially masked)
statusCredential status

API secrets are encrypted and never returned in API responses.