Download the PHP package vptrading/telebirr-ussd-laravel without Composer
On this page you can find all versions of the php package vptrading/telebirr-ussd-laravel. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download vptrading/telebirr-ussd-laravel
More information about vptrading/telebirr-ussd-laravel
Files in vptrading/telebirr-ussd-laravel
Package telebirr-ussd-laravel
Short Description Laravel package for quick telebirr ussd payment gateway integration
License MIT
Homepage https://github.com/VP-Trading/telebirr-ussd
Informations about the package telebirr-ussd-laravel
Laravel Package For
Telebirr USSD
Introduction
This Laravel package is a featherweight package to integrate Telebirr USSD®.
Usage Guide
Step One
Run composer require vptrading/telebirr-ussd-laravel
Step Two
Run the artisan command to publish the Vptrading\TelebirrUssd configuration file.
After running that command you will see a telebirr.php
configuration file in your application's config
directory.
Step Three
Open the telebirr.php
configuration file and add the key's provided to you from Telebirr®
Usage
Push
In order to send a buy request using Telebirr® all you have to do is import the TelebirrUssd
Facade where you want to use it and call the push
method. The TelebirrUssd::push()
method accepts three parameters, these are: Price, Phone, and Reference Number.
Example
Note: The
ShortCode
is provided by Ethio Telecom
When calling that method it return a response
Response Example
Note: The
OriginatorConversationID
is the reference number you used to as theRefNo
This will send a push ussd to the phone number you used. Once the user fills their password and confirmed the payment Telebirr will send a notification.
Deconstruct
The next is being notified when a payment is successfull. After the user has paid the amount described, Telebirr® will send you a notification on the Result URL you specified in the telebirr.php
config file.
Example Notification String From Telebirr®
In order to decode this, the package provides a deconstruct
method. All you need to do is put the notification string sent from Telebirr® in to that static method and it will be decoded.
Example
Result
The result is a json with the unique OriginatorConversationID
for you to query your database with.
🚀 And that's it. Do your thing and Give us a star if this helped you.🚀