Twitch POST request for OAuth2 token (Node & Express)

So you fixed you problem or you are still having a problem?

Note in the callback you passed in req

and then here

You are “trashing” the req variable. So you can’t terminate the express req.

You also might want to look at using the helper library request or if thats too “heavy” use got to save some hassle with http(s) requests.

Or since you are in node anyway tmi.js

1 Like