---
title: "Kraken JavaScript & TypeScript SDK for Node.js | Siebly"
description: "Kraken JavaScript SDK by Siebly with TypeScript-first REST and WebSocket clients, Node.js runtime guidance, examples, endpoint references, and release links."
canonical: "https://siebly.io/sdk/kraken/javascript"
---

# Kraken JavaScript SDK

Use @siebly/kraken-api to read Kraken market data, manage orders, and consume streams from Node.js. JavaScript and TypeScript use the same clients; request and response types are included.

- [Make a first request](#quickstart)
- [Full tutorial](/sdk/kraken/javascript/tutorial)
- [Endpoint reference](#endpoint-reference)

- [npm: @siebly/kraken-api](https://www.npmjs.com/package/@siebly/kraken-api)
- [GitHub repository](https://github.com/sieblyio/kraken-api)
- [README](https://github.com/sieblyio/kraken-api#readme)
- [Kraken examples](/examples/Kraken)
- [View release feed](/releases/sdk/kraken-api)

## Choose a client

- [SpotClient](/sdk/kraken/javascript/tutorial): Spot REST
- [DerivativesClient](/sdk/kraken/javascript/tutorial): Futures REST
- [WebsocketClient](/sdk/kraken/javascript/tutorial): Public and private streams
- [WebsocketAPIClient](/sdk/kraken/javascript/tutorial): Spot API commands

## Integration Profile

**REST API:** Use the Kraken SDK for spot, futures, account, order, balance, and market data workflows that need typed REST methods and signed private requests.

**WebSockets:** Use WebSocket clients for Kraken public market streams, private account/order events, and Spot WebSocket API request/response trading flows in the product areas supported by the SDK.

**Reliability:** Keep API key permissions, nonce/timestamp handling, and futures-vs-spot client boundaries explicit; monitor reconnect and resubscribe behavior in long-running services.

<a id="quickstart"></a>

## Make a first public request

In a Node.js project, install the package once. The REST and WebSocket API examples below use `.mjs` files so Node.js can run their imports directly.

```sh
npm install @siebly/kraken-api
```

### REST API

Read public XBTUSD Spot data with `SpotClient`. These public requests require no credentials.

Save the code as `rest-public.mjs` and run:

```sh
node rest-public.mjs
```

```javascript
import { SpotClient } from '@siebly/kraken-api';

const client = new SpotClient();

async function main() {
  const serverTime = await client.getServerTime();
  const systemStatus = await client.getSystemStatus();
  const ticker = await client.getTicker({ pair: 'XBTUSD' });
  const orderBook = await client.getOrderBook({ pair: 'XBTUSD', count: 10 });

  console.log({
    serverTime,
    systemStatus,
    ticker,
    orderBook,
  });
}

// Since each of the above API calls is wrapped in an awaited promise, a high level catch will detect any exceptions:
main().catch(console.error);
```

### Expected response

Market values change on each run. These are the fields to check in the logged output.

| Field | Expected result |
| --- | --- |
| error / result | Each logged response retains the Kraken envelope. An empty `error` array indicates success; data is under `result`. |
| serverTime | `result.unixtime` is Unix seconds; `result.rfc1123` is a readable time string. |
| ticker / orderBook | Result objects keyed by the returned pair name, such as `XXBTZUSD`. Book levels contain price, quantity, and timestamp. |

[View the source example](https://github.com/sieblyio/kraken-api/blob/main/docs/KRAKEN_SDK_QUICKSTART_GUIDE.md)

- [More REST examples](https://github.com/sieblyio/crypto-api-examples/blob/master/examples/Kraken/Derivatives/Private/orderManagement.ts)

### WebSocket Streams

Connecting to Kraken Derivatives private WebSocket streams is straightforward with the `WebsocketClient`.

- Install the Kraken JavaScript SDK via NPM: `npm install @siebly/kraken-api`.
- Import the `WebsocketClient`, `WS_KEY_MAP`, and any typed topic helpers you want to use.
- Create an authenticated client instance with your Kraken futures API credentials.
- Configure event handlers for key lifecycle events such as `open`, `message`, `response`, `reconnecting`, `reconnected`, `close`, `exception`, and `authenticated`.
- Subscribe to private topics on the `derivativesPrivateV1` connection key for private derivatives topics. 
  - Spot is also available via the dedicated spot connection key.

In this example, we:

- Subscribe to private derivatives topics including `open_orders`, `open_orders_verbose`, `fills`, `balances`, `open_positions`, `account_log`, and `notifications_auth`.
- Show both typed topic request objects and simple topic-name subscriptions.
- Rely on the SDK to automatically fetch, cache, and sign the challenge parameters required for private derivatives subscriptions.
- Authentication is completely automatic with the provided API keys.
- If the connection drops or goes stale, the highly resilient WebsocketClient for Kraken will quickly detect any issues, respawn a replacement connection and resubscribe to the topics you were consuming before the drop.

This setup lets you monitor derivatives account activity in real time without polling the REST API for the same information.

```typescript
// eslint-disable-next-line @typescript-eslint/no-unused-vars
import {
  DefaultLogger,
  LogParams,
  WebsocketClient,
  WS_KEY_MAP,
  WSTopicRequest,
} from '@siebly/kraken-api';
import { WSDerivativesTopic } from '@siebly/kraken-api';

const customLogger: DefaultLogger = {
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
  trace: (...params: LogParams): void => {
    // console.log(new Date(), '--> trace', ...params);
  },
  info: (...params: LogParams): void => {
    console.log(new Date(), '--> info', ...params);
  },
  error: (...params: LogParams): void => {
    console.error(new Date(), '--> error', ...params);
  },
};

async function start() {
  const account = {
    key: process.env.API_FUTURES_KEY || 'keyHere',
    secret: process.env.API_FUTURES_SECRET || 'secretHere',
  };

  /**
   * The WebsocketClient is the core class to manage WebSocket subscriptions. Give it the topics you want to subscribe to, and it will handle the rest:
   * - Connection management (connect, disconnect, reconnect)
   * - Authentication for private topics
   * - Subscription management (subscribe, unsubscribe, resubscribe on reconnect)
   * - Message handling (dispatch messages to appropriate handlers)
   *
   * All you need to do is provide the topics you want to subscribe to when calling `subscribe()`, and the client will take care of the rest.
   *
   * Here we create a WebsocketClient instance with API key/secret for private topic subscriptions.
   *
   * In terms of product groups such as Spot, Derivatives, etc., the WebsocketClient understand the product group from the WsKey you provide when subscribing. For example, using `WS_KEY_MAP.spotPrivateV2` indicates that the subscription is for Spot private topics, as shown below.
   *
   * Refer to WS_KEY_MAP in the source code for all available WsKey options.
   */
  const client = new WebsocketClient(
    {
      apiKey: account.key,
      apiSecret: account.secret,
    },
    customLogger,
  );

  client.on('open', (data) => {
    console.log(new Date(), 'connected ', data?.wsKey);
  });

  // Data received
  client.on('message', (data) => {
    console.info(new Date(), 'data received: ', JSON.stringify(data));
  });

  // Something happened, attempting to reconnect
  client.on('reconnecting', (data) => {
    console.log(new Date(), 'reconnect: ', data?.wsKey);
  });

  // Reconnect successful
  client.on('reconnected', (data) => {
    console.log(new Date(), 'reconnected: ', data?.wsKey);
  });

  // Connection closed. If unexpected, expect reconnect -> reconnected.
  client.on('close', (data) => {
    console.error(new Date(), 'close: ', data);
  });

  // Reply to a request, e.g. "subscribe"/"unsubscribe"/"authenticate"
  client.on('response', (data) => {
    console.info(new Date(), 'server reply: ', JSON.stringify(data), '\n');
  });

  client.on('exception', (data) => {
    console.error(new Date(), 'exception: ', data);
  });

  client.on('authenticated', (data) => {
    console.error(new Date(), 'authenticated: ', data);
  });

  /**
   * The below examples demonstrate how you can subscribe to private topics.
   *
   * Note: while the documentation specifies "api_key", "original_challenge" and "signed_challenge" as required parameters, but don't worry about that. The SDK will automatically:
   * - Fetch the challenge using your API key,
   * - Cache the challenge
   * - Include the key, original challenge and signed challenge parameters for you when subscribing to private topics on the derivativesPrivateV1 WebSocket connection.
   *
   * You do NOT need to manually fetch or provide the "original_challenge" and "signed_challenge" tokens when subscribing to private topics.
   *
   * Do note that all of these include the "derivativesPrivateV1" WsKey reference. This tells the WebsocketClient to use the private "wss://futures.kraken.com/ws/v1" endpoint for these private subscription requests. It will also automatically authenticate the connection when it is established.
   */

  try {
    /**
     * All of the following parameters require API keys for Derivatives APIs.
     *
     * Note: your "WsTopicRequest" does not need to include "api_key", "original_challenge" and "signed_challenge". See above for details, or below for examples.
     */

    // Open orders: https://docs.kraken.com/api/docs/futures-api/websocket/open_orders
    const openOrdersTopicRequest: WSTopicRequest<WSDerivativesTopic> = {
      topic: 'open_orders',
    };
    client.subscribe(openOrdersTopicRequest, WS_KEY_MAP.derivativesPrivateV1);

    // Note: if there are no parameters needed, you can also just request the topic by name
    // This is the same as openOrdersTopicRequest, since openOrdersTopicRequest contains no parameters
    // client.subscribe('open_orders', WS_KEY_MAP.derivativesPrivateV1);

    // Open orders (verbose): https://docs.kraken.com/api/docs/futures-api/websocket/open_orders
    client.subscribe('open_orders_verbose', WS_KEY_MAP.derivativesPrivateV1);

    // Fills: https://docs.kraken.com/api/docs/futures-api/websocket/fills
    const accountFillsTopicRequest: WSTopicRequest<WSDerivativesTopic> = {
      topic: 'fills',
      // Optionally, the product_ids field can be used to subscribe only to specific product.
      // payload: {
      //   product_ids: ['PF_XBTUSD'],
      // },
    };
    client.subscribe(accountFillsTopicRequest, WS_KEY_MAP.derivativesPrivateV1);

    // Balances: https://docs.kraken.com/api/docs/futures-api/websocket/balances
    client.subscribe('balances', WS_KEY_MAP.derivativesPrivateV1);

    // Open Position: https://docs.kraken.com/api/docs/futures-api/websocket/open_position
    client.subscribe('open_positions', WS_KEY_MAP.derivativesPrivateV1);

    // Account Log: https://docs.kraken.com/api/docs/futures-api/websocket/account_log
    client.subscribe('account_log', WS_KEY_MAP.derivativesPrivateV1);

    // Notification: https://docs.kraken.com/api/docs/futures-api/websocket/notifications
    client.subscribe('notifications_auth', WS_KEY_MAP.derivativesPrivateV1);
  } catch (e) {
    console.error('Req error: ', e);
  }
}

start();
```

[View the source example](https://github.com/sieblyio/crypto-api-examples/blob/master/examples/Kraken/Derivatives/WebSockets/privateWs.ts)

### WebSocket API

WebSocket API commands require API credentials. Set the environment variables shown in the code using credentials for the live environment. This example only constructs the client; it sends no request and places no order. Continue with the maintained example below for supported commands and connection handling.

Save the code as `ws-api-setup.mjs` and run:

```sh
node ws-api-setup.mjs
```

```javascript
import { WebsocketAPIClient } from '@siebly/kraken-api';

const credentials = {
  apiKey: process.env.KRAKEN_SPOT_API_KEY,
  apiSecret: process.env.KRAKEN_SPOT_API_SECRET,
};

if (Object.values(credentials).some((value) => !value)) {
  throw new Error('Set KRAKEN_SPOT_API_KEY, KRAKEN_SPOT_API_SECRET before running.');
}

const wsApi = new WebsocketAPIClient(credentials);
console.log('Client configured. No request sent.');
```

[View the source example](https://github.com/sieblyio/crypto-api-examples/blob/master/examples/Kraken/Spot/WebSockets/wsAPI.ts)

## Endpoint Reference

[View the endpoint map source](https://github.com/sieblyio/kraken-api/blob/main/docs/endpointFunctionList.md)

### Endpoint maps

<p align="center">
  <a href="https://www.npmjs.com/package/@siebly/kraken-api">
    <picture>
      <source media="(prefers-color-scheme: dark)" srcset="https://github.com/sieblyio/kraken-api/blob/main/docs/images/logoDarkMode2.svg?raw=true#gh-dark-mode-only">
      <img alt="SDK Logo" src="https://github.com/sieblyio/kraken-api/blob/main/docs/images/logoBrightMode2.svg?raw=true#gh-light-mode-only">
    </picture>
  </a>
</p>

Each REST client is a JavaScript class, which provides functions individually mapped to each endpoint available in the exchange's API offering.

The following table shows all methods available in each REST client, whether the method requires authentication (automatically handled if API keys are provided), as well as the exact endpoint each method is connected to.

This can be used to easily find which method to call, once you have [found which endpoint you're looking to use](https://github.com/sieblyio/awesome-crypto-examples/wiki/How-to-find-SDK-functions-that-match-API-docs-endpoint).

All REST clients are in the [src](https://github.com/sieblyio/kraken-api/tree/main/src) folder. For usage examples, make sure to check the [examples](https://github.com/sieblyio/kraken-api/tree/main/examples) folder.

List of clients:

- [SpotClient](#spotclientts)
- [DerivativesClient](#derivativesclientts)
- [InstitutionalClient](#institutionalclientts)
- [PartnerClient](#partnerclientts)
- [AffiliateClient](#affiliateclientts)
- [WebsocketAPIClient](#websocketapiclientts)

If anything is missing or wrong, please open an issue or let us know in our [Node.js Traders](https://t.me/nodetraders) telegram group!

#### How to use table

Table consists of 4 parts:

- Function name
- AUTH
- HTTP Method
- Endpoint

**Function name** is the name of the function that can be called through the SDK. Check examples folder in the repo for more help on how to use them!

**AUTH** is a boolean value that indicates if the function requires authentication - which means you need to pass your API key and secret to the SDK.

**HTTP Method** shows HTTP method that the function uses to call the endpoint. Sometimes endpoints can have same URL, but different HTTP method so you can use this column to differentiate between them.

**Endpoint** is the URL that the function uses to call the endpoint. Best way to find exact function you need for the endpoint is to search for URL in this table and find corresponding function name.

### SpotClient.ts

This table includes all endpoints from the official Exchange API docs and corresponding SDK functions for each endpoint that are found in [SpotClient.ts](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts).

| Function                                                                                               | AUTH | HTTP Method | Endpoint                          |
| ------------------------------------------------------------------------------------------------------ | :--: | :---------: | --------------------------------- |
| [getSystemStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L155)           |      |     GET     | `0/public/SystemStatus`           |
| [getMaintenanceSchedule()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L164)    |      |     GET     | `0/public/MaintenanceSchedule`    |
| [getAssetInfo()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L175)              |      |     GET     | `0/public/Assets`                 |
| [getAssetPairs()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L187)             |      |     GET     | `0/public/AssetPairs`             |
| [getTicker()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L200)                 |      |     GET     | `0/public/Ticker`                 |
| [getCandles()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L214)                |      |     GET     | `0/public/OHLC`                   |
| [getOrderBook()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L226)              |      |     GET     | `0/public/Depth`                  |
| [getGroupedBook()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L237)            |      |     GET     | `0/public/GroupedBook`            |
| [getLevel3OrderBook()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L248)        |  🔐  |     POST    | `0/private/Level3`                |
| [getRecentTrades()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L259)           |      |     GET     | `0/public/Trades`                 |
| [getRecentSpreads()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L270)          |      |     GET     | `0/public/Spread`                 |
| [getAccountBalance()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L288)         |  🔐  |     POST    | `0/private/Balance`               |
| [getApiKeyInfo()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L303)             |  🔐  |     POST    | `0/private/GetApiKeyInfo`         |
| [getWalletAccounts()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L314)         |  🔐  |     POST    | `0/private/ListWalletAccounts`    |
| [getExtendedBalance()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L326)        |  🔐  |     POST    | `0/private/BalanceEx`             |
| [getCreditLines()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L342)            |  🔐  |     POST    | `0/private/CreditLines`           |
| [getTradeBalance()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L358)           |  🔐  |     POST    | `0/private/TradeBalance`          |
| [getOpenOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L374)             |  🔐  |     POST    | `0/private/OpenOrders`            |
| [getClosedOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L390)           |  🔐  |     POST    | `0/private/ClosedOrders`          |
| [getOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L405)                 |  🔐  |     POST    | `0/private/QueryOrders`           |
| [getOrderAmends()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L421)            |  🔐  |     POST    | `0/private/OrderAmends`           |
| [getTradesHistory()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L438)          |  🔐  |     POST    | `0/private/TradesHistory`         |
| [getTrades()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L453)                 |  🔐  |     POST    | `0/private/QueryTrades`           |
| [getOpenPositions()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L468)          |  🔐  |     POST    | `0/private/OpenPositions`         |
| [getLedgersInfo()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L484)            |  🔐  |     POST    | `0/private/Ledgers`               |
| [getLedgers()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L499)                |  🔐  |     POST    | `0/private/QueryLedgers`          |
| [getTradingVolume()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L515)          |  🔐  |     POST    | `0/private/TradeVolume`           |
| [requestLedgersExport()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L526)      |  🔐  |     POST    | `0/private/AddExport`             |
| [getLedgersExportStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L537)    |  🔐  |     POST    | `0/private/ExportStatus`          |
| [getLedgersExport()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L548)          |  🔐  |     POST    | `0/private/RetrieveExport`        |
| [deleteLedgersExport()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L557)       |  🔐  |     POST    | `0/private/RemoveExport`          |
| [submitOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L577)               |  🔐  |     POST    | `0/private/AddOrder`              |
| [amendOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L591)                |  🔐  |     POST    | `0/private/AmendOrder`            |
| [cancelOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L606)               |  🔐  |     POST    | `0/private/CancelOrder`           |
| [cancelAllOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L622)           |  🔐  |     POST    | `0/private/CancelAll`             |
| [cancelAllOrdersAfter()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L638)      |  🔐  |     POST    | `0/private/CancelAllOrdersAfter`  |
| [getWebSocketsToken()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L655)        |  🔐  |     POST    | `0/private/GetWebSocketsToken`    |
| [submitBatchOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L667)         |  🔐  |     POST    | `0/private/AddOrderBatch`         |
| [cancelBatchOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L682)         |  🔐  |     POST    | `0/private/CancelOrderBatch`      |
| [submitStrategy()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L707)            |  🔐  |     POST    | `0/private/AddStrategy`           |
| [cancelStrategy()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L720)            |  🔐  |     POST    | `0/private/CancelStrategy`        |
| [getOpenStrategies()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L733)         |  🔐  |     POST    | `0/private/GetOpenStrategies`     |
| [queryStrategies()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L746)           |  🔐  |     POST    | `0/private/QueryStrategies`       |
| [getClosedStrategies()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L760)       |  🔐  |     POST    | `0/private/GetClosedStrategies`   |
| [getDepositMethods()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L777)         |  🔐  |     POST    | `0/private/DepositMethods`        |
| [getDepositAddresses()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L788)       |  🔐  |     POST    | `0/private/DepositAddresses`      |
| [getDepositsStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L799)         |  🔐  |     POST    | `0/private/DepositStatus`         |
| [getWithdrawalMethods()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L810)      |  🔐  |     POST    | `0/private/WithdrawMethods`       |
| [getWithdrawalAddresses()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L821)    |  🔐  |     POST    | `0/private/WithdrawAddresses`     |
| [getWithdrawalInfo()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L832)         |  🔐  |     POST    | `0/private/WithdrawInfo`          |
| [submitWithdrawal()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L843)          |  🔐  |     POST    | `0/private/Withdraw`              |
| [getWithdrawalsStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L856)      |  🔐  |     POST    | `0/private/WithdrawStatus`        |
| [cancelWithdrawal()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L867)          |  🔐  |     POST    | `0/private/WithdrawCancel`        |
| [submitTransferToFutures()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L880)   |  🔐  |     POST    | `0/private/WalletTransfer`        |
| [createSubaccount()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L900)          |  🔐  |     POST    | `0/private/CreateSubaccount`      |
| [submitSubaccountTransfer()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L913)  |  🔐  |     POST    | `0/private/AccountTransfer`       |
| [allocateEarnFunds()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L931)         |  🔐  |     POST    | `0/private/Earn/Allocate`         |
| [deallocateEarnFunds()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L944)       |  🔐  |     POST    | `0/private/Earn/Deallocate`       |
| [getEarnAllocationStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L956)   |  🔐  |     POST    | `0/private/Earn/AllocateStatus`   |
| [getEarnDeallocationStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L969) |  🔐  |     POST    | `0/private/Earn/DeallocateStatus` |
| [getEarnStrategies()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L985)         |  🔐  |     POST    | `0/private/Earn/Strategies`       |
| [getEarnAllocations()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L1000)       |  🔐  |     POST    | `0/private/Earn/Allocations`      |
| [getPreTradeData()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L1018)          |      |     GET     | `0/public/PreTrade`               |
| [getPostTradeData()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L1030)         |      |     GET     | `0/public/PostTrade`              |
| [getOAuthAccessToken()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L1048)      |      |     POST    | `oauth/token`                     |
| [getOAuthUserInfo()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L1060)         |  🔐  |     GET     | `oauth/userinfo`                  |
| [createOAuthFastApiKey()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L1070)    |  🔐  |     POST    | `oauth/fast-api-key`              |
| [deleteOAuthFastApiKey()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L1082)    |  🔐  |    DELETE   | `oauth/fast-api-key`              |
| [updateOAuthFastApiKey()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L1096)    |  🔐  |     PUT     | `oauth/fast-api-key`              |
| [listOAuthFastApiKeys()](https://github.com/sieblyio/kraken-api/blob/main/src/SpotClient.ts#L1108)     |  🔐  |     GET     | `oauth/fast-api-keys`             |

### DerivativesClient.ts

This table includes all endpoints from the official Exchange API docs and corresponding SDK functions for each endpoint that are found in [DerivativesClient.ts](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts).

| Function                                                                                                            | AUTH | HTTP Method | Endpoint                                                        |
| ------------------------------------------------------------------------------------------------------------------- | :--: | :---------: | --------------------------------------------------------------- |
| [getTradeHistory()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L110)                 |      |     GET     | `derivatives/api/v3/history`                                    |
| [getOrderbook()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L124)                    |      |     GET     | `derivatives/api/v3/orderbook`                                  |
| [getTickers()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L135)                      |      |     GET     | `derivatives/api/v3/tickers`                                    |
| [getTicker()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L146)                       |      |     GET     | `derivatives/api/v3/tickers/{symbol}`                           |
| [getInstruments()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L163)                  |      |     GET     | `derivatives/api/v3/instruments`                                |
| [getTradingInstruments()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L174)           |  🔐  |     GET     | `derivatives/api/v3/trading/instruments`                        |
| [getInstrumentStatusList()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L185)         |      |     GET     | `derivatives/api/v3/instruments/status`                         |
| [getInstrumentStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L198)             |      |     GET     | `derivatives/api/v3/instruments/{symbol}/status`                |
| [batchOrderManagement()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L218)            |  🔐  |     POST    | `derivatives/api/v3/batchorder`                                 |
| [cancelAllOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L237)                 |  🔐  |     POST    | `derivatives/api/v3/cancelallorders`                            |
| [cancelAllOrdersAfter()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L253)            |  🔐  |     POST    | `derivatives/api/v3/cancelallordersafter`                       |
| [cancelOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L268)                     |  🔐  |     POST    | `derivatives/api/v3/cancelorder`                                |
| [editOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L292)                       |  🔐  |     POST    | `derivatives/api/v3/editorder`                                  |
| [getOpenOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L307)                   |  🔐  |     GET     | `derivatives/api/v3/openorders`                                 |
| [submitOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L318)                     |  🔐  |     POST    | `derivatives/api/v3/sendorder`                                  |
| [getOrderStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L333)                  |  🔐  |     POST    | `derivatives/api/v3/orders/status`                              |
| [getPnlPreferences()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L355)               |  🔐  |     GET     | `derivatives/api/v3/pnlpreferences`                             |
| [setPnlPreference()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L367)                |  🔐  |     PUT     | `derivatives/api/v3/pnlpreferences`                             |
| [getLeverageSettings()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L381)             |  🔐  |     GET     | `derivatives/api/v3/leveragepreferences`                        |
| [setLeverageSettings()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L395)             |  🔐  |     PUT     | `derivatives/api/v3/leveragepreferences`                        |
| [getRfqAssignmentMaxLeverage()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L409)     |  🔐  |     GET     | `derivatives/api/v3/rfq-assignment/max-leverage`                |
| [setRfqAssignmentMaxLeverage()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L420)     |  🔐  |     PUT     | `derivatives/api/v3/rfq-assignment/max-leverage`                |
| [deleteRfqAssignmentMaxLeverage()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L433)  |  🔐  |    DELETE   | `derivatives/api/v3/rfq-assignment/max-leverage`                |
| [getAccounts()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L452)                     |  🔐  |     GET     | `derivatives/api/v3/accounts`                                   |
| [getOpenPositions()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L464)                |  🔐  |     GET     | `derivatives/api/v3/openpositions`                              |
| [getPositionPercentile()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L475)           |  🔐  |     GET     | `derivatives/api/v3/unwindqueue`                                |
| [getPortfolioMarginParameters()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L490)    |  🔐  |     GET     | `derivatives/api/v3/portfolio-margining/parameters`             |
| [simulateMarginRequirements()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L504)      |  🔐  |     POST    | `derivatives/api/v3/portfolio-margining/simulate`               |
| [getAssignmentPrograms()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L523)           |  🔐  |     GET     | `derivatives/api/v3/assignmentprogram/current`                  |
| [addAssignmentPreference()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L534)         |  🔐  |     POST    | `derivatives/api/v3/assignmentprogram/add`                      |
| [deleteAssignmentPreference()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L547)      |  🔐  |     POST    | `derivatives/api/v3/assignmentprogram/delete`                   |
| [getAssignmentPreferencesHistory()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L560) |  🔐  |     GET     | `derivatives/api/v3/assignmentprogram/history`                  |
| [getFeeSchedules()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L581)                 |      |     GET     | `derivatives/api/v3/feeschedules`                               |
| [getFeeScheduleVolumes()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L594)           |  🔐  |     GET     | `derivatives/api/v3/feeschedules/volumes`                       |
| [getNotifications()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L613)                |  🔐  |     GET     | `derivatives/api/v3/notifications`                              |
| [getFills()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L630)                        |  🔐  |     GET     | `derivatives/api/v3/fills`                                      |
| [getHistoricalFundingRates()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L647)       |      |     GET     | `derivatives/api/v3/historical-funding-rates`                   |
| [getSelfTradeStrategy()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L666)            |  🔐  |     GET     | `derivatives/api/v3/self-trade-strategy`                        |
| [updateSelfTradeStrategy()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L679)         |  🔐  |     PUT     | `derivatives/api/v3/self-trade-strategy`                        |
| [getSubaccountTradingStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L702)      |  🔐  |     GET     | `derivatives/api/v3/subaccount/{subaccountUid}/trading-enabled` |
| [updateSubaccountTradingStatus()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L715)   |  🔐  |     PUT     | `derivatives/api/v3/subaccount/{subaccountUid}/trading-enabled` |
| [getSubaccounts()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L731)                  |  🔐  |     GET     | `derivatives/api/v3/subaccounts`                                |
| [submitWalletTransfer()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L748)            |  🔐  |     POST    | `derivatives/api/v3/transfer`                                   |
| [submitSubaccountTransfer()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L761)        |  🔐  |     POST    | `derivatives/api/v3/transfer/subaccount`                        |
| [submitTransferToSpot()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L775)            |  🔐  |     POST    | `derivatives/api/v3/withdrawal`                                 |
| [getOpenRFQs()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L797)                     |      |     GET     | `derivatives/api/v3/rfqs`                                       |
| [getOpenRFQ()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L811)                      |      |     GET     | `derivatives/api/v3/rfqs/{rfqUid}`                              |
| [getRFQOpenOffers()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L825)                |  🔐  |     GET     | `derivatives/api/v3/rfqs/open-offers`                           |
| [submitRFQNewOffer()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L839)               |  🔐  |     POST    | `derivatives/api/v3/rfqs/{rfqUid}/place-offer`                  |
| [updateRFQOpenOffer()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L858)              |  🔐  |     PUT     | `derivatives/api/v3/rfqs/{rfqUid}/replace-offer`                |
| [cancelRFQOffer()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L877)                  |  🔐  |    DELETE   | `derivatives/api/v3/rfqs/{rfqUid}/cancel-offer`                 |
| [getExecutionEvents()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L896)              |  🔐  |     GET     | `api/history/v3/executions`                                     |
| [getOrderEvents()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L911)                  |  🔐  |     GET     | `api/history/v3/orders`                                         |
| [getTriggerEvents()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L926)                |  🔐  |     GET     | `api/history/v3/triggers`                                       |
| [getPositionEvents()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L941)               |  🔐  |     GET     | `api/history/v3/positions`                                      |
| [getAccountLog()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L957)                   |  🔐  |     GET     | `api/history/v3/account-log`                                    |
| [getAccountLogCsv()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L968)                |  🔐  |     GET     | `api/history/v3/accountlogcsv`                                  |
| [getPublicExecutionEvents()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L983)        |      |     GET     | `api/history/v3/market/{tradeable}/executions`                  |
| [getPublicOrderEvents()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L997)            |      |     GET     | `api/history/v3/market/{tradeable}/orders`                      |
| [getPublicMarkPriceEvents()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L1011)       |      |     GET     | `api/history/v3/market/{tradeable}/price`                       |
| [getTickTypes()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L1031)                   |      |     GET     | `api/charts/v1/`                                                |
| [getMarketsForTickType()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L1041)          |      |     GET     | `api/charts/v1/{tickType}`                                      |
| [getResolutions()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L1054)                 |      |     GET     | `api/charts/v1/{tickType}/{symbol}`                             |
| [getCandles()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L1069)                     |      |     GET     | `api/charts/v1/{tickType}/{symbol}/{resolution}`                |
| [getLiquidityPoolStatistic()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L1087)      |      |     GET     | `api/charts/v1/analytics/liquidity-pool`                        |
| [getMarketAnalytics()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L1098)             |      |     GET     | `api/charts/v1/analytics/{symbol}/{analyticsType}`              |
| [checkApiKeyV3()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L1118)                  |  🔐  |     GET     | `api/auth/v1/api-keys/v3/check`                                 |
| [getAccountMarketShare()](https://github.com/sieblyio/kraken-api/blob/main/src/DerivativesClient.ts#L1134)          |  🔐  |     GET     | `api/stats/v1/rebates/self-market-share`                        |

### InstitutionalClient.ts

This table includes all endpoints from the official Exchange API docs and corresponding SDK functions for each endpoint that are found in [InstitutionalClient.ts](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts).

| Function                                                                                                          | AUTH | HTTP Method | Endpoint                            |
| ----------------------------------------------------------------------------------------------------------------- | :--: | :---------: | ----------------------------------- |
| [listCustodyVaults()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L73)            |  🔐  |     POST    | `0/private/ListCustodyVaults`       |
| [getCustodyVaultbyId()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L86)          |  🔐  |     POST    | `0/private/GetCustodyVault`         |
| [getCustodyDepositMethods()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L103)    |  🔐  |     POST    | `0/private/DepositMethods`          |
| [getCustodyDepositAddresses()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L119)  |  🔐  |     POST    | `0/private/DepositAddresses`        |
| [listCustodyTransactions()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L134)     |  🔐  |     POST    | `0/private/ListCustodyTransactions` |
| [getCustodyTransactionbyId()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L149)   |  🔐  |     POST    | `0/private/GetCustodyTransaction`   |
| [getCustodyWithdrawMethods()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L170)   |  🔐  |     POST    | `0/private/WithdrawMethods`         |
| [getCustodyWithdrawAddresses()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L185) |  🔐  |     POST    | `0/private/WithdrawAddresses`       |
| [listCustodyTasks()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L211)            |  🔐  |     POST    | `0/private/ListCustodyTasks`        |
| [getCustodyTaskbyId()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L224)          |  🔐  |     POST    | `0/private/GetCustodyTask`          |
| [listCustodyActivities()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L240)       |  🔐  |     POST    | `0/private/ListCustodyActivities`   |
| [getCustodyActivitybyId()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L253)      |  🔐  |     POST    | `0/private/GetCustodyActivity`      |
| [createOtcQuoteRequest()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L276)       |  🔐  |     POST    | `0/private/CreateOtcQuoteRequest`   |
| [updateOtcQuote()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L290)              |  🔐  |     POST    | `0/private/UpdateOtcQuote`          |
| [getOtcPairs()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L304)                 |  🔐  |     POST    | `0/private/GetOtcPairs`             |
| [getOtcActiveQuotes()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L316)          |  🔐  |     POST    | `0/private/GetOtcActiveQuotes`      |
| [getOtcHistoricalQuotes()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L331)      |  🔐  |     POST    | `0/private/GetOtcHistoricalQuotes`  |
| [getOtcExposures()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L345)             |  🔐  |     POST    | `0/private/GetOtcExposures`         |
| [checkOtcClient()](https://github.com/sieblyio/kraken-api/blob/main/src/InstitutionalClient.ts#L359)              |  🔐  |     POST    | `0/private/CheckOtcClient`          |

### PartnerClient.ts

This table includes all endpoints from the official Exchange API docs and corresponding SDK functions for each endpoint that are found in [PartnerClient.ts](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts).

| Function                                                                                                       | AUTH | HTTP Method | Endpoint                            |
| -------------------------------------------------------------------------------------------------------------- | :--: | :---------: | ----------------------------------- |
| [createEmbedUser()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L94)                 |  🔐  |     POST    | `b2b/users`                         |
| [getEmbedUser()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L107)                   |  🔐  |     GET     | `b2b/users/{user}`                  |
| [updateEmbedUser()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L116)                |  🔐  |    PATCH    | `b2b/users/{user}`                  |
| [submitEmbedVerification()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L138)        |  🔐  |     POST    | `b2b/verifications/{user}`          |
| [listEmbedAssets()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L159)                |  🔐  |     GET     | `b2b/assets`                        |
| [getEmbedAsset()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L170)                  |  🔐  |     GET     | `b2b/assets/{asset}`                |
| [listEmbedAssetRates()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L183)            |  🔐  |     GET     | `b2b/assets/{asset}/rates`          |
| [requestEmbedQuote()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L201)              |  🔐  |     POST    | `b2b/quotes`                        |
| [getEmbedQuote()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L216)                  |  🔐  |     GET     | `b2b/quotes/{quote_id}`             |
| [executeEmbedQuote()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L228)              |  🔐  |     PUT     | `b2b/quotes/{quote_id}`             |
| [getEmbedQuoteLimits()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L242)            |  🔐  |     GET     | `b2b/quotes/limits`                 |
| [requestEmbedProspectiveQuote()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L253)   |  🔐  |     POST    | `b2b/quotes/prospective`            |
| [createEmbedCustomOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L274)         |  🔐  |     POST    | `b2b/custom-orders`                 |
| [listEmbedCustomOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L289)          |  🔐  |     GET     | `b2b/custom-orders`                 |
| [getEmbedCustomOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L300)            |  🔐  |     GET     | `b2b/custom-orders/{order_id}`      |
| [cancelEmbedCustomOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L312)         |  🔐  |     POST    | `b2b/custom-orders/{id}/cancel`     |
| [getEmbedPortfolioSummary()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L332)       |  🔐  |     GET     | `b2b/portfolio/{user}/summary`      |
| [getEmbedPortfolioHistory()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L345)       |  🔐  |     GET     | `b2b/portfolio/{user}/history`      |
| [listEmbedPortfolioDetails()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L357)      |  🔐  |     GET     | `b2b/portfolio/{user}/details`      |
| [listEmbedPortfolioTransactions()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L369) |  🔐  |     GET     | `b2b/portfolio/{user}/transactions` |
| [getEmbedEarnSummary()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L388)            |  🔐  |     GET     | `b2b/earn/{user}`                   |
| [listEmbedEarnAssets()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L401)            |  🔐  |     GET     | `b2b/earn/assets`                   |
| [toggleEmbedAutoEarn()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L414)            |  🔐  |     PUT     | `b2b/earn/{user}/auto`              |
| [withdrawEmbedFunds()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L435)             |  🔐  |     POST    | `b2b/funds/withdrawals`             |
| [listEmbedFundingTransactions()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L450)   |  🔐  |     GET     | `b2b/funds/transactions`            |
| [listEmbedSettlementReports()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L468)     |  🔐  |     GET     | `b2b/reports/settlement`            |
| [getEmbedSettlementReport()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L479)       |  🔐  |     GET     | `b2b/reports/settlement/{id}`       |
| [listRampBuyCryptoAssets()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L497)        |  🔐  |     GET     | `b2b/ramp/buy/crypto`               |
| [listRampFiatCurrencies()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L506)         |  🔐  |     GET     | `b2b/ramp/fiat-currencies`          |
| [listRampPaymentMethods()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L516)         |  🔐  |     GET     | `b2b/ramp/payment-methods`          |
| [listRampCountries()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L526)              |  🔐  |     GET     | `b2b/ramp/countries`                |
| [getRampLimits()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L541)                  |  🔐  |     GET     | `b2b/ramp/limits`                   |
| [getRampProspectiveQuote()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L553)        |  🔐  |     GET     | `b2b/ramp/quotes/prospective`       |
| [getRampCheckoutUrl()](https://github.com/sieblyio/kraken-api/blob/main/src/PartnerClient.ts#L571)             |  🔐  |     GET     | `b2b/ramp/checkout`                 |

### AffiliateClient.ts

This table includes all endpoints from the official Exchange API docs and corresponding SDK functions for each endpoint that are found in [AffiliateClient.ts](https://github.com/sieblyio/kraken-api/blob/main/src/AffiliateClient.ts).

| Function                                                                                          | AUTH | HTTP Method | Endpoint                      |
| ------------------------------------------------------------------------------------------------- | :--: | :---------: | ----------------------------- |
| [getCpaProgress()](https://github.com/sieblyio/kraken-api/blob/main/src/AffiliateClient.ts#L26)   |  🔐  |     GET     | `affiliate/v1/cpa-progress`   |
| [getPayoutHistory()](https://github.com/sieblyio/kraken-api/blob/main/src/AffiliateClient.ts#L35) |  🔐  |     GET     | `affiliate/v1/payout-history` |
| [getDailyActivity()](https://github.com/sieblyio/kraken-api/blob/main/src/AffiliateClient.ts#L44) |  🔐  |     GET     | `affiliate/v1/daily-activity` |

### WebsocketAPIClient.ts

This table includes all endpoints from the official Exchange API docs and corresponding SDK functions for each endpoint that are found in [WebsocketAPIClient.ts](https://github.com/sieblyio/kraken-api/blob/main/src/WebsocketAPIClient.ts).

This client provides WebSocket API endpoints which allow for faster interactions with the Kraken API via a WebSocket connection.

| Function                                                                                                      | AUTH | HTTP Method | Endpoint                  |
| ------------------------------------------------------------------------------------------------------------- | :--: | :---------: | ------------------------- |
| [submitSpotOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/WebsocketAPIClient.ts#L85)           |  🔐  |      WS     | `add_order`               |
| [amendSpotOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/WebsocketAPIClient.ts#L99)            |  🔐  |      WS     | `amend_order`             |
| [cancelSpotOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/WebsocketAPIClient.ts#L113)          |  🔐  |      WS     | `cancel_order`            |
| [cancelAllSpotOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/WebsocketAPIClient.ts#L127)      |  🔐  |      WS     | `cancel_all`              |
| [cancelAllSpotOrdersAfter()](https://github.com/sieblyio/kraken-api/blob/main/src/WebsocketAPIClient.ts#L139) |  🔐  |      WS     | `cancel_all_orders_after` |
| [batchSubmitSpotOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/WebsocketAPIClient.ts#L158)    |  🔐  |      WS     | `batch_add`               |
| [batchCancelSpotOrders()](https://github.com/sieblyio/kraken-api/blob/main/src/WebsocketAPIClient.ts#L172)    |  🔐  |      WS     | `batch_cancel`            |
| [editSpotOrder()](https://github.com/sieblyio/kraken-api/blob/main/src/WebsocketAPIClient.ts#L189)            |  🔐  |      WS     | `edit_order`              |

## Kraken JavaScript FAQ

### What does the Kraken JavaScript SDK cover?

Kraken supports Spot, Futures, Margin, WebSockets, and WebSocket API workflows. The JavaScript guide covers the main REST and WebSocket integration patterns.

### How do I authenticate private Kraken API calls in JavaScript?

The public REST example above needs no credentials. For private calls, follow the authentication setup for @siebly/kraken-api in the full tutorial, including the credentials or signer required by your exchange.

- [Kraken authentication and setup](/sdk/kraken/javascript/tutorial)

### Does the Kraken JavaScript SDK help with WebSocket connection management?

Yes. Use the SDK WebSocket client for subscriptions, reconnect handling, and stream lifecycle management instead of building raw socket flows yourself.

### When should I use the Kraken WebSocket API instead of REST?

Use REST for standard request and response workflows such as account queries and order management. Use the WebSocket API flow when you want persistent low-latency interactions over a connected session.

## Machine Resources

- [AI prompt framework](/ai)
- [LLM discovery](/llms.txt)
- [SDK catalog](/.well-known/siebly-sdk-catalog.json)
- [Agent skill](/.well-known/agent-skills/siebly-crypto-exchange-api/SKILL.md)
