Log in with twitch on my website

I’m a new html/php developer and i would like to use twitch’s log in system on my webpage but i cant seem to find any useful information on the internet.
Does any one know a tutorial or example about it?

Hey, you should probably get yourself familiar with OAuth2.

Take those concepts and apply them to Authentication | Twitch Developers

Best of luck to you!

Is there any example code for me to read or something like that? all i want to do is get the user’s chanel name and email and save it to a mysql database

Includes examples. Note that Twitch doesn’t provide email addresses via the API, so I assume you are going to ask for that separately?

1 Like

You could also check out this thread:

That might have what you want if you are looking for PHP rather than JS.

1 Like

There are also code samples, including PHP, that we provide on the Get Started page: https://dev.twitch.tv/get-started

Look under Authentication.

1 Like

Doesn’t twitch give email address from the user_read scope?

It does, unless the user has not verified their email.

1 Like

My bad, I forgot about that part of the API.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.