PHP code example of selfreliance / apitokens

1. Go to this page and download the library: Download selfreliance/apitokens library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

selfreliance / apitokens example snippets


php artisan vendor:publish --provider="Selfreliance\apitokens\ApiTokensServiceProvider" --force

class User extends Authenticatable
{
    public function wallets($order='asc')
    {
       return $this->hasMany('App\Models\Users_Wallets', 'user_id')->orderBy('id', $order);
    }	
}

php artisan migrate