Telegram bot in 10 minutes with grammY
From BotFather to a working bot with commands, echo replies and error handling, using grammY and Node.js.
DiscordDiscord bot with discord.js
Create the application, invite the bot, register slash commands and answer them, without privileged intents.
RailwayDeploy a bot to Railway
Push a bot to GitHub, deploy it on Railway with variables, read the logs, switch to webhooks and keep costs under control.
VPSBot on a Vultr VPS with systemd
Create a small VPS, harden SSH and the firewall, install Node.js, and run the bot as a restricted systemd service with logs and auto-restart.
TelegramTelegram webhook + Caddy
Point a domain at a small Node or Python webhook and let Caddy obtain certificates.
DiscordRegister guild slash commands
Use guild command registration while developing, then promote to global.
DevOps/healthz + uptime ping
Expose a liveness route and point any uptime checker at it.
SlackSlack Bolt locally
Develop slash commands without exposing a public URL.
TelegramNode http Telegram webhook
Secret token check, fast 200 and async sendMessage.
TelegramTelegraf first bot
Install, long poll, /start and clean shutdown.
DiscordLeast-privilege Discord invite
Build the URL with the permissions calculator.
SecurityDebug HMAC mismatch
Raw body, encoding and constant-time compare.
DevOpssystemd bot service
Unit file, env file, restart and logs.
DevOpsHealthz + monitor
Liveness route and alerts you will actually see.
DevOps.env.example in CI
Fail builds when required keys are missing from the example.
ReliabilityWebhook fixtures in CI
Replay anonymized payloads without live tokens.
TelegramRotate Telegram secret_token
Dual-support briefly, setWebhook, then drop the old secret.
DiscordEphemeral admin command
Guild install, permission check and ephemeral reply.
SlackSocket Mode to HTTP
Expose a signed Request URL and turn Socket Mode off.
DataLitestream for SQLite bots
Continuous backup without giving up single-node SQLite.
TelegramgrammY webhook secret
Reject requests that omit or mismatch the secret header.
ArchitectureQueued broadcast
ACK the admin command, enqueue recipients, rate-limit sends.
DevOps/readyz with dependencies
Liveness stays dumb; readiness fails when DB or queue is down.
ReliabilityAnonymize fixtures
Replace tokens and PII while keeping signature-valid structure.
HostingCaddy TLS for webhooks
Automatic HTTPS reverse proxy to your local bot port.
TelegramRegister Telegram commands after deploy
Call setMyCommands for default and group scopes.
TelegramShip a one-shot inline button flow
Version callback_data and answerCallbackQuery.
DiscordRegister guild slash commands
Guild registration for fast iteration.
DiscordACK a Discord button interaction
Respond within about 3s or defer.
SlackACK Slack slash via response_url
Return 200 quickly then use response_url.
WhatsAppSend an approved WhatsApp template
Cloud API template send outside the 24h window.
SecurityVerify Slack signatures in Express
Raw body plus timing-safe compare.
SecurityShort-lived JWTs for bot dashboards
Sign admin sessions with short TTL.
DevOpsMulti-stage Docker build for a Node bot
Non-root final image with HEALTHCHECK.
DevOpsKubernetes Deployment for a bot
Probes, resources and Secret refs.
DataTransactional outbox worker
Same-txn intents; async publish.
ReliabilityPer-chat Redis token bucket
Key by platform, chat and action.
AIOpenAI-compatible chat client wrapper
Base URL, model and timeouts from env.
AIRAG document ingest pipeline
Chunk, embed, store with tenant ACL.
Matrixmatrix-nio echo in unencrypted room
Login, sync and reply.
HostingCaddyfile for bot webhooks
Automatic HTTPS reverse_proxy.
HostingNginx TLS proxy for webhooks
Terminate TLS and proxy_pass to the bot.
DevOpsGitHub Actions CI for bots
Lint, tests and bad-signature fixture.
DevOpsError tracker setup for bots
Init SDK, scrub PII, tag handlers.
ArchitectureBullMQ jobs after webhook ACK
Enqueue slow work with concurrency caps.
TelegramFilter grammY commands by chat type
Chat-type filters for menus.
Telegramaiogram FSM conversation sketch
External state; expire abandoned flows.
DiscordHandle Discord modal submit
ACK submit and validate lengths.
DiscordImplement slash autocomplete
Filtered choices under the deadline.
SlackPublish Slack App Home view
views.publish on app_home_opened.
SlackHandle block_actions button
ACK then response_url update.
WhatsAppWhatsApp webhook verify challenge
Echo hub.challenge on token match.
WhatsAppValidate X-Hub-Signature-256
HMAC-SHA256 raw body with app secret.
AIAllowlist tools for LLM agents
Named tools plus JSON Schema args.
AIPrompt evals in CI
Golden prompts must not regress.
DataConsistent SQLite backup script
Use backup API; encrypt the artifact.
DataExpand-contract column add
Nullable first; backfill; tighten later.
DevOpsOTel span around webhook ACK
Start at entry; end after ACK.
DevOpsACK latency Prometheus histogram
Observe verify plus ACK duration.
SecurityRotate Discord bot token safely
Deploy new; revoke old; audit.
HostingSSH tunnel for staging webhooks
Forward carefully; prefer staging DNS.
DataRestore Litestream SQLite replica
Fresh dir; verify; then cutover.
ArchitectureLaunch command behind a flag
Default off; pilot; remove flag.
PrivacyShip /privacy and /export stubs
Short privacy text; authenticated export.
ReliabilityExpose JSON status document
Separate host from bot when possible.
TelegramGraceful Telegraf SIGTERM stop
Stop polling; close; exit 0.
SlackSwitch Bolt to HTTP mode
Signing secret and Request URL; disable Socket.
DiscordEphemeral follow-up after defer
Defer then ephemeral followUp.
DevOpsAdd /healthz to Node http server
GET /healthz returns 200 JSON.
DevOpsKeep .env.example synced
CI checks example vs required keys.
ArchitectureWebhook idempotency middleware
Short-circuit duplicate event ids.
ReliabilityAdmin DLQ single-message replay
Authz plus replay one redacted job.
SecurityCSP on bot admin dashboard
Lock script-src; avoid inline JS.
SecurityEncrypt DB dumps with age or GPG
Encrypt before upload; keys off-host.
MatrixHandle leave or ban in Matrix sync
Stop room work on leave events.
Want the theory behind them? See the guides. Ready-made code lives in templates.