Socket
Socket
Sign inDemoInstall

@marinade.finance/incentives-distribution-sdk

Package Overview
Dependencies
93
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @marinade.finance/incentives-distribution-sdk

SDK of the incentives distribution contract


Version published
Weekly downloads
113
increased by54.79%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

SDK of incentives distribution program

A contract to distribute incentives for using MNDE token.

The basic workflow is:

  • an admin creates a treasury account that configures admin holds statistics and defines token store, a vault for tokens to be distributed

  • the treasury stands for a root configuration account that's aligned to one token type

  • the admin creates a claimRecord account for an wallet address

  • the admin funds the treasury vault (token store account)

  • the admin appoints a part of the funded tokens from treasury vault to the claimRecord

  • the owner of the wallet (the claim authority) proceed claim operation on claimRecord to withdraw the appointed token amount

  • All amounts works in lamports of the token

  • The on-chain claimRecord works with totalAmount and nonClaimedAmount. To calculate claimed amount for a claim record one gets it as a subtraction totalAmount - nonClaimedAmount

Marinade MNDE Treasuries

Marinade Incentives Distribution Program address indiXdKbsC4QSLQQnn6ngZvkqfywn6KgEeQbkGSpk1V.

The treasuries configured are available via src/sdk.ts.

  • MSOL and native SOL stakers treasury at inTrQECqatDmvAt7ahYeWg82efX5PsxhiFXzQk9eKYG (STAKERS_TREASURY)
  • Referrers treasury at iNTrR8cP5Vw86X17sDNwuGxKyqR57sYZ8HvpRY7r1FF (REFERRERS_TREASURY)
  • Season 2 treasury at iNtR2h6yAUDXawbiVBHVUBZ5qN3qsFCezZJABgfWT8h (SEASON2_TREASURY)

Claiming

Claiming of the tokens means to deposit tokens to SPL Governance Voter State Registry (VSR) plugin. The wallet owner then can unlock the tokens via SPL Gov UI or use them for voting when they are locked.

To claim the amount from the incentives distribution program one should use claimOwnerAndDepositInstructions. That generates set of instructions that checks the VSR plugin accounts and may add instructions that creates the Voter account and configure deposit entries. The last call is claimAndDeposit that do the transfer from incentives program to VSR program.

Keywords

FAQs

Last updated on 09 Apr 2024

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc