Getting a token: 400 Bad Request

I didn’t using this script https://github.com/BarryCarlyon/twitch_misc/blob/master/authentication/app_access_tokens/php/generate_token_as_qs.php

Which I wrote this morning to test this thread

Also corrected my original reply due to bad copy paste of my script. I need to go find some coffee