Staking SDK V2
Integrate native Bitcoin staking into your own application, providing your community easy access to earning yield through liquid staking, with LBTC.
Our TypeScript Staking SDK can be integrated into any frontend app: wallets, portfolio management apps, staking dashboards, custody portals.
If you're interested in integrating our Staking SDK please fill out this Google Form and we will issue you with a partner Id.
Important: You must take all measures for your app and its users to comply with our Terms of Service, including removing access for unauthorized countries.
⭐️ New Features
LBTC is automatically minted by Lombard for users. This improves user experience, by the user explicitly agreeing for a small amount of LBTC to be diverted to Lombard's treasury to cover gas costs.
Installation
Dependencies
The SDK requires the following peer dependencies:
Integration Guide
1. Exchange Rate & Minimum Deposit
Before users deposit BTC, display the exchange rate and minimum deposit amount:
Important: Deposits below minAmount will not be processed. Each individual deposit must exceed this threshold.
When a user has entered a valid BTC amount and confirm by pressing a "Stake" button, proceed to the next step.
2. Network Fee Authorization
If mintingFee
is greater than zero (true on Ethereum), users must authorize Lombard to deduct a small LBTC fee to cover minting costs. This step is not required for chains where Lombard Protocol covers the fees.
Note: You can verify if a user has a valid fee authorization using
getNetworkFeeSignature
.
3. BTC Deposit Address Generation
Each deposit address is uniquely linked to:
Destination chain (where LBTC will be minted)
User's wallet address
Your partner ID
First, check for an existing address:
If no address exists, generate a new one:
You may now prompt the user to deposit to this address.
4. Checking for deposits
Finally you can use getDepositsByAddress
to fetch and display the deposit history for a specified address.
Last updated