1. Go to this page and download the library: Download dmitry-ivanov/dark-sky-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/ */
dmitry-ivanov / dark-sky-api example snippets
use DmitryIvanov\DarkSkyApi\DarkSkyApi;
$forecast = (new DarkSkyApi('secret-key'))
->location(46.482, 30.723)
->forecast('daily');
echo $forecast->daily()->summary();
$timeMachine = (new DarkSkyApi('secret-key'))
->location(46.482, 30.723)
->timeMachine('2020-01-01', 'daily');
echo $timeMachine->daily()->summary();