nexpcb / laravel-octopart
Laravel octopart package uses phpoctopart.
dev-master
2019-03-28 08:41 UTC
Requires
- nexpcb/phpoctopart: dev-master
This package is auto-updated.
Last update: 2024-11-29 05:38:40 UTC
README
A laravel octopart package.
Installation
composer require "nexpcb/laravel-octopart"
php artisan vendor:publish --provider='NexPCB\LaravelOctopart\LaravelOctopartServiceProvider'
- Configure OCTOPART_API_KEY=xxxxx on .env file.
- Adds Facades to
config/app.php
file:'Octopart' => NexPCB\LaravelOctopart\Facades\Octopart::class,
Examples
Using Facades making the reference to the methods easier like below:
- \Octopart::getBrandsByUID('2239e3330e2df5fe')
- \Octopart::getMultipleBrands(['uid' => ['2239e3330e2df5fe', '56b297b87fa88175'])
- \Octopart::searchBrands(['q' => 'texas'])