π―SDK Usage Guide
Basic Usage
Initializing the SDK
import { YoinkSDK } from "yoink-sdk";
import { Connection, Keypair, LAMPORTS_PER_SOL, PublicKey } from "@solana/web3.js";
import { AnchorProvider } from "@coral-xyz/anchor";
import NodeWallet from "@coral-xyz/anchor/dist/cjs/nodewallet";
// Setup connection and provider
const connection = new Connection("RPC_URL_LINK");
const wallet = new NodeWallet(yourKeypair);
const provider = new AnchorProvider(connection, wallet, { commitment: "confirmed" });
// Initialize SDK
const sdk = new YoinkSDK(provider);Core Features
π° Trading Operations
Buy Tokens
Sell Tokens
Get Price Quotes
π Market Data & Analytics
Get Bonding Curve Information
Get Protocol Information
Advanced Features
π Price Monitoring
π― Smart Trading with Price Checks
Error Handling
Common Error Patterns
Constants & Utilities
Available Constants
Helper Functions
Best Practices
π Security
β‘ Performance
Next Steps
Last updated
