All guides
Getting started
What a bot is, how to pick a platform, polling versus webhooks, and the minimum production checklist.
TelegramTelegram bots
Create a bot with BotFather, handle updates with polling or webhooks, add inline keyboards and stay within limits.
DiscordDiscord bots
Register an application, choose Gateway intents, ship slash commands and buttons, and verify HTTP interactions.
WhatsAppWhatsApp Cloud API
Send and receive WhatsApp messages through Meta's official Cloud API with templates, webhooks and opt-in.
SlackSlack bots
Create a Slack app with a manifest, choose scopes, receive events over HTTP or Socket Mode and verify requests.
AIAI chatbots and agents
Add language models to a bot with tool calling, retrieval and MCP while controlling cost, latency and prompt injection.
AutomationAutomation workflows
Design trigger and action workflows, self-host n8n, handle errors and know when to move to code.
WebhooksAPIs and webhooks
Build webhook receivers that verify signatures, acknowledge fast, deduplicate and retry correctly.
ScrapingWeb scraping ethics
When automated collection is acceptable, how to be a polite crawler, and the lines you should not cross.
HostingHosting bots
Pick the right runtime for polling, Gateway and webhook bots, and run it with restarts, logs and backups.
ServerlessBots on Cloudflare Workers
Deploy a webhook bot at the edge with secrets, storage, background work and scheduled jobs.
SecurityBot security
A threat model and checklist for bots: secret management, least privilege, signed webhooks, SSRF, injection and leaks.
ReliabilityReliability and rate limits
Keep a bot fast and correct under load: respect 429s, queue work, deduplicate, time out and alert.
MetaMessenger and Instagram bots
Connect a bot to a Facebook Page or Instagram professional account through the Messenger Platform: webhooks, the 24-hour window and app review.
CommunityTwitch, Reddit and X bots
Build community bots for Twitch chat, Reddit and X: authentication, EventSub, API access rules, rate limits and disclosure.
MatrixMatrix bots
Write bots for the open, federated Matrix network: access tokens, /sync, sending events, encryption and when to use an appservice.
VoiceVoice bots
Design voice assistants and phone bots: the STT, LLM and TTS pipeline, streaming, turn-taking, latency targets and consent for recording.
AIRAG chatbots
Ground bot answers in your own docs: chunking, embeddings, hybrid search, reranking, citations, permissions and evaluation.
AIFunction calling
Let an LLM call your APIs safely: write tool schemas, validate arguments, confirm side effects, handle errors and limit loops.
QualityTesting bots
A test strategy for bots: pure handlers, recorded payloads, fake platform APIs, conversation scripts, contract checks and LLM evals.
DevOpsCI/CD for bots
Ship bot changes safely: CI checks, secret handling, staging bots, registering commands on deploy, webhook updates and fast rollback.
DataDatabases and state
Choose where bot state lives: in-memory, key-value, SQL or document stores; model sessions and flows; handle concurrency and retention.
i18nInternationalization (i18n)
Make a bot speak several languages: detect and store locale, use message catalogs with plurals, localize commands, dates and numbers.
PaymentsPayments in bots
Accept money in a bot correctly: Telegram invoices and Stars, Discord SKUs and entitlements, external checkout, webhooks and refunds.
ScaleScaling, queues and monitoring
Grow from one process to many: split ingestion from work with queues, shard gateways, and watch the right metrics with useful alerts.
LegalLegal, terms and privacy
What bot builders should know: platform developer terms, privacy policies, GDPR-style rights, retention, AI disclosure and spam rules.
AI securityPrompt injection defense
Defend LLM bots against direct and indirect prompt injection with least privilege, confirmation, isolation, output checks and red-team tests.
TelegramTelegram bot in Python
From BotFather to a deployed bot: handlers, conversations, inline buttons, error handling, persistence and switching from polling to a webhook.
DiscordDiscord bot in Python
Application setup, intents, a CommandTree with typed slash commands, deferring, buttons, permissions, error handling and deployment.
BasicsBot commands and menus
Name commands well, register them per platform, localize them, scope them to the right users and fall back to buttons where commands do not exist.
AutomationScheduled messages and reminders
Store jobs in a database, poll for due work, handle time zones and DST, respect platform limits and deliver each reminder exactly when it should.
DevOpsDocker for bots
Package Node and Python bots in containers with non-root users, health checks and Compose for Redis or Postgres.
DevOpsLogging for bots
Structure logs, redact tokens, trace webhook requests and alert on silence.
SecurityWebhook security deep dive
Verify signatures, reject old timestamps, avoid SSRF when fetching URLs and ACK fast.
ArchitectureMulti-platform bots
Design a core domain with thin platform adapters instead of copy-pasting handlers.
PrivacyBot analytics and privacy
Count commands and errors, not private message contents. Retention and disclosure tips.
BasicsEnv and config
Separate secrets from config, validate on boot, and keep per-environment files out of git.
ReliabilityError handling
Classify errors, reply safely to users, retry with backoff and capture enough context for debugging.
TelegramTelegram webhooks in production
Set up setWebhook with secret_token, reverse proxies and safe rotations.
DiscordDiscord interaction timeouts
Acknowledge slash commands in time, defer long work and edit the response.
DataSQLite for bots
Use SQLite for single-node bots, WAL mode, backups and clear migration paths to Postgres.
ArchitectureFeature flags for bots
Roll out commands to a guild allow-list, kill switches and per-platform flags.
BasicsDocumenting your bot
Write a clear /help, permissions list, privacy summary and support path.
ReliabilityIdempotency for bots
Make payments, tickets and role grants safe under webhook retries.
ReliabilityGraceful degradation
Fallback replies, cached answers and feature flags when dependencies fail.
DevOpsBackup and restore
What to back up, how often, and how to test restores on a staging bot.
ReliabilityRate-limit strategies
Queues, token buckets, per-chat limits and honoring Retry-After.
BasicsAdmin commands
Restrict /broadcast and /stats to owner ids without shipping a full dashboard.
BasicsMessage formatting
Pick parse modes, escape user content and keep buttons usable.
ArchitectureQueues for bots
Move LLM calls and broadcasts off the webhook request path.
HostingDNS for webhooks
Point hooks.example.com at your VPS or edge worker correctly.
DevOpsVersioning bots
Tag releases, announce breaking command changes and keep a changelog users can read.
SecurityInput validation
Length limits, allow-lists, rejecting unexpected attachment types.
ReliabilityChaos testing bots
Break dependencies on purpose in staging.
DevOpsCanary deploys
Route a fraction of chats to the new version.
ReliabilitySLAs and error budgets
Define uptime goals that match your on-call reality.
BasicsStructured arguments
Prefer typed slash options over fragile regex parsing.
BasicsChat pagination
Buttons for next/prev beat huge walls of text.
DiscordEphemeral replies
Keep admin noise out of public channels.
TelegramGroup privacy mode
Know what your bot can and cannot see.
WhatsAppWhatsApp templates overview
Outside the 24h window you need approved templates.
MatrixMatrix bots quickstart
Homeserver access tokens and sync loops.
PlatformsReddit API rules
Use official APIs and stay within rate limits.
DevOpsThree pillars of observability
What to collect first when you run bots alone.
DevOpsBlue-green bot deploys
Two URLs, one cutover, zero missed updates.
ReliabilityDead-letter queues
Keep poison messages out of the hot path.
ReliabilityCircuit breakers
Stop calling a failing dependency for a while.
SecuritySecrets rotation runbook
Tokens, webhook secrets and OAuth clients without downtime.
ReliabilityLoad testing webhooks
Synthetic traffic, not production users.
ArchitectureMulti-tenant bots
Guild/workspace ids as tenants and hard data boundaries.
BasicsBot UX writing
Short, clear, actionable messages with an escape hatch.
ArchitectureSchedulers vs chat process
Separate cron workers from the webhook/gateway process.
DataPostgres SKIP LOCKED
A durable queue without Redis for small fleets.
ReliabilityRedis rate limits
Token buckets and fixed windows keyed by chat id.
AIOpenAI-compatible APIs
Base URLs, keys, timeouts and aborting streams.
AIStreaming replies
Edit messages as tokens arrive without spamming edits.
AITool calling safety
Allow-lists, confirmations and argument schemas.
AIVector store ops
Reindex, delete-by-user and stale chunk cleanup.
DiscordDiscord sharding intro
Guild thresholds, shard formula and session starts.
TelegramTelegram Mini Apps notes
Init data validation and opening from a bot button.
SlackSlack interactivity ACK
Three-second window and response_url follow-ups.
WhatsAppWhatsApp 24h window
When free-form replies are allowed vs templates.
MatrixMatrix E2EE bots
When bots can participate in encrypted rooms.
DevOpsInfra as code
Terraform/Pulumi tips without over-engineering a single bot.
DevOpsContainer healthchecks
Wire Docker HEALTHCHECK to /healthz correctly.
SecuritySafe dependency updates
Dependabot, staging bots and reading changelogs.
LegalAbuse reports
Respond, pause, document, restore or terminate.
BasicsAccessible messages
Do not rely on color or emoji alone for meaning.
BasicsLocalization plurals
Use ICU/CLDR plural forms, not naive +s.
SecurityWebhook mTLS notes
When mutual TLS is worth it inside a VPC.
ReliabilityACK latency SLOs
Measure time-to-200 separately from time-to-reply.
ArchitectureBot config schema
Validate config at boot; fail fast on typos.
SecurityEgress IP allowlists
Optional defense in depth after signature checks.
PrivacyTranscript export
DSAR-friendly exports without over-collecting.
BasicsBot naming
Clear identity, no impersonation, stable handle.
ArchitectureHorizontal scaling webhooks
Dedup, sticky sessions myths and shared state.
TelegramSingle-flight polling
Only one getUpdates loop per token.
DiscordDiscord audit logs
Intents, permissions and privacy caveats.
SlackSlack App Home
Publish views carefully; keep payloads small.
CostsLLM cost attribution
Meter tokens with tenant labels in your logs.
SecurityBackup encryption
Encrypt at rest and test restores with the key.
BasicsProgressive /help
Short help first; details on demand.
ReliabilityBot status pages
Separate status from marketing; say what is broken.
ArchitectureEmail to chat
Parse carefully; never execute links from email.
SecurityUpload scanning
Size caps first; async scan before processing.
DiscordGuild install analytics
Count installs, not message contents.
TelegramTelegram Business bots
Read current Bot API business methods before shipping.
ArchitectureWorker concurrency
Cap in-flight LLM calls per process.
SecurityWebhook replay protection
Reject old timestamps and reuse of event ids.
ReliabilityOn-call basics for bot teams
Alerts that wake humans should be rare, actionable and tied to user impact.
BasicsChoosing a language for your first bot
Pick the ecosystem you can ship and operate — not the trendiest runtime.
DevOpsShadow traffic for bot deploys
Replay or fork a slice of webhooks to a candidate build before cutting DNS.
TelegramRegistering bot commands with setMyCommands
setMyCommands controls the in-client command menu; scopes decide where each command appears.
TelegramInline keyboards without callback chaos
inline buttons persist on old messages so callback_data must stay backward compatible.
TelegramBots in Telegram forum topics
forum topics require echoing message_thread_id or replies fall into General.
TelegramDownloading Telegram files safely
getFile returns a temporary path; treat downloads as untrusted binary input.
TelegramHandling Telegram Bot API 429 responses
Telegram signals overload with 429 and retry timing you must honor.
DiscordMessage components and buttons
component interactions must ACK fast; version custom_id and never store secrets there.
DiscordSlash command autocomplete
autocomplete handlers have a short deadline and must stay side-effect free.
DiscordModal forms for Discord bots
modals collect structured text you must length-check and sanitize.
DiscordPresence and activity updates
presence updates are gateway traffic; flapping wastes session budget
DiscordWorking with Discord threads
threads need Create Public/Private Threads permission and archival handling.
DiscordChannel webhooks vs bot tokens
incoming webhook URLs are secrets suited to simple posts not slash UX.
DiscordRole checks for privileged commands
authorize by role id because names are renamable.
DiscordSelect menus for Discord bots
select values must be allowlisted like any form input.
DiscordUser and message context menus
context menus act on a target; verify the invoker may touch that target.
DiscordGuild scheduled events from bots
Manage Events permission plus UTC storage for start and end.
DiscordCustom emoji and stickers in replies
custom emoji need guild availability; fall back to unicode.
DiscordGateway resume and session restart
resume correctly after disconnects to avoid burning session_start_limit.
DiscordMESSAGE_CONTENT intent checklist
privileged message content requires portal enablement and a clear need.
DiscordDiscord embed field limits in practice
embeds reject oversized titles fields and totals; validate before send.
DiscordResolving channel permissions for actions
compute effective permissions before send react or manage messages.
DiscordAudit log reasons from bots
supply clear reason strings without embedding secrets or PII dumps
DiscordWorking alongside Discord AutoMod
coordinate bot actions with AutoMod so you do not fight the platform
DiscordInvite attribution basics
track vanity and invite uses carefully and disclose analytics
DiscordTimeout members via moderation API
communication_disabled_until needs rights confirmation and an audit reason
DiscordLocalizing slash command names
command name localizations have charset and length rules per Discord docs
SlackValidating Block Kit payloads
Block Kit has strict element limits; invalid payloads fail at runtime
SlackSlack global and message shortcuts
shortcuts still need 3s ACK and may open modals
SlackSlash command acknowledgment patterns
slash commands must ACK quickly then use response_url or chat APIs
SlackExternal select options load
options load endpoints must respond fast with filtered choices
SlackLegacy workflow steps vs modern automation
prefer current Slack automation primitives; keep secrets out of step configs
SlackAssistant-style threads in Slack
keep assistant UX ephemeral where needed and respect channel context
SlackHandling file_shared events
file events need download auth and malware scanning before processing
SlackUser token scopes vs bot tokens
prefer bot tokens; user tokens widen blast radius and need clearer UX consent
SlackSlack event_id deduplication
Slack may retry events; dedupe on event_id in a shared store
SlackApp Home publish rate limits
views.publish is rate-limited; coalesce updates per user
SlackEvent metadata and correlation
propagate enterprise/team/user ids into logs without storing message bodies
SlackInteractivity payload versions
parse block_actions carefully and version private_metadata
SlackSocket Mode reconnect storms
backoff reconnects and cap concurrent connections per app
SlackEnterprise Grid considerations
team vs enterprise ids differ; test installs across workspaces
SlackLink unfurls from Slack bots
unfurl handlers must be fast and must not leak private link content broadly
WhatsAppWhatsApp template categories
template category choice affects approval and pricing treatment; follow Meta rules
WhatsAppWhatsApp media message sends
media uploads need type allowlists size caps and hosted URLs Meta can fetch
WhatsAppWhatsApp interactive buttons
interactive replies are session-bound; handle button payloads as untrusted input
WhatsAppPhone number quality rating awareness
poor quality ratings throttle delivery; monitor and fix template/user opt-in issues
WhatsAppCapturing WhatsApp opt-in correctly
store proof of opt-in and honor opt-out quickly
WhatsAppWhatsApp Cloud API webhook fields
parse entry changes carefully and ACK before slow work
WhatsAppWhatsApp Graph error codes in bots
map common Graph errors to user-visible guidance without leaking tokens
WhatsAppMulti phone-number bot routing
route by phone_number_id and isolate tokens per number
WhatsAppWhatsApp Flows notes for bot builders
Flows are a separate surface; validate endpoints and do not mix with chat ACK paths carelessly
WhatsAppWhatsApp business profile fields
keep profile description consistent with bot /help and privacy text
AISystem prompts for chat bots
keep system prompts versioned short and free of secrets
AIChunking strategies for RAG bots
chunk size and overlap affect retrieval quality and cost
AIEmbedding model upgrades
changing embedding models requires reindexing and dual-read plans
AIOutput filters before send
scan model output for secrets and policy violations before chat send
AIPrompt injection defenses
treat retrieved docs and user text as untrusted; constrain tools
AIRouting between models
send easy tasks to cheaper models; keep an allowlist of model ids
AIStructured JSON outputs from LLMs
validate JSON schema before side effects; repair carefully
AICitations and grounded answers
do not invent citations; show retrieval misses honestly
AIPer-request token budgets
hard-cap prompt and completion tokens to protect latency and cost
AIOffline eval harness for bot prompts
keep a golden set of prompts and expected traits in CI
AITimeouts around tool calls
every tool call needs a deadline and a user-visible fallback
AIConversation memory windows
summarize or truncate history; never ship unbounded transcripts to the model
AIPII redaction before LLM calls
strip emails phones and tokens from prompts when policy requires
AIFallback models on provider outages
define ordered fallbacks and circuit-break open providers
AILayered guardrails for agents
combine allowlists schemas human confirmations and output filters
DevOpsHealth endpoint contracts for bots
separate liveness from readiness; keep liveness dependency-light
DevOpsDraining connections on deploy
fail readiness then wait for in-flight ACKs before exit
DevOpsLog sampling under high chat volume
sample debug logs; always keep security and ACK failures
DevOpsNaming metrics for bot fleets
stable metric names beat clever ones; avoid high-cardinality labels
DevOpsHot-reloading bot config safely
reload non-secret config with validation; never hot-reload tokens casually
DevOpsExpand/contract migrations for bots
add nullable columns first; remove later after dual-write window
DevOpsCanary guilds and tenants
ship risky commands to a pilot set before global enable
DevOpsSBOM and dependency inventory for bots
generate SBOM in CI and track critical advisories
DevOpsPinning language runtimes in images
pin major.minor of Node/Python in Docker digests when possible
DevOpsSecret scanning in bot repositories
block commits that look like bot tokens or webhook URLs
DevOpsActive-active bots across regions
share idempotency and rate-limit state; avoid dual polling
DevOpsCron jitter for scheduled bot jobs
spread minute-0 jobs to avoid thundering herds on shared APIs
DevOpsOpenTelemetry traces for webhooks
propagate trace context from ACK through queue to LLM
DevOpsCleaning up stale feature flags
remove flags after rollout to avoid permanent branching debt
DevOpsSigning release artifacts
sign container images or zip artifacts and verify in deploy
DevOpsBackup restore drills for bot data
schedule restores into isolated envs; measure RTO honestly
DevOpsEgress proxies for bot HTTP
centralize egress for allowlists and TLS policy
DevOpsParsing upstream rate-limit headers
honor Retry-After and vendor-specific remaining headers
DevOpsProcess supervision choices for bots
systemd/pm2/k8s each need SIGTERM handlers and restart budgets
DevOpsFail-fast config validation on boot
validate env against schema before accepting traffic
SecurityStoring bot tokens at rest
encrypt tokens at rest and restrict decrypt roles
SecurityWebhook secret entropy requirements
generate high-entropy secrets; avoid human-memorable phrases
SecurityConstant-time secret compares
use timing-safe compares for HMAC and secret tokens
SecuritySSRF guards for bot-fetched URLs
block link-local and metadata IPs when fetching user URLs
SecurityAdmin action audit logs
record who ran privileged commands with correlation ids
SecurityCSP for bot admin dashboards
lock down script sources on any HTML admin UI
SecurityOAuth state and PKCE for bot installs
validate state and prefer PKCE when the platform supports it
SecuritySession fixation on bot dashboards
rotate session ids on login and use Secure cookies
SecuritySecurity impact of floating versions
floating latest tags pull surprise breakages and advisories
SecurityLightweight threat models for bots
list assets attackers want: tokens webhooks and user PII
SecurityWAF rules in front of webhooks
allow platform user-agents carefully; do not block signature failures wrongly
SecuritySeparating signing and API keys
different keys for webhook verify vs outbound API calls
SecuritySecurity headers on bot HTTP servers
set minimal headers even on JSON APIs behind TLS terminators
SecurityAbuse-oriented rate limits
limit expensive commands per user harder than cheap reads
SecurityHandling leaked bot tokens
revoke first rotate second then audit sends
DataIndexing chat and user ids
index text ids used in WHERE clauses; avoid leading-wildcard searches
DataTransactional outbox for bot sends
write outbound intents in the same DB transaction as state changes
DataInbox table for webhook dedupe
store event ids with TTL longer than platform retry windows
DataSoft deletes for chat records
prefer soft delete when users may request export later
DataDB pools for webhook workers
size pools to concurrency limits; never hold connections during LLM calls
DataRead replicas for bot queries
send heavy analytics reads to replicas; keep ACK path on primary
DataSchema comments as documentation
comment tables with ownership and retention in migrations
DataJSON columns for bot state
use JSON for evolving optional fields; keep hot filters as real columns
DataAvoiding long migration locks
batch backfills; avoid rewriting huge tables in one txn
DataScheduled retention jobs
delete or anonymize expired rows on a schedule you can prove
DataIdempotent upserts for bot state
upsert on natural keys from platform event ids
DataQueue payload size budgets
keep jobs small; store blobs in object storage by reference
DataStoring user timezones
store IANA names not numeric offsets alone
DataMarking PII columns explicitly
tag PII in schema docs and restrict SELECT in analytics roles
DataPII in database backups
encrypt backups and limit who can restore identifiable data
ArchitectureHexagonal layout for bot codebases
isolate platform adapters from domain logic for testability
ArchitectureCommand bus for chat intents
map slash/text intents to command handlers with authz hooks
ArchitectureLight event sourcing for bots
append domain events for critical audits without full CQRS theater
ArchitectureAnti-corruption layers for platforms
translate platform payloads into your domain types at the edge
ArchitectureCanceling long-running bot sagas
support user cancel and deadlines across multi-step flows
ArchitectureBackpressure from chat to workers
shed load when queues deepen instead of unbounded accept
ArchitectureShared kernels across bot platforms
share domain modules; keep transport packages separate
ArchitectureSandboxing bot plugins
load third-party plugins with allowlisted capabilities
ArchitectureVersioning internal bot APIs
version HTTP and queue contracts independently of chat UX
ArchitectureContract tests for platform adapters
freeze fixtures per platform and fail CI on parser drift
ArchitectureBulkheads between dependencies
isolate thread/async pools per dependency to stop cascades
ArchitecturePreventing retry storms
cap retries jitter and use idempotency keys everywhere
ArchitectureState machines for conversations
explicit states beat boolean soup for multi-turn flows
ArchitectureActor-ish per-chat concurrency
serialize work per chat id to avoid races
ArchitectureTesting ports without network
fake platform ports in unit tests; reserve network for contract suites
BasicsUser onboarding checklist for bots
welcome permissions privacy and first success action in order
BasicsWriting error messages users understand
say what failed how to fix and how to get help without stack traces
BasicsEmpty states in bot UX
when lists are empty say how to create the first item
BasicsConfirmations that prevent mistakes
summarize the irreversible action before the confirm button
BasicsProgress updates for long tasks
edit a single status message instead of flooding the chat
BasicsOrganizing i18n keys for bots
namespace keys by feature; avoid concatenating translated fragments
BasicsText alternatives for rich messages
provide plain-text fallbacks beside embeds and images
BasicsExamples inside /help
show one copy-pastable example per top command
BasicsTone guidelines for bot replies
document voice do/don't so LLM and templates stay consistent
BasicsSupport macros for human handoff
give humans macros that include correlation ids
BasicsAnnouncing changes inside the bot
optional /changelog command summarizing user-visible changes
BasicsExplaining permission requests
say why each scope is needed before the install link
BasicsFormatting for mobile chat clients
short paragraphs; avoid wide ASCII tables
BasicsFirst-run permission diagnostics
detect missing permissions and tell admins how to fix invites
BasicsKeeping personality within bounds
personality should not override safety refusals or legal text
MatrixJoining and leaving Matrix rooms
handle invites knock and leave cleanly; log room ids
MatrixAppservice bridge basics
appservices need correct namespaces and HS registration YAML
MatrixMatrix HS rate limits
respect HS rate limits; backoff soft-fail user actions
MatrixPush rules awareness for bots
bots should not rely on noisy notifies; prefer explicit mentions carefully
MatrixReading room state events
cache state carefully and invalidate on state events
HostingTLS certificate renewal monitoring
alert before expiry; test renewals in staging
HostingReverse proxy buffer sizes
size request buffers for webhook bodies you actually accept
HostingCDNs in front of webhooks
usually terminate TLS at origin/proxy; avoid caching POST webhooks
HostingVPS firewall defaults for bots
deny by default; allow 22/80/443 and admin sources carefully
HostingShipping logs to object storage
batch upload rotated logs with encryption and retention
HostingSwap and OOM behavior for bot hosts
prefer OOM visibility over hidden swap thrash for latency-sensitive bots
HostingClock sync for signature checks
skew breaks Slack timestamp checks; keep NTP healthy
HostingDisk watermarks before log floods
alert on disk used before webhook workers fill the volume
HostingIPv6 for webhook endpoints
publish AAAA only if your stack listens and platforms can reach you
HostingCapacity planning for chat spikes
plan for launch spikes with queue depth and ACK SLOs
ReliabilityWorking an ACK error budget
burn alerts should change deploy pace not just page endlessly
ReliabilitySynthetic checks for bots
probe /healthz and a signed fake webhook path in staging
ReliabilityPager routing for bot incidents
route by severity; critical for ACK outages warning for queue depth
ReliabilityBlameless postmortems for bot outages
capture timeline impact and action items with owners
ReliabilitySLOs on dependencies not just bots
track LLM and DB success ratios separately from chat ACK
ReliabilityLoad shedding strategies
reject low-priority work when ACK budget burns
ReliabilityChaos experiments on webhook paths
inject latency and 500s in staging only with kill switches
ReliabilityLinking alerts to runbooks
every page must include a runbook URL and correlation hint
ReliabilityChange freeze windows
freeze risky deploys during peak launches you cannot staff
ReliabilityWarm standby bot processes
keep a standby region ready with synced secrets and data plan
PrivacyDSAR export playbooks for bots
authenticate the requester and deliver via short-lived URLs
PrivacyDSAR deletion playbooks
delete or anonymize across DB vectors and backups policy
PrivacyLogging consent events
store when how and what was consented without message bodies
PrivacyAge-gated bot features
avoid collecting child data; follow platform policies
PrivacyInventorying subprocessors
list LLM hosts and analytics vendors in privacy text
PrivacyData minimization for chat logs
store ids and outcomes not full transcripts by default
PrivacyCross-border data notes for bots
know where your host and LLM providers store data
PrivacyPrivacy by default toggles
defaults should share less; opt-in to analytics
PrivacyShowing retention in product UI
surface retention periods next to export/delete commands
PrivacyBreach notification runbook sketch
define who decides who notifies and where evidence lives
TelegramReply keyboards vs inline keyboards
reply keyboards replace the client keyboard; remove them explicitly when done.
TelegramTelegram webhook IP allowlists
if you filter ingress, keep Telegram's published ranges updated and still verify secret_token.
TelegramTelegram deep links and start payloads
t.me deep links pass start payloads into /start as untrusted input.
TelegramEditing and deleting bot messages
edits fail on identical content or old messages; deletes need rights in groups.
TelegramsendChatAction typing indicators
chat actions expire within seconds; refresh during long work then stop.
TelegramValidating Telegram Mini App initData
initData is HMAC-signed with the bot token; skipping validation forges user identity.
TelegramModeration with banChatMember and restrictChatMember
moderation calls can lock users out; require confirmation and audit trails.
TelegramTelegram Payments integration notes
pre-checkout queries need fast answers and successful_payment must be idempotent.
TelegramAuthorization with getChatMember
privileged actions should re-check that the caller is still a member or admin.
TelegramParsing message entities safely
entity offsets use UTF-16 length; naive string indexes break on emoji.
TelegramInline mode and answerInlineQuery
inline queries need fast answersInlineQuery responses and cache_time choices.
DevOpsClient timeouts for outbound platform calls
set explicit timeouts on every Telegram Discord Slack HTTP client call
ArchitectureIdempotency-Key for bot-originated HTTP
send Idempotency-Key when calling payment or ticket APIs
ArchitectureExperiments and A/B flags in bots
assign sticky variants per chat without leaking into logs as PII unnecessarily
BasicsBot avatar and profile consistency
keep avatar description and /about aligned across platforms
BasicsCommand aliases and redirects
map old commands to new ones during renames with a deprecation window
DiscordPer-guild configuration storage
isolate config by guild id and validate on write
DiscordDaily digests into Discord channels
render digests offline and send once; avoid per-item spam
SlackPosting to Slack canvases carefully
follow current canvas APIs; keep secrets out of canvas text
TelegramAdmin tools for forum topics
close reopen and rename topics only with clear authz
WhatsAppCatalog messages overview for bots
catalog features need commerce setup; verify current Cloud API support
AISeparating safety filters from prompts
keep policy filters in code not only in prompt text
AIACL filters on vector retrieval
filter retrieved chunks by tenant before prompting
DataRedis pub/sub for bot fan-out
use pub/sub for notify; still persist durable work in a queue
DataSQLite WAL mode for bots
enable WAL for better concurrent readers on single-node bots
DevOpsKubernetes probes for bot deployments
configure liveness readiness and startup probes with realistic delays
DevOpsHelm values for bot charts
keep secrets out of values.yaml; use sealed secrets or external refs
SecuritymTLS between bot internal services
authenticate service-to-service calls beyond a flat private network
SecurityOverlapping HMAC secret rotation
accept dual secrets during rotation windows
ReliabilityStatus embeds for incidents
post structured incident embeds with next-update times
ReliabilityPoison message handling
detect repeated failures and park payloads in DLQ with redaction
MatrixDevice keys hygiene for Matrix bots
protect device keys like passwords if participating in E2EE
HostingFilesystem snapshots before upgrades
snapshot disks before OS or major dependency upgrades
PrivacyFirst-message privacy banners
show a short privacy notice on first interaction per user
ArchitectureTesting domain logic without Discord SDK
unit-test pure handlers with fake ports
BasicsButton label length and clarity
prefer verbs on buttons; keep labels short for mobile
SlackUsing channel bookmarks with bots
link runbooks via bookmarks instead of pinning secrets
DiscordDiscord forum channels vs text channels
forum posts need thread semantics; do not assume classic text channel behavior
WhatsAppThroughput planning for WhatsApp sends
pace template sends; watch quality rating and throughput limits in current docs
AIAlerting on LLM spend anomalies
alert on sudden per-tenant cost spikes not only monthly totals
DataPartitioning large chat event tables
partition by time for retention drops and query pruning
SecurityDevice trust for admin dashboards
require 2FA and consider device checks for destructive admin actions
ReliabilityMulti-window burn-rate alerts
combine fast and slow burn windows on ACK SLOs
Hostingcgroup memory limits for bot containers
set memory limits so one leak cannot eat the host
DevOpsPre-commit hooks for bot repos
lint secret patterns and formatters before push
PrivacyCookie notices on bot marketing sites
if the marketing site sets non-essential cookies disclose them
Suggested learning path
- Read Getting started to choose a platform and an architecture.
- Build a first bot on one platform: Telegram is the fastest to set up; Discord and Slack teach you interactions and scopes.
- Learn the plumbing: APIs and webhooks, then hosting.
- Harden it with security and reliability.
- Add intelligence with AI chatbots and agents.