Trading Data

Documentation on interacting with a variety of OKX's Trading Data API functions through the PENDAX JavaScript SDK.

The API endpoints of Trading Data do not require authentication.

Trading Data

Get Support Coin

Please refer to the official OKX API Docs for the required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-support-coin

Function name:

getSupportCoin()

Usage:

import { createExchange } from "./exchanges/exchange.js";

  let myOkxAccount = createExchange({
      exchange: "okx",
      authenticate: "true",
      key: "myKeys",
      secret: "mySecret",
      passphrase: "myPassphrase",
      label: "okx",
      marginType: "usdt"
});

async function getSupportCoin(exchange) {
    try {
        let result = await exchange.getSupportCoin();
        console.log(result);
    } catch (error) {
        console.log(error.message);
    }
}

const result = await getSupportCoin(myOkxAccount)

Get Taker Volume

Please refer to the official OKX API Docs for required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-taker-volume

Function name:

Usage:

Get Margin Lending Ratio

Please refer to the official OKX API Docs for required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-margin-lending-ratio

Function name:

Usage:

Get Long/Short Ratio

Please refer to the official OKX API Docs for required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-long-short-ratio

Function name:

Usage:

Get Contracts Open Interest and Volume

Please refer to the official OKX API Docs for required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-contracts-open-interest-and-volume

Function name:

Usage:

Get Options Open Interest and Volume

Please refer to the official OKX API Docs for required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-options-open-interest-and-volume

Function name:

Usage:

Get Put/Call Ratio

Please refer to the official OKX API Docs for required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-put-call-ratio

Function name:

Usage:

Get Open Interest and Volume (expiry)

Please refer to the official OKX API Docs for required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-open-interest-and-volume-expiry

Function name:

Usage:

Get Open Interest and Volume (strike)

Please refer to the official OKX API Docs for required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-open-interest-and-volume-strike

Function name:

Usage:

Get Taker Flow

Please refer to the official OKX API Docs for required parameters.

https://www.okx.com/docs-v5/en/#rest-api-trading-data-get-taker-flow

Function name:

Usage:

Last updated