Download OpenAPI specification:Download
This is the official Kollider Api documentation. For code examples please head on over to our Github
Base Rest API Url: https://api.kollider.xyz/v1/
Base WS API Url: wss://api.kollider.xyz/v1/ws/
You can authenticate using HMAC symmetric key signing. Every request you make to the api needs to contain the following header parameters.
Header Name | Header Value |
---|---|
K-API-KEY | Your API key |
K-SIGNATURE | HMAC Signature |
K-TIMESTAMP | Timestamp |
K-PASSPHRASE | Your Passphrase |
Kollider's technology allows users to choose between two different settlement types, namely Instant
and Delayed
.
These parameters are passed into every Order
or order manipulation action (Move
or Cancel
). Traders that select the Instant
settlement type don't have to deposit funds prior to submitting an order. Instead when they submit an order, they will be prompted to
pay a BTC Lighting invoice of exactly the margin requirement. When the payment is detected by the Kollider settlement engine, the order will be unlocked and it will be live
in the order book. Conversely, when an order submitted by the trader decreases the size of a position and Instant
settlement type is selected the trader will be prompted to
generate a BTC Lightning invoice of the amount owed to them by the trading engine.
The Delayed
settlement type behaves similar to traditional venues where settlements can be deffered to a later date. This type is recommended for HFT traders.
curl https://api.kollider.xyz/v1/market/products
{- "BTCUSD.PERP": {
- "symbol": "BTCUSD.PERP",
- "contract_size": "1",
- "max_leverage": "100.00",
- "base_margin": "0.00500",
- "maintnance_margin": "0.00400",
- "is_inverse_priced": true,
- "price_dp": 1,
- "underlying_symbol": ".XTBUSD",
- "last_price": 130713
}, - "LTCUSD.PERP": {
- "symbol": "LTCUSD.PERP",
- "contract_size": "1,",
- "max_leverage": "25.00",
- "base_margin": "0.00500",
- "maintnance_margin": "0.00400",
- "is_inverse_priced": false,
- "price_dp": 1,
- "underlying_symbol": ".LTCUSD",
- "last_price": 546
}
}
level | integer There are three levels of orderbook data. |
symbol | string The product symbol. |
curl https://api.kollider.xyz/v1/market/orderbook?symbol=BTCUSD.PERP&level=Level2&depth=9
{- "level": 1,
- "bids": [
- [
- "price",
- "size",
- "n_orders"
], - [
- 120.5,
- 321,
- 12
], - [
- 119,
- 3123,
- 100
], - [
- 118.5,
- 3211,
- 121
]
], - "asks": [
- [
- "price",
- "size",
- "n_orders"
], - [
- 121.5,
- 321,
- 12
], - [
- 122,
- 3123,
- 100
], - [
- 123.5,
- 3211,
- 121
]
]
}
The current trade price of a product.
symbol | string The product symbol. |
curl https://api.kollider.xyz/v1/market/ticker?symbol=BTCUSD.PERP
{- "best_bid": "12958.4",
- "best_ask": "12972.2",
- "mid": "12965.3",
- "last_quantity": 1,
- "last_price": 12958.4,
- "last_side": "Ask",
- "symbol": "BTCUSD.PERP"
}
For complete list of all indicies available, either check our website or query the products endpoint.
limit | integer Max number of values to be returned. |
symbol | string The index symbol. |
start | string UNIX time since Epoch |
end | string UNIX time since Epoch |
interval_size | string 5m, 15m, 1h, 1d |
curl https://api.kollider.xyz/v1/market/index_prices?symbol=.BTCUSD&offset_start='1h'
[- {
- "time": 1603557600,
- "min": 13075.46491050265,
- "max": 13091.00364505778,
- "mean": 13082.302335440983
}, - {
- "time": 1603558200,
- "min": 13081.4617188041,
- "max": 13099.734774947656,
- "mean": 13091.383202178808
}
]
Allows you to query a specific time range of funding rates.
symbol | string The index symbol. |
start | string UNIX time since Epoch |
end | string UNIX time since Epoch |
interval_size | string 5m, 15m, 1h, 1d |
curl https://api.kollider.xyz/v1/market/historical_funding_rate?symbol="BTCUSD.PERP"&start=1679656925000&interval_size=1h'
[- {
- "time": 1679655600000000000,
- "rate": -0.0003443959099451336
}, - {
- "time": 1679659200000000000,
- "rate": -0.00017514997448351725
}
]