The twitchingpython api throws an exception and i found out that it’s doing that because my token is invalid (but it is not, i double checked with direct url in my browser).
If you are getting a 401 error, it is most likely that your token is invalid, or that you aren’t sending the token properly for some reason. Assuming your wrapper is used by other people and not buggy, it’s reasonable that your token is not valid, or does not possess the scopes required to update channel information.
You can check if an oauth token is valid and what scopes it has by GETting https://api.twitch.tv/kraken/?oauth_token=TOKEN. Updating channel status and game requires the channel_editor scope.
Make sure the uri is exactly the same. Ex: http://discuss.dev.twitch.tv/discuss.dev.twitch.tv
Every character must be the same, even if they point to the same ip.