Skip to content

TradeSEB/Orca-Sniper-Bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Orca CLMM Sniper Bot

TypeScript Solana trading bot focused on Orca Whirlpools (CLMM):

  • Monitors Orca Whirlpool pool-initialize transactions in real time
  • Detects newly created pools
  • Instantly buys when pool includes your configured quote mint
  • Manages open positions with take-profit and stop-loss exits
  • Includes a gather command to export positions and optionally harvest fees/rewards

Features

  • Orca CLMM monitor via Whirlpool program log subscription
  • Immediate buy on new pool creation
  • TP/SL sell loop based on live quote simulation
  • Risk controls (MAX_POSITIONS, slippage, token allowlist)
  • Gather/report utility for wallet positions

Stack

  • Node.js + TypeScript
  • @orca-so/whirlpools (v7 action APIs)
  • @solana/kit + @solana/web3.js

Quick Start

  1. Install dependencies:
npm install
  1. Create env file:
cp .env.example .env
  1. Configure required values in .env:
  • PRIVATE_KEY (base58 or JSON byte array)
  • RPC_HTTP_URL, RPC_WS_URL
  • QUOTE_MINT, QUOTE_DECIMALS, BUY_AMOUNT
  • TAKE_PROFIT_PCT, STOP_LOSS_PCT
  1. Start bot:
npm run dev

Commands

  • npm run dev - run bot in tsx mode
  • npm run build - compile to dist/
  • npm run start - run compiled bot
  • npm run gather - generate report under reports/

Environment Variables

See .env.example for full list.

Important ones:

  • NETWORK: solanaMainnet or solanaDevnet
  • ORCA_WHIRLPOOL_PROGRAM_ID: Orca Whirlpool program
  • QUOTE_MINT: token used for sniping buys
  • TOKEN_ALLOWLIST: optional comma separated target mint filter

How It Works

  1. OrcaPoolMonitor subscribes to Whirlpool program logs and watches for initialize instructions.
  2. New pool address + token mints are extracted from the create transaction accounts.
  3. Trader immediately executes swap from quote token into the new token.
  4. Position loop continuously evaluates current value using swapInstructions quote.
  5. If PnL hits TP or SL threshold, bot executes a sell swap and closes the position.

Safety Notes

  • This bot executes real trades with your wallet.
  • Start on devnet and low amounts before mainnet.
  • Use dedicated RPC providers with fast websocket support for competitive sniping.
  • Add strict allowlists/denylists before production usage.

📞 Support

About

Solana orca sniper, orca snipe bot

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors