This project demonstrates how to manage a vault to store Native SOLs using blinks. It is built using Next.js and leverages the @solana/actions
, @solana/web3.js
, and @coral-xyz/anchor
libraries to interact with the Solana blockchain.
The main use of Svault is to provide a simple and efficient way to manage a vault on the Solana blockchain. This can be useful for developers building decentralized applications (dApps) on the Solana blockchain, as well as for users who need to create, deposit, withdraw, and close their vaults.
First, install the dependencies:
npm install
# or
yarn install
# or
pnpm install
Then, run the development server:
npm run dev
# or
yarn dev
# or
pnpm dev
Open http://localhost:3000 with your browser to see the result.
- Endpoint:
/api/actions/initialize
- Method:
POST
- Endpoint:
/api/actions/deposit
- Method:
POST
- Body Parameters:
amount
: The amount of SOL to deposit.
- Endpoint:
/api/actions/withdraw
- Method:
POST
- Body Parameters:
amount
: The amount of SOL to withdraw.
- Endpoint:
/api/actions/close
- Method:
POST