roq-kraken#
Important
This gateway needs sponsorship to complete certain features.
Links#
Purpose#
Maintain network connectivity with the Kraken exchange
Route exchange updates to connected clients
Route client requests to the relevant exchange accounts
Stream all messages to an event-log
Overview#
Products
Spot |
✓ |
Futures |
|
Options |
Market Data
Reference Data |
✓ |
Market Status |
|
Top of Book |
✓ |
Market by Price (L2) |
✓ |
Market by Order (L3) |
|
Trade Summary |
✓ |
Statistics |
Order Management
Create |
✓ |
Modify |
|
Cancel |
✓ |
Cancel All |
✓ |
Auto Cancellation |
✓ |
Account Management
Positions |
✓ |
Funds |
✓ |
Data center located in Costa Rica (to be confirmed, best source here)
Conda#
$ mamba install \
--channel https://roq-trading.com/conda/stable \
roq-kraken
$ cp $CONDA_PREFIX/share/roq-kraken/config.toml $CONFIG_FILE_PATH
# Then modify $CONFIG_FILE_PATH to match your specific configuration
$ roq-kraken \
--name "kraken" \
--config_file "$CONFIG_FILE_PATH" \
--client_listen_address "$UNIX_SOCKET_PATH" \
--service_listen_address "$TCP_LISTEN_PORT" \
--flagfile "$FLAG_FILE"
Config#
Flags#
$ roq-kraken --help
|
Maximum order book depth. The exchange will limit order book updates to this depth. Please refer to Kraken Websockets API for further details. |
Environments#
# flagfile
--rest_uri=https://api.kraken.com
--ws_public_uri=wss://ws.kraken.com
--ws_private_uri=wss://ws-auth.kraken.com
# flagfile
--rest_uri=https://beta-api.kraken.com
--ws_public_uri=wss://beta-ws.kraken.com
--ws_private_uri=wss://beta-ws-auth.kraken.com
Warning
The test environment is used to beta test new API’s
Market Data#
Event |
Stream |
Messages |
Comments |
---|---|---|---|
Unavailable |
|||
Unavailable |
|||
MarketData |
spread |
||
MarketData |
book |
||
Unavailable |
|||
MarketData |
trade |
||
Not supported |
Event |
Stream |
Messages |
Comments |
---|---|---|---|
OrderEntry |
/0/public/AssetPairs |
||
Statistics#
Order Management#
Event |
Stream |
Messages |
Comments |
---|---|---|---|
DropCopy |
openOrders |
Not implemented |
|
DropCopy |
ownTrades |
Not implemented |
Event |
Stream |
Messages |
Comments |
---|---|---|---|
Event |
Stream |
Messages |
Comments |
---|---|---|---|
DropCopy |
addOrder |
Not implemented |
|
Unavailable |
|||
DropCopy |
cancelOrder |
Not implemented |
|
DropCopy |
cancelAll |
Not implemented |
Event |
Stream |
Messages |
Comments |
---|---|---|---|
DropCopy |
addOrder, cancelOrder |
Not implemented |
Order Types#
TBD
Time in Force#
TBD
Position Effect#
TBD
Execution Instructions#
TBD
Account Management#
Event |
Stream |
Messages |
Comments |
---|---|---|---|
Event |
Stream |
Messages |
Comments |
---|---|---|---|
OrderEntry |
/0/private/OpenPositions |
Not implemented |
|
OrderEntry |
/0/private/Balance, /0/private/TradeBalance |
Not implemented |
Streams#
Type |
Comments |
---|---|
REST |
Primary purpose
Each connection
The master account is used to
|
Type |
Comments |
---|---|
WebSocket |
Primary purpose
Each connection
|
Type |
Comments |
---|---|
WebSocket |
Primary purpose
Each connection
|
Constraints#
Rate-limit usage is not communicated by the exchange
- Order book ends up in bad state
Downtime (scheduled or not) appears to not shutdown existing connections nor are established subscriptions unsubscribed. Worse, during downtime, what appears to be uninitialized order book data can be disseminated. (This was confirmed with Kraken support early May 2020).
Warning
We currently have no means to detect bad order book updates. At best, a parse exception will terminate your gateway with an unhandled excpetion.