rikudosama/cinetpay is a Laravel package for a laravel package for integrating cinetpay.
It currently has 0 GitHub stars and 5 downloads on Packagist.
Install it with composer require rikudosama/cinetpay.
Discover more Laravel packages by rikudosama
or browse all Laravel packages to compare alternatives.
Last updated
A Laravel package for integrating CinetPay
You can install the package via composer:
composer require Rikudosama/Cinetpay
You can publish and run the migrations with:
php artisan vendor:publish --provider="Rikudosama\Cinetpay\CinetpayServiceProvider" --tag="config"
php artisan migrate
You can publish the config file with:
php artisan vendor:publish --tag="config"
This is the contents of the published config file:
return [
'api_key' => env('CINETPAY_API_KEY'),
'site_id' => env('CINETPAY_SITE_ID'),
'base_url' => env('CINETPAY_BASE_URL', 'https://api.cinetpay.com/v1/'),
];
Optionally, you can publish the views using
php artisan vendor:publish --tag=":cinetpay-views"
use Rikudosama\Cinetpay\Cinetpay;
class PaymentController extends Controller
{
protected $cinetpay;
public function __construct(Cinetpay $cinetpay)
{
$this->cinetpay = $cinetpay;
}
public function processPayment(Request $request)
{
$data = [
// Les données requises pour le paiement
];
$response = $this->cinetpay->makePayment($data);
// Traitez la réponse comme nécessaire
}
}
return view('cinetpay::cinetpay');
composer test
Please see CHANGELOG for more information on what has changed recently.
Please see CONTRIBUTING for details.
Please review our security policy on how to report security vulnerabilities.
The MIT License (MIT). Please see License File for more information.