Documentation Index
Fetch the complete documentation index at: https://docs.kaleidoswap.com/llms.txt
Use this file to discover all available pages before exploring further.
Version Compatibility
The current SDK implementation inkaleido-sdk (TypeScript) and kaleido_sdk (Python) is v0.1.5.
Both SDKs are generated from the same Maker API and RGB Lightning Node specs, then wrapped with handwritten clients for:
client.makerfor Kaleidoswap market, swap, and LSPS1 endpointsclient.rlnfor RGB Lightning Node wallet, channel, payment, and swap endpoints
Installation
Requirements
- TypeScript
- Python
- Node.js 18 or higher
- TypeScript 5.x recommended
Basic Setup
KaleidoClient.create() is synchronous in both SDKs. Do not await client creation.Configuration
TypeScript
KaleidoClient.create() accepts a KaleidoConfig object:
baseUrl?: Maker API base URL. Defaults tohttps://api.regtest.kaleidoswap.comnodeUrl?: RGB Lightning Node URLapiKey?: optional API keytimeout?: request timeout in secondslogLevel?: SDK log levellogger?: custom logger implementation
Python
KaleidoClient.create() accepts keyword arguments:
max_retries: retry budget for the HTTP clientcache_ttl: cache TTL in secondslog_level: standard Python logging level
Environment Variables
The SDK does not auto-load environment variables, but these names are used by the examples and work well as a convention:| Variable | Typical use |
|---|---|
KALEIDO_API_URL | Maker API base URL |
KALEIDO_NODE_URL | RGB Lightning Node URL |
KALEIDO_API_KEY | API key |
Available Environments
Common Maker API endpoints used in this repo:| Environment | API URL |
|---|---|
| Regtest | https://api.regtest.kaleidoswap.com |
| Signet / staging | https://api.staging.kaleidoswap.com |
| Signet | https://api.signet.kaleidoswap.com |
Sub-Client Architecture
Node Configuration Checks
TypeScript exposesclient.hasNode() and always returns an rln client instance. Python exposes client.has_node(), and client.rln raises NodeNotConfiguredError if node_url is missing.