@dumpster-cash/dumpster-sdk
v1.1.0
Published
TypeScript SDK for Dumpster, DumpsterSwap, and DumpsterFees programs
Readme
@dumpster-cash/dumpster-sdk
TypeScript SDK for Dumpster, DumpsterSwap, and DumpsterFees on Gorbagana.
- Docs:
https://docs.dumpster.cash - Package:
https://www.npmjs.com/package/@dumpster-cash/dumpster-sdk
Installation
npm install @dumpster-cash/dumpster-sdk @solana/web3.js @coral-xyz/anchor bn.jsQuick Start
import { Connection, PublicKey } from '@solana/web3.js';
import { DumpsterClient } from '@dumpster-cash/dumpster-sdk';
const connection = new Connection('https://your-rpc.example');
const client = new DumpsterClient(connection);
const mint = new PublicKey('...');
const global = await client.accounts.fetchGlobal();
const feeConfig = await client.accounts.fetchFeeConfig();
const tradeState = await client.accounts.fetchCurveTradeState({
mint,
user: wallet.publicKey,
});
const preview = client.preview.curveBuy({
feeConfig,
bondingCurve: tradeState.bondingCurve,
gorAmount: 1_000_000_000n,
});
const instructions = await client.curve.buildCurveBuyExactOutAutoResolve({
mint,
user: wallet.publicKey,
tokenAmountOut: preview.tokenAmountOut,
maxGorAmountIn: preview.gorAmountIn,
slippageBps: 500,
});What Is Included
- Curve instruction builders
- DumpsterSwap instruction builders
- Account fetchers
- Trade preview helpers
- PDA helpers
- Transaction helpers
- Error normalization helpers
Primary Entry Point
Use DumpsterClient for new integrations.
Lower-level exports remain available for:
- raw instruction building
- direct account decoding
- pure math helpers
- Anchor program access
Programs
| Program | Address | Purpose |
| --- | --- | --- |
| Dumpster | DUMPfA5gPgYgRA6xJ5vKtypK6jnVxywbkj7eb6k9HhdC | Launch, bonding curve trading, migration |
| DumpsterFees | DUMPFaKPGxZVbn4vUVy4gaPZFLdLAAvSn5MqarkCjvLZ | Fee tiers and fee config |
| DumpsterSwap | DUMPa37F7hSccYfbman3k5h93LhBayXEUdWdUHZ5Bhev | Post-migration AMM |
Full Documentation
Use the full docs for:
- launch flow
- bonding-curve trading
- AMM trading
- trade previews
- PDA derivation
- account fetching
- transaction building
- error handling
https://docs.dumpster.cash
