open-index/open-npm huggingface dataset:
npm package: @m0-foundation/solana-m-sdk
Description: Solana M SDK
Author: M0
Latest version: 0.2.5

# M0 Solana SDK

This SDK contains common actions for earn managers and program admins for M and M extensions

```bash
npm i @m0-foundation/solana-m-sdk
```

https://www.npmjs.com/package/@m0-foundation/solana-m-sdk

### Sample Usage

```typescript
import { EarnManager } from '@m0-foundation/solana-m-sdk';

const manager = await EarnManager.fromManagerAddress(connection, evmClient, manager.publicKey);
const ix = await manager.buildAddEarnerInstruction(user);

const earner = await Earner.fromTokenAccount(connection, evmClient, tokenAccount);
const claims = await earner.getHistoricalClaims();
```