PHP code example of develings / api-x
1. Go to this page and download the library: Download develings/api-x 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/ */
develings / api-x example snippets
// add this to config/app.php
'providers' => [
...
\ApiX\ApiXServiceProvider::class,
],
// add the route (e.g. routes/web.php)
$api = new ApiX\ApiX(base_path('api.json'));
$api->setRoutes();
shell script
php artisan api:make