Get a Discord embed the moment a proven Solana deployer — one with a real bonding track record on pump.fun or LaunchLab — launches a new token or one of their tokens bonds. This tutorial walks the open-source deployer-alert-discord-bot starter: zero dependencies, ~130 lines, a Discord webhook, and a free MadeOnSol API key.
Every Solana trading group has the same ritual: someone drops a fresh mint, and three people ask "is it safe?" before anyone has opened a scanner. The answer is automatable. In this tutorial you'll stand up a Telegram bot that replies to any pasted mint with a scored rug-risk report — in about ten minutes, on a free API key, with zero npm dependencies.
The code is the open-source rug-check-telegram-bot starter (MIT licensed, ~150 lines). You clone it, set two environment variables, and it runs. This post walks through what it does, how the scoring works, and where to take it next.
What you'll build
DM your bot a mint address (or several — it batch-checks up to 10 per message) and it answers with something like:
🔴 7xKX…gAsU — risk 78/100 (danger)
⛔ Mint authority: not revoked — supply can be inflated
⚠️ Liquidity: $4.2k — thin vs $310k MC
⚠️ Launch: bundled open (38 SOL in first 20 buys)
The number is not a black box. Unlike one-number checkers, every point in the 0–100 score is attributed to a named factor, so your group can argue with the reasons, not just the verdict.
Data only, DYOR: MadeOnSol is a data API — it never executes trades and holds no funds, and neither does this bot. A clean score is a signal, not a guarantee.
Prerequisites
- Node.js 20+ — the bot uses the built-in
fetch, no packages to install.
- A free MadeOnSol API key — sign up at madeonsol.com/pricing; the free tier includes 200 requests/day, no payment details.
- A Telegram bot token — message @BotFather, send
/newbot, copy the token. Two minutes.
Step 1 — Clone and run
git clone https://github.com/madeonsol/rug-check-telegram-bot
cd rug-check-telegram-bot
export MADEONSOL_API_KEY=msk_your_key_here
export TELEGRAM_BOT_TOKEN=123456:ABC...
node index.mjs
That's the whole install. The bot uses raw Telegram Bot API long polling — no framework, no webhook server, no public URL. It runs from a laptop, a VPS, or a free-tier container equally well.
No Telegram token yet? Test the scoring straight from your terminal:
node index.mjs So11111111111111111111111111111111111111112
Step 2 — Understand what your key tier returns
The bot detects your key's tier automatically (one call to GET /me) and adapts:
| Key | What each mint returns |
|---|
| Free | 0–100 early-buyer quality score — known dump-cluster wallets among the first buyers, bot domination, KOL and alpha-wallet presence |
| PRO / ULTRA | The full 0–100 rug-risk score with ten auditable factors: mint/freeze authority, liquidity depth and thinness, LP burn status, Token-2022 transfer fee, bundled launch detection, deployer track record, KOL distribution, and blacklist checks |
Same code, richer output — when a PRO key hits the batch endpoint, checking 10 mints in one message costs one API request. If a free key calls a PRO endpoint, the bot catches the 403 and falls back gracefully, so nothing crashes while you evaluate.
Step 3 — Read the code (it's short on purpose)
Everything interesting lives in two files. lib.mjs is pure logic — mint extraction from free-text messages, HTML escaping for Telegram, score-to-emoji banding — and is fully unit-tested without any network. index.mjs is the loop: poll Telegram, extract mints, call the API, format, reply.
The API calls are two endpoints:
GET /api/v1/tokens/{mint}/buyer-quality — the free-tier score, built from the first buyers' wallet history (dump-cluster membership, recycled wallets, smart-money presence).
POST /api/v1/tokens/batch/risk — the PRO batch rug score, ~200ms for up to 50 mints.
Run the test suite with your key to see live response shapes: node test.mjs.
Step 4 — Make it yours
The starter is deliberately a floor, not a ceiling. The natural next steps:
- Auto-check every mint posted in a group — remove the reply gate and score everything that hits the chat, silently flagging only dangerous ones.
- Score at alert time in your own pipeline — the batch endpoint prices 50 mints per call, which makes "check every new deploy" economical.
- Add the cap table —
GET /tokens/{mint}/cap-table (PRO) returns the named early-buyer breakdown so the bot can say who is in the first 20 wallets, not just how many are toxic.
- Cross-check smart money —
GET /token/{mint} includes live KOL net flow; a risky token that smart money is exiting is a different conversation than one they're entering.
Why not just use an existing checker bot?
Existing checkers give you their score in their bot with their rate limits and their branding. This one is 150 lines you own: score threshold, output format, which factors matter for your group, whether results post publicly or only to admins — all yours to change. And because the data layer is an API built for embedding, the same key powers whatever you build next — the KOL copy-trade starter, a dashboard, or an AI agent.
Full endpoint reference: madeonsol.com/api-docs. Plans and the free key: madeonsol.com/pricing.