Solard Documentation
SOLARD is a local-first execution stack for Pump and PumpSwap. Its SOLARD trade app, solard CLI, and typed SDK share one SQLite database, one venue resolver, and one transaction pipeline.
bun run indexer/main.tsbunx tradjs server./solard.db0 by default#Quickstart
The actual trade app is two long-running processes. The indexer collects and writes market state; the TradJS server reads that state and serves the browser interface. Run both from the repository root in separate shells.
1 · Clone and install
$ git clone https://github.com/7flash/solard $ cd solard $ bun install $ cp .env.example .env
2 · Configure the minimum
# required for wallet import/decryption SOLARD_MASTER_KEY=replace-with-a-long-secret # required for chain operations and indexing HELIUS_RPC_URL=https://mainnet.helius-rpc.com/?api-key=... # keep live execution disabled while testing SOLARD_ENABLE_LIVE_TRADES=0
3 · Start the indexer
Leave this process running. Without it, the trade app can render but its indexed market state will not advance.
$ bun run indexer/main.ts4 · Start the TradJS trade app
Open a second shell in the same repository. Export the port before starting TradJS.
$ export BUN_PORT=3000 $ bunx tradjs server # open http://localhost:3000
5 · Use the CLI separately
The CLI is an operator interface, not the trade-app launcher. Inspect its commands independently:
$ solard help6 · Make the first simulation
$ solard wallet import <base58_private_key> --name main $ solard token add <token_ca> $ solard quote <token_ca> --sol 0.1 $ solard buy <token_ca> --wallet main --sol 0.1 --simulate-only
#Configuration
Runtime configuration uses the SOLARD_ prefix alongside provider-specific variables. Use the names exactly as shown.
| variable | default / status | purpose |
|---|---|---|
| SOLARD_DB_PATH | ./solard.db | Shared SQLite database for CLI, web routes, jobs, portfolio, and indexed state. |
| SOLARD_MASTER_KEY | required for wallets | Encrypts and decrypts stored wallet secrets. |
| HELIUS_RPC_URL | configure | Preferred RPC endpoint. RPC_ENDPOINT is accepted for compatibility. |
| HELIUS_API_KEY | optional | Used to derive the Helius websocket URL when an override is not supplied. |
| HELIUS_SENDER_URL | optional | Helius Sender fast-lane endpoint. |
| HELIUS_TIP_ACCOUNT | optional | Tip account for Sender submissions. |
| JITO_BLOCK_ENGINE_URL | sender-specific | Used only when the Jito sender is explicitly selected. |
| SOLARD_ENABLE_LIVE_TRADES | 0 | Rejects live buy, sell, and launch requests until explicitly set to 1. |
| SOLARD_WEB_TOKEN | optional | When set, browser/API requests send x-solard-web-token. |
| SOLARD_PUMP_FEED_SOURCE | helius | Selects the primary Pump feed source. |
| PUMP_METADATA_PROVIDER | pump-frontend | Metadata uploader; pinata requires PINATA_JWT. |
| SOLARD_LOG_LEVEL | info | Application/measure logging verbosity. |
| SOLARD_MAX_JOBS | 100 | Background job retention limit. |
SOLARD_WEB_TOKEN and prefer a VPN or SSH tunnel over public port forwarding.#Architecture
Core boundaries
- Venue registry: resolves one executable market plugin for a token and user.
- Pump plugin: includes bonding-curve and PumpSwap venue implementations, instruction builders, routing, launch sources, and creator-fee claims.
- Senders: CLI trade flags expose
rpc,helius, andjito. - Persistence: the CLI and web console share a local database.
- Observability: worker supervision uses bgrun and operations are instrumented with measure-fn.
Repository modules
src/venuesmarket plugins and resolversrc/txtransaction composition/sendingsrc/claimsclaim-source interfacessrc/launcheslaunch source abstractionssrc/runnerscript registration/executionsrc/solardconsole server, workers, stores#Workers
A standard start brings up server-worker and helius-logs-v1. Telegram signals joins when SOLARD_TELEGRAM_SIGNALS=1. Additional workers can be enabled for LaserStream, PumpPortal, curve snapshots, holder snapshots, metadata repair, and reconciliation.
| worker spec | role | default boot? |
|---|---|---|
| solard-server-worker | SOLARD trade app and API server | yes |
| solard-helius-logs-v1 | standard logs subscription ingestion | yes |
| solard-telegram-signals | signal ingestion | when enabled |
| solard-helius-live-v2 | Helius live stream path | registered spec |
| solard-helius-laserstream-v1 | transaction subscription / LaserStream path | registered spec |
| solard-pumpportal-live-v2 | PumpPortal stream path | registered spec |
| solard-curve-snapshots | bonding-account snapshots | registered spec |
| solard-holder-snapshots | largest-account snapshots | registered spec |
| solard-metadata-repair | metadata repair loop | registered spec |
| solard-reconciler | reconciliation and heartbeat | registered spec |
#Web console
The browser trade app is served by TradJS. Start the indexer first with bun run indexer/main.ts, then run export BUN_PORT=3000 and bunx tradjs server in a second shell.
/tradelive trading/watchlistswatched tokens, wallets, programs/signalssignal projections/launchlaunch workflow and jobs/walletswallet and group operations/portfolioportfolio state/tradetrade workflow/activityjobs and activityThe public /trade route streams token discovery through polling and adds Dexscreener pair metrics as they become available. Wallet and execution routes remain inside the SOLARD console.
#HTTP API
The repository's app/api tree exposes route families for health, status, processes, workers, trade app data, prices, tokens, portfolio, trade, wallet import, groups, watch groups, signals, jobs, launching, and SMA data.
| route family | examples / purpose |
|---|---|
| health & status | /api/health, /api/status, process state |
| trade app | Pump feeds, Pump live state, holder data, trade-specific routes |
| market | price and SMA routes |
| portfolio | overview and portfolio routes |
| execution | trade and launch/pump routes |
| state changes | wallet import, groups, watches, worker ensure |
| operations | jobs, history, processes, signals |
SOLARD_WEB_TOKEN is set, send it through the x-solard-web-token header.#New-token stream & DEX enrichment
The server starts token discovery when the Bun process starts. An inline bootstrap polls /api/tokens while the page HTML is loading, before the TradJS page client mounts. The page client then replays buffered events and continues scheduled polling.
Source selection
| source | meaning | selection |
|---|---|---|
| PumpPortal | Pump.fun and PumpSwap creation events through subscribeNewToken. | Used in auto mode when a PumpPortal key or custom websocket URL is configured. |
| Solana RPC | Confirmed Pump create transactions discovered with logsSubscribe, then resolved with getTransaction. | Keyless default in auto mode. Use a dedicated RPC in production. |
| DEX Screener profiles | Newly published DEX Screener profiles, not every on-chain mint. | Optional; force with NEW_TOKEN_STREAM_SOURCE=dexscreener. |
Pipeline
- Discovery begins with the server process, so arrivals can be buffered before a browser opens.
- The root-layout bootstrap opens polling automatically; no button, scroll, or other interaction starts the stream.
- Each unique mint is returned on the next poll with its creation signature when available.
- An enrichment queue batches up to 30 addresses into DEX Screener token requests.
- Missing pairs are retried with bounded backoff at 5, 15, 30, 60, and 120 seconds.
- When a pair appears, an polling update replaces “pair pending” with price, liquidity, market cap, volume, and transaction counts.
- ETags, bounded backoff, and visibility-aware intervals keep polling predictable and easy to debug.
Stream configuration
| variable | default | purpose |
|---|---|---|
| NEW_TOKEN_STREAM_SOURCE | auto | auto, pumpportal, solana-rpc, or dexscreener. |
| PUMPPORTAL_API_KEY | — | Enables PumpPortal in auto mode; kept on the server. |
| PUMPPORTAL_WS_URL | official endpoint | Optional credentialed websocket override. |
| SOLANA_RPC_URL | public mainnet RPC | HTTP endpoint used to resolve create transactions. A dedicated endpoint is recommended. |
| SOLANA_WS_URL | derived/public mainnet WS | WebSocket endpoint used for Pump-program logsSubscribe. |
| DEXSCREENER_PROFILE_WS_URL | official endpoint | Optional profile-websocket override for explicit DEX-profile mode. |
| DEXSCREENER_PROFILE_POLL_MS | 15000 | REST catch-up interval used only in DEX-profile mode. |
Pair enrichment
New mints appear before a DEX pair exists. Until Dexscreener indexes a usable pair, the interface shows pair pending instead of inventing a price or liquidity value.
| variable | default | purpose |
|---|---|---|
| DEXSCREENER_TOKEN_ADDREpollingS | — | Optional Solana watchlist for the pair-metrics view. |
| DEXSCREENER_CACHE_MS | 20000 | Snapshot cache duration, clamped between 10 and 120 seconds. |
| DEXSCREENER_API_BASE_URL | official API | Optional REST proxy or test override. |
See the Solana logsSubscribe reference, getTransaction reference, PumpPortal real-time API docs, and DEX Screener API reference.
#CLI reference
Run solard help for the current command list. From a source checkout, the equivalent entrypoint is bun src/cli.ts ….
Wallets and tokens
solard import <private_key> [name] cat key.json | solard import --stdin [name] solard wallets [--token <token>] [--addresses-only] solard token <token_ca> [name] [--metadata-json <json>] solard token set <token|ca> [--pool <address>] [--quote-mint <mint>] [--quote-program <program>] solard token refresh <token|ca> solard tokens
Prices and trading
solard quote buy <token|ca> --sol 0.5 solard price <token|ca> solard price average <token|ca> --period 15m solard price watch <token|ca...> [--interval 1s] [--period 1m] solard buy <token|ca> (--wallet <wallet> | --wallets w1,w2 | --group <name>) --sol 0.5 [--sender rpc|helius|jito] [--simulate-only] solard sell <token|ca> (--wallet <wallet> | --wallets w1,w2 | --group <name>) [--bps 10000] [--sender rpc|helius|jito] [--simulate-only] solard unwrap-wsol (--wallet <wallet> | --wallets w1,w2 | --group <name>) [--simulate-only] solard claim <token|ca> --wallet <wallet> [--sender rpc|helius|jito]
Groups, agents, watches, and ALTs
solard group create <name> [description] solard group add <group> <wallet> [weight_bps] solard group add-many <group> w1,w2,w3 solard group show <group> solard group list solard agent create <name> --wallet <wallet> [--config-json <json>] solard agent list solard watch token <token|ca> [label] solard watch wallet <wallet> [label] solard watch program <address> [label] solard watch list solard history solard jito tip-accounts [--endpoint <url>] solard alt add <address> [label] solard alt list solard alt create --wallet <wallet> solard alt extend <address> --wallet <wallet> <account...>
#Venues & senders
The Pump plugin directory contains separate pump-curve-venue.ts and pumpswap-venue.ts implementations plus routing and instruction builders.
- bonding-curve venue implementation
- Pump instruction builders
- creator-fee claim source
- launch source and launchpad support
- AMM venue implementation
- separate PumpSwap instructions
- resolved through the venue registry
- token pool/quote configuration supported by CLI
Senders
| flag | path | use |
|---|---|---|
| rpc | configured RPC | default general-purpose sender |
| helius | Helius Sender / configured policy | fast-lane path when configured |
| jito | Jito block engine | group buys/sells are documented as bundles of five transactions |
--simulate-only. Launching uses its own --live and --skip-simulation controls.#Launching
The CLI supports metadata upload, direct Pump deployment, coordinated buyer groups, and script-driven launch workflows. Use solard deploy pump for direct deployment or a registered script for multi-step workflows.
solard metadata upload --image ./logo.png --name "TOKEN" --symbol TKN --description "..." [--provider pump-frontend|pinata]
solard deploy pump --wallet dev --name "TOKEN" --symbol TKN --image ./logo.png --description "..." [--live]
solard run launch-pump-token --creator dev --metadata token.json [--creator-buy-sol 0.1] [--buyer-group snipers] [--live] solard run prepare-pump-launch-alt --creator dev --metadata token.json --creator-buy-sol 0.1 [--create --live]
Submit modes
after-deploy-processedspam-after-market-readyfast-spam
#SDK, scripts & agents
The package exports the SDK root plus venue, claims, Pump venue, trader preset, launches, launchpads, and runner modules.
import { defineSolardConfig } from "solard/runner"; export default defineSolardConfig({ scripts: { snipe: "./scripts/snipe.ts", "claim-trade-send": "./scripts/claim-trade-send.ts", }, });
solard scripts solard run <name-or-path> [script flags...] solard run snipe --name "EXACT NAME" --group snipers --sol 0.05 --sender jito solard run claim-trade-send --claim <token> --buy <token> --wallet main --recipient <address>
Agent posture
- Use dedicated low-balance wallets.
- Allow read-only quotes and simulations freely.
- Keep
SOLARD_ENABLE_LIVE_TRADES=0while developing tool calls. - Use group weights and agent config as blast-radius controls.
- Inspect history and activity after every automated run.
#Safety & operations
- Live gate: shipped as
SOLARD_ENABLE_LIVE_TRADES=0. - Wallet encryption: CLI help requires
SOLARD_MASTER_KEYto import/decrypt stored wallets. - Simulation: buy, sell, and unwrap support
--simulate-only. - Local auth: use
SOLARD_WEB_TOKENwhen serving beyond localhost. - Supervision: bgrun process state, staleness deadlines, optional auto-recovery.
- Tracing: measure-fn instrumentation is present across the codebase.
#Source reference
package.jsonpackage name, binary, exports, scripts, dependencies
indexer/main.tsmarket indexing entry point
src/cli.tscanonical command help
src/venues/pumpPump curve, PumpSwap, routing, launches, claims
main.tsworker registry and default startup selection
app/SOLARD trade app routes
app/api/HTTP API route families
.env.exampleruntime configuration