Request

Requests use JSON Objects and responses are also in JSON Object format. The request is mainly divided into ticket field, type field, and format field. You can specify multiple type fields in a single request. For details on the ticket field and format field, please refer to Request Method and Format.

📘

Request format

[{Ticket Field},{Type Field},....,{Type Field},{Format Field}]

Type Field

This is a field for listing the market data you want to receive.
The fields isOnlySnapshot and isOnlyRealtime are optional. If both are omitted, you will receive both snapshot and real-time data.

/Field Name
Type
Description
Requirement
Default
typeStringData type
ticker
O
codesListMarket code
*Request in C.
O
isOnlySnapshotBooleanProvides only quote snapshot market data.Xfalse
isOnlyRealtimeBooleanProvides only real-time market data.Xfalse

Response

Field Name
Simplified Format (format: SIMPLE)
Description
TypeValue
typetyTypeStringtrade
codecdMarket code (ex. KRW-BTC)String
trade_pricetpTrade priceDouble
trade_volumetvTrade volumeDouble
ask_bidabOrder typeStringASK

BID
prev_closing_pricepcpPrevious closing priceDouble
changecChange price type compared to the previous day's closing priceStringRISE

EVEN

FALL
change_pricecpUnsigned change price compared to the previous day's closing priceDouble
trade_datetdTrade date (UTC)Stringyyyy-MM-dd
trade_timettmTrade time (UTC)StringHH:mm:ss
trade_timestampttmsTrade timestamp (millisecond)Long
timestamptmsTimestamp (millisecond)Long
sequential_idsidTrade sequential ID (Unique)Long
stream_typestStream typeStringSNAPSHOT

REALTIME
  • The sequential_id field can be used as the basis for assessing the uniqueness of a trade. However, this does not guarantee trade order.

Example

Request

[
  {
    "ticket": "test example"
  },
  {
    "type": "trade",
    "codes": [
      "KRW-BTC",
      "KRW-ETH"
    ]
  },
  {
    "format": "DEFAULT"
  }
]

Response

{
  "type": "trade",
  "code": "KRW-BTC",
  "timestamp": 1676965220452,
  "trade_date": "2023-02-21",
  "trade_time": "07:40:20",
  "trade_timestamp": 1676965220395,
  "trade_price": 32292000,
  "trade_volume": 0.03096742,
  "ask_bid": "BID",
  "prev_closing_price": 31883000.00000000,
  "change": "RISE",
  "change_price": 409000.00000000,
  "sequential_id": 1676965220395000,
  "stream_type": "SNAPSHOT"
}