Forward TweetStream tweets to Discord via webhooks
Forward filtered tweets into any Discord channel via webhooks — no bot user, no OAuth.
Why Discord webhooks
Discord channel webhooks take a single HTTP POST and render the body as a native embed. No Discord bot user, no OAuth flow, no gateway connection on your side.
Pair that with TweetStream's filtered stream and you get a zero-maintenance alerting channel — the worker you run is a thin translator between our WebSocket and Discord's webhook endpoint.
1. Get a Discord webhook URL
In the target channel, open Edit Channel → Integrations → Webhooks → New Webhook. Copy the webhook URL — it encodes the channel ID and a secret token. Treat it as a credential.
2. Install worker dependencies
The examples below assume a fresh project. Install the package imports first so the snippets run without module errors.
Node.js:
Python:
3. Forward tweets (Node.js)
A minimal Node.js worker that posts every tweet from the stream as a Discord embed.
3b. Forward tweets (Python)
Same worker in Python using websockets and aiohttp.
4. Filter on detected tokens (optional)
Swap the listener to react on tweet/meta envelopes so you only alert when TweetStream has detected a ticker, contract address, or DEX URL.
Rate-limit and deployment notes
- Discord webhooks allow roughly 30 requests per minute per webhook. Batch or throttle if your stream exceeds that.
- Discord embeds render better than raw text — use
title,description,url, andauthorfields. - Keep the webhook URL in a secret manager. Rotating it means regenerating the integration in Discord.
- For alerts per tracked handle, set
discordWebhookon each tracked account via the dashboard — TweetStream will route matching tweets without a worker process.
Start real-time Twitter WebSocket alerts today
WebSocket delivery, OCR, and token detection - no infrastructure to build.
Start 7-Day TrialFrom $199/mo · Basic/Elite 7-day trial · OCR + token detection included
