1. Go to this page and download the library: Download darvis/snelstart 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/ */
darvis / snelstart example snippets
use Darvis\Snelstart\Services\SnelstartAPI;
class MyController extends Controller
{
public function index(SnelstartAPI $snelstart)
{
$relations = $snelstart->getRelaties();
$articles = $snelstart->getArtikelen();
return view('overview', compact('relations', 'articles'));
}
}
use Darvis\Snelstart\Services\EchoService;
$echo = app(EchoService::class);
// GET test
$result = $echo->getEchoResource(['param1' => 'test']);
// POST test
$result = $echo->postEchoResource(['key' => 'value']);