> ## Documentation Index
> Fetch the complete documentation index at: https://docs.idax.exchange/llms.txt
> Use this file to discover all available pages before exploring further.

# Spot

## Public

Security: None

***

### Test Connectivity

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/ping`
</Note>

This endpoint checks connectivity to the host.

<Tabs>
  <Tab title="200: OK  Connection normal">
    ```json theme={"system"}
    {}
    ```
  </Tab>
</Tabs>

***

### Check Server Time

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/time`
</Note>

This endpoint checks connectivity to the server and retrieves server timestamp.

<Tabs>
  <Tab title="200: OK  Successfully retrieved server time">
    ```json theme={"system"}
    {
        "timezone": "GMT+08:00",
        "serverTime": 1595563624731
    }
    ```
  </Tab>
</Tabs>

***

### Pairs List

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/symbols`
</Note>

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    {
        "symbols": [
            {
                "quantityPrecision": 3,
                "symbol": "sccadai",
                "pricePrecision": 6,
                "baseAsset": "SCCA",
                "quoteAsset": "DAI",
                "limitAmountMin": "100",
                "limitPriceMin": "123.45",
                "limitVolumeMin": "10",
                "feeRateMaker": "0.002",
                "feeRateTaker": "0.002"
            },
            {
                "quantityPrecision": 8,
                "symbol": "btcusdt",
                "pricePrecision": 2,
                "baseAsset": "BTC",
                "quoteAsset": "USDT",
                "limitAmountMin": "100",
                "limitPriceMin": "123.45",
                "limitVolumeMin": "10",
                "feeRateMaker": "0.002",
                "feeRateTaker": "0.002"
            },
            {
                "quantityPrecision": 3,
                "symbol": "bchusdt",
                "pricePrecision": 2,
                "baseAsset": "BCH",
                "quoteAsset": "USDT",
                "limitAmountMin": "100",
                "limitPriceMin": "123.45",
                "limitVolumeMin": "10",
                "feeRateMaker": "0.002",
                "feeRateTaker": "0.002"
            }
        ]
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 1**

#### Response:

| Name              | Type    | Example    | Description                               |
| ----------------- | ------- | ---------- | ----------------------------------------- |
| symbol            | string  | `BTCUSDT`  | Name of the symbol                        |
| baseAsset         | string  | `BTC`      | Underlying asset for the symbol           |
| quoteAsset        | string  | `USDT`     | Quote asset for the symbol                |
| pricePrecision    | integer | `2`        | Precision of the price                    |
| quantityPrecision | integer | `6`        | Precision of the quantity                 |
| limitAmountMin    | string  | `100`      | Limit order minimum order amount (quote)  |
| limitPriceMin     | string  | `100`      | Minimum price of a limit order            |
| limitVolumeMin    | string  | `100`      | Limit order minimum order quantity (base) |
| baseAssetName     | string  | `BTC`      | Base currency display name                |
| quoteAssetName    | string  | `USDT`     | Quote currency display name               |
| SymbolName        | string  | `BTC/USDT` | Trading pair display name                 |
| feeRateMaker      | string  | `0.002`    | Maker fee rate                            |
| feeRateTaker      | string  | `0.002`    | Taker fee rate                            |

***

## Market

Security Type: None

***

### Depth

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/depth`
</Note>

Market depth data.

#### Query Parameters

| Name                                         | Type    | Description               |
| -------------------------------------------- | ------- | ------------------------- |
| limit                                        | integer | Default 100; Max 100      |
| symbol <span style={{color:'red'}}>\*</span> | string  | Symbol Name E.g. BTC/USDT |

<Tabs>
  <Tab title="200: OK  Successfully retrieved market depth data">
    ```json theme={"system"}
    {
      "bids": [
        [
          "3.90000000",
          "431.00000000"
        ],
        [
          "4.00000000",
          "431.00000000"
        ]
      ],
      "asks": [
        [
          "4.00000200",
          "12.00000000"
        ],
        [
          "5.10000000",
          "28.00000000"
        ]
      ]
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 5**

#### Response:

| Name | Type | Example         | Description                                                     |
| ---- | ---- | --------------- | --------------------------------------------------------------- |
| time | long | `1595563624731` | Current timestamp (ms)                                          |
| bids | list |                 | List of all bids, best bids first. See below for entry details. |
| asks | list |                 | List of all asks, best asks first. See below for entry details. |

The fields `bids` and `asks` are lists of order book price level entries, sorted from best to worst.

| Name | Type  | Example | Description                                       |
| ---- | ----- | ------- | ------------------------------------------------- |
|      | float | `131.1` | Price level                                       |
|      | float | `2.3`   | The total quantity of orders for this price level |

***

### 24hrs ticker

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/ticker`
</Note>

24 hour price change statistics.

* If `symbol` parameter is not provided, the API will consume a significantly higher rate limit, and the response structure will also be different.
* If the symbol is not sent, orders for all symbols will be returned in an array.

#### Query Parameters

ps: If both `symbol` and `symbols` are provided, `symbol` takes precedence. If neither is provided, ticker data for all symbols will be returned.

| Name    | Type   | Description                                                                               |
| ------- | ------ | ----------------------------------------------------------------------------------------- |
| symbol  | string | Symbol Name E.g. BTC/USDT                                                                 |
| symbols | string | **Coin pair name**: Use English commas to separate multiple pairs. e.g. `btcusdt,ethusdt` |

<Tabs>
  <Tab title="200: OK  Successfully retrieved ticker data">
    ```json theme={"system"}
    {
        "high": "9279.0301",
        "vol": "1302",
        "last": "9200",
        "low": "9279.0301",
        "rose": "0",
        "time": 1595563624731,
        "symbol": "btcusdt",
        "amount": "3213",
        "askPrice": "123",
        "askVolume": "213213",
        "bidPrice": "12323",
        "bidVolume": "213213"
    }
    ```
  </Tab>

  <Tab title="200: OK  Successfully retrieve ticker information without passing symbol">
    ```json theme={"system"}
    [
        {
            "high": "9279.0301",
            "vol": "1302",
            "last": "9200",
            "low": "9279.0301",
            "rose": "0",
            "time": 1595563624731,
            "symbol": "btcusdt",
            "amount": "3213",
            "askPrice": "123",
            "askVolume": "213213",
            "bidPrice": "12323",
            "bidVolume": "213213"
        },
        {
            "high": "9279.0301",
            "vol": "1302",
            "last": "9200",
            "low": "9279.0301",
            "rose": "0",
            "time": 1595563624731,
            "symbol": "ethusdt",
            "amount": "3213",
            "askPrice": "123",
            "askVolume": "213213",
            "bidPrice": "12323",
            "bidVolume": "213213"
        }
    ]
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 5**

**`symbol` not provided: weight = 80**

**`symbols` not provided: weight = 80**

**`symbols` 1-20: weight = 5**

**`symbols` 21-100: weight = 40**

**`symbols` ≥ 101: weight = 80**

#### Response:

| Name      | Type   | Example         | Description                           |
| --------- | ------ | --------------- | ------------------------------------- |
| time      | long   | `1595563624731` | Open time                             |
| high      | float  | `9900`          | High price                            |
| low       | float  | `8800.34`       | Low price                             |
| open      | float  | `8700`          | Open price                            |
| last      | float  | `8900`          | Last price                            |
| vol       | float  | `4999`          | Trade volume                          |
| rose      | float  | `0`             | Price increase or price rise          |
| symbol    | string | `btcusdt`       | Symbol                                |
| amount    | string | `1233`          | Trading volume, quote currency volume |
| askPrice  | string | `23321`         | Best ask price                        |
| askVolume | string | `3321`          | Best ask size                         |
| bidPrice  | string | `21`            | Best bid price                        |
| bidVolume | string | `12`            | Best bid size                         |

***

### Recent Trades List

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/trades`
</Note>

#### Query Parameters

| Name                                         | Type   | Description               |
| -------------------------------------------- | ------ | ------------------------- |
| symbol <span style={{color:'red'}}>\*</span> | string | Symbol Name E.g. BTC/USDT |
| limit                                        | string | Default 100; Max 1000     |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    {
        "list": [
            {
                "price": "3.000001",
                "qty": "11.0",
                "time": 1499865549590,
                "side": "BUY",
                "id": 629861,
                "symbol": "BTC/USDT"
            }
        ]
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 5**

#### Response:

| Name   | Type   | Example         | Description            |
| ------ | ------ | --------------- | ---------------------- |
| price  | float  | `0.055`         | The price of the trade |
| time   | long   | `1537797044116` | Current timestamp (ms) |
| qty    | float  | `5`             | The quantity traded    |
| side   | string | `BUY/SELL`      | Taker side             |
| id     | long   | `629861`        | Transaction ID         |
| symbol | string | `BTC/USDT`      | Currency pair          |

***

### Kline/candlestick data

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/klines`
</Note>

#### Query Parameters

| Name                                           | Type    | Description                                                                                                  |
| ---------------------------------------------- | ------- | ------------------------------------------------------------------------------------------------------------ |
| symbol <span style={{color:'red'}}>\*</span>   |         | Symbol Name E.g. BTC/USDT                                                                                    |
| interval <span style={{color:'red'}}>\*</span> | string  | Interval of the Kline. Possible values: `1min`, `5min`, `15min`, `30min`, `60min`, `1day`, `1week`, `1month` |
| limit                                          | integer | Returns the number of k-lines. Default 100; Max 300                                                          |
| startTime                                      | long    | Start time. Example: `1538728740000`                                                                         |
| endTime                                        | long    | End time. Example: `1538728740000`                                                                           |
| timezone                                       | string  | Time zone, e.g. `UTC-09`                                                                                     |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    [
        {
            "high": "6228.77",
            "vol": "111",
            "low": "6228.77",
            "idx": 1594640340,
            "close": "6228.77",
            "open": "6228.77"
        },
        {
            "high": "6228.77",
            "vol": "222",
            "low": "6228.77",
            "idx": 1587632160,
            "close": "6228.77",
            "open": "6228.77"
        },
        {
            "high": "6228.77",
            "vol": "333",
            "low": "6228.77",
            "idx": 1587632100,
            "close": "6228.77",
            "open": "6228.77"
        }
    ]
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 1**

#### Response:

| Name  | Type  | Example         | Description |
| ----- | ----- | --------------- | ----------- |
| `idx` | long  | `1538728740000` | Open time   |
| open  | float | `36.00000`      | Open price  |
| close | float | `33.00000`      | Close price |
| high  | float | `36.00000`      | High price  |
| low   | float | `30.00000`      | Low price   |
| vol   | float | `2456.111`      | Volume      |

***

## Trade

### Security Type: TRADE

Endpoints under **Trade** require an API Key and a signature.

***

### New Order

<Note type="success">
  **`POST`** `https://openapi.idax.exchange/sapi/v2/order`
</Note>

**Rate Limit: 100 times/2s**

#### Query Parameters

| Name        | Type    | Description  |
| ----------- | ------- | ------------ |
| X-CH-SIGN   | string  | Sign         |
| X-CH-APIKEY | string  | Your API key |
| X-CH-TS     | integer | Timestamp    |

#### Request Body

| Name                                         | Type    | Description                                                                                                   |
| -------------------------------------------- | ------- | ------------------------------------------------------------------------------------------------------------- |
| symbol <span style={{color:'red'}}>\*</span> | string  | Symbol Name E.g. BTC/USDT                                                                                     |
| volume <span style={{color:'red'}}>\*</span> | number  | Order volume. For MARKET BUY orders, vol = amount.                                                            |
| side <span style={{color:'red'}}>\*</span>   | string  | Side of the order: `BUY/SELL`                                                                                 |
| type <span style={{color:'red'}}>\*</span>   | string  | Type of the order: `LIMIT` / `MARKET` / `FOK` / `POST_ONLY` / `IOC` / `STOP`                                  |
| price <span style={{color:'red'}}>\*</span>  | number  | Order price, REQUIRED for LIMIT orders                                                                        |
| newClientOrderId                             | string  | Unique order ID generated by users to mark their orders                                                       |
| recvwindow                                   | integer | Time window                                                                                                   |
| triggerPrice                                 | number  | Take Profit and Stop Loss trigger price (when `type` is `STOP`, `price` and `triggerPrice` are both required) |

<Tabs>
  <Tab title="200: OK  Successfully post new order">
    ```json theme={"system"}
    {
        "symbol": "LXTUSDT",
        "orderId": 150695552109032492,
        "orderIdString": "150695552109032492",
        "clientOrderId": "157371322565051",
        "transactTime": "1573713225668",
        "price": "0.005452",
        "origQty": "110",
        "executedQty": "0",
        "status": "0",
        "type": "LIMIT",
        "side": "SELL"
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 5**

#### Response:

| Name          | Type    | Example                | Description                        |
| ------------- | ------- | ---------------------- | ---------------------------------- |
| orderId       | long    | `150695552109032492`   | ID of the order                    |
| orderIdString | string  | `"150695552109032492"` | String type order ID (recommended) |
| clientOrderId | string  | `213443`               | A unique ID of the order           |
| symbol        | string  | `BTCUSDT`              | Symbol name                        |
| symbolName    | string  | `BTC/USDT`             | Currency display name              |
| transactTime  | integer | `1273774892913`        | Time the order is placed           |
| price         | float   | `4765.29`              | Order price                        |
| origQty       | float   | `1.01`                 | Quantity ordered                   |
| executedQty   | float   | `1.01`                 | Quantity of orders executed        |
| type          | string  | `LIMIT`                | Order type: `LIMIT`, `MARKET`      |
| side          | string  | `BUY`                  | Order side: `BUY`, `SELL`          |
| status        | string  | `0`                    | `0` = new order                    |

***

### Test New Order

<Note type="success">
  **`POST`** `https://openapi.idax.exchange/sapi/v2/order/test`
</Note>

Test new order creation and signature/recvWindow length. Creates and validates a new order but does not send the order into the matching engine.

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

#### Request Body

| Name                                         | Type    | Description                                             |
| -------------------------------------------- | ------- | ------------------------------------------------------- |
| type <span style={{color:'red'}}>\*</span>   | string  | Type of the order: `LIMIT/MARKET`                       |
| price <span style={{color:'red'}}>\*</span>  | number  | Order price, REQUIRED for `LIMIT` orders                |
| volume <span style={{color:'red'}}>\*</span> | number  | Order volume. For MARKET BUY orders, vol = amount.      |
| side <span style={{color:'red'}}>\*</span>   | string  | Side of the order: `BUY/SELL`                           |
| symbol <span style={{color:'red'}}>\*</span> | string  | Symbol Name E.g. BTC/USDT                               |
| recvwindow                                   | integer | Time window                                             |
| newClientorderId                             | string  | Unique order ID generated by users to mark their orders |

<Tabs>
  <Tab title="200: OK  Successfully test new order">
    ```json theme={"system"}
    {}
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 1**

***

### Batch Orders

<Note type="success">
  **`POST`** `https://openapi.idax.exchange/sapi/v2/batchOrders`
</Note>

**Batch contains at most 10 orders.**

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

#### Request Body

| Name                                         | Type   | Description                                         |
| -------------------------------------------- | ------ | --------------------------------------------------- |
| orders                                       | array  | The batch order information, maximum of 10 records. |
| symbol <span style={{color:'red'}}>\*</span> | string | Symbol Name E.g. BTC/USDT                           |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    {
        "idsString": [
            "165964665990709251",
            "165964665990709252",
            "165964665990709253"
        ],
        "ids": [
            165964665990709251,
            165964665990709252,
            165964665990709253
        ]
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 10**

#### Request `orders` field:

| Name      | Type   | Example        | Description |
| --------- | ------ | -------------- | ----------- |
| price     | float  | `1000`         | Price       |
| volume    | float  | `20.1`         | Quantity    |
| side      | string | `BUY/SELL`     | Direction   |
| batchType | string | `LIMIT/MARKET` | Type        |

#### Response:

| Name      | Type    | Example     | Description                                   |
| --------- | ------- | ----------- | --------------------------------------------- |
| idsString | string  | `"3213213"` | A collection of order numbers of type string. |
| ids       | integer | `2100`      | Collection of order numbers.                  |

***

### Query Order

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/order`
</Note>

#### Query Parameters

| Name                                          | Type   | Description                                                                                        |
| --------------------------------------------- | ------ | -------------------------------------------------------------------------------------------------- |
| orderId <span style={{color:'red'}}>\*</span> | string | Order ID                                                                                           |
| newClientorderId                              | string | Client Order ID, unique order ID generated by users to mark their orders. E.g. `354444heihieddada` |
| symbol <span style={{color:'red'}}>\*</span>  | string | Symbol Name E.g. BTC/USDT                                                                          |

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    {
        "orderId": "499890200602846976",
        "clientOrderId": "157432755564968",
        "symbol": "BHTUSDT",
        "price": "0.01",
        "origQty": "50",
        "executedQty": "0",
        "avgPrice": "0",
        "status": "NEW",
        "type": "LIMIT",
        "side": "BUY",
        "transactTime": "1574327555669"
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 1**

#### Response:

| Name          | Type   | Example              | Description                                                               |
| ------------- | ------ | -------------------- | ------------------------------------------------------------------------- |
| orderId       | long   | `150695552109032492` | Order ID (system generated)                                               |
| clientOrderId | string | `213443`             | Order ID (sent by yourself)                                               |
| symbol        | string | `BTCUSDT`            | Currency pair name                                                        |
| price         | float  | `4765.29`            | Order price                                                               |
| origQty       | float  | `1.01`               | Number of orders                                                          |
| executedQty   | float  | `1.01`               | Number of orders already filled                                           |
| avgPrice      | float  | `4754.24`            | Average price of orders already filled                                    |
| type          | string | `LIMIT`              | The order type: `LIMIT`, `MARKET`                                         |
| side          | string | `BUY`                | Order direction: `BUY` (buy long) and `SELL` (sell short)                 |
| status        | string | `NEW`                | Order status: `NEW`, `PARTIALLY_FILLED`, `FILLED`, `CANCELED`, `REJECTED` |
| transactTime  | string | `1574327555669`      | Order creation time                                                       |

***

### Cancel Order

<Note type="success">
  **`POST`** `https://openapi.idax.exchange/sapi/v2/cancel`
</Note>

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

#### Request Body

| Name                                          | Type   | Description                                                                                        |
| --------------------------------------------- | ------ | -------------------------------------------------------------------------------------------------- |
| newClientOrderId                              | string | Client Order ID, unique order ID generated by users to mark their orders. E.g. `354444heihieddada` |
| orderId <span style={{color:'red'}}>\*</span> | string | Order ID                                                                                           |
| symbol <span style={{color:'red'}}>\*</span>  | string | Symbol Name E.g. BTC/USDT                                                                          |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    {
        "symbol": "BHTUSDT",
        "clientOrderId": "0",
        "orderId": "499890200602846976",
        "status": "CANCELED"
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 5**

#### Response:

| Name          | Type   | Example              | Description                                                               |
| ------------- | ------ | -------------------- | ------------------------------------------------------------------------- |
| orderId       | long   | `150695552109032492` | ID of the order                                                           |
| clientOrderId | string | `213443`             | Unique ID of the order                                                    |
| symbol        | string | `BTCUSDT`            | Name of the symbol                                                        |
| status        | string | `NEW`                | Order status: `NEW`, `PARTIALLY_FILLED`, `FILLED`, `CANCELED`, `REJECTED` |

***

### Batch cancel orders

<Note type="success">
  **`POST`** `https://openapi.idax.exchange/sapi/v2/batchCancel`
</Note>

**Batch contains at most 10 orders.**

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

#### Request Body

| Name                                           | Type   | Description                     |
| ---------------------------------------------- | ------ | ------------------------------- |
| orderIds <span style={{color:'red'}}>\*</span> | string | Order ID collection `[123,456]` |
| symbol <span style={{color:'red'}}>\*</span>   | string | Symbol Name E.g. BTC/USDT       |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    {
        "success": [
            165964665990709251,
            165964665990709252,
            165964665990709253
        ],
        "failed": [
            165964665990709250
        ]
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 10**

***

### Current Open Orders

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/openOrders`
</Note>

If `symbol` parameter is not provided, the API will consume a significantly higher rate limit.

#### Query Parameters

| Name   | Type    | Description               |
| ------ | ------- | ------------------------- |
| symbol | string  | Symbol Name E.g. BTC/USDT |
| limit  | integer | Default 100; Max 1000     |

* If the symbol is not sent, orders for all symbols will be returned in an array.

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    [
        {
            "orderId": 499902955766523648,
            "orderIdString": "499902955766523648",
            "symbol": "BHTUSDT",
            "price": "0.01",
            "origQty": "50",
            "executedQty": "0",
            "avgPrice": "0",
            "status": "NEW",
            "type": "LIMIT",
            "side": "BUY",
            "time": "1574329076202",
            "stopPrice": 123321,
            "isWorking": true
        }
    ]
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 1**

**`symbol` not provided: weight = 80**

#### Response:

| Name          | Type    | Example                | Description                                                               |
| ------------- | ------- | ---------------------- | ------------------------------------------------------------------------- |
| orderId       | long    | `150695552109032492`   | ID of the order                                                           |
| orderIdString | string  | `"150695552109032492"` | String type order ID (recommended)                                        |
| clientOrderId | string  | `213443`               | Unique ID of the order                                                    |
| symbol        | string  | `BTCUSDT`              | Name of the symbol                                                        |
| price         | float   | `4765.29`              | Price of the order                                                        |
| origQty       | float   | `1.01`                 | Quantity ordered                                                          |
| executedQty   | float   | `1.01`                 | Quantity of orders that has been executed                                 |
| avgPrice      | float   | `4754.24`              | Average price of filled orders                                            |
| type          | string  | `LIMIT`                | The order type: `LIMIT`, `MARKET`                                         |
| side          | string  | `BUY`                  | The order side: `BUY`, `SELL`                                             |
| status        | string  | `NEW`                  | Order status: `NEW`, `PARTIALLY_FILLED`, `FILLED`, `CANCELED`, `REJECTED` |
| time          | string  | `1574327555669`        | Creation time                                                             |
| stopPrice     | float   | `21323.32`             | Take Profit and Stop Loss trigger price                                   |
| isWorking     | boolean | `true`                 | Does the order appear in the order book?                                  |

***

### History Orders

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v3/historyOrders`
</Note>

If `symbol` parameter is not provided, the API will consume a significantly higher rate limit.

#### Query Parameters

| Name      | Type    | Description                                                                                                                                                                                                                                                 |
| --------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| symbol    | string  | Symbol Name E.g. BTC/USDT                                                                                                                                                                                                                                   |
| limit     | integer | Default 50; Max 100                                                                                                                                                                                                                                         |
| startTime | long    | The start timestamp (ms). startTime and endTime not passed returns 7 days by default; only startTime passed returns startTime to startTime+7 days; only endTime passed returns endTime-7 days to endTime; if both are passed, endTime - startTime ≤ 7 days. |
| endTime   | long    | The end timestamp (ms)                                                                                                                                                                                                                                      |

* If the symbol is not sent, orders for all symbols will be returned in an array.
* Support query within the last 6 months only.

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    [
        {
            "orderId": 499902955766523648,
            "orderIdString": "499902955766523648",
            "symbol": "BHTUSDT",
            "price": "0.01",
            "origQty": "50",
            "executedQty": "0",
            "avgPrice": "0",
            "status": "NEW",
            "type": "LIMIT",
            "side": "BUY",
            "time": "1574329076202",
            "stopPrice": 123321,
            "isWorking": true
        }
    ]
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 20**

**`symbol` not provided: weight = 80**

#### Response:

| Name          | Type    | Example                | Description                                                               |
| ------------- | ------- | ---------------------- | ------------------------------------------------------------------------- |
| orderId       | long    | `150695552109032492`   | ID of the order                                                           |
| orderIdString | string  | `"150695552109032492"` | String type order ID (recommended)                                        |
| clientOrderId | string  | `213443`               | Unique ID of the order                                                    |
| symbol        | string  | `BTCUSDT`              | Name of the symbol                                                        |
| price         | float   | `4765.29`              | Price of the order                                                        |
| origQty       | float   | `1.01`                 | Quantity ordered                                                          |
| executedQty   | float   | `1.01`                 | Quantity of orders that has been executed                                 |
| avgPrice      | float   | `4754.24`              | Average price of filled orders                                            |
| type          | string  | `LIMIT`                | The order type: `LIMIT`, `MARKET`                                         |
| side          | string  | `BUY`                  | The order side: `BUY`, `SELL`                                             |
| status        | string  | `NEW`                  | Order status: `NEW`, `PARTIALLY_FILLED`, `FILLED`, `CANCELED`, `REJECTED` |
| time          | string  | `1574327555669`        | Creation time                                                             |
| stopPrice     | float   | `21323.32`             | Take Profit and Stop Loss trigger price                                   |
| isWorking     | boolean | `true`                 | Does the order appear in the order book?                                  |

***

### Trades

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v2/myTrades`
</Note>

#### Query Parameters

| Name                                         | Type   | Description               |
| -------------------------------------------- | ------ | ------------------------- |
| symbol <span style={{color:'red'}}>\*</span> | string | Symbol Name E.g. BTC/USDT |
| limit                                        | string | Default 100; Max 1000     |
| fromId                                       | string | Trade ID to fetch from    |

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    [
      {
        "symbol": "ETHBTC",
        "id": 100211,
        "bidId": 150695552109032492,
        "askId": 150695552109032493,
        "price": "4.00000100",
        "qty": "12.00000000",
        "time": 1499865549590,
        "isBuyer": true,
        "isMaker": false,
        "feeCoin": "ETH",
        "fee": "0.001",
        "bidUserId": 23334,
        "askUserId": 44112
      }
    ]
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 1**

#### Response:

| Name      | Type    | Example              | Description                      |
| --------- | ------- | -------------------- | -------------------------------- |
| symbol    | string  | `BTCUSDT`            | Name of the symbol               |
| id        | integer | `28457`              | Trade ID                         |
| bidId     | long    | `150695552109032492` | Bid order ID                     |
| askId     | long    | `150695552109032492` | Ask order ID                     |
| price     | integer | `4.01`               | Price of the trade               |
| qty       | float   | `12`                 | Quantity of the trade            |
| time      | number  | `1499865549590`      | Timestamp of the trade           |
| isBuyer   | bool    | `true`               | `true` = Buyer, `false` = Seller |
| isMaker   | bool    | `false`              | `true` = Maker, `false` = Taker  |
| feeCoin   | string  | `ETH`                | Trading fee coin                 |
| fee       | number  | `0.001`              | Trading fee                      |
| bidUserId | long    | `23334`              | Buyer UID                        |
| askUserId | long    | `44112`              | Seller UID                       |
| isSelf    | bool    | `true`               | Whether the trade was self-dealt |

***

### Trades-V3

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v3/myTrades`
</Note>

If `symbol` parameter is not provided, the API will consume a significantly higher rate limit.

#### Query Parameters

| Name      | Type    | Description                                                                                                                                                                                                                                                 |
| --------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| symbol    | string  | Symbol Name E.g. BTC/USDT                                                                                                                                                                                                                                   |
| limit     | integer | Default 50; Max 100                                                                                                                                                                                                                                         |
| startTime | long    | The start timestamp (ms). startTime and endTime not passed returns 7 days by default; only startTime passed returns startTime to startTime+7 days; only endTime passed returns endTime-7 days to endTime; if both are passed, endTime - startTime ≤ 7 days. |
| endTime   | long    | The end timestamp (ms)                                                                                                                                                                                                                                      |

* If the symbol is not sent, trades for all symbols will be returned in an array.
* Support query within the last 6 months only.

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    [
      {
        "symbol": "ETH/BTC",
        "id": 100211,
        "bidId": 150695552109032492,
        "askId": 150695552109032493,
        "price": "4.00000100",
        "qty": "12.00000000",
        "time": 1499865549590,
        "isBuyer": true,
        "isMaker": false,
        "feeCoin": "ETH",
        "fee": "0.001",
        "bidUserId": 23334,
        "askUserId": 44112
      }
    ]
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 20**

**`symbol` not provided: weight = 80**

#### Response:

| Name      | Type    | Example              | Description                      |
| --------- | ------- | -------------------- | -------------------------------- |
| symbol    | string  | `BTC/USDT`           | Name of the symbol               |
| id        | integer | `28457`              | Trade ID                         |
| bidId     | long    | `150695552109032492` | Bid order ID                     |
| askId     | long    | `150695552109032492` | Ask order ID                     |
| price     | integer | `4.01`               | Price of the trade               |
| qty       | float   | `12`                 | Quantity of the trade            |
| time      | number  | `1499865549590`      | Timestamp of the trade           |
| isBuyer   | bool    | `true`               | `true` = Buyer, `false` = Seller |
| isMaker   | bool    | `false`              | `true` = Maker, `false` = Taker  |
| feeCoin   | string  | `ETH`                | Trading fee coin                 |
| fee       | number  | `0.001`              | Trading fee                      |
| bidUserId | long    | `23334`              | Buyer UID                        |
| askUserId | long    | `44112`              | Seller UID                       |
| isSelf    | bool    | `true`               | Whether the trade was self-dealt |

***

## Account

Security Type: USER\_DATA

Endpoints under Account require an API key and a signature.

***

### Account Information

<Note type="info">
  **`GET`** `https://openapi.idax.exchange/sapi/v1/account`
</Note>

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |
| X-CH-SIGN   | string | Sign         |

<Tabs>
  <Tab title="200: OK  Successfully retrieved account information">
    ```json theme={"system"}
    {
        "balances": [
            {
                "uid": 32556741,
                "asset": "BTC",
                "free": "0.0000000000",
                "locked": "0.0000000000"
            }
        ]
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 1**

#### Response:

| Name       | Type  | Description  |
| ---------- | ----- | ------------ |
| `balances` | array | Balance list |

`balances` field:

| Name     | Type   | Example   | Description                     |
| -------- | ------ | --------- | ------------------------------- |
| `uid`    | string | `10001`   | User ID                         |
| `asset`  | string | `USDT`    | Name of the asset               |
| `free`   | float  | `1000.30` | Amount available for use        |
| `locked` | float  | `400`     | Amount locked (for open orders) |

***

### Transfer

<Note type="success">
  **`POST`** `https://openapi.idax.exchange/sapi/v1/asset/transfer`
</Note>

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-SIGN   | string | Sign         |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |

#### Request Body

| Name                                              | Type   | Description                                                           |
| ------------------------------------------------- | ------ | --------------------------------------------------------------------- |
| coinSymbol <span style={{color:'red'}}>\*</span>  | string | Coin symbol                                                           |
| amount <span style={{color:'red'}}>\*</span>      | float  | Quantity                                                              |
| fromAccount <span style={{color:'red'}}>\*</span> | string | From Account. **EXCHANGE**: Spot Account, **FUTURE**: Futures Account |
| toAccount <span style={{color:'red'}}>\*</span>   | string | To Account. **EXCHANGE**: Spot Account, **FUTURE**: Futures Account   |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    {
        "code": "0",
        "msg": "SUCCESS",
        "data": {
            "transferId": "1a9ec387-8b81-4789-a98e-bc6a606c8736"
        }
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 5**

#### Response:

| Name       | Type   | Example                                | Description |
| ---------- | ------ | -------------------------------------- | ----------- |
| transferId | string | `1a9ec387-8b81-4789-a98e-bc6a606c8736` | Transfer ID |

***

### Transfer Record Query

<Note type="success">
  **`POST`** `https://openapi.idax.exchange/sapi/v1/asset/transferQuery`
</Note>

#### Headers

| Name        | Type   | Description  |
| ----------- | ------ | ------------ |
| X-CH-SIGN   | string | Sign         |
| X-CH-APIKEY | string | Your API key |
| X-CH-TS     | string | Timestamp    |

#### Request Body

When `transferId` is not provided, `fromAccount`/`toAccount` are required.
If `startTime` and `endTime` are not provided, the default is to return data from the last 7 days.
Only data from the last 6 months is supported for querying.

| Name        | Type    | Description                                                           |
| ----------- | ------- | --------------------------------------------------------------------- |
| transferId  | string  | Transfer ID                                                           |
| coinSymbol  | string  | Coin symbol                                                           |
| fromAccount | string  | From Account. **EXCHANGE**: Spot Account, **FUTURE**: Futures Account |
| toAccount   | string  | To Account. **EXCHANGE**: Spot Account, **FUTURE**: Futures Account   |
| startTime   | long    | Start time, 13-digit timestamp                                        |
| endTime     | long    | End time, 13-digit timestamp                                          |
| page        | integer | If not provided, default is 1                                         |
| limit       | integer | If not provided, default is 20, maximum 100                           |

<Tabs>
  <Tab title="200: OK">
    ```json theme={"system"}
    {
        "code": "0",
        "msg": "SUCCESS",
        "data": {
            "list": [
                {
                    "transferId": "1a9ec387-8b81-4789-a98e-bc6a606c8736",
                    "fromAccount": "EXCHANGE",
                    "toAccount": "FUTURE",
                    "coinSymbol": "USDT",
                    "createTime": 1742369830000,
                    "amount": "1",
                    "status": "SUCCESS"
                }
            ]
        }
    }
    ```
  </Tab>
</Tabs>

**weight(IP/UID): 5**

#### Response:

| Name        | Type   | Example                                | Description                                                             |
| ----------- | ------ | -------------------------------------- | ----------------------------------------------------------------------- |
| transferId  | string | `1a9ec387-8b81-4789-a98e-bc6a606c8736` | Transfer ID                                                             |
| fromAccount | string | `EXCHANGE`                             | From account                                                            |
| toAccount   | string | `FUTURE`                               | To account                                                              |
| coinSymbol  | string | `USDT`                                 | Coin symbol                                                             |
| createTime  | long   | `1742300000000`                        | Creation timestamp                                                      |
| amount      | string | `1`                                    | Quantity                                                                |
| status      | string | `SUCCESS`                              | Status: `SUCCESS` = Success, `PENDING` = In Progress, `FAILED` = Failed |
