@satsterminal-sdk/swaps
v1.6.23
Published
Swaps module for the SatsTerminal SDK
Readme
@satsterminal-sdk/swaps
Swaps-only client for the SatsTerminal platform. Existing SatsTerminal usage works unchanged; new consumers can import this package directly for a slimmer install.
Installation
npm install @satsterminal-sdk/swaps
# or use the aggregator if you also need borrow/bridge:
npm install satsterminal-sdkUsage (swaps only)
import { SatsTerminal } from '@satsterminal-sdk/swaps';
const swaps = new SatsTerminal({ apiKey: process.env.API_KEY! });
const quote = await swaps.swapQuote({
amount: '0.001',
fromToken: 'BTC',
toToken: 'USDC',
address: 'bc1...',
protocol: 'runes',
params: {}
});Usage via aggregator
import { createClient } from 'satsterminal-sdk';
const { swaps } = createClient({ apiKey: process.env.API_KEY! });
const result = await swaps.fetchQuote({ /* ... */ });Exports
SatsTerminal(class)createSwapsClient(config)helper- All swaps-related types
