Hi guys,
anyone have a clue how to get the access-token from the TwitchAPI v5?
This is the link: https://dev.twitch.tv/docs/v5/guides/authentication/
I have all things together to sent my stuff to Twitch, but HOW? :D
NETWEBGET is not working for me...
I don't know,is it possible with Sockets?
For the case i/we can send it to twitchAPI, we need the returned URL with the access-token in it. :puke:
Connection to the TwitchIRC was easy, but this...
I would suggest reading up on OAuth 2 authentication. It's counterintuitive at first. There are many libraries in PHP that take care of this low-level problem. Of course, GLBasic, you would have to write your own.
On the other hand, it seems they explain right on the page you sent:
GET https://api.twitch.tv/kraken/oauth2/authorize
?client_id=<your client ID>
&redirect_uri=<your registered redirect URI>
&response_type=code
&scope=<space-separated list of scopes>
The question is how to get the information with the GLBasic network commands... Is that possible?
property also require https. im not sure its works with https. Howover a php based might also works and communicate to that and let glbasic such a script.
On iOS im would property use xcode directly.
One option is CURL, maybe i write a DLL-Wrapper for this one.
Any other opinions?
I would set up a PHP relay. So I could use NETWEBGET on the PHP site, and it would use a PHP library which is made for the Twitch API, like this:
NETWEBGET("www.example.com", "/page.php?get_certificate=1", 80, "twitch_response.txt")
This is a universal PHP interface designed specifically to connect to and interact with the twitch.tv Kraken API servers. It was designed with the intention of being very controlled, safe and light for both the user server and the Kraken API servers. Almost, if not all capable calls are coded directly into the interface, allowing the interface to perform almost, if not all functions that the API allows. Any functions that you believe need to be added or improved can be done via a pull request or opening up an issue.
Currently this interface supports all V5 API calls.
https://github.com/IBurn36360/Twitch_Interface (https://github.com/IBurn36360/Twitch_Interface)
The relay would cause an extra network latency, but it would save you from having to reinvent the wheel I think.