Skip to main content
The Market Data service provides real-time market information including available markets, order book depth, tickers, and recent trade executions. Most Market Data endpoints do not require authentication. Client accessor: client.MarketData

Available Methods

MethodHTTP EquivalentDescription
ListMarketsGET /trading/marketsList available trading markets
GetOrderBookGET /trading/markets/{market}/order-bookGet the order book for a market
GetTickerGET /trading/markets/{market}/tickerGet the ticker for a market
ListRecentExecutionsGET /trading/markets/{market}/recent-executionsList recent trades for a market

ListMarkets

markets, err := client.MarketData.ListMarkets(ctx)
if err != nil {
    log.Fatal(err)
}
for _, m := range markets {
    fmt.Printf("%s: %s / %s\n", m.Market, m.BaseAsset, m.QuoteAsset)
}

GetOrderBook

book, err := client.MarketData.GetOrderBook(ctx, "BTC-USD")
if err != nil {
    log.Fatal(err)
}
fmt.Printf("Best bid: %s, Best ask: %s\n", book.Bids[0].Price, book.Asks[0].Price)
For the full REST API documentation, see the Market Data API Reference.