is the code trying to call window.Twitch in clientSide browser code
Or is it somewhere in the server side code and it’s not contextuall in the browser
You say you are trying to access the config service, if you are doing this “in a server” then you need to call the API not the JS helper. So I’m wondering if this code is contextually in the wrong place