Download the PHP package hubertprein/craft-jwtmanager without Composer
On this page you can find all versions of the php package hubertprein/craft-jwtmanager. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download hubertprein/craft-jwtmanager
More information about hubertprein/craft-jwtmanager
Files in hubertprein/craft-jwtmanager
Package craft-jwtmanager
Short Description Manage JWTs for users which can be used to login.
License
Informations about the package craft-jwtmanager
Craft-JwtManager
Manage JWTs for users which can be used to login.
Requirements
This plugin requires Craft CMS 3.0.0-RC1 or later.
Installation
To install the plugin, follow these instructions.
-
Open your terminal and go to your Craft project:
cd /path/to/project
-
Then tell Composer to load the plugin:
composer require hubertprein/craft-jwtmanager
- In the Control Panel, go to Settings → Plugins and click the “Install” button for JWT Manager.
Functionality
Use JWT manager to enable auto login features for your websites and mobile apps using JWTs.
You can also use it as a sort of framework to manually call the JWT and auto login features.
When do you use it? Your mobile apps requests data which needs the user to login with every request that they do. While you should never send the username and password everytime, one should use a JWT. Bonus to it is that logging in using a JWT, is much faster.
Available actions
-
Login returns JSON with a
token
,refreshToken
anduser
(filled with user information of the logged in user). You can send credentials here filled withusername
andpassword
. You can send a JWT with aAuthorization Bearer
header.https://www.yourdomainhere.nl/actions/jwt-manager/auth/login
https://www.yourdomainhere.nl/actions/jwt-manager/auth/logout
- Send a refresh token in a
Authorization Bearer
header. Which will return a new JWT based on the refresh token.https://www.yourdomainhere.nl/actions/jwt-manager/jwts/use-refresh
All versions of craft-jwtmanager with dependencies
firebase/php-jwt Version ^4.0.0
mobiledetect/mobiledetectlib Version ^2.8