Package Data | |
---|---|
Maintainer Username: | pangpondpon |
Maintainer Contact: | pond@netearth.net (Patompong Savaengsuk) |
Package Create Date: | 2016-08-26 |
Package Last Update: | 2023-08-04 |
Language: | PHP |
License: | Unknown |
Last Refreshed: | 2025-02-08 15:05:38 |
Package Statistics | |
---|---|
Total Downloads: | 280 |
Monthly Downloads: | 0 |
Daily Downloads: | 0 |
Total Stars: | 2 |
Total Watchers: | 4 |
Total Forks: | 1 |
Total Open Issues: | 0 |
This library let your laravel application talk with Logicboxes API with ease.
composer require pangpondpon/laravel-lb
to include this library to your projectLaravelLb\LaravelLbServiceProvider::class
into your providers array in config/app.phpphp artisan vendor:publish
to publish the config file<?php
return [
"test_mode" => env('LB_TEST_MODE', true),
"auth_userid" => env('LB_AUTH_USERID', 'YOUR_USER_ID'),
"api_key" => env('LB_API_KEY', 'YOUR_API_KEY'),
];
Use case - Buy an ssl from comodo
<?php
namespace App\Http\Controllers;
use App\Http\Requests;
use Illuminate\Http\Request;
use LaravelLb\LogicBoxesComodo;
class ComodoCertController extends Controller
{
public $comodo;
public function __construct()
{
$this->comodo = new LogicBoxesComodo();
}
// Buy the ssl from comodo, see LogicBoxesComodo class for api call info
public function buy()
{
// Order buy use method add from LogicBoxesComodo class
$response = $this->comodo->add([
"domain-name" => "ssldemosite.com",
"months" => 12,
"customer-id" => "52213365",
"plan-id" => LogicBoxesComodo::POSITIVE_SSL, // Check more options in LogicBoxesComodo
"invoice-option" => LogicBoxesComodo::NO_INVOICE // Check more options in LogicBoxesComodo
])->toArray();
return $response;
}
}
See more example in /example folder.