Connect Twitch

A Twitch connection is one channel. Marketing uses it to send a live stream to the channel (it reads the channel's stream key), to set the broadcast's title and category, to read and write the channel's chat, and to read its numbers. It is your org's or a brand's. See Connections for how connecting works in general.

Ways to connect

There is no key option.

Making your own app

  1. Open the Use your own app dialog for Twitch on the Connections page, and keep it open.
  2. Twitch's developer console requires two-factor authentication on the Twitch account that registers the app. Switch it on in that account's security settings if it is not.
  3. Open the new application page above and give the application a name. Twitch names are unique across Twitch.
  4. Add the redirect URL from the dialog as an OAuth Redirect URL, copied exactly.
  5. Choose a category, and set the client type to Confidential. Create the application.
  6. Open the application's Manage page. Copy the Client ID, and choose New Secret and copy the secret. A new secret replaces the old one at once.
  7. Paste both into the dialog and press Connect. Sign in to Twitch as the channel's account and allow it.

Scopes

Twitch applications take their scopes in the sign-in request, so there is nothing to tick in Twitch's console. For your reference, this is what GreenMind asks for:

Use Scopes
Stream out channel:read:stream_key
Run broadcasts (title and category) channel:manage:broadcast
Live chat user:read:chat, user:write:chat
Read numbers moderator:read:followers, channel:read:subscriptions, analytics:read:games

The Use your own app dialog asks for the live scopes only. Reconnect asks for all of them, which is how a connection gains the numbers scopes later. A connection that was given only some of the numbers scopes is read for those alone.

Webhooks

Nothing to set up in Twitch's console. GreenMind makes its own EventSub subscriptions for the channel, using your application's client ID and secret, and Twitch confirms them with a signed request that GreenMind answers.

If it goes wrong

  • Twitch asks you to confirm each time you sign in. That is on purpose: GreenMind asks Twitch to confirm which account is signing in.
  • Invalid client or redirect mismatch. The client ID or secret is mistyped, the secret was replaced since you copied it, or the OAuth redirect URL on the application differs from the dialog's.
  • Needs reconnecting. Twitch no longer accepts the token. Twitch also asks an application to validate tokens regularly, which GreenMind does for you. Reconnect.