mirror of
https://github.com/d0zingcat/solana-agent-kit.git
synced 2026-05-31 07:36:46 +00:00
feat: add staking
This commit is contained in:
15
README.md
15
README.md
@@ -8,6 +8,7 @@ A powerful toolkit for interacting with the Solana blockchain, providing easy-to
|
||||
- Deploy new SPL tokens
|
||||
- Transfer SOL and SPL tokens
|
||||
- Check token balances
|
||||
- Stake SOL
|
||||
|
||||
- 🖼️ NFT Management
|
||||
- Deploy NFT collections
|
||||
@@ -110,6 +111,17 @@ const signature = await lendAsset(
|
||||
);
|
||||
```
|
||||
|
||||
### Stake SOL
|
||||
|
||||
```typescript
|
||||
import { stakeWithJup } from 'solana-agent-kit';
|
||||
|
||||
const signature = await stakeWithJup(
|
||||
agent,
|
||||
1 // amount in SOL
|
||||
);
|
||||
```
|
||||
|
||||
## API Reference
|
||||
|
||||
### Core Functions
|
||||
@@ -135,6 +147,9 @@ Check SOL or token balance for the agent's wallet.
|
||||
#### `lendAsset(agent, assetMint, amount, apiKey)`
|
||||
Lend idle assets to earn interest with Lulo.
|
||||
|
||||
#### `stakeWithJup(agent, amount)`
|
||||
Stake SOL with Jupiter to earn rewards.
|
||||
|
||||
## Dependencies
|
||||
|
||||
The toolkit relies on several key Solana and Metaplex libraries:
|
||||
|
||||
Reference in New Issue
Block a user