PHP code example of blood72 / laravel-riot-api

1. Go to this page and download the library: Download blood72/laravel-riot-api 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/ */

    

blood72 / laravel-riot-api example snippets


// in riot-api.php
'key' => env('RIOT_API_KEY'),
'region' => env('RIOT_API_REGION', 'na'),

'cache' => env('RIOT_API_CACHE', true),

'league' => [
    // ...
    'settings' => [
        //
    ],
],

'ddragon' => [
    // ...
    'settings' => [
        //
    ],
],

$summoner = app('league-api')->getSummonerByName('__SOMEONE__');
$matchList = LeagueAPI::getMatchlistByAccount($summoner->accountId);

$icon = resolve('ddragon-api')->getChampionIcon('Diana');
$splash = DataDragonAPI::getChampionSplashUrl('Diana', 11);
bash
php artisan vendor:publish --provider="Blood72\RiotAPI\RiotAPIServiceProvider"