1. Go to this page and download the library: Download capeandbay/birdeye 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/ */
return [
// Other configs left out for brevity
'accounts' => [
'client-a' => env('BIRD_EYE_CLIENT_A_KEY', 'something'),
'client-b' => 'some-token'
],
];
namespace App;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use CapeAndBay\BirdEye\Traits\HasBirdEyeBusiness;
class StoreLocation extends Model
{
use HasBirdEyeBusiness, SoftDeletes;
public $birdeye_id_column = 'some_column';
/** Rest of the Logic assumed */
}
use App\LocationModel;
$location = LocationModel::find(1);
$birdeye_biz = $location->birdeye_business()->first();