While connected to websocket, you can also use it in pull style by sending message to the server.

To submit a request, use the following template:

//request
{
  "req": "topic to req",
  "id": "id generate by client"
}

For example,

//request
{
  "req": "market.ethbtc.kline.1min",
  "id": "id10"
}

From the above request, the server should return something like the following:

//response
{
  "status": "ok",
  "rep": "market.btcusdt.kline.1min",
  "tick": [
    {
      "amount": 1.6206,
      "count":  3,
      "id":     1494465840,
      "open":   9887.00,
      "close":  9885.00,
      "low":    9885.00,
      "high":   9887.00,
      "vol":    16021.632026
    },
    {
      "amount": 2.2124,
      "count":  6,
      "id":     1494465900,
      "open":   9885.00,
      "close":  9880.00,
      "low":    9880.00,
      "high":   9885.00,
      "vol":    21859.023500
    }
  ]
}

If a request is made and there is an error somewhere in the formatting of the request, the request will fail and the server will return an error and explain why the request failed.

For example, the following request:

//request
{
  "req": "market.invalidsymbol.kline.1min",
  "id": "id10"
}

//response
{
  "status": "error",
  "id": "id10",
  "err-code": "bad-request",
  "err-msg": "invalid topic market.invalidsymbol.trade.detail",
  "ts": 1494483996521
}