You could use the user ID as the static identifier to the user. https://dev.twitch.tv/docs/v5/guides/using-the-twitch-api/ shows the response to the https://api.twitch.tv/kraken/user endpoint with a user name and user id in v5. In v3 it only had the user name last I checked. You could then tie their user id in your database with a secure cookie on their browser representing they logged in with twitch.
1 Like