This page walks through everything you need to go from zero to a working Kraken integration: installing the package, querying public market data over the Spot REST API, subscribing to a live WebSocket ticker stream, and adding credentials to access private endpoints. Each step builds on the last, so you can stop at any point once your integration is running.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/sieblyio/kraken-api/llms.txt
Use this file to discover all available pages before exploring further.
Install the package
Add The package ships both ESM and CommonJS builds. Node.js will automatically select the correct bundle based on your project’s module system — no extra configuration is required.
@siebly/kraken-api to your project using your preferred package manager.Make your first public REST call
Public endpoints don’t need API keys. Create a If you see a server time, a system status of
SpotClient with no arguments and call a few market data methods to verify your connection.online, and ticker data in your console, your integration is working correctly. See the SpotClient reference for the full list of available methods.Subscribe to WebSocket market data
For real-time data, use the The SDK automatically manages the WebSocket connection. If the connection drops, it will reconnect and resubscribe to all active topics without any action required from your code. See the WebSocket overview for more on event handling and available topics.
WebsocketClient. Public WebSocket streams don’t require credentials. The WS_KEY_MAP export tells the SDK which Kraken WebSocket endpoint to connect to — use WS_KEY_MAP.spotPublicV2 for Spot market data.Add credentials for private endpoints
Private endpoints — account balances, order placement, trade history — require API keys. Pass your Store your API keys in environment variables — never hardcode them in source files. Use
apiKey and apiSecret when constructing the client.Spot and Futures use completely separate API keys. Keys created on kraken.com only work with the Spot REST API and Spot WebSocket streams. Keys created on futures.kraken.com only work with the Derivatives REST API and Derivatives WebSocket streams. See the authentication guide for step-by-step instructions on creating keys with the right permissions.
process.env to read them at runtime, or a .env file loaded via Node’s --env-file flag or a library like dotenv.Next steps
- Full SpotClient reference — browse every available method and its parameters in the SpotClient docs.
- WebSocket streams — explore all available public and private subscription topics in the WebSocket overview.
- Authentication — learn how to create Kraken API keys, understand the Spot/Futures credential split, and configure credentials securely in the authentication guide.