The RestPublicClient is used to make public requests to the Katana Perps API. It does not require any special options to access.
Options for configuring the RestPublicClient
import { RestPublicClient } from '@katanaperps/katana-perps-sdk';
// works without any options
// const publicClient = new RestPublicClient();
const publicClient = new RestPublicClient({
sandbox: true,
// Optionally provide an API key to increase rate limits
apiKey: '1f7c4f52-4af7-4e1b-aa94-94fac8d931aa',
});
const tickers = await publicClient.getTickers('ETH-USD');
console.log('Tickers: ', tickers);
Returns basic information about the exchange.
Endpoint Parameters
An object matching katanaperps.KatanaPerpsExchange KatanaPerpsExchange providing properties relating to the exchange.
Returns estimated gas fees by bridge and target chain
Endpoint Parameters
Returns information about the currently listed markets
market request
parameter.Endpoint Parameters
Optional params: RestRequestGetMarketsReturns market statistics for the trailing 24-hour period
Endpoint Parameters
Optional params: RestRequestGetTickersReturns candle (OHLCV) data for a market
interval property (see example)Endpoint Parameters
import { RestPublicClient, CandleInterval } from '@katanaperps/katana-perps-sdk';
const client = new RestPublicClient();
const candles = await client.getCandles({
market: 'ETH-USD',
interval: CandleInterval.ONE_MINUTE
})
Returns trade data for a market. In this documentation, "trades" refers to public information about trades, whereas "fills" refers to detailed non-public information about trades resulting from orders placed by the API account.
Endpoint Parameters
- HTTP Request:
GET /v1/trades- Endpoint Security: Public
- API Key Scope: None
- Pagination: katanaperps.RestRequestPaginationWithFromId.start start, katanaperps.RestRequestPaginationWithFromId.end end, katanaperps.RestRequestPaginationWithFromId.limit limit, katanaperps.RestRequestPaginationWithFromId.fromId fromId
Returns a level-1 order book of a market.
Endpoint Parameters
Get current order book price levels for a market
Endpoint Parameters
Get liquidations for a market
Endpoint Parameters
- HTTP Request:
GET /v1/liquidations- Endpoint Security: Public
- API Key Scope: None
- Pagination: katanaperps.RestRequestPaginationWithFromId.start start, katanaperps.RestRequestPaginationWithFromId.end end, katanaperps.RestRequestPaginationWithFromId.limit limit, katanaperps.RestRequestPaginationWithFromId.fromId fromId
Get Funding Rates
Endpoint Parameters
Get Funding Rate Samples
Endpoint Parameters
Returns the current server time
Endpoint Parameters
An object with the current server time in UTC
The RestPublicClient is used to make public requests to the Katana Perps API. It does not require any special options to access.
truein order to point to the Katana Perps Sandbox API.Example
See