npm.io
4.0.0 • Published 2 months ago

@lombard.finance/sdk-common

Licence
MIT
Version
4.0.0
Deps
0
Size
26 kB
Vulns
0
Weekly
0

Lombard SDK

The official SDK for integrating with Lombard Finance - Bitcoin liquid staking.

Packages

Package Description npm
@lombard.finance/sdk Core SDK for BTC/EVM operations npm
@lombard.finance/sdk-common Shared utilities and types npm
@lombard.finance/sdk-solana Solana integration npm
@lombard.finance/sdk-sui Sui integration npm
@lombard.finance/sdk-starknet Starknet integration npm
@lombard.finance/sdk-devtools Developer tools npm

Quick Start

npm install @lombard.finance/sdk
import { createLombardSDK, Chain, AssetId } from '@lombard.finance/sdk';

// Initialize the SDK
const sdk = await createLombardSDK({
  env: 'prod',
  providers: {
    evm: () => window.ethereum,
    bitcoin: () => window.btc,
  },
});

// Create a BTC Stake action
const stake = sdk.chain.btc.stake({
  assetOut: AssetId.LBTC,
  destChain: Chain.ETHEREUM,
});

// Execute the staking flow
await stake.prepare({ amount: '0.001', recipient: '0x...' });
await stake.authorize();
await stake.generateDepositAddress();

console.log('Deposit BTC to:', stake.depositAddress);

Documentation

Development

# Install dependencies
yarn install

# Build all packages
yarn build

# Run tests
yarn test

# Lint
yarn lint

Contributing

See CONTRIBUTING.md for guidelines.

Security

See SECURITY.md for reporting vulnerabilities.

License

MIT - see LICENSE

Third-Party License Notes

This repository is MIT-licensed, but includes dependencies with additional terms.

  • LayerZero integration packages (@layerzerolabs/*) currently use BUSL-1.1.
  • Some development tooling paths currently pull MetaMask SDK packages with non-commercial terms.

See Third-Party License Notice and license policy for the current allowlist and approved exceptions.

Keywords