PHP code example of earnould / laravel-velo-api
1. Go to this page and download the library: Download earnould/laravel-velo-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/ */
earnould / laravel-velo-api example snippets
VeloStations::all();
Collection {
array [
0 => Earnould\LaravelVeloApi\Station {
[
"id" => "036"
"name" => "036- Bourla"
"address" => "Schuttershofstraat n° 2"
"addressNumber" => null
"zipCode" => "2000"
"districtCode" => null
"districtName" => null
"altitude" => null
"location" => array:2 [
"lat" => "51.2163878210059"
"lon" => "4.40593043087013"
]
"stationType" => "BIKE"
]
}
... => Earnould\LaravelVeloApi\Station {...}
VeloStations::allWithStatuses();
Collection {
[
0 => Earnould\LaravelVeloApi\Station {
[
"id" => "036"
"name" => "036- Bourla"
"address" => "Schuttershofstraat n° 2"
"addressNumber" => null
"zipCode" => "2000"
"districtCode" => null
"districtName" => null
"altitude" => null
"location" => [
"lat" => "51.2163878210059",
"lon" => "4.40593043087013"
]
"stationType" => "BIKE"
"status" => "OPN"
"availability" => [
"bikes" => 19,
"slots" => 1
]
]
... => Earnould\LaravelVeloApi\Station {...}
]
}
bash
php artisan vendor:publish --provider="Earnould\LaravelVeloApi\VeloServiceProvider" --tag="config"