LBank Market Data API

Public market data endpoints for ticker, depth, trades, and K-line data

GitHub OpenAPI

Operations 7

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

4 of 7 operations are conformant: apis.io called them with no credentials and the responses matched this contract; 1 more answered but could not be checked against a schema. Checked 2026-11-12. how this works · status file

GET /v1/ticker.do Get 24-hour ticker data for a pair · Get 24-hour ticker data conformant #
Ask an LLM
“What is the 24-hour high, low and volume for BTC/USDT?”
“Can I get the 24-hour ticker for every trading pair at once?”
Tell an agent
Get the 24-hour ticker for {symbol}.
Show 24-hour stats for all pairs by setting symbol to {symbol}.
GET /v1/currencyPairs.do List available spot trading pairs · Get available trading pairs observed #
Ask an LLM
“Which spot trading pairs does LBank support?”
“What base and quote currencies can I trade?”
Tell an agent
List all available spot trading pairs.
Show me every spot pair on LBank.
GET /v1/depth.do Get the order book depth for a pair · Get order book depth conformant #
Ask an LLM
“What are the best bid and ask prices for ETH/BTC right now?”
“Can I get the order book depth for a pair at a specific merge level?”
Tell an agent
Get the order book depth for {symbol}.
Show {size} price levels of the {symbol} book merged at {merge}.
GET /v1/trades.do Get recent trade history for a pair · Get historical trades #
Ask an LLM
“What were the last trades on BTC/USDT?”
“Can I pull trade history for a pair starting from a given timestamp?”
Tell an agent
Get the last {size} trades for {symbol}.
Show {size} trades on {symbol} from {time} onwards.
GET /v1/kline.do Get candlestick data for a pair · Get K-line (candlestick) data #
Ask an LLM
“What were the hourly OHLCV candles for ETH/BTC yesterday?”
“Can I get daily candlesticks for a pair starting from a timestamp?”
Tell an agent
Get {size} {type} candles for {symbol} starting at {time}.
Pull {size} {type} candles for {symbol} from {time} in seconds.
GET /v1/accuracy.do Get price and quantity accuracy for pairs · Get trading pair accuracy information conformant #
Ask an LLM
“How many decimal places does each trading pair quote price and amount to?”
“What accuracy does BTC/USDT use for its price and quantity?”
Tell an agent
Show price and quantity accuracy for all trading pairs.
List the decimal precision of every spot pair.
GET /v1/usdToCny.do Get the USD to CNY exchange rate · Get USD/CNY exchange rate conformant #
Ask an LLM
“What is today's USD to CNY rate?”
“When is the USD/CNY rate updated?”
Tell an agent
Get the current USD to CNY exchange rate.
Show today's USD/CNY rate.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/lbank:lbank-market-data-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

lbank-market-data-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: LBank Spot Market REST Market Data API
  description: Public REST endpoints providing real-time and historical market data for all LBank spot trading pairs. All endpoints are unauthenticated and suitable for market data aggregators, dashboards, and trading bots.
  version: 1.0.0
  contact:
    url: https://www.lbank.com/en-US/docs/
  termsOfService: https://www.lbank.com/en-US/agreement/
servers:
- url: https://api.lbkex.com
  description: LBank REST API (primary)
- url: https://api.lbkex.net
  description: LBank REST API (secondary)
- url: https://api.lbank.info
  description: LBank REST API (tertiary)
tags:
- name: Market Data
  description: Public market data endpoints for ticker, depth, trades, and K-line data
paths:
  /v1/ticker.do:
    get:
      operationId: getMarketTicker
      summary: Get 24-hour ticker data
      description: Returns 24-hour ticker statistics for one or all trading pairs. Set symbol to 'all' to retrieve data for all pairs.
      tags:
      - Market Data
      parameters:
      - name: symbol
        in: query
        required: true
        description: Trading pair (e.g. eth_btc) or 'all' for all pairs
        schema:
          type: string
          example: eth_btc
      responses:
        '200':
          description: Ticker data for the requested symbol(s)
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/TickerResponse'
                - type: array
                  items:
                    $ref: '#/components/schemas/TickerResponseItem'
  /v1/currencyPairs.do:
    get:
      operationId: getCurrencyPairs
      summary: Get available trading pairs
      description: Returns a list of all available spot trading pairs on LBank.
      tags:
      - Market Data
      responses:
        '200':
          description: Array of available trading pair symbols
          content:
            application/json:
              schema:
                type: array
                items:
                  type: string
                example:
                - eth_btc
                - zec_btc
                - qtum_btc
  /v1/depth.do:
    get:
      operationId: getMarketDepth
      summary: Get order book depth
      description: Returns the current order book (asks and bids) for a trading pair at the specified depth.
      tags:
      - Market Data
      parameters:
      - name: symbol
        in: query
        required: true
        description: Trading pair (e.g. eth_btc)
        schema:
          type: string
          example: eth_btc
      - name: size
        in: query
        required: false
        description: Number of price levels to return (1-60, default 60)
        schema:
          type: integer
          minimum: 1
          maximum: 60
          default: 60
      - name: merge
        in: query
        required: false
        description: Depth merge precision (0 or 1, default 0)
        schema:
          type: integer
          enum:
          - 0
          - 1
          default: 0
      responses:
        '200':
          description: Order book depth data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DepthResponse'
  /v1/trades.do:
    get:
      operationId: getHistoricalTrades
      summary: Get historical trades
      description: Returns recent trade records for a trading pair. Optionally filter by start timestamp.
      tags:
      - Market Data
      parameters:
      - name: symbol
        in: query
        required: true
        description: Trading pair (e.g. eth_btc)
        schema:
          type: string
          example: eth_btc
      - name: size
        in: query
        required: true
        description: Number of records to return (1-600)
        schema:
          type: integer
          minimum: 1
          maximum: 600
      - name: time
        in: query
        required: false
        description: Start transaction timestamp (milliseconds). Returns latest records if not provided.
        schema:
          type: string
          example: '1482311600000'
      responses:
        '200':
          description: List of historical trades
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Trade'
  /v1/kline.do:
    get:
      operationId: getKlineData
      summary: Get K-line (candlestick) data
      description: Returns historical K-line (OHLCV) candlestick data for a trading pair at the specified interval.
      tags:
      - Market Data
      parameters:
      - name: symbol
        in: query
        required: true
        description: Trading pair (e.g. eth_btc)
        schema:
          type: string
          example: eth_btc
      - name: size
        in: query
        required: true
        description: Number of K-line bars to return (1-2880)
        schema:
          type: integer
          minimum: 1
          maximum: 2880
      - name: type
        in: query
        required: true
        description: K-line interval type
        schema:
          type: string
          enum:
          - minute1
          - minute5
          - minute15
          - minute30
          - hour1
          - hour4
          - hour8
          - hour12
          - day1
          - week1
          - month1
      - name: time
        in: query
        required: true
        description: Start timestamp in seconds
        schema:
          type: string
          example: '1482311600'
      responses:
        '200':
          description: Array of K-line bars. Each bar is [timestamp, open, high, low, close, volume]
          content:
            application/json:
              schema:
                type: array
                items:
                  type: array
                  items:
                    type: number
                  minItems: 6
                  maxItems: 6
                  description: '[timestamp, open, high, low, close, volume]'
  /v1/accuracy.do:
    get:
      operationId: getTradingPairInfo
      summary: Get trading pair accuracy information
      description: Returns price and quantity accuracy (decimal places) for all trading pairs.
      tags:
      - Market Data
      responses:
        '200':
          description: List of trading pair accuracy configurations
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/TradingPairAccuracy'
  /v1/usdToCny.do:
    get:
      operationId: getUsdToCnyRate
      summary: Get USD/CNY exchange rate
      description: Returns the current USD to CNY exchange rate. Updated daily at 00:00.
      tags:
      - Market Data
      responses:
        '200':
          description: USD to CNY exchange rate
          content:
            application/json:
              schema:
                type: object
                properties:
                  USD2CNY:
                    type: string
                    description: Exchange rate of USD to CNY
                    example: '6.4801'
components:
  schemas:
    TickerResponse:
      type: object
      properties:
        timestamp:
          type: string
          description: Timestamp of latest transaction (milliseconds)
        ticker:
          $ref: '#/components/schemas/TickerData'
    TickerResponseItem:
      type: object
      properties:
        symbol:
          type: string
          description: Trading pair symbol
        timestamp:
          type: string
          description: Timestamp of latest transaction (milliseconds)
        ticker:
          $ref: '#/components/schemas/TickerData'
    TickerData:
      type: object
      properties:
        change:
          type: string
          description: Price change percentage in 24 hours
        high:
          type: string
          description: Highest price in 24 hours
        latest:
          type: string
          description: Latest transaction price
        low:
          type: string
          description: Lowest price in 24 hours
        turnover:
          type: string
          description: Total turnover in 24 hours (quote currency)
        vol:
          type: string
          description: 24-hour trading volume (base currency)
    TradingPairAccuracy:
      type: object
      properties:
        symbol:
          type: string
          description: Trading pair symbol
        priceAccuracy:
          type: string
          description: Number of decimal places for price
        quantityAccuracy:
          type: string
          description: Number of decimal places for quantity
    DepthResponse:
      type: object
      properties:
        asks:
          type: array
          description: Asks (sellers) sorted by price ascending
          items:
            type: array
            items:
              type: number
            minItems: 2
            maxItems: 2
            description: '[price, quantity]'
        bids:
          type: array
          description: Bids (buyers) sorted by price descending
          items:
            type: array
            items:
              type: number
            minItems: 2
            maxItems: 2
            description: '[price, quantity]'
    Trade:
      type: object
      properties:
        date_ms:
          type: integer
          description: Transaction timestamp in milliseconds
        amount:
          type: number
          description: Transaction volume
        price:
          type: number
          description: Transaction price
        type:
          type: string
          enum:
          - buy
          - sell
          description: Trade direction
        tid:
          type: string
          description: Transaction ID