PHPackages                             xzag/yii3-jwt - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. xzag/yii3-jwt

ActiveYii3-extension[Authentication &amp; Authorization](/categories/authentication)

xzag/yii3-jwt
=============

Trait for easier JWT integration

3.0.0(7y ago)08MITPHPPHP ^7.2

Since Nov 9Pushed 7y ago1 watchersCompare

[ Source](https://github.com/xzag/yii3-jwt)[ Packagist](https://packagist.org/packages/xzag/yii3-jwt)[ Docs](https://github.com/xzag/yii3-jwt)[ RSS](/packages/xzag-yii3-jwt/feed)WikiDiscussions master Synced 4d ago

READMEChangelog (1)Dependencies (12)Versions (7)Used By (0)

yii3-jwt
========

[](#yii3-jwt)

JWT implementation for Yii3

For details see [JWT official website](https://jwt.io/introduction/).

Installation
------------

[](#installation)

To install run:

```
    composer require "xzag/yii3-jwt: ~3.0"

```

Or add this line to *require* section of composer.json:

```
    "xzag/yii3-jwt": "~3.0"

```

Usage
-----

[](#usage)

There is only one trait - *UserTrait* - which gives you 5 methods for authorization and JWT-management in User model

Set up:

In controller:

```
