PHP code example of vinbolt / laravel

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

    

vinbolt / laravel example snippets


use Vinbolt\Laravel\Facades\Vinbolt;

$home    = Vinbolt::pages->get('home');
$header  = Vinbolt::site->header();
$brand   = Vinbolt::brand->get();
$cars    = Vinbolt::vehicles->list(['make' => 'Honda']);

Vinbolt::leads->create([
    'email'       => '[email protected]',
    'name'        => 'Jane Doe',
    'vehicle_vin' => '1HGCM82633A123456',
]);

use Vinbolt\Sdk\VinboltClient;

class HomeController
{
    public function __construct(private VinboltClient $vinbolt) {}

    public function show()
    {
        return view('home', [
            'page'   => $this->vinbolt->pages->get('home'),
            'header' => $this->vinbolt->site->header(),
        ]);
    }
}
bash
php artisan vendor:publish --tag=vinbolt-config