SolanaLaser API
SolanaLaser exposes server-side Solana execution endpoints for managed-wallet workflows. You do not sign transactions locally and do not need your own RPC: you call an endpoint with your API key, SolanaLaser signs with your managed wallet, simulates, submits, and returns the transaction signature.
Every endpoint uses the same base URL and a SolanaLaser API key.
const API_URL = "https://your-solanalaser-host"; // your deployment URL
const API_KEY = "pb_your_key";
async function solanaLaser(path: string, body?: unknown, method?: string) {
const response = await fetch(`${API_URL}${path}`, {
method: method ?? (body === undefined ? "GET" : "POST"),
headers: {
"content-type": "application/json",
"x-api-key": API_KEY,
},
body: body === undefined ? undefined : JSON.stringify(body),
});
const data = await response.json().catch(() => null);
if (!response.ok) {
throw new Error(data?.detail ?? `HTTP ${response.status}`);
}
return data;
}
All examples in these docs use this helper.
Endpoints
| Endpoint | Purpose |
|---|---|
POST /v1/laser/setup | One-call onboarding: account + API key + default managed wallet. |
POST /v1/wallets | Create a server-managed encrypted wallet. |
POST /v1/wallets/import | Import a private key into managed wallet storage. |
GET /v1/wallets | List managed wallet public metadata. |
PUT /v1/wallets/{public_key}/default | Set account default managed wallet. |
DELETE /v1/wallets/{public_key} | Delink a wallet and remove its stored secret and local history. |
POST /v1/trades/execute | Execute a Pump/PumpSwap buy or sell with auto venue routing. |
POST /v1/laser/create | Launch a new Pump token from a managed wallet. |
POST /v1/laser/bundle | Build, server-sign, and submit an atomic Jito bundle. |
POST /v1/sol/split/execute | Split SOL from one managed wallet to up to five destinations. |
POST /v1/sol/consolidate/execute | Consolidate SOL from many managed wallets into one destination. |
POST /v1/cashback/check | Check Pump cashback claimable for wallets. |
POST /v1/cashback/claim/execute | Claim Pump/PumpSwap cashback from a managed wallet. |
Conventions
executemeans SolanaLaser signs and submits the transaction.- No endpoint requires client-side transaction signing.
- No endpoint requires you to call Solana RPC directly.
confirm: truewaits for on-chain confirmation before responding.- Managed wallet private keys are stored encrypted and decrypted only in memory at signing time.
- Errors always include
{ "code": "...", "detail": "..." }— see Errors.
Where to Start
- Call
POST /v1/laser/setupto get an API key and a managed wallet. - Fund the wallet with SOL.
- Trade or create a token.