Four values into config.env and your bot posts thank-yous in your Twitch chat. Takes about ten minutes if you've never done it before, less if you have.
everything happens in your own Twitch developer portal.
config.env on your own host: a Client ID, an OAuth token, and two numeric user IDs. Your Twitch account stays in your control; nothing about this setup routes through us. When the bot starts, it connects to Twitch's EventSub, subscribes to your channel's chat, and posts thank-yous when a tip lands on-chain.
The bot posts in chat as a Twitch account. You have two options and they're both fine:
yourname_bot). Thank-yous post under that handle, visually distinct from your own messages. Good if you want the bot to feel like a separate entity in chat.Whichever you pick, you'll need to be signed in as that account when you generate the OAuth token in Step 3. If you're using a dedicated bot account, sign in to it first in your browser.
Registering an app gives you a Client ID — a public identifier Twitch uses to recognize your bot's API calls. Not a secret.
http://localhost:3000 (required by the form; we don't actually use this redirect)You don't need the Client Secret for this bot. We use user-access tokens, not app-access tokens, so the secret isn't part of the flow.
The OAuth token is a credential that lets the bot read chat and post chat as the bot's Twitch account. It's a secret. Treat it like a password.
user:bot — lets the token identify the account as a chatbotuser:read:chat — read chat messagesuser:write:chat — post chat messagesThe Twitch CLI is Twitch's official tool. Install it, then:
twitch configure
# paste your Client ID when prompted
twitch token --user-token --scopes "user:bot user:read:chat user:write:chat"
It opens a browser, you sign in as the bot account, approve the scopes, and it prints the token to your terminal. Copy it — you'll paste it into config.env in a moment.
If you'd rather stay in a browser: twitchtokengenerator.com is a popular community tool. Select Custom Scope Token, tick the three scopes above, authorize, and it gives you a token. This runs on someone else's infrastructure — if you'd rather not trust a third-party generator, use the CLI instead.
/check and you'll regenerate via the same steps and paste the new token in. No other cleanup needed.
Twitch's API identifies accounts by numeric ID, not by the visible login name. You need two:
If your bot account is your streaming channel (solo streamer using the main account), these two IDs are identical.
Enter the account's login name at streamweasels's username-to-ID tool — it returns the numeric ID instantly. Do this twice (once for the bot account, once for the channel) unless they're the same account.
If you have the OAuth token from Step 3 handy and curl available:
curl -H "Authorization: Bearer YOUR_OAUTH_TOKEN" \
-H "Client-Id: YOUR_CLIENT_ID" \
"https://api.twitch.tv/helix/users?login=YOUR_LOGIN_NAME"
The response has an id field — that's the numeric user ID.
Open your bot's config.env file and fill in the Twitch section:
Save the file and restart the bot:
# if you're running locally
# stop the bot (ctrl-C) and run npm start again
# if you're on Railway/Render/Fly
# redeploy — they'll restart with the new env vars
Open /check on your bot's URL. The Twitch row should go green, with a message like "connecting to eventsub; announcing in channel user 12345678". If it shows red, the detail text on the row tells you what to fix.
When a tip lands on any chain the bot watches, the Twitch adapter posts a thank-you in the target channel. When a viewer mentions the bot with the word "tip" or starts a message with !tip, the bot replies with your tip page URL. Both are stateless — the bot doesn't remember anything between tips.
The OAuth token is wrong, expired, or missing scopes. Regenerate it in Step 3 and make sure all three scopes are selected. Tokens don't include the oauth: prefix anymore — paste just the letters and digits.
The bot's account doesn't have permission to post in the target channel — or the channel's chat is in a mode (emote-only, followers-only, subscribers-only) that excludes the bot. Make the bot account a moderator in the channel, or adjust the channel's chat mode.
Twitch requires some channels' chatters to have phone verification. Sign in to the bot account, go to Security & Privacy settings, add a phone number, verify it.
First check that tips are actually landing — open /check and confirm the chain rows (XRPL/Base/Arbitrum/Solana) are green. If they are but Twitch doesn't post, check the bot's logs for twitch send-chat-message failed — the error message tells you whether it's an auth issue (revalidate token) or a channel permission issue (make bot a mod).
See the general troubleshooter or post an issue. For Twitch-specific quirks not covered here, the Twitch chat documentation is the authoritative source — their error messages tend to be precise.
Head to the configurator, scroll to the Twitch subsection of the chat platforms block, and paste them in. The generator includes them in your bundle's config.env.
You can also skip the configurator entirely and just edit config.env directly in an existing bundle — the bot picks up the values on next restart.