No idea. thats up to you to debug whats wrong with your environment, routing or something else.
The first calls are to id.twitch.tv the second to api.twitch.tv clutching at straws: did you hostfile api.twitch.tv somewhere else and it’s 404’ing since it’s not actually going to Twitch?
The problem needs to be traceed with/from your machine, as the code works fine on my machine