NAV Navbar
shell javascript

REST API

Uvas Exchange provides a REST API using standard HTTP requests.

Connection

REST API endpoint starts with https://api.uvas.com/v1/public for public methods and https://api.uvas.com/v1/private for private methods.

Rate Limiting

Uvas Exchange uses rate limiting to ensure API availability and processing capacity. Any single IP can send up to 3 requests per second.

Request/Response Structure

Request

Request

curl -X GET 'https://api.uvas.com/v1/public/method?parameter1=value1&parameter2=value2'

According to the HTTP specification GET requests must be URL in the following format:

Name Type Description
method string Requested method (e.g. get-stats)
parameterX string Query string parameter. Can be omitted if the requested method requires no parameters (e.g. instrumentId)

Success response

Response

{
  "result": {
    ...
  }
}

If successful, the API returns a response with the following structure:

Name Type Description
result object or array Object or array with the request processing result

Error response

Response (HTTP 200)

{
  "error": {
    "code": 13500,
    "message": "Instrument id is invalid."
  }
}

Response (HTTP 500)

{
  "error": {
    "code": 10000,
    "message": "General server error."
  }
}

In case of an error the API returns a response with the following structure:

Name Type Description
error object Request processing error
-> code integer Error code
-> message string Error message
-> data object Additional error data specific to the given error code

HTTP Statuses

HTTP Status Description
500 For error code 10000
200 For other error codes

Data Types

Timestamps

All timestamps are represented as UNIX epoch timestamps in microseconds, if not specified otherwise.

Authentication

/v1/public/get-token

Request (grantType = passphrase)

curl -X POST 'https://api.uvas.com/v1/public/get-token' \
-H 'Content-Type: application/json' \
-d '{
  "grantType": "passphrase",
  "apiKey": "ydb17hvUb5Haa2IF",
  "apiPassphrase": "tvhftAj1Xv5ZIHiDl4eWSLOL"
}'

Request (grantType = signature)

curl -X POST 'https://api.uvas.com/v1/public/get-token' \
-H 'Content-Type: application/json' \
-d '{
  "grantType": "signature",
  "apiKey": "ydb17hvUb5Haa2IF",
  "timestamp": 1594800486782215,
  "signature": "3fa04a98094320084f0c9363b42491650f450ec116f7edfb8ba3cbf421381671"
}'

Request (grantType = refreshToken)

curl -X POST 'https://api.uvas.com/v1/public/get-token' \
-H 'Content-Type: application/json' \
-d '{
  "grantType": "refreshToken",
  "accessToken": "...",
  "refreshToken": "..."
}'

Response

{ 
  "result": {
    "accessToken": "...",
    "refreshToken": "..."
  }
}

Gets access and refresh tokens.

Parameters

Name Type Required Description
grantType string Yes Grant type. Supported values: passphrase, signature, refreshToken
apiKey string Conditional API key, required for grantType = passphrase and grantType = signature
apiPassphrase string Conditional API passphrase, required for grantType = passphrase
signature string Conditional User generated signature, required for grantType = signature
timestamp timestamp Conditional Timestamp, required for grantType = signature
accessToken string Conditional Access token, required for grantType = refreshToken.
refreshToken string Conditional Refresh token, required for grantType = refreshToken

echo -n "timestamp.apiKey" | openssl sha256 -hmac "apiPassphrase"

Example:

echo -n "1594800486782215.ydb17hvUb5Haa2IF" | openssl sha256 -hmac "tvhftAj1Xv5ZIHiDl4eWSLOL"

3fa04a98094320084f0c9363b42491650f450ec116f7edfb8ba3cbf421381671

Response

Name Type Description
result object
-> accessToken string Access token
-> refreshToken string Refresh token

/v1/private/revoke-token

Request

curl -X POST 'https://api.uvas.com/v1/private/revoke-token' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer accessToken'

Response

200 OK

Revokes refresh token.

Parameters

No parameters.

Response

Empty HTTP response.

Market Data

Market data methods are public and require no authentication.

/v1/public/get-assets

Request

curl -X GET 'https://api.uvas.com/v1/public/get-assets'

Response

{
  "result": [
    {
      "id": "BTC",
      "displayName": "Bitcoin"
    },
    {
      "id": "ETH",
      "displayName": "Ethereum"
    }
  ]
}

Retrieves all assets supported by the API.

Parameters

No parameters.

Response

Name Type Description
result array of objects
-> id string Id
-> displayName string Descriptive name

/v1/public/get-instruments

Request

curl -X GET 'https://api.uvas.com/v1/public/get-instruments?type=spot&asset=ETH'

Response

{
  "result": [
    {
      "id": "ETH-BTC",
      "displayName": "ETH/BTC",
      "type": "spot",
      "base": "ETH",
      "quote": "BTC",
      "minQty": 0.0001,
      "maxQty": 10000000.0,
      "tickSize": 0.000001,
      "takerFee": 0.001,
      "makerFee": 0.0,
      "feeCurrency": "acquired"
    },
    {
      "id": "ETH-USDT",
      "displayName": "ETH/USDT",
      "type": "spot",
      "base": "ETH",
      "quote": "USDT",
      "minQty": 0.001,
      "maxQty": 10000000.0,
      "tickSize": 0.01,
      "takerFee": 0.001,
      "makerFee": 0.0,
      "feeCurrency": "acquired"
    }
  ]
}

Retrieves all instruments supported by the API.

Parameters

Name Type Required Description
asset string No Asset ID
type string No Type. Supported values: spot

Response

Name Type Description
result array of objects
-> id string Instrument ID
-> displayName string Descriptive name
-> type string Type. Supported values: spot
-> base string Base asset
-> quote string Quote asset
-> minQty decimal Min order quantity
-> maxQty decimal Max order quantity
-> tickSize decimal Tick size
-> takerFee decimal User fee as a taker
-> makerFee decimal User fee as a maker
-> feeCurrency string Fee currency. Supported values: base, quote, acquired

/v1/public/get-instrument

Request

curl -X GET 'https://api.uvas.com/v1/public/get-instrument?instrumentId=ETH-BTC'

Response

{
  "result": {
    "id": "ETH-BTC",
    "displayName": "ETH/BTC",
    "type": "spot",
    "base": "ETH",
    "quote": "BTC",
    "minQty": 0.0001,
    "maxQty": 10000000.0,
    "tickSize": 0.000001,
    "takerFee": 0.001,
    "makerFee": 0.0,
    "feeCurrency": "acquired"
  }
}

Retrieves a single instrument info.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID

Response

Name Type Description
result object
-> id string Instrument ID
-> displayName string Descriptive name
-> type string Type. Supported values: spot
-> base string Base asset
-> quote string Quote asset
-> minQty decimal Min order quantity
-> maxQty decimal Max order quantity
-> tickSize decimal Tick size
-> takerFee decimal User fee as a taker
-> makerFee decimal User fee as a maker
-> feeCurrency string Fee currency. Supported values: base, quote, acquired

/v1/public/get-order-book

Request

curl -X GET 'https://api.uvas.com/v1/public/get-order-book?instrumentId=ETH-BTC&depth=2'

Response

{
  "result": {
    "bids": [
      [ 0.025935, 0.1063 ],
      [ 0.025927, 0.2573 ]
    ],
    "asks": [
      [ 0.02597, 0.1933 ],
      [ 0.025978, 0.1658 ]
    ],
    "time": 1594801120260274
  }
}

Retrieves a list of open orders by instrument.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID
depth integer No Depth. All levels if omitted

Response

Name Type Description
result object
-> bids array of 2-element arrays Sorted bids. First element is price. Second element is quantity
-> asks array of 2-element arrays Sorted asks. First element is price. Second element is quantity
-> time timestamp Server time

/v1/public/get-ticker

Request

curl -X GET 'https://api.uvas.com/v1/public/get-ticker?instrumentId=ETH-BTC'

Response

{
  "result": {
    "lastTradeId": 2340622,
    "price": 0.025958,
    "qty": 0.167,
    "bidPrice": 0.025941,
    "askPrice": 0.025976,
    "bidQty": 0.1469,
    "askQty": 0.1767,
    "volumeUsd": 20815.51,
    "volume": 53.2365,
    "time": 1594801336189644
  }
}

Retrieves a last trade price, best bid/ask and 24h volume by instrument.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID

Response

Name Type Description
result object
-> lastTradeId long Last trade ID
-> price decimal Last trade price
-> qty decimal Last trade quantity
-> bidPrice decimal Best bid price
-> askPrice decimal Best ask price
-> bidQty decimal Best bid quantity
-> askQty decimal Best ask quantity
-> volumeUsd decimal 24h volume in USD
-> volume decimal 24h volume in base currency
-> time timestamp Server time

/v1/public/get-last-trades

Request

curl -X GET 'https://api.uvas.com/v1/public/get-last-trades?instrumentId=ETH-BTC&start=1594800000000000&end=1594800600000000&offset=5&limit=2'

Response

{
  "result": {
    "data": [
      {
        "id": 2340564,
        "time": 1594800486782215,
        "price": 0.02595400,
        "qty": 0.05280000,
        "side": "buy"
      },
      {
        "id": 2340563,
        "time": 1594800474577835,
        "price": 0.02595400,
        "qty": 0.03910000,
        "side": "sell"
      }
    ],
    "next": true
  }
}

Retrieves a list of last trades by instrument.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200
start timestamp No Return trades from specified date/time
end timestamp No Return trades until specified date/time

Response

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of trades
--> id long Trade ID
--> time timestamp Date and time
--> price decimal Price
--> qty decimal Quantity
--> side string Side. Supported values: buy, sell

/v1/public/get-candles

Request

curl -X GET 'https://api.uvas.com/v1/public/get-candles?instrumentId=ETH-BTC&size=60&start=1594800000000000&end=1594800600000000&offset=5&limit=2'

Response

{
  "result": {
    "data": [
      {
        "time": 1594800288981015,
        "low": 0.025954,
        "high": 0.025954,
        "open": 0.025954,
        "close": 0.025954,
        "volume": 0.1
      },
      {
        "time": 1594800348981015,
        "low": 0.025954,
        "high": 0.025954,
        "open": 0.025954,
        "close": 0.025954,
        "volume": 0.003
      }
    ],
    "next": true
  }
}

Retrieves a list of candles by instrument.

Parameters

Pagination is supported.

Name Type Required Description
instrumentId string Yes Instrument ID
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200
start timestamp No Return candles from specified date/time
end timestamp No Return candles until specified date/time
size integer Yes Candle size in seconds. Supported values: 60 (1m), 300 (5m), 900 (15m), 3600 (1h), 43200 (12h)

Response

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of candles
--> time timestamp Time of candle start
--> low decimal Low price
--> high decimal High price
--> open decimal Open price
--> close decimal Close price
--> volume decimal Volume in base currency

/v1/public/get-stats

Request

curl -X GET 'https://api.uvas.com/v1/public/get-stats?instrumentId=ETH-BTC'

Response

{
  "result": {
    "first": 0.02595500,
    "last": 0.025969,
    "low": 0.025916,
    "high": 0.02610700,
    "volumeUsd": 21147.71,
    "volume": 54.0862
  }
}

Retrieves last 24 hr stats for the instrument.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID

Response

Name Type Description
result array of objects
-> first decimal First price
-> last decimal Last price
-> low decimal Lowest price
-> high decimal Highest price
-> volumeUsd decimal Volume in USD
-> volume decimal Volume in base currency

Account

/v1/private/get-account-summary

Request

curl -X GET 'https://api.uvas.com/v1/private/get-account-summary?extended=true' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": {
    "id": 11,
    "visibleIdentity": "kYMqRfWAQ7",   
    "tier": 1,
    "email": "user@email.address",
    "registrationTimestamp": 1348287392009658,
    "tfaEnabled": false,
    "assets": {
      "BTC": {
        "depositAddress": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
        "balance": {
          "total": 123.5,
          "available": 100,
          "blocked": 23.5
        }
      },
      "ETH": {
        ...
      }
    },
    "trading": {
      "allowed": true
    },
    "fundsTransfers": {
      "depositsAllowed": true,
      "withdrawalsAllowed": false
    }
  }
}

Retrieves account summary.

Parameters

Name Type Required Description
extended boolean No Include additional fields

Response

Name Type Description
result object
-> id integer User ID (available when extended = true)
-> visibleIdentity string Visible identity (available when extended = true)
-> tier integer User tier (available when extended = true)
-> email string User email (available when extended = true)
-> registrationTimestamp timestamp Registration date (available when extended = true)
-> tfaEnabled boolean TFA status (available when extended = true)
-> assets object
--> assetId object Asset ID
---> depositAddress string Deposit address
---> balance object
----> available decimal Available user balance
----> blocked decimal Blocked user balance
----> total decimal Total user balance (available + blocked)
-> trading object
--> allowed boolean User can trade
-> fundsTransfers object
--> depositAllowed boolean User can deposit funds
--> withdrawalAllowed boolean User can withdrawal funds

Wallet

/v1/private/get-fees

Request

curl -X GET 'https://api.uvas.com/v1/private/get-fees' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": [
    {
      "asset": "BTC",
      "deposit": {
        "fixedFee": 0.000001,
        "percentFee": 0,
        "minAmount": 0.0001
      },
      "withdrawal": {
        "fixedFee": 0.000002,
        "percentFee": 0,
        "minAmount": 0.002
      }
    },
    ...
  ]
}

Returns funds transfer fees for the account.

Parameters

No parameters.

Response

Name Type Description
result array of objects
-> asset string Asset ID
-> deposit object
--> fixedFee decimal Fixed fee
--> percentFee decimal Percent fee
--> minAmount decimal Min amount
-> withdrawal object
--> fixedFee decimal Fixed fee
--> percentFee decimal Percent fee
--> minAmount decimal Min amount

/v1/private/get-deposit-address

Request

curl -X GET 'https://api.uvas.com/v1/private/get-deposit-address?asset=BTC' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": {
    "asset": "BTC",
    "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc"
  }
}

Retrieves a deposit address for the specified asset.

Parameters

Name Type Required Description
asset string Yes Asset ID

Response

Name Type Description
result object
-> asset string Asset ID
-> address string Deposit address

/v1/private/get-deposits

Request

curl -X GET 'https://api.uvas.com/v1/private/get-deposits?asset=BTC&start=1594800000000000&end=1594800600000000&offset=5&limit=2' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": {
    "data": [
      {
        "id": 234,
        "timestamp": 1594800486782215,
        "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
        "asset": "BTC",
        "amount": 0.001,
        "fee": 0.000002,
        "transactionId": null,
        "status": "pending"
      },
      ...
    ],
    "next": true
  }
}

Retrieves a list of user deposits (incoming transfers).

Parameters

Name Type Required Description
asset string No Asset ID
start timestamp No Return deposits from specified date/time
end timestamp No Return deposits until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of deposits
--> id long Deposit ID
--> timestamp timestamp Date and time
--> address string Deposit address
--> asset string Asset ID
--> amount decimal Amount
--> fee decimal Fee
--> transactionId string Transaction ID. null if transaction id not available
--> status string Deposit status pending, settled, clearing, cleared

/v1/private/withdraw

Request

curl -X POST 'https://api.uvas.com/v1/private/withdraw' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer accessToken' \
-d '{
  "asset": "BTC",
  "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
  "amount": 0.1
}'

Response

{
  "result": {
    "id": 234,
    "timestamp": 1594800486782215,
    "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
    "asset": "BTC",
    "amount": 0.099998,
    "fee": 0.000002,
    "transactionId": null,
    "status": "pending"
  }
}

Creates a new withdrawal request.

Parameters

Name Type Required Description
asset string required Asset ID
address string required Address
amount string required Withdrawal amount

Response

Name Type Description
result object
-> id long Withdrawal ID
-> timestamp timestamp Date and time
-> address string Withdrawal address
-> asset string Asset ID
-> amount decimal Amount
-> fee decimal Fee
-> transactionId string Transaction ID. null if transaction id not available
-> status string Withdrawal status awaitingAuthentication, pending, rejected, settled, cleared, cancelledByUser, cancelledByProcessor

/v1/private/get-withdrawals

Request

curl -X GET 'https://api.uvas.com/v1/private/get-withdrawals?asset=BTC&start=1594800000000000&end=1594800600000000&offset=5&limit=2' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": {
    "data": [
      {
        "id": 234,
        "timestamp": 1594800486782215,
        "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
        "asset": "BTC",
        "amount": 0.001,
        "fee": 0.000002,
        "transactionId": null,
        "status": "pending"
      },
      ...
    ],
    "next": true
  }
}

Retrieves a list of user withdrawals (outgoing transfers).

Parameters

Name Type Required Description
asset string No Asset ID
start timestamp No Return withdrawals from specified date/time
end timestamp No Return withdrawals until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of withdrawals
--> id long Withdrawal ID
--> timestamp timestamp Date and time
--> address string Withdrawal address
--> asset string Asset ID
--> amount decimal Amount
--> fee decimal Fee
--> transactionId string Transaction ID. null if transaction id not available
--> status string Withdrawal status awaitingAuthentication, pending, rejected, settled, cleared, cancelledByUser, cancelledByProcessor

Trading

/v1/private/place-order

Request

curl -X POST 'https://api.uvas.com/v1/private/place-order' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer accessToken' \
-d '{
  "instrumentId": "ETH-BTC",
  "type": "limit",
  "side": "sell",
  "price": 0.02595400,
  "qty": 0.02595400
}'

Response

{
  "result": {
    "orderId": 234
  }
}

Places a new order.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID
type string Yes Order type. Supported values: limit, market
side string Yes Order side. Supported values: buy, sell
price decimal Conditional Order price, ignored for market orders
qty decimal Conditional Order quantity in base asset
cashQty decimal Conditional Order quantity in quote asset

qty specifies the amount of base asset to buy/sell. CashQty specifies the amount of quote asset to spend/receive to buy/sell base asset. For a limit order qty must be set and cashQty must not be set. For a market order one of these values must be set. If none or both values are set, an error is reported.

Response

Name Type Description
result object
-> orderId long Placed order ID

/v1/private/edit-order

Request

curl -X POST 'https://api.uvas.com/v1/private/edit-order' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer accessToken' \
-d '{
  "orderId": 234,
  "type": "limit",
  "price": 0.02595400,
  "qty": 0.02595400,
  "cancelOriginalOnReject": false
}'

Response

{
  "result": {
    "originalOrderId": 234,
    "newOrderId": 567,
    "status": "replaced"
  }
}

Response (cancelOriginalOnReject = true)

{
  "result": {
    "originalOrderId": 234,
    "newOrderId": null,
    "status": "cancelled"
  }
}

Edits order parameters.

Parameters

Name Type Required Description
orderId long Yes Order ID
type string No Order type. Supported values: limit, market
price decimal No Order price, only for limit orders
qty decimal Yes Order quantity in base asset
cancelOriginalOnReject boolean No Original order should be cancelled if request is rejected

Response

Name Type Description
result object
-> originalOrderId long Original order ID
-> newOrderId long New order ID. Not null if order is replaced
-> status string Execution status notChanged, cancelled, edited, replaced

/v1/private/get-order

Request

curl -X GET 'https://api.uvas.com/v1/private/get-order?id=234' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": {
    "id": 234,
    "instrumentId": "ETH-BTC",
    "status": "filled",
    "type": "limit",
    "side": "sell",
    "qty": 0.02000123,
    "cumQty": 0.02000123,
    "price": 0.02595400,
    "timestamp": 1594800486782215
  }
}

Retrieves the order.

Parameters

Name Type Required Description
orderId long Yes Order ID

Response

Name Type Description
result object
-> id long Order ID
-> instrumentId string Instrument ID
-> status string Order status open, partiallyFilled, filled, cancelled
-> type string Order type limit, market
-> side string Order side buy, sell
-> qty decimal Total quantity
-> cumQty decimal Executed quantity
-> price decimal Price
-> timestamp timestamp Date and time

/v1/private/cancel-order

Request

curl -X POST 'https://api.uvas.com/v1/private/cancel-order' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer accessToken' \
-d '{
  "orderId": 234
}'

Response

{
  "result": {
    "id": 234,
    "instrumentId": "ETH-BTC",
    "status": "cancelled",
    "type": "limit",
    "side": "sell",
    "qty": 0.02000123,
    "cumQty": 0.01595400,
    "price": 0.02595400,
    "timestamp": 1594800486782215
  }
}

Cancels the order.

Parameters

Name Type Required Description
orderId long Yes Order ID

Response

Name Type Description
result object
-> id long Cancelled order ID
-> instrumentId string Instrument ID
-> status string Order status cancelled
-> type string Order type limit, market
-> side string Order side buy, sell
-> qty decimal Total quantity
-> cumQty decimal Executed quantity
-> price decimal Price
-> timestamp timestamp Date and time

/v1/private/cancel-all-orders

Request

curl -X POST 'https://api.uvas.com/v1/private/cancel-all-orders' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer accessToken' \
-d '{
  "instrumentId": "ETH-BTC",
  "side": "sell"
}'

Response

{
  "result": [
    234,
    456
  ]
}

Cancels all orders.

Parameters

Name Type Required Description
instrumentId string No Instrument ID
side string No Order side. Supported values: buy, sell

Response

Name Type Description
result array of long Cancelled order IDs

/v1/private/get-open-orders

Request

curl -X GET 'https://api.uvas.com/v1/private/get-open-orders?instrumentId=ETH-BTC&side=sell&start=1594800000000000&end=1594800600000000&offset=5&limit=2' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": {
    "data": [
      {
        "id": 234,
        "instrumentId": "ETH-BTC",
        "status": "open",
        "type": "limit",
        "side": "sell",
        "qty": 0.02000123,
        "cumQty": 0.01595400,
        "price": 0.02595400,
        "timestamp": 1594800486782215
      },
      ...
    ],
    "next": true
  }
}

Retrieves open and partially filled orders.

Parameters

Name Type Required Description
instrumentId string No Instrument ID
side string No Order side. Supported values: buy, sell
start timestamp No Return orders from specified date/time
end timestamp No Return orders until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of orders
--> id long Order ID
--> instrumentId string Instrument ID
--> status string Order status open, partiallyFilled
--> type string Order type limit, market
--> side string Order side buy, sell
--> qty decimal Total quantity
--> cumQty decimal Executed quantity
--> price decimal Price
--> timestamp timestamp Date and time

/v1/private/get-orders

Request

curl -X GET 'https://api.uvas.com/v1/private/get-orders?instrumentId=ETH-BTC&side=sell&includeCancelled=true&start=1594800000000000&end=1594800600000000&offset=5&limit=2' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": {
    "data": [
      {
        "id": 234,
        "instrumentId": "ETH-BTC",
        "status": "filled",
        "type": "limit",
        "side": "sell",
        "qty": 0.02000123,
        "cumQty": 0.02000123,
        "price": 0.02595400,
        "timestamp": 1594800486782215
      },
      ...
    ],
    "next": true
  }
}

Retrieves filled and cancelled orders.

Parameters

Name Type Required Description
instrumentId string No Instrument ID
side string No Order side. Supported values: buy, sell
includeCancelled boolean No Include cancelled orders
start timestamp No Return orders from specified date/time
end timestamp No Return orders until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of orders
--> id long Order ID
--> instrumentId string Instrument ID
--> status string Order status filled, cancelled
--> type string Order type limit, market
--> side string Order side buy, sell
--> qty decimal Total quantity
--> cumQty decimal Executed quantity
--> price decimal Price
--> timestamp timestamp Date and time

/v1/private/get-trades

Request

curl -X GET 'https://api.uvas.com/v1/private/get-trades?instrumentId=ETH-BTC&start=1594800000000000&end=1594800600000000&offset=5&limit=2' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": {
    "data": [
      {
        "id": 1,
        "instrumentId": "ETH-BTC",
        "price": 0.02595400,
        "qty": 0.02000123,
        "orderId": 234,
        "userSide": "sell",
        "fee": 0.00000001,
        "feeAsset": "BTC",
        "timestamp": 1594800486782215
      },
      ...
    ],
    "next": true
  }
}

Retrieves trades.

Parameters

Name Type Required Description
instrumentId string No Instrument ID
start timestamp No Return trades from specified date/time
end timestamp No Return trades until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of trades
--> id long Trade ID
--> instrumentId string Instrument ID
--> price decimal Price
--> qty decimal Total quantity
--> orderId long Order ID
--> userSide string User side buy, sell
--> fee decimal Fee
--> feeAsset string Fee asset
--> timestamp timestamp Date and time

/v1/private/get-trades-by-order

Request

curl -X GET 'https://api.uvas.com/v1/private/get-trades-by-order?orderId=234' \
-H 'Authorization: Bearer accessToken'

Response

{
  "result": [
    {
      "id": 1,
      "instrumentId": "ETH-BTC",
      "price": 0.02595400,
      "qty": 0.02000123,
      "orderId": 234,
      "userSide": "sell",
      "fee": 0.00000001,
      "feeAsset": "BTC",
      "timestamp": 1594800486782215
    },
    ...
  ]
}

Retrieves trades for the specified order.

Parameters

Name Type Required Description
orderId long Yes Order ID

Response

Items are sorted by date. From old to new.

Name Type Description
result array of objects
-> id long Trade ID
-> instrumentId string Instrument ID
-> price decimal Price
-> qty decimal Total quantity
-> orderId long Order ID
-> userSide string User side buy, sell
-> fee decimal Fee
-> feeAsset string Fee asset
-> timestamp timestamp Date and time

Error Codes

{
  "10000": "General server error.",
  "10001": "Request timeout.",
  "10002": "Too many requests.",
  "10500": "Several request parameters are invalid.",
  "10501": "Request parameters have incorrect format.",
  "10502": "Period is invalid.",
  "10503": "Offset is invalid.",
  "10504": "Limit is invalid.",
  "12000": "User is not authorized.",
  "12001": "User is not authenticated.",
  "12002": "Session token expired.",
  "12004": "Login failed.",
  "12005": "Login temporarily locked.",
  "12006": "User blocked.",
  "12500": "Grant type is invalid.",
  "12501": "Api key is required.",
  "12502": "Api passphrase is required.",
  "12503": "Signature is required.",
  "12504": "Timestamp is required.",
  "12505": "Refresh token is required.",
  "12506": "Access token is required.",
  "13000": "Instrument not found.",
  "13001": "Asset not found.",
  "13500": "Instrument id is invalid.",
  "13501": "Asset id is invalid.",
  "13502": "Instrument type is invalid.",
  "14500": "Depth is invalid.",
  "14501": "Candle size is invalid.",
  "15000": "Trading not allowed.",
  "15001": "Order not found.",
  "15002": "Market not found.",
  "15003": "Market is closed.",
  "15004": "Market is empty.",
  "15500": "Order type is invalid.",
  "15501": "Order side is invalid.",
  "15502": "Order id is invalid.",
  "15503": "Quantity is invalid.",
  "15504": "Cash quantity is invalid.",
  "15505": "Price is invalid.",
  "16000": "Limit exceeded.",
  "16001": "Insufficient funds.",
  "16002": "Deposits not allowed.",
  "16003": "Withdrawals not allowed.",
  "16500": "Address is invalid.",
  "16501": "Amount is invalid."
}
Code Message Description
10000 General server error. An error occurred on the server while serving the request.
10001 Request timeout. Timeout occurred on the server while serving the request.
10002 Too many requests. Request rate exceeded the API limits.
10500 Several request parameters are invalid. Two or more request parameters are invalid.
10501 Request parameters have incorrect format. An error occurred on the server while parsing the request parameters.
10502 Period is invalid. Date period is invalid.
10503 Offset is invalid. Paging offset is invalid.
10504 Limit is invalid. Paging limit is invalid.
12000 User is not authorized. User is not authorized.
12001 User is not authenticated. User is not authenticated.
12004 Login failed. Login failed due to incorrect credentials.
12005 Login temporarily locked. Login is temporarily locked.
12006 User is blocked. User account is suspended.
12500 Grant type is invalid. Grant type is invalid.
12501 Api key is required. Api key is required.
12502 Api passphrase is required. Api passphrase is required.
12503 Signature is required. Signature is required.
12504 Timestamp is required. Timestamp is required.
12505 Refresh token is required. Refresh token is required.
12506 Access token is required. Access token is required.
13000 Instrument not found. Instrument does not exist.
13001 Asset not found. Asset does not exist.
13500 Instrument id is invalid. Instrument ID has invalid format.
13501 Asset id is invalid. Asset ID has invalid format.
13502 Instrument type is invalid. Instrument type has invalid format or is not supported by the server.
14500 Depth is invalid. Order book depth value is invalid.
14501 Candle size is invalid. Candle size is invalid.
15000 Trading not allowed. Trading not allowed for this user.
15001 Order not found. Order not found.
15002 Market not found. Market does not exist.
15003 Market is closed. Market is closed.
15004 Market is empty. Market is empty.
15500 Order type is invalid. Order type has invalid format or is not supported by the server.
15501 Order side is invalid. Order side has invalid format or is not supported by the server.
15502 Order id is invalid. Order ID has invalid format.
15503 Quantity is invalid. Order quantity is invalid.
15504 Cash quantity is invalid. Order cash quantity is invalid.
15505 Price is invalid. Order price is invalid.
16000 Limit exceeded. Deposit/withdrawal limit exceeded.
16001 Insufficient funds. Insufficient funds for this withdrawal.
16002 Deposits not allowed. Deposits not allowed for this user.
16003 Withdrawals not allowed. Withdrawals not allowed for this user.
16500 Address is invalid. Address has invalid format.
16501 Amount is invalid. Amount value is invalid.

JSON-RPC API

Uvas Exchange provides a JSON-RPC API using JSON-RPC 2.0.

JSON-RPC does not specify what transport protocol must be used. Uvas JSON-RPC API currently supports HTTPS and WebSockets.

Connection

JSON-RPC API endpoint is https://api.uvas.com/v1 or wss://api.uvas.com/v1 for public and private methods.

Rate Limiting

Uvas Exchange uses rate limiting to ensure API availability and processing capacity. Any single IP can send up to 3 requests per second.

Request/Response Structure

Request

Request

{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-stats",
  "params": {
    "instrumentId": "ETH-BTC"
  }
}

According to the JSON-RPC specification requests must be JSON objects with the following structure:

Name Type Description
jsonrpc string JSON-RPC version. Must be 2.0
id string Request ID to match requests and responses. Can be omitted
method string Requested method
params object Requested method parameters. Can be omitted if the requested method requires no parameters

Success response

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "first": 0.02595500,
    "last": 0.025969,
    "low": 0.025916,
    "high": 0.02610700,
    "volumeUsd": 21147.71,
    "volume": 54.0862
  }
}

If successful, the API returns a response with the following structure:

Name Type Description
jsonrpc string JSON-RPC version. Will be 2.0
id string Response ID that equals the corresponding request ID. Will be null if the request had no ID
result object or array Object or array with the request processing result

Error response

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "error": {
    "code": 13500,
    "message": "Instrument id is invalid."
  }
}

In case of an error the API returns a response with the following structure:

Name Type Description
jsonrpc string JSON-RPC version. Will be 2.0
id string Response ID that equals the corresponding request ID. Will be null if the request had no ID
error object Request processing error
-> code integer Error code
-> message string Error message
-> data object Additional error data specific to the given error code

Data Types

Timestamps

All timestamps are represented as UNIX epoch timestamps in microseconds, if not specified otherwise.

Authentication

/v1/public/get-token

Request (grantType = passphrase)

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-token",
  "params": {
    "grantType": "passphrase",
    "apiKey": "ydb17hvUb5Haa2IF",
    "apiPassphrase": "tvhftAj1Xv5ZIHiDl4eWSLOL"
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-token",
  "params": {
    "grantType": "passphrase",
    "apiKey": "ydb17hvUb5Haa2IF",
    "apiPassphrase": "tvhftAj1Xv5ZIHiDl4eWSLOL"
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Request (grantType = signature)

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-token",
  "params": {
    "grantType": "signature",
    "apiKey": "ydb17hvUb5Haa2IF",
    "timestamp": 1594800486782215,
    "signature": "3fa04a98094320084f0c9363b42491650f450ec116f7edfb8ba3cbf421381671"
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-token",
  "params": {
    "grantType": "signature",
    "apiKey": "ydb17hvUb5Haa2IF",
    "timestamp": 1594800486782215,
    "signature": "3fa04a98094320084f0c9363b42491650f450ec116f7edfb8ba3cbf421381671"
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Request (grantType = refreshToken)

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-token",
  "params": {
    "grantType": "refreshToken",
    "accessToken": "...",
    "refreshToken": "..."
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-token",
  "params": {
    "grantType": "refreshToken",
    "accessToken": "...",
    "refreshToken": "..."
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "accessToken": "...",
    "refreshToken": "..."
  }
}

Gets access and refresh tokens.

Parameters

Name Type Required Description
grantType string Yes Grant type. Supported values: passphrase, signature, refreshToken
apiKey string Conditional API key, required for grantType = passphrase and grantType = signature
apiPassphrase string Conditional API passphrase, required for grantType = passphrase
signature string Conditional User generated signature, required for grantType = signature
timestamp timestamp Conditional Timestamp, required for grantType = signature
accessToken string Conditional Access token, required for grantType = refreshToken.
refreshToken string Conditional Refresh token, required for grantType = refreshToken

echo -n "timestamp.apiKey" | openssl sha256 -hmac "apiPassphrase"

Example:

echo -n "1594800486782215.ydb17hvUb5Haa2IF" | openssl sha256 -hmac "tvhftAj1Xv5ZIHiDl4eWSLOL"

3fa04a98094320084f0c9363b42491650f450ec116f7edfb8ba3cbf421381671

Response

Name Type Description
result object
-> accessToken string Access token
-> refreshToken string Refresh token

/v1/private/revoke-token

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/revoke-token"
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/revoke-token",
  "params": {
    "accessToken": "..."
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {}
}

Revokes refresh token.

Parameters

No parameters.

Response

Empty JSON-RPC response.

WebSocket

Parameters

Name Type Required Description
accessToken string Yes JWT token for revocation without Bearer prefix.

Response

Empty JSON-RPC response.

Session (WebSocket only)

/v1/public/set-session-token

Request

var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/set-session-token",
  "params": {
    "token": "accessToken"
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {}
}

Sets the session token for the current WebSocket connection.

Parameters

Name Type Required Description
token string required JWT token without Bearer prefix

Response

Empty JSON-RPC response.

/v1/private/clear-session-token

Request

var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/clear-session-token"
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {}
}

Clears the session token for the current WebSocket connection.

Parameters

No parameters.

Response

Empty JSON-RPC response.

Market Data

Market data methods are public and require no authentication.

/v1/public/get-assets

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-assets"
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-assets"
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": [
    {
      "id": "BTC",
      "displayName": "Bitcoin"
    },
    {
      "id": "ETH",
      "displayName": "Ethereum"
    }
  ]
}

Retrieves all assets supported by the API.

Parameters

No parameters.

Response

Name Type Description
result array of objects
-> id string Id
-> displayName string Descriptive name

/v1/public/get-instruments

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-instruments",
  "params": {
    "type": "spot",
    "asset": "ETH"
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-instruments",
  "params": {
    "type": "spot",
    "asset": "ETH"
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": [
    {
      "id": "ETH-BTC",
      "displayName": "ETH/BTC",
      "type": "spot",
      "base": "ETH",
      "quote": "BTC",
      "minQty": 0.0001,
      "maxQty": 10000000.0,
      "tickSize": 0.000001,
      "takerFee": 0.001,
      "makerFee": 0.0,
      "feeCurrency": "acquired"
    },
    {
      "id": "ETH-USDT",
      "displayName": "ETH/USDT",
      "type": "spot",
      "base": "ETH",
      "quote": "USDT",
      "minQty": 0.001,
      "maxQty": 10000000.0,
      "tickSize": 0.01,
      "takerFee": 0.001,
      "makerFee": 0.0,
      "feeCurrency": "acquired"
    }
  ]
}

Retrieves all instruments supported by the API.

Parameters

Name Type Required Description
asset string No Asset ID
type string No Type. Supported values: spot

Response

Name Type Description
result array of objects
-> id string Instrument ID
-> displayName string Descriptive name
-> type string Type. Supported values: spot
-> base string Base asset
-> quote string Quote asset
-> minQty decimal Min order quantity
-> maxQty decimal Max order quantity
-> tickSize decimal Tick size
-> takerFee decimal User fee as a taker
-> makerFee decimal User fee as a maker
-> feeCurrency string Fee currency. Supported values: base, quote, acquired

/v1/public/get-instrument

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-instrument",
  "params": {
    "instrumentId": "ETH-BTC"
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-instrument",
  "params": {
    "instrumentId": "ETH-BTC"
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "id": "ETH-BTC",
    "displayName": "ETH/BTC",
    "type": "spot",
    "base": "ETH",
    "quote": "BTC",
    "minQty": 0.0001,
    "maxQty": 10000000.0,
    "tickSize": 0.000001,
    "takerFee": 0.001,
    "makerFee": 0.0,
    "feeCurrency": "acquired"
  }
}

Retrieves a single instrument info.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID

Response

Name Type Description
result object
-> id string Instrument ID
-> displayName string Descriptive name
-> type string Type. Supported values: spot
-> base string Base asset
-> quote string Quote asset
-> minQty decimal Min order quantity
-> maxQty decimal Max order quantity
-> tickSize decimal Tick size
-> takerFee decimal User fee as a taker
-> makerFee decimal User fee as a maker
-> feeCurrency string Fee currency. Supported values: base, quote, acquired

/v1/public/get-order-book

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-order-book",
  "params": {
    "instrumentId": "ETH-BTC",
    "depth": 2
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-order-book",
  "params": {
    "instrumentId": "ETH-BTC",
    "depth": 2
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "bids": [
      [ 0.025935, 0.1063 ],
      [ 0.025927, 0.2573 ]
    ],
    "asks": [
      [ 0.02597, 0.1933 ],
      [ 0.025978, 0.1658 ]
    ],
    "time": 1594801120260274
  }
}

Retrieves a list of open orders by instrument.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID
depth integer No Depth. All levels if omitted

Response

Name Type Description
result object
-> bids array of 2-element arrays Sorted bids. First element is price. Second element is quantity
-> asks array of 2-element arrays Sorted asks. First element is price. Second element is quantity
-> time timestamp Server time

/v1/public/get-ticker

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-ticker",
  "params": {
    "instrumentId": "ETH-BTC"
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-ticker",
  "params": {
    "instrumentId": "ETH-BTC"
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "lastTradeId": 2340622,
    "price": 0.025958,
    "qty": 0.167,
    "bidPrice": 0.025941,
    "askPrice": 0.025976,
    "bidQty": 0.1469,
    "askQty": 0.1767,
    "volumeUsd": 20815.51,
    "volume": 53.2365,
    "time": 1594801336189644
  }
}

Retrieves a last trade price, best bid/ask and 24h volume by instrument.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID

Response

Name Type Description
result object
-> lastTradeId long Last trade ID
-> price decimal Last trade price
-> qty decimal Last trade quantity
-> bidPrice decimal Best bid price
-> askPrice decimal Best ask price
-> bidQty decimal Best bid quantity
-> askQty decimal Best ask quantity
-> volumeUsd decimal 24h volume in USD
-> volume decimal 24h volume in base currency
-> time timestamp Server time

/v1/public/get-last-trades

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-last-trades",
  "params": {
    "instrumentId": "ETH-BTC",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-last-trades",
  "params": {
    "instrumentId": "ETH-BTC",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "data": [
      {
        "id": 2340564,
        "time": 1594800486782215,
        "price": 0.02595400,
        "qty": 0.05280000,
        "side": "buy"
      },
      {
        "id": 2340563,
        "time": 1594800474577835,
        "price": 0.02595400,
        "qty": 0.03910000,
        "side": "sell"
      }
    ],
    "next": true
  }
}

Retrieves a list of last trades by instrument.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200
start timestamp No Return trades from specified date/time
end timestamp No Return trades until specified date/time

Response

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of trades
--> id long Trade ID
--> time timestamp Date and time
--> price decimal Price
--> qty decimal Quantity
--> side string Side. Supported values: buy, sell

/v1/public/get-candles

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-candles",
  "params": {
    "instrumentId": "ETH-BTC",
    "size": 60,
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-candles",
  "params": {
    "instrumentId": "ETH-BTC",
    "size": 60,
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "data": [
      {
        "time": 1594800288981015,
        "low": 0.025954,
        "high": 0.025954,
        "open": 0.025954,
        "close": 0.025954,
        "volume": 0.1
      },
      {
        "time": 1594800348981015,
        "low": 0.025954,
        "high": 0.025954,
        "open": 0.025954,
        "close": 0.025954,
        "volume": 0.003
      }
    ],
    "next": true
  }
}

Retrieves a list of candles by instrument.

Parameters

Pagination is supported.

Name Type Required Description
instrumentId string Yes Instrument ID
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200
start timestamp No Return candles from specified date/time
end timestamp No Return candles until specified date/time
size integer Yes Candle size in seconds. Supported values: 60 (1m), 300 (5m), 900 (15m), 3600 (1h), 43200 (12h)

Response

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of candles
--> time timestamp Time of candle start
--> low decimal Low price
--> high decimal High price
--> open decimal Open price
--> close decimal Close price
--> volume decimal Volume in base currency

/v1/public/get-stats

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-stats",
  "params": {
    "instrumentId": "ETH-BTC"
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "public/get-stats",
  "params": {
    "instrumentId": "ETH-BTC"
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "first": 0.02595500,
    "last": 0.025969,
    "low": 0.025916,
    "high": 0.02610700,
    "volumeUsd": 21147.71,
    "volume": 54.0862
  }
}

Retrieves last 24 hr stats for the instrument.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID

Response

Name Type Description
result array of objects
-> first decimal First price
-> last decimal Last price
-> low decimal Lowest price
-> high decimal Highest price
-> volumeUsd decimal Volume in USD
-> volume decimal Volume in base currency

Account

/v1/private/get-account-summary

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-account-summary",
  "params": {
    "extended": true
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-account-summary",
  "params": {
    "extended": true
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "id": 11,
    "visibleIdentity": "kYMqRfWAQ7",   
    "tier": 1,
    "email": "user@email.address",
    "registrationTimestamp": 1348287392009658,
    "tfaEnabled": false,
    "assets": {
      "BTC": {
        "depositAddress": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
        "balance": {
          "total": 123.5,
          "available": 100,
          "blocked": 23.5
        }
      },
      "ETH": {
        ...
      }
    },
    "trading": {
      "allowed": true
    },
    "fundsTransfers": {
      "depositsAllowed": true,
      "withdrawalsAllowed": false
    }
  }
}

Retrieves account summary.

Parameters

Name Type Required Description
extended boolean No Include additional fields

Response

Name Type Description
result object
-> id integer User ID (available when extended = true)
-> visibleIdentity string Visible identity (available when extended = true)
-> tier integer User tier (available when extended = true)
-> email string User email (available when extended = true)
-> registrationTimestamp timestamp Registration date (available when extended = true)
-> tfaEnabled boolean TFA status (available when extended = true)
-> assets object
--> assetId object Asset ID
---> depositAddress string Deposit address
---> balance object
----> available decimal Available user balance
----> blocked decimal Blocked user balance
----> total decimal Total user balance (available + blocked)
-> trading object
--> allowed boolean User can trade
-> fundsTransfers object
--> depositAllowed boolean User can deposit funds
--> withdrawalAllowed boolean User can withdrawal funds

Wallet

/v1/private/get-fees

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-fees"
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-fees"
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": [
    {
      "asset": "BTC",
      "deposit": {
        "fixedFee": 0.000001,
        "percentFee": 0,
        "minAmount": 0.0001
      },
      "withdrawal": {
        "fixedFee": 0.000002,
        "percentFee": 0,
        "minAmount": 0.002
      }
    },
    ...
  ]
}

Returns funds transfer fees for the account.

Parameters

No parameters.

Response

Name Type Description
result array of objects
-> asset string Asset ID
-> deposit object
--> fixedFee decimal Fixed fee
--> percentFee decimal Percent fee
--> minAmount decimal Min amount
-> withdrawal object
--> fixedFee decimal Fixed fee
--> percentFee decimal Percent fee
--> minAmount decimal Min amount

/v1/private/get-deposit-address

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-deposit-address",
  "params": {
    "asset": "BTC"
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-deposit-address",
  "params": {
    "asset": "BTC"
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "asset": "BTC",
    "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc"
  }
}

Retrieves a deposit address for the specified asset.

Parameters

Name Type Required Description
asset string Yes Asset ID

Response

Name Type Description
result object
-> asset string Asset ID
-> address string Deposit address

/v1/private/get-deposits

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-deposits",
  "params": {
    "asset": "BTC",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-deposits",
  "params": {
    "asset": "BTC",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "data": [
      {
        "id": 234,
        "timestamp": 1594800486782215,
        "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
        "asset": "BTC",
        "amount": 0.001,
        "fee": 0.000002,
        "transactionId": null,
        "status": "pending"
      },
      ...
    ],
    "next": true
  }
}

Retrieves a list of user deposits (incoming transfers).

Parameters

Name Type Required Description
asset string No Asset ID
start timestamp No Return deposits from specified date/time
end timestamp No Return deposits until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of deposits
--> id long Deposit ID
--> timestamp timestamp Date and time
--> address string Deposit address
--> asset string Asset ID
--> amount decimal Amount
--> fee decimal Fee
--> transactionId string Transaction ID. null if transaction id not available
--> status string Deposit status pending, settled, clearing, cleared

/v1/private/withdraw

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/withdraw",
  "params": {
    "asset": "BTC",
    "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
    "amount": 0.1
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/withdraw",
  "params": {
    "asset": "BTC",
    "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
    "amount": 0.1
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "id": 234,
    "timestamp": 1594800486782215,
    "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
    "asset": "BTC",
    "amount": 0.099998,
    "fee": 0.000002,
    "transactionId": null,
    "status": "pending"
  }
}

Creates a new withdrawal request.

Parameters

Name Type Required Description
asset string required Asset ID
address string required Address
amount string required Withdrawal amount

Response

Name Type Description
result object
-> id long Withdrawal ID
-> timestamp timestamp Date and time
-> address string Withdrawal address
-> asset string Asset ID
-> amount decimal Amount
-> fee decimal Fee
-> transactionId string Transaction ID. null if transaction id not available
-> status string Withdrawal status awaitingAuthentication, pending, rejected, settled, cleared, cancelledByUser, cancelledByProcessor

/v1/private/get-withdrawals

Request

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-withdrawals",
  "params": {
    "asset": "BTC",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-withdrawals",
  "params": {
    "asset": "BTC",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "data": [
      {
        "id": 234,
        "timestamp": 1594800486782215,
        "address": "17ciVVLxLcdCUCMf9s4t5jTexACxwF55uc",
        "asset": "BTC",
        "amount": 0.001,
        "fee": 0.000002,
        "transactionId": null,
        "status": "pending"
      },
      ...
    ],
    "next": true
  }
}

Retrieves a list of user withdrawals (outgoing transfers).

Parameters

Name Type Required Description
asset string No Asset ID
start timestamp No Return withdrawals from specified date/time
end timestamp No Return withdrawals until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of withdrawals
--> id long Withdrawal ID
--> timestamp timestamp Date and time
--> address string Withdrawal address
--> asset string Asset ID
--> amount decimal Amount
--> fee decimal Fee
--> transactionId string Transaction ID. null if transaction id not available
--> status string Withdrawal status awaitingAuthentication, pending, rejected, settled, cleared, cancelledByUser, cancelledByProcessor

Trading

/v1/private/place-order

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/place-order",
  "params": {
    "instrumentId": "ETH-BTC",
    "type": "limit",
    "side": "sell",
    "price": 0.02595400,
    "qty": 0.02595400
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/place-order",
  "params": {
    "instrumentId": "ETH-BTC",
    "type": "limit",
    "side": "sell",
    "price": 0.02595400,
    "qty": 0.02595400
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "id": 234
  }
}

Places a new order.

Parameters

Name Type Required Description
instrumentId string Yes Instrument ID
type string Yes Order type. Supported values: limit, market
side string Yes Order side. Supported values: buy, sell
price decimal Conditional Order price, ignored for market orders
qty decimal Conditional Order quantity in base asset
cashQty decimal Conditional Order quantity in quote asset

qty specifies the amount of base asset to buy/sell. CashQty specifies the amount of quote asset to spend/receive to buy/sell base asset. For a limit order qty must be set and cashQty must not be set. For a market order one of these values must be set. If none or both values are set, an error is reported.

Response

Name Type Description
result object
-> orderId long Placed order ID

/v1/private/edit-order

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/edit-order",
  "params": {
    "orderId": 234,
    "type": "limit",
    "price": 0.02595400,
    "qty": 0.02595400,
    "cancelOriginalOnReject": false
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/edit-order",
  "params": {
    "orderId": 234,
    "type": "limit",
    "price": 0.02595400,
    "qty": 0.02595400,
    "cancelOriginalOnReject": false
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "originalOrderId": 234,
    "newOrderId": 567,
    "status": "replaced"
  }
}

Response (cancelOriginalOnReject = true)

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "originalOrderId": 234,
    "newOrderId": null,
    "status": "cancelled"
  }
}

Edits order parameters.

Parameters

Name Type Required Description
orderId long Yes Order ID
type string No Order type. Supported values: limit, market
price decimal No Order price, only for limit orders
qty decimal Yes Order quantity in base asset
cancelOriginalOnReject boolean No Original order should be cancelled if request is rejected

Response

Name Type Description
result object
-> originalOrderId long Original order ID
-> newOrderId long New order ID. Not null if order is replaced
-> status string Execution status notChanged, cancelled, edited, replaced

/v1/private/get-order

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-order",
  "params": {
    "orderId": 234
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-order",
  "params": {
    "orderId": 234
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "id": 234,
    "instrumentId": "ETH-BTC",
    "status": "filled",
    "type": "limit",
    "side": "sell",
    "qty": 0.02000123,
    "cumQty": 0.02000123,
    "price": 0.02595400,
    "timestamp": 1594800486782215
  }
}

Retrieves the order.

Parameters

Name Type Required Description
orderId long Yes Order ID

Response

Name Type Description
result object
-> id long Order ID
-> instrumentId string Instrument ID
-> status string Order status open, partiallyFilled, filled, cancelled
-> type string Order type limit, market
-> side string Order side buy, sell
-> qty decimal Total quantity
-> cumQty decimal Executed quantity
-> price decimal Price
-> timestamp timestamp Date and time

/v1/private/cancel-order

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/cancel-order",
  "params": {
    "orderId": 234
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/cancel-order",
  "params": {
    "orderId": 234
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "id": 234,
    "instrumentId": "ETH-BTC",
    "status": "cancelled",
    "type": "limit",
    "side": "sell",
    "qty": 0.02000123,
    "cumQty": 0.01595400,
    "price": 0.02595400,
    "timestamp": 1594800486782215
  }
}

Cancels the order.

Parameters

Name Type Required Description
orderId long Yes Order ID

Response

Name Type Description
result object
-> id long Cancelled order ID
-> instrumentId string Instrument ID
-> status string Order status cancelled
-> type string Order type limit, market
-> side string Order side buy, sell
-> qty decimal Total quantity
-> cumQty decimal Executed quantity
-> price decimal Price
-> timestamp timestamp Date and time

/v1/private/cancel-all-orders

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/cancel-all-orders",
  "params": {
    "instrumentId": "ETH-BTC",
    "side": "sell"
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/cancel-all-orders",
  "params": {
    "instrumentId": "ETH-BTC",
    "side": "sell"
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": [
    234,
    456
  ]
}

Cancels all orders.

Parameters

Name Type Required Description
instrumentId string No Instrument ID
side string No Order side. Supported values: buy, sell

Response

Name Type Description
result array of long Cancelled order IDs

/v1/private/get-open-orders

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-open-orders",
  "params": {
    "instrumentId": "ETH-BTC",
    "side": "sell",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-open-orders",
  "params": {
    "instrumentId": "ETH-BTC",
    "side": "sell",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "data": [
      {
        "id": 234,
        "instrumentId": "ETH-BTC",
        "status": "open",
        "type": "limit",
        "side": "sell",
        "qty": 0.02000123,
        "cumQty": 0.01595400,
        "price": 0.02595400,
        "timestamp": 1594800486782215
      },
      ...
    ],
    "next": true
  }
}

Retrieves open and partially filled orders.

Parameters

Name Type Required Description
instrumentId string No Instrument ID
side string No Order side. Supported values: buy, sell
start timestamp No Return orders from specified date/time
end timestamp No Return orders until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of orders
--> id long Order ID
--> instrumentId string Instrument ID
--> status string Order status open, partiallyFilled
--> type string Order type limit, market
--> side string Order side buy, sell
--> qty decimal Total quantity
--> cumQty decimal Executed quantity
--> price decimal Price
--> timestamp timestamp Date and time

/v1/private/get-orders

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-orders",
  "params": {
    "instrumentId": "ETH-BTC",
    "side": "sell",
    "includeCancelled": true,
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-orders",
  "params": {
    "instrumentId": "ETH-BTC",
    "side": "sell",
    "includeCancelled": true,
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "data": [
      {
        "id": 234,
        "instrumentId": "ETH-BTC",
        "status": "filled",
        "type": "limit",
        "side": "sell",
        "qty": 0.02000123,
        "cumQty": 0.02000123,
        "price": 0.02595400,
        "timestamp": 1594800486782215
      },
      ...
    ],
    "next": true
  }
}

Retrieves filled and cancelled orders.

Parameters

Name Type Required Description
instrumentId string No Instrument ID
side string No Order side. Supported values: buy, sell
includeCancelled boolean No Include cancelled orders
start timestamp No Return orders from specified date/time
end timestamp No Return orders until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of orders
--> id long Order ID
--> instrumentId string Instrument ID
--> status string Order status filled, cancelled
--> type string Order type limit, market
--> side string Order side buy, sell
--> qty decimal Total quantity
--> cumQty decimal Executed quantity
--> price decimal Price
--> timestamp timestamp Date and time

/v1/private/get-trades

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-trades",
  "params": {
    "instrumentId": "ETH-BTC",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-trades",
  "params": {
    "instrumentId": "ETH-BTC",
    "start": 1594800000000000,
    "end": 1594800600000000,
    "offset": 5,
    "limit": 2
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": {
    "data": [
      {
        "id": 1,
        "instrumentId": "ETH-BTC",
        "price": 0.02595400,
        "qty": 0.02000123,
        "orderId": 234,
        "userSide": "sell",
        "fee": 0.00000001,
        "feeAsset": "BTC",
        "timestamp": 1594800486782215
      },
      ...
    ],
    "next": true
  }
}

Retrieves trades.

Parameters

Name Type Required Description
instrumentId string No Instrument ID
start timestamp No Return trades from specified date/time
end timestamp No Return trades until specified date/time
offset integer No Pagination offset, 0 if omitted
limit integer No Pagination limit, 20 if omitted. Value cannot be greater than 200

Response

Items are sorted by date. From old to new.

Name Type Description
result object
-> next boolean Next page of results can be retrieved
-> data array of objects Array of trades
--> id long Trade ID
--> instrumentId string Instrument ID
--> price decimal Price
--> qty decimal Total quantity
--> orderId long Order ID
--> userSide string User side buy, sell
--> fee decimal Fee
--> feeAsset string Fee asset
--> timestamp timestamp Date and time

/v1/private/get-trades-by-order

curl -X POST 'https://api.uvas.com/v1' \
-H 'Authorization: Bearer accessToken' \
-H 'Content-Type: application/json' \
-d '{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-trades-by-order",
  "params": {
    "orderId": 234
  }
}'
var request = 
{
  "id": "52",
  "jsonrpc": "2.0",
  "method": "private/get-trades-by-order",
  "params": {
    "orderId": 234
  }
};
var ws = new WebSocket('wss://api.uvas.com/v1');
ws.onmessage = function (e) {
    console.log('Data received from server : ', e.data);
};
ws.onopen = function () {
    // Connection should be authenticated (use /public/set-session-token call before)
    ws.send(JSON.stringify(request));
};

Response

{
  "jsonrpc": "2.0",
  "id": "52",
  "result": [
    {
      "id": 1,
      "instrumentId": "ETH-BTC",
      "price": 0.02595400,
      "qty": 0.02000123,
      "orderId": 234,
      "userSide": "sell",
      "fee": 0.00000001,
      "feeAsset": "BTC",
      "timestamp": 1594800486782215
    },
    ...
  ]
}

Retrieves trades for the specified order.

Parameters

Name Type Required Description
orderId long Yes Order ID

Response

Items are sorted by date. From old to new.

Name Type Description
result array of objects
-> id long Trade ID
-> instrumentId string Instrument ID
-> price decimal Price
-> qty decimal Total quantity
-> orderId long Order ID
-> userSide string User side buy, sell
-> fee decimal Fee
-> feeAsset string Fee asset
-> timestamp timestamp Date and time

Error Codes

{
  "-32700": "Invalid JSON was received by the server.",
  "-32601": "Method not found.",
  "-32600": "The JSON sent is not a valid Request object.",
  "-30000": "JSON RPC version is invalid.",
  "10000": "General server error.",
  "10001": "Request timeout.",
  "10002": "Too many requests.",
  "10500": "Several request parameters are invalid.",
  "10501": "Request parameters have incorrect format.",
  "10502": "Period is invalid.",
  "10503": "Offset is invalid.",
  "10504": "Limit is invalid.",
  "12000": "User is not authorized.",
  "12001": "User is not authenticated.",
  "12002": "Session token expired.",
  "12004": "Login failed.",
  "12005": "Login temporarily locked.",
  "12006": "User blocked.",
  "12007": "Session token is empty.",
  "12500": "Grant type is invalid.",
  "12501": "Api key is required.",
  "12502": "Api passphrase is required.",
  "12503": "Signature is required.",
  "12504": "Timestamp is required.",
  "12505": "Refresh token is required.",
  "12506": "Access token is required.",
  "13000": "Instrument not found.",
  "13001": "Asset not found.",
  "13500": "Instrument id is invalid.",
  "13501": "Asset id is invalid.",
  "13502": "Instrument type is invalid.",
  "14500": "Depth is invalid.",
  "14501": "Candle size is invalid.",
  "15000": "Trading not allowed.",
  "15001": "Order not found.",
  "15002": "Market not found.",
  "15003": "Market is closed.",
  "15004": "Market is empty.",
  "15500": "Order type is invalid.",
  "15501": "Order side is invalid.",
  "15502": "Order id is invalid.",
  "15503": "Quantity is invalid.",
  "15504": "Cash quantity is invalid.",
  "15505": "Price is invalid.",
  "16000": "Limit exceeded.",
  "16001": "Insufficient funds.",
  "16002": "Deposits not allowed.",
  "16003": "Withdrawals not allowed.",
  "16500": "Address is invalid.",
  "16501": "Amount is invalid."
}
Code Message Description
-32700 Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text.
-32601 Method not found. The method does not exist or is not available.
-32600 The JSON sent is not a valid Request object. The JSON sent has invalid structure.
-30000 JSON RPC version is invalid. The JSON RPC version does not equal 2.0
10000 General server error. An error occurred on the server while serving the request.
10001 Request timeout. Timeout occurred on the server while serving the request.
10002 Too many requests. Request rate exceeded the API limits.
10500 Several request parameters are invalid. Two or more request parameters are invalid.
10501 Request parameters have incorrect format. An error occurred on the server while parsing the request parameters.
10502 Period is invalid. Date period is invalid.
10503 Offset is invalid. Paging offset is invalid.
10504 Limit is invalid. Paging limit is invalid.
12000 User is not authorized. User is not authorized.
12001 User is not authenticated. User is not authenticated.
12004 Login failed. Login failed due to incorrect credentials.
12005 Login temporarily locked. Login is temporarily locked.
12006 User is blocked. User account is suspended.
12007 Session token is empty. Session token is empty. Only for WebSocket transport
12500 Grant type is invalid. Grant type is invalid.
12501 Api key is required. Api key is required.
12502 Api passphrase is required. Api passphrase is required.
12503 Signature is required. Signature is required.
12504 Timestamp is required. Timestamp is required.
12505 Refresh token is required. Refresh token is required.
12506 Access token is required. Access token is required.
13000 Instrument not found. Instrument does not exist.
13001 Asset not found. Asset does not exist.
13500 Instrument id is invalid. Instrument ID has invalid format.
13501 Asset id is invalid. Asset ID has invalid format.
13502 Instrument type is invalid. Instrument type has invalid format or is not supported by the server.
14500 Depth is invalid. Order book depth value is invalid.
14501 Candle size is invalid. Candle size is invalid.
15000 Trading not allowed. Trading not allowed for this user.
15001 Order not found. Order not found.
15002 Market not found. Market does not exist.
15003 Market is closed. Market is closed.
15004 Market is empty. Market is empty.
15500 Order type is invalid. Order type has invalid format or is not supported by the server.
15501 Order side is invalid. Order side has invalid format or is not supported by the server.
15502 Order id is invalid. Order ID has invalid format.
15503 Quantity is invalid. Order quantity is invalid.
15504 Cash quantity is invalid. Order cash quantity is invalid.
15505 Price is invalid. Order price is invalid.
16000 Limit exceeded. Deposit/withdrawal limit exceeded.
16001 Insufficient funds. Insufficient funds for this withdrawal.
16002 Deposits not allowed. Deposits not allowed for this user.
16003 Withdrawals not allowed. Withdrawals not allowed for this user.
16500 Address is invalid. Address has invalid format.
16501 Amount is invalid. Amount value is invalid.

FIX API

Uvas Exchange provides a FIX API using FIX 4.4 and 5.0.

FIX (Financial Information eXchange) is a standard protocol which can be used to enter orders, submit cancel requests, and receive fills. Users of the FIX API will typically have existing software using FIX for order management.

Credentials management

In order to connect to the Uvas Exchange FIX server, API credential set is needed. The set consists of ApiKey and ApiPassphrase. ApiKey is used as the SenderCompId tag value of every FIX message originating from the client. You can see the Message structure section for details. ApiPassphrase is used to calculate a Password tag value of a Logon message in order to successfully authenticate. You can see a Sessions and Authentication section for details. Make sure to keep both values secret.

API credential sets can be managed via Uvas Exchange UI in a "FIX API" section in Settings. The list with available API credential sets will be displayed. Only ApiKeys displayed as ApiPassphrase are considered strictly secret and must be kept separately and securely. Anyone gaining access to both your ApiKey and ApiPassphrase will be able to trade on your behalf. It's possible to create up to 10 credential sets per user.

Once you click the button "Add New Credentials", the dialog window will appear. Please select the FIX API version and submit. Subsequently a newly created ApiKey and an ApiPassphrase will be displayed. Remember to copy and secretly store the ApiPassphrase, as it will not be accessible afterwards. If ApiPassphrase gets lost, the credential set has to be deleted and a new one created.

In order to delete a credential set, click an "Options" icon in the given set's row and select "Delete". The API credential set will get deleted and an active FIX session will be immediately terminated, if present.

Connection

The Uvas Exchange FIX server uses TCP transport protocol. IP address is fix.uvas.com. Port is 777. TLS 1.3 is used.

Message structure

Every FIX message consists of three parts: header, body and trailer. Body is specific for every message type. Header and trailer must have the same tags for all the messages. The structure as follows:

Tag Name Type Required Description
8 BeginString string Yes Protocol version. It contains FIX.4.4 for FIX version 4.4 and FIXT.1.1 for FIX version 5.0
9 BodyLength int Yes Message length in bytes, not including BeginString, BodyLength and CheckSum
35 MsgType string Yes Message type
34 MsgSeqNum int Yes Message sequence number. It starts with 1 for every session and increases by 1 for every subsequent message within a session.
49 SenderCompId string Yes Identifier of message sender. It equals ApiKey from FIX API credentials, if the client is a sender. It is UVASFIXSERVER, if the server is a sender
52 SendingTime datetime Yes Date and time when the message is sent. Example 20190702-05:11:35.123
56 TargetCompID string Yes Identifier of a message receiver. It will be ApiKey from FIX API credential set, if client is receiver. It must equal UVASFIXSERVER, if server is receiver
10 CheckSum string Yes Message checksum consists of 3 symbols. See FIX specification for checksum calculation details.

All tags from the table except CheckSum represent a message header. The CheckSum tag represents a message trailer. The message starts with BeginString, BodyLength and MsgType in this exact order. The message ends with CheckSum.

The description of specific messages below does not include header and trailer tags.

Sessions and Authentication

FIX is a session-based protocol. In order to establish a session the client must authenticate himself by sending a Logon message. In order to terminate a session either the FIX server or the client must send a Logout message. Heartbeat and TestRequest messages are used to keep a session active, if no other activity is performed. See detailed description of every message below.

Logon

MsgType = A

Tag Name Type Required Description
96 RawData string Yes See below
554 Password string Yes See below
98 EncryptMethod int Yes Message encryption method. Currently, only 0 (None) is supported.
108 HeartBtInt int Yes Heartbeats interval

The structure of RawData is timestamp.nonce - timestamp value and nonce value separated by an ASCII period. timestamp must be of a 64-bit integer type. Its value increases in every subsequent Logon message. We recommend using a current timestamp in milliseconds. nonce must be a random byte array encoded in Base64. It is important for nonce bytes to be generated by a cryptographically secure random number generator. The size is from 32 to 512 bytes.

Password is used for authentication. You can calculate it by following the steps below:

In short, Password = Base64(SHA256(RawData+ApiPassphrase)). The FIX server performs the same steps and compares the resulting value with Password provided. If the values match, the user is authenticated and a session established.

Success response

In case of a successful authentication the FIX server responds with a Logon message containing EncryptMethod and HeartBtInt tags.

Error responses

In case of a failed authentication the FIX server responds with a Logout message containing a Text tag that specifies a failure reason. The list of reasons currently includes:

Text Description
Rejected Logon Attempt: ApiKey not found The server has no ApiKey corresponding to the value sent in SenderCompId tag. Check the value or generate new FIX API credentials
Rejected Logon Attempt: Wrong format of RawData RawData value has an incorrect format. Make sure it has structure of timestamp.nonce
Rejected Logon Attempt: Timestamp in RawData must be numeric timestamp is not numeric
Rejected Logon Attempt: Timestamp is less or equal to the last one used timestamp has not increased since the last Logon message. Make sure it is an always-increasing value
Rejected Logon Attempt: Nonce is in invalid format nonce is not a Base64-encoded string. Check the algorithm used to generate nonce
Rejected Logon Attempt: Nonce is less than 32 bytes nonce is less than 32 bytes. Check the algorithm used to generate nonce
Rejected Logon Attempt: Nonce is greater than 512 bytes nonce is greater than 512 bytes. Check the algorithm used to generate nonce
Rejected Logon Attempt: Wrong password Password calculated by the server based on RawData and ApiPassphrase does not match Password value in the Logon message. Check if the correct ApiPassphrase is used

Logout

MsgType = 5

If either the client or the server decides to terminate a session, it sends a Logout message with no body. The other party acknowledges the session termination by sending a Logout message with no body.

Heartbeat

MsgType = 0

If any FIX party has not received or sent any data for the interval specified in HeartBtInt tag of Logon message it must send a Heartbeat message with no body.

Success response

When other party receives a Heartbeat message it sends back another Heartbeat message as a confirmation.

TestRequest

MsgType = 1

If any FIX party has not received any data for the interval specified in the HeartBtInt tag of the Logon message it must send a TestRequest message.

Tag Name Type Required Description
112 TestReqId string Yes Test request identifier

Success response

When other party receives the TestRequest message it sends the Heartbeat message with a TestReqId tag mirroring the received value.

Accounts

UserRequest

It is used to request the user account balance information.

MsgType = BE

Tag Name Type Required Description
923 UserRequestID string Yes Request identifier
924 UserRequestType int Yes RequestType. Currently only 4 (RequestIndividualUserStatus) is supported
15 Currency string Yes Currency to get balance of, e.g. BTC

Success response

The server responds with a UserResponse message containing user account balances.

MsgType = BF

Tag Name Type Required Description
923 UserRequestID string Yes UserRequestID from UserRequest message
926 UserStatus int Yes User status. 1 (LoggedIn) is returned
15 Currency string Yes Balance currency
100002 UserBalance decimal Yes User account balance

Error response

If the user request was rejected the server responds with a UserResponse message.

MsgType = BF

Tag Name Type Required Description
923 UserRequestID string Yes UserRequestID from UserRequest message
926 UserStatus int Yes Reject reason
927 UserStatusText string Yes Reject reason description

Possible errors:

UserStatus UserStatus Name UserStatusText Description
3 USER_NOT_RECOGNISED ACCOUNT_NOT_FOUND User account not found
6 OTHER UNSUPPORTED_USER_REQUEST_TYPE Unsupported UserRequestType
6 OTHER CURRENCY_NOT_FOUND Currency not found
6 OTHER UNKNOWN_ERROR Unknown error encountered. Contact the support

Instruments

SecurityListRequest

Requests a list of instruments.

MsgType = x

Tag Name Type Required Description
320 SecurityReqID string Yes Unique request identifier assigned by the client
559 SecurityListRequestType int Yes Request type. Currently only 4 (AllSecurities) is supported

Success response

The server responds with a SecurityList message containing the list of instruments.

MsgType = y

Tag Name Type Required Description
320 SecurityReqID string Yes SecurityReqID value from SecurityListRequest message
322 SecurityResponseID string Yes Unique identifier of response
560 SecurityRequestResult int Yes Request result. 0 (ValidRequest) is returned
146 NoRelatedSym int No Number of instruments following
-> 55 Symbol string Yes Instrument symbol

Orders

NewOrderSingle

Used to submit a single order to the exchange.

MsgType = D

Tag Name Type Required Description
11 ClOrdID string Yes Unique client order identifier assigned by the client
55 Symbol string Yes Instrument symbol, e.g. BTC_USD
40 OrdType char Yes Order type. Supported values: 1 (Market), 2 (Limit)
54 Side char Yes Order side. Supported values: 1 (Buy), 2 (Sell)
44 Price decimal Yes Order price, ignored for market orders
38 OrderQty decimal Conditional Order quantity in base currency
152 CashOrderQty decimal Conditional Order quantity in quote currency

OrderQty specifies the amount of base currency to buy/sell. CashOrderQty specifies the amount of quote currency to spend/receive to buy/sell base currency. For a limit order OrderQty must be set and CashOrderQty must not be set. For a market order one of these values must be set. If none or both values are set, an error is reported.

Success response

The server responds with an ExecutionReport message containing information about the submitted order.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from NewOrderSingle message
17 ExecID string Yes Unique identifier of the execution report
150 ExecType char Yes Order execution type. 0 (New) is returned
37 OrderID string Yes Server-generated permanent order identifier
39 OrdStatus char Yes Order status. 0 (New) is returned
40 OrdType char Yes Order type
54 Side char Yes Order side
55 Symbol string Yes Instrument symbol
38 OrdQty decimal Yes Total quantity
14 CumQty decimal Yes Executed quantity
151 LeavesQty decimal Yes Quantity open for further execution
44 Price decimal Yes Price
6 AvgPx decimal Yes Average execution price. 0 if no quantity executed yet
60 TransactTime datetime Yes Date and time of the transaction

Error response

If the order was rejected due to business related reasons, the server responds with an ExecutionReport message.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from NewOrderSingle message
17 ExecID string Yes Unique identifier of the execution report
150 ExecType char Yes Order execution type. 8 (Rejected) is returned
103 OrdRejReason int Yes Reject reason
58 Text string Conditional Reject text
37 OrderID string Yes Server-generated permanent order identifier. 0 is returned
39 OrdStatus char Yes Order status. 8 (Rejected) is returned
40 OrdType char Yes Order type
54 Side char Yes Order side
55 Symbol string Yes Instrument symbol
38 OrdQty decimal Yes Total quantity. 0 is returned
14 CumQty decimal Yes Executed quantity. 0 is returned
151 LeavesQty decimal Yes Quantity open for further execution. 0 is returned
44 Price decimal Yes Price
6 AvgPx decimal Yes Average execution price. 0 is returned
60 TransactTime datetime Yes Date and time of the transaction

Possible errors:

OrdRejReason OrdRejReason Name Text Description
11 UNSUPPORTED_ORDER_CHARACTERISTIC UNSUPPORTED_ORDER_TYPE Unsupported OrdType
11 UNSUPPORTED_ORDER_CHARACTERISTIC UNSUPPORTED_SIDE Unsupported Side
15 UNKNOWN_ACCOUNT - User account not found
1 UNKNOWN_SYMBOL - Unknown Symbol
2 EXCHANGE_CLOSED - Order book for the instrument is closed
13 INCORRECT_QUANTITY BOTH_QUANTITY_AND_CASH_QUANTITY_SPECIFIED Both OrderQty and CashOrderQty are specified, which is invalid
13 INCORRECT_QUANTITY NO_QUANTITY_SPECIFIED Neither OrderQty not CashOrderQty is specified
13 INCORRECT_QUANTITY CASH_QUANTITY_SPECIFIED_FOR_LIMIT_ORDER CashOrderQty is specified for the limit order
13 INCORRECT_QUANTITY QUANTITY_NOT_SPECIFIED_FOR_LIMIT_ORDER OrderQty is not specified for the limit order
13 INCORRECT_QUANTITY NEGATIVE_OR_ZERO_QUANTITY Negative or zero OrderQty
13 INCORRECT_QUANTITY TOO_LARGE_QUANTITY Too large OrderQty or CashOrderQty
13 INCORRECT_QUANTITY TOO_SMALL_QUANTITY Too small OrderQty or CashOrderQty
6 DUPLICATE_ORDER - Order with the same ClOrdID already submitted
99 OTHER ACCOUNT_SUSPENDED User account is suspended
99 OTHER INVALID_PRICE Invalid Price
99 OTHER INSUFFICIENT_FUNDS User account has insufficient funds
99 OTHER UNKNOWN_ERROR Unknown error encountered. Contact support

OrderCancelRequest

Cancels an active order.

MsgType = F

Tag Name Type Required Description
11 ClOrdID string Yes Unique request identifier assigned by the client
41 OrigClOrdID string Conditional Client order identifier, see below
37 OrderID string Conditional Server order identifier, see below

The order to cancel can be specified in two ways: by OrderID and by OrigClOrdID. OrderID is a server-generated identifier and can be used across sessions. OrigClOrdID is a client-generated identifier and cannot be used across sessions. Use it only in the same session in which NewOrderSingle (or the OrderCancelReplaceRequest) submitting the order was sent. The OrigClOrdID value must be equal to the ClOrdId value sent in an NewOrderSingle message or in an OrderCancelReplaceRequest message if the order was created as a result of another order change.

If both OrderID and OrigClOrdID are specified, OrderID is used. If neither value is specified, an error is reported.

Success response

The server responds with an ExecutionReport message containing information about the cancelled order.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from OrderCancelRequest message
17 ExecID string Yes Unique identifier of execution report
150 ExecType char Yes Order execution type. 4 (Canceled) is returned
41 OrigClOrdID string No OrigClOrdID value from OrderCancelRequest message
37 OrderID string Yes Server-generated permanent order identifier
39 OrdStatus char Yes Order status. 4 (Canceled) is returned
40 OrdType char Yes Order type
54 Side char Yes Order side
55 Symbol string Yes Instrument symbol
38 OrdQty decimal Yes Total quantity
14 CumQty decimal Yes Executed quantity
151 LeavesQty decimal Yes Quantity open for further execution
44 Price decimal Yes Price
6 AvgPx decimal Yes Average execution price. 0 if no quantity was executed yet
60 TransactTime datetime Yes Date and time of the transaction

Error response

If an order cancellation was rejected due to business related reasons, the server responds with an OrderCancelReject message.

MsgType = 9

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from OrderCancelRequest message
434 CxlRejResponseTo char Yes Target of response. 1 (OrderCancelRequest) is returned
102 CxlRejReason int Yes Reject reason
58 Text string Conditional Reject text
39 OrdStatus char Yes Order status. 0 (New) is currently returned
41 OrigClOrdID string Yes OrigClOrdID value from OrderCancelRequest message. NONE is returned if not provided
37 OrderID string Yes Server-generated permanent order identifier. NONE is returned if not provided

Possible errors:

CxlRejReason CxlRejReason Name Text Description
1 UNKNOWN_ORDER NO_ORDER_IDS_SPECIFIED Neither OrderID nor OrigClOrdID is specified
1 UNKNOWN_ORDER ORDER_NOT_FOUND Order with given identifiers not found
99 OTHER INVALID_ORDER_ID Invalid OrderID
99 OTHER INVALID_CLIENT_ORDER_ID Invalid OrigClOrdID
99 OTHER ACCOUNT_NOT_FOUND User account not found
99 OTHER ACCOUNT_SUSPENDED User account suspended
99 OTHER UNKNOWN_ERROR Unknown error encountered. Contact support

OrderMassCancelRequest

Used to cancel multiple active orders that match a given set of criteria.

MsgType = q

Tag Name Type Required Description
11 ClOrdID string Yes Unique request identifier assigned by client
530 MassCancelRequestType char Yes Request types, see below
55 Symbol string Conditional Instrument symbol, see below
54 Side char No Order side. Supported values: 1 (Buy), 2 (Sell). See below

Currently two values of MassCancelRequestType are supported: 1 (CancelOrdersForASecurity) and 7 (CancelAllOrders). If MassCancelRequestType equals 1, Symbol must be specified to cancel all orders for a given instrument. If MassCancelRequestType equals 7, Symbol is not required and is ignored if specified. This request type cancels all orders.

Side can be optionally specified for both request types to cancel only buy or sell orders.

Success response

The server responds with an OrderMassCancelReport message to indicate a successful execution of the request.

MsgType = r

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from OrderMassCancelRequest message
530 MassCancelRequestType char Yes MassCancelRequestType value from OrderMassCancelRequest message
531 MassCancelResponse char Yes Response type. Mirrors MassCancelRequestType value from OrderMassCancelRequest message
60 TransactTime datetime Yes Date and time of transaction

Subsequently for every cancelled order the server responds with a ExecutionReport message containing information about the order.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from OrderMassCancelRequest message
17 ExecID string Yes Unique identifier of execution report
150 ExecType char Yes Order execution type. 4 (Canceled) is returned
37 OrderID string Yes Server-generated permanent order identifier
39 OrdStatus char Yes Order status. 4 (Canceled) is returned
40 OrdType char Yes Order type
54 Side char Yes Order side
55 Symbol string Yes Instrument symbol
38 OrdQty decimal Yes Total quantity
14 CumQty decimal Yes Executed quantity
151 LeavesQty decimal Yes Quantity open for further execution
44 Price decimal Yes Price
6 AvgPx decimal Yes Average execution price. 0 if no quantity executed yet
60 TransactTime datetime Yes Date and time of transaction

Error response

If the order mass cancellation was rejected due to business related reasons, the server responds with a OrderMassCancelReport message.

MsgType = r

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from OrderMassCancelRequest message
530 MassCancelRequestType char Yes MassCancelRequestType value from OrderMassCancelRequest message
531 MassCancelResponse char Yes Response type. 0 (CancelRequestRejected) is returned
532 MassCancelRejectReason int Yes Reject reason
58 Text string Conditional Reject text
60 TransactTime datetime Yes Date and time of the transaction

Possible errors:

MassCancelRejectReason MassCancelRejectReason Name Text Description
1 INVALID_OR_UNKNOWN_SECURITY INVALID_SYMBOL Invalid Symbol
1 INVALID_OR_UNKNOWN_SECURITY ORDER_BOOK_NOT_FOUND Order book for instrument not found
99 OTHER UNSUPPORTED_MASS_CANCEL_REQUEST_TYPE Unsupported MassCancelRequestType
99 OTHER CURRENCY_NOT_FOUND Base or quote currency not found
99 OTHER ACCOUNT_NOT_FOUND User account not found
99 OTHER ACCOUNT_SUSPENDED User account is suspended
99 OTHER UNKNOWN_ERROR Unknown error encountered. Contact support

OrderCancelReplaceRequest

Changes the parameters of an active order.

MsgType = G

Tag Name Type Required Description
11 ClOrdID string Yes Unique request identifier assigned by client
41 OrigClOrdID string Conditional Client order identifier, see below
37 OrderID string Conditional Server order identifier, see below
40 OrdType char Yes Order type to set
44 Price decimal No Price to set
38 OrderQty decimal Yes Total quantity to set
9619 CancelOrigOnReject char No Set Y to indicate whether original order should be cancelled if request is rejected

The order to change can be specified in two ways: by OrderID and by OrigClOrdID. OrderID is a server-generated identifier and can be used across sessions. OrigClOrdID is a client-generated identifier and cannot be used across sessions. Use it only in the same session in which NewOrderSingle (or OrderCancelReplaceRequest) submitting the order was sent. The OrigClOrdID value must be equal to the ClOrdId value sent in a the NewOrderSingle message or in the OrderCancelReplaceRequest message if the order was created as a result of another order change.

If both OrderID and OrigClOrdID are specified, OrderID is used. If neither value is specified, an error is reported.

Success response

The server responds with an ExecutionReport message for every order affected by the change.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from OrderCancelReplaceRequest message
17 ExecID string Yes Unique identifier of execution report
150 ExecType char Yes Order execution type. 5 (Replaced) is returned
41 OrigClOrdID string No OrigClOrdID value from OrderCancelReplaceRequest message
37 OrderID string Yes Server-generated permanent order identifier
39 OrdStatus char Yes Order current status
40 OrdType char Yes Order type
54 Side char Yes Order side
55 Symbol string Yes Instrument symbol
38 OrdQty decimal Yes Total quantity
14 CumQty decimal Yes Executed quantity
151 LeavesQty decimal Yes Quantity open for further execution
44 Price decimal Yes Price
6 AvgPx decimal Yes Average execution price. 0 if no quantity executed yet
60 TransactTime datetime Yes Date and time of the transaction

Possible request outcomes include:

  1. The original order was changed and no new order was created

The ExecutionReport for the changed original order is sent.

  1. The original order was cancelled and a new order created

Only ExecutionReport for the new order is sent. OrigClOrdID is omitted.

  1. The original order was cancelled and no new order created

ExecutionReport for the cancelled original order is sent.

Error response

If the order change was rejected due to business related reasons, the server responds with an OrderCancelReject message. If CancelOrigOnReject was specified in the request, ExecutionReport for the cancelled order will also be sent as described above.

MsgType = 9

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from OrderCancelRequest message
434 CxlRejResponseTo char Yes Target of the response. 2 (OrderCancelReplaceRequest) is returned
102 CxlRejReason int Yes Reject reason
58 Text string Conditional Reject text
39 OrdStatus char Yes Order status. 0 (New) is currently returned
41 OrigClOrdID string Yes OrigClOrdID value from OrderCancelRequest message. NONE is returned if not provided
37 OrderID string Yes Server-generated permanent order identifier. NONE is returned if not provided

Possible errors:

CxlRejReason CxlRejReason Name Text Description
1 UNKNOWN_ORDER NO_ORDER_IDS_SPECIFIED Neither OrderID nor OrigClOrdID is specified
1 UNKNOWN_ORDER ORDER_NOT_FOUND Order with given identifiers not found
99 OTHER UNSUPPORTED_ORDER_TYPE Unsupported OrdType
99 OTHER INVALID_ORDER_ID Invalid OrderID
99 OTHER INVALID_CLIENT_ORDER_ID Invalid OrigClOrdID
99 OTHER ACCOUNT_NOT_FOUND User account not found
99 OTHER ACCOUNT_SUSPENDED User account suspended
99 OTHER INVALID_PRICE Invalid Price
99 OTHER INSUFFICIENT_FUNDS User account has insufficient funds
99 OTHER NEGATIVE_OR_ZERO_QUANTITY Negative or zero OrderQty
99 OTHER TOO_LARGE_QUANTITY Too large OrderQty
99 OTHER TOO_SMALL_QUANTITY Too small OrderQty
99 OTHER EXCHANGE_CLOSED Order book for the instrument is closed
99 OTHER UNKNOWN_ERROR Unknown error encountered. Contact support

OrderStatusRequest

Used to request an order status.

MsgType = H

Tag Name Type Required Description
11 ClOrdID string Yes Unique request identifier assigned by client
41 OrigClOrdID string Conditional Client order identifier, see below
37 OrderID string Conditional Server order identifier, see below

The order which status we intend to get can be specified in two ways: by OrderID or by OrigClOrdID. OrderID is a server-generated identifier and can be used across sessions. OrigClOrdID is a client-generated identifier and cannot be used across sessions. Use it only in the same session in which NewOrderSingle (or the OrderCancelReplaceRequest) submitting the order was sent. The OrigClOrdID value must be equal to the ClOrdId value sent in the NewOrderSingle message or in the OrderCancelReplaceRequest message if the order was created as a result of another order change.

If both OrderID and OrigClOrdID are specified, OrderID is used. If neither value is specified, an error is reported.

Success response

The server responds with an ExecutionReport message.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from OrderStatusRequest message
17 ExecID string Yes Unique identifier of execution report
150 ExecType char Yes Order execution type. I (OrderStatus) is returned
41 OrigClOrdID string No OrigClOrdID value from OrderCancelReplaceRequest message
37 OrderID string Yes Server-generated permanent order identifier
39 OrdStatus char Yes Order current status
40 OrdType char Yes Order type
54 Side char Yes Order side
55 Symbol string Yes Instrument symbol
38 OrdQty decimal Yes Total quantity
14 CumQty decimal Yes Executed quantity
151 LeavesQty decimal Yes Quantity open for further execution
44 Price decimal Yes Price
6 AvgPx decimal Yes Average execution price. 0 if no quantity was executed yet
60 TransactTime datetime Yes Date and time of transaction

Error response

If the status request was rejected due to business related reasons, the server responds with an ExecutionReport message.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId value from OrderStatusRequest message
17 ExecID string Yes Unique identifier of execution report
150 ExecType char Yes Order execution type. 8 (Rejected) is returned
103 OrdRejReason int Yes Reject reason
58 Text string Conditional Reject text
41 OrigClOrdID string No OrigClOrdID value from OrderCancelReplaceRequest message
37 OrderID string Yes Server-generated permanent order identifier. NONE if it is unknown
39 OrdStatus char Yes Order current status. 8 (Rejected) is returned
54 Side char Yes Order side. B (AsDefined) is returned
55 Symbol string Yes Instrument symbol. NONE is returned
38 OrdQty decimal Yes Total quantity. 0 is returned
14 CumQty decimal Yes Executed quantity. 0 is returned
151 LeavesQty decimal Yes Quantity open for further execution. 0 is returned
6 AvgPx decimal Yes Average execution price. 0 is returned
60 TransactTime datetime Yes Date and time of transaction

Possible errors:

OrdRejReason OrdRejReason Name Text Description
5 UNKNOWN_ORDER NO_ORDER_IDS_SPECIFIED Neither OrderID nor OrigClOrdID specified
5 UNKNOWN_ORDER ORDER_NOT_FOUND Order with given identifiers not found
99 OTHER INVALID_ORDER_ID Invalid OrderID
99 OTHER INVALID_CLIENT_ORDER_ID Invalid OrigClOrdID
99 OTHER ACCOUNT_NOT_FOUND User account not found
99 OTHER UNKNOWN_ERROR Unknown error encountered. Contact support

OrderMassStatusRequest

Used to request statuses of multiple orders that match a given set of criteria.

MsgType = AF

Tag Name Type Required Description
584 MassStatusReqID string Yes Unique request identifier assigned by client
585 MassStatusReqType int Yes Request type, see below
55 Symbol string Conditional Instrument symbol, see below
54 Side char No Order side. Supported values: 1 (Buy), 2 (Sell). See below

Currently the two values of MassStatusReqType are supported: 1 (StatusForOrdersForASecurity) and 7 (StatusForAllOrders). If MassStatusReqType equals 1, Symbol must be specified to get the statuses of all the orders for a given instrument. If MassStatusReqType equals 7, Symbol must not be specified. This request type gets the statuses of all the orders.

Side can be optionally specified for both request types to get statuses of only buy or sell orders.

Success response

The server responds with an ExecutionReport message for every order.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes None is returned
584 MassStatusReqID string Yes MassStatusReqID value from OrderMassStatusRequest
17 ExecID string Yes Unique identifier of execution report
150 ExecType char Yes Order execution type. I (OrderStatus) is returned
37 OrderID string Yes Server-generated permanent order identifier
39 OrdStatus char Yes Order current status
40 OrdType char Yes Order type
54 Side char Yes Order side
55 Symbol string Yes Instrument symbol
38 OrdQty decimal Yes Total quantity
14 CumQty decimal Yes Executed quantity
151 LeavesQty decimal Yes Quantity open for further execution
44 Price decimal Yes Price
6 AvgPx decimal Yes Average execution price. 0 if no quantity was executed yet
60 TransactTime datetime Yes Date and time of transaction

Error response

If the mass status request was rejected due to business related reasons, the server responds with an ExecutionReport message.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes MassStatusReqID value from OrderMassStatusRequest
584 MassStatusReqID string Yes MassStatusReqID value from OrderMassStatusRequest
17 ExecID string Yes Unique identifier of execution report
150 ExecType char Yes Order execution type. 8 (Rejected) is returned
103 OrdRejReason int Yes Reject reason
58 Text string Conditional Reject text
37 OrderID string Yes Server-generated permanent order identifier. NONE is returned
39 OrdStatus char Yes Order current status. 8 (Rejected) is returned
54 Side char Yes Side from OrderMassStatusRequest or B (AsDefined) if not specified
55 Symbol string Yes Symbol from OrderMassStatusRequest or NONE if not specified
38 OrdQty decimal Yes Total quantity. 0 is returned
14 CumQty decimal Yes Executed quantity. 0 is returned
151 LeavesQty decimal Yes Quantity open for further execution. 0 is returned
6 AvgPx decimal Yes Average execution price. 0 is returned
60 TransactTime datetime Yes Date and time of the transaction

Possible errors:

OrdRejReason OrdRejReason Name Text Description
11 UNSUPPORTED_ORDER_CHARACTERISTIC UNSUPPORTED_SIDE Unsupported side
15 UNKNOWN_ACCOUNT - User account not found
1 UNKNOWN_SYMBOL - Unknown Symbol
99 OTHER SYMBOL_SPECIFIED Symbol specified for MassStatusReqType == 7 (StatusForAllOrders)
99 OTHER NO_SYMBOL_SPECIFIED Symbol not specified for MassStatusReqType == 1 (StatusForOrdersForASecurity)
99 OTHER INVALID_SYMBOL Invalid Symbol
99 OTHER UNSUPPORTED_MASS_STATUS_REQUEST_TYPE Unsupported MassStatusReqID
99 OTHER UNKNOWN_ERROR Unknown error encountered. Contact support

Fills reporting

The server sends ExecutionReport for every order fill on the exchange.

MsgType = 8

Tag Name Type Required Description
11 ClOrdID string Yes ClOrdId of request that created the order. If request happened in past session NONE is returned
17 ExecID string Yes Unique identifier of execution report
150 ExecType char Yes Order execution type. F (Trade) is returned
37 OrderID string Yes Server-generated permanent order identifier
39 OrdStatus char Yes Order current status
40 OrdType char Yes Order type
54 Side char Yes Order side
55 Symbol string Yes Instrument symbol
38 OrdQty decimal Yes Total quantity
14 CumQty decimal Yes Executed quantity
151 LeavesQty decimal Yes Quantity open for further execution
44 Price decimal Yes Price
6 AvgPx decimal Yes Average execution price. 0 if no quantity executed yet
31 LastPx decimal Yes Last trade price
60 TransactTime datetime Yes Date and time of fill

Market Data

MarketDataRequest

Used to request market data. Market data represents the order book and the trades state and updates.

MsgType = V

Tag Name Type Required Description
262 MDReqID string Yes Unique request identifier assigned by the client
263 SubscriptionRequestType char Yes Request type, see below
264 MarketDepth int No Market depth, see below. 0 is used if not specified
265 MDUpdateType int Conditional Market data update type, see below
266 AggregatedBook boolean No Specifies if order book entries should be aggregated, see below. Supported values: Y, N. Y used if not specified
267 NoMDEntryTypes int Yes Number of subsequent MDEntryType tags
-> 269 MDEntryType char Yes Market data entry type, see below
146 NoRelatedSym int Yes Number of subsequent Symbol tags
-> 55 Symbol string Yes Symbol of instrument to request market data for, see below
100007 TradeCount int No Trade count, see below. 20 used if not specified
100008 TradesSinceTimestamp datetime No Timestamp to get trades since, see below

Request types

SubscriptionRequestType can have 3 values: 0 (Snapshot), 1 (SnapshotPlusUpdates) and 2 (DisablePreviousSnapshotPlusUpdateRequest).

The MDUpdateType is required for this type of request. Two values are supported: 0 (FullRefresh) and 1 (IncrementalRefresh). Specifying 0 will make each update contain full state of market data. Specifying 1 will make each update contain only state changes. 0 (FullRefresh) is not supported for trades.

Order book aggregation

The order book can be aggregated. It means that all the orders on the same price level will be represented by a single order book entry. If the order book is not aggregated, each order will have its own order book entry even if some of them share the same price level. An AggregatedBook tag controls whether the order book should be reported as aggregated. Only the aggregated order books are currently supported.

Market data entry types

MDEntryType specifies which kind of market data should be reported. Supported values: 0 (Bid) - buy side of order book; 1 (Offer) - sell side of order book; 2 (Trade) - trades. Any combination of types can be specified in a request, though duplicates and empty set are not allowed.

Market data instruments

A set of Symbol tags specifies instruments for which market data should be reported. Several instruments can be specified in the request, though duplicates and empty set are not allowed.

Market depth

A MarketDepth value specifies how many top price levels for both sides of the order book to return in a snapshot or full/incremental refresh update messages.

If SubscriptionRequestType equals 0 (Snapshot) MarketDepth can equal any value.

If SubscriptionRequestType equals 1 (SnapshotPlusUpdates) and MDUpdateType equals 0 (FullRefresh) MarketDepth must equal 1, 10 or 20.

If SubscriptionRequestType equals 1 (SnapshotPlusUpdates) and MDUpdateType equals 1 (IncrementalRefresh) MarketDepth must equal 0.

Trades limit

TradeCount or TradesSinceTimestamp can be used to limit the number of trades returned in a snapshot by count or timestamp, accordingly.

Success response

The server sends MarketDataSnapshotFullRefresh messages to a return market data snapshot or to a report market data full refresh update. One message per instrument is sent.

MsgType = W

Tag Name Type Required Description
262 MDReqID string Yes MDReqID value from MarketDataRequest that initiated this message
55 Symbol string Yes Instrument symbol
268 NoMDEntries int Yes Number of entries following
-> 269 MDEntryType char Yes Market data entry type
-> 270 MDEntryPx decimal Yes Market data entry price
-> 271 MDEntrySize decimal Yes Market data entry quantity
-> 272 MDEntryDate date Conditional Market data entry date. Returned for trades only
-> 273 MDEntryTime time Conditional Market data entry time. Returned for trades only

The server sends MarketDataIncrementalRefresh messages to report a market data incremental update.

MsgType = X

Tag Name Type Required Description
262 MDReqID string Yes MDReqID value from MarketDataRequest that initiated this message
268 NoMDEntries int Yes Number of entries following
-> 279 MDUpdateAction char Yes Market data update type. Possible values: 0 (New), 1 (Change), 2 (Delete). Always equals 0 (New) for trades
-> 269 MDEntryType char Yes Market data entry type
-> 58 Symbol string Conditional Instrument symbol, see below
-> 270 MDEntryPx decimal Yes Market data entry price
-> 271 MDEntrySize decimal Conditional Market data entry quantity. Not present if MDUpdateAction equals 2 (Delete)
-> 272 MDEntryDate date Conditional Market data entry date. Returned for trades only
-> 273 MDEntryTime time Conditional Market data entry time. Returned for trades only

The server does not send a Symbol value in each MDEntry group. It sends Symbol in the first group and then omits it for all the following groups. This means that all the groups have the Symbol value from the first group. If some of the subsequent groups need to have another Symbol value, the server sends it in the first group of given subset and then again omits it for all the following groups.

Error response

If a market data request was rejected due to business related reasons, the server responds with a MarketDataRequestReject message.

MsgType = Y

Tag Name Type Required Description
262 MDReqID string Yes MDReqID value from MarketDataRequest
281 MDReqRejReason char Conditional Reject reason
58 Text string Conditional Reject text

Possible errors:

MDReqRejReason MDReqRejReason Name Text Description
6 UNSUPPORTED_MDUPDATETYPE - Unsupported MDUpdateType
4 UNSUPPORTED_SUBSCRIPTIONREQUESTTYPE - Unsupported SubscriptionRequestType
4 UNSUPPORTED_SUBSCRIPTIONREQUESTTYPE UNSUPPORTED_PARAMETERS Unsupported SubscriptionRequestType for given parameters
5 UNSUPPORTED_MARKETDEPTH - Unsupported MarketDepth
7 UNSUPPORTED_AGGREGATEDBOOK - Unsupported AggregatedBook
8 UNSUPPORTED_MDENTRYTYPE - Unsupported MDEntryType
0 UNKNOWN_SYMBOL - Unknown Symbol
1 DUPLICATE_MDREQID - Duplicate MDReqID
- - DUPLICATE_SYMBOL Duplicate Symbol
- - DUPLICATE_ENTRY_TYPE Duplicate MDEntryType
- - UNSUPPORTED_TRADES_COUNT Unsupported TradeCount
- - UNSUPPORTED_TIMESTAMP_FILTER Unsupported TradesSinceTimestamp
- - UNKNOWN_MDREQID Unknown MDReqID

Errors

BusinessMessageReject

The server responds with BusinessMessageReject if an unexpected internal server error occurs during the processing of any type of message from the client.

MsgType = j

Tag Name Type Required Description
372 RefMsgType string Yes MsgType of message that caused the processing error
45 RefSeqNum int Yes MsgSeqNum of message that caused processing error
380 BusinessRejectReason int Yes Reject reason. 4 (ApplicationNotAvailable) is returned