moertel / wp-login-with-twitch

Enables your websites viewers to login using Twitch

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

WordPress Login With Twitch API

What is the purpose of this plugin?

The main purpose of this plugin is just to allow you to login using your Twitch credentials. However I do have a few ideas I would like to implement later on with this plugin that would take advantage of the Twitch API. As this is developed in my spare time progress may not be too quick.

How does this plugin work?

  1. User clicks "Login with Twitch" on the admin login screen.
  2. User is redirected to the Twitch website to allow your site to access their profile.
  3. If the user accepted then they are re-directed back to your site with a code generated by Twitch.
  4. Your site will then check if that user exists in the wp_users table.
    • If so then the site logs them in.
    • If they don't exist:
      1. Create a new WordPress account with the information retrieved from Twitch (Username, Email Address, Twitch ID etc)
      2. Apply the Twitch data as meta fields (Used as part of the query to find out if a user is already registered)
      3. Log the new user in
  5. Done

Setup Guide

  1. After installing this plugin head to API Settings on the left sidebar.
  2. In the "Twitch Name" field add your twitch name.
  3. Now head over to Twitch and register your own Twitch App .
  4. Under OAuth Redirect URL insert the url from your dashboard in the API Settings.
  5. Once registered you should receive a Client ID and a Client Secret. (Client ID is a public ID and everyone will see it. Do not allow anyone to see your secret though.)
  6. Insert the Client ID & Secret into your WordPress dashboard in the API settings section.
  7. Now you can log out and test everything works. By using the "Login With Twitch" button on your admin login page.

Disclaimer

This plugin does not guarantee security, I have tested it and taken precautions to secure date however accidents do happen and things do get overlooked. This plugin downloaded from my repo does not store any information that would allow you access to any-ones Twitch account. However as it is open source I can't be held responsible for any modified versions of this plugin.

This plugin is also not created by Twitch and is unofficial. Twitch don't take any responsibility for this plugin.

About

Enables your websites viewers to login using Twitch

License:MIT License


Languages

Language:PHP 98.3%Language:CSS 1.7%