oussamamadjmaa/sofizpay-laravel

A Laravel wrapper for the SofizPay API — CIB card payments and prepaid service operations (phone, internet, game recharge, bill payments) for Algeria, with typed DTOs, response objects, and built-in sandbox mocking.

Maintainers

Package info

github.com/oussamamadjmaa/sofizpay-laravel

pkg:composer/oussamamadjmaa/sofizpay-laravel

Transparency log

Statistics

Installs: 5

Dependents: 0

Suggesters: 0

Stars: 1

Open Issues: 0

v1.0.0 2026-07-16 18:09 UTC

This package is auto-updated.

Last update: 2026-07-16 18:44:21 UTC


README

Latest Version on Packagist License

A Laravel package for SofizPay CIB transactions and service operations. It provides DTOs for phone, internet, game, and bill operations, plus typed response objects.

Requirements

  • PHP 8.1 or later
  • Laravel 10, 11, 12, or 13

Installation

composer require oussamamadjmaa/sofizpay-laravel

The package is discovered automatically. Publish its configuration when you need to set values in a config file:

php artisan vendor:publish --provider="OussamaMadjmaa\SofizPay\SofizPayServiceProvider" --tag=config

Set the required environment variables:

SOFIZPAY_ACCOUNT_ID=
SOFIZPAY_ENCRYPTED_SK=
SOFIZPAY_SANDBOX=true

Quick start

use OussamaMadjmaa\SofizPay\DTOs\MakeCIBTransactionDTO;
use OussamaMadjmaa\SofizPay\SofizPay;

$payment = app(SofizPay::class)->cibTransaction()->make(
    new MakeCIBTransactionDTO(
        amount: 2500,
        fullName: 'Oussama Madjmaa',
        phone: '0555123456',
        email: 'oussama@example.com',
        returnUrl: 'https://example.com/payments/return',
    ),
);

return redirect()->away($payment->paymentUrl);

You may also use the OussamaMadjmaa\SofizPay\Facades\SofizPay facade.

Documentation

Security

Please report vulnerabilities according to our security policy.

Contributing

Contributions are welcome. Read CONTRIBUTING.md and CODE_OF_CONDUCT.md first.

License

SofizPay for Laravel is open-sourced software licensed under the MIT license.