Update README.md

This commit is contained in:
Neodyme
2021-08-27 01:09:58 +02:00
committed by GitHub
parent 3f7b25b8f0
commit 3a0ae949d5

View File

@@ -9,7 +9,7 @@ Node-RED flow to subscribe, receive and respond to Twitch webhook
- This Flow is compatible with the "regular" [Twitch API](https://dev.twitch.tv/docs/api/reference) and the following [flow](https://github.com/n3odym3/Twitch-API_Node-RED)
## Prerequisites
- [Node-RED](https://nodered.org/) running on port 443 with [HTTPS](https://nodered.org/docs/user-guide/runtime/securing-node-red#enabling-https-access) enabled OR a [ngrock auth token](https://dashboard.ngrok.com/get-started/your-authtoken)
- [Node-RED](https://nodered.org/) running on port 443 with [HTTPS](https://nodered.org/docs/user-guide/runtime/securing-node-red#enabling-https-access) enabled OR a [ngrok auth token](https://dashboard.ngrok.com/get-started/your-authtoken)
- Twitch [APP](https://dev.twitch.tv/console/apps/) Client ID
- Twitch [APP](https://dev.twitch.tv/console/apps/) Client Secret
@@ -19,11 +19,11 @@ Node-RED flow to subscribe, receive and respond to Twitch webhook
- node-red-contrib-crypto-js-dynamic
- Optional : node-red-contrib-ngrok
## For ngrock users
- Create a free account on [ngrock](https://ngrok.com/)
## For ngrok users
- Create a free account on [ngrok](https://ngrok.com/)
- Save your AuthToken
- Install the [ngrock](https://flows.nodered.org/node/node-red-contrib-ngrok) node on Node-RED
- Drag and drop a ngrock node on your flow
- Install the [ngrok](https://flows.nodered.org/node/node-red-contrib-ngrok) node on Node-RED
- Drag and drop a ngrok node on your flow
- Setup the node using your AuthToken
- Open a tunnel and save the URL
@@ -31,7 +31,7 @@ Node-RED flow to subscribe, receive and respond to Twitch webhook
## Twitch Setup
- Create an [APP](https://dev.twitch.tv/console/apps/) and save your APP ID and Secret
- Add the following URL using your domain name or ngrock tunnel URL
- Add the following URL using your domain name or ngrok tunnel URL
<img src="https://github.com/n3odym3/Node-RED_Twitch_EventSub/blob/main/pictures/Redirect.png" width="80%">
## Node-RED Setup
@@ -41,10 +41,10 @@ Node-RED flow to subscribe, receive and respond to Twitch webhook
- Twitch client secret
- Sub secret : a password (defined by the user) to validate the Twitch event signature
- Twitch channel
- Sub URI : your Node-RED server name or ngrock tunnel URL **WITHOUT** "HTTPS://" (Ex : your.domain.name or xxxxxxxxxxx.ngrock.io)
- Sub URI : your Node-RED server name or ngrok tunnel URL **WITHOUT** "HTTPS://" (Ex : your.domain.name or xxxxxxxxxxx.ngrok.io)
- [Scopes](https://dev.twitch.tv/docs/authentication#scopes) (space-separated)
<img src="https://github.com/n3odym3/Node-RED_Twitch_EventSub/blob/main/pictures/Settings.png" width="50%">
- Go to the Node-RED dashboard (https://your.domain.name/ui or https://xxxxxxxxxx.ngrock.io/ui)
- Go to the Node-RED dashboard (https://your.domain.name/ui or https://xxxxxxxxxx.ngrok.io/ui)
- Generate an APP token and USER token by clicking on Auhtorize APP and Authorize USER (will requires to loggin with your Twitch account and accept the scopes)
- Optional : you can test the validity and expiration of the Token using "Validate" nodes on the Node-RED editor
- Clic on the "Get channel ID" inject node