Skip to content

Commit

Permalink
feat: support for php 7.4 and higher
Browse files Browse the repository at this point in the history
  • Loading branch information
bajoski34 committed Sep 16, 2022
1 parent 527732a commit 3150a04
Show file tree
Hide file tree
Showing 336 changed files with 6,413 additions and 32,487 deletions.
File renamed without changes.
10 changes: 8 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -187,5 +187,11 @@ tmtags
# Local History for Visual Studio Code
.history/

vendor

vendor/
composer.lock

*.log
examples/*.log
examples/endpoint/*.log
example.php
.phpunit.result.cache
38 changes: 19 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ if($postData['amount']){
The following implementation shows how to initiate a direct bank charge. Use the Playground DIrectory to view Responses and samples of use.

```php
require("Flutterwave-Rave-PHP-SDK/library/AccountPayment.php");
require("Flutterwave-Rave-PHP-SDK/src/AccountPayment.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\AccountPayment;

//The data variable holds the payload
Expand Down Expand Up @@ -340,7 +340,7 @@ print_r($result);
The following implementation shows how to accept payments directly from customers in the US and South Africa. Use the Playground DIrectory to view Responses and samples of use.

```php
require("Flutterwave-Rave-PHP-SDK/library/AchPayment.php");
require("Flutterwave-Rave-PHP-SDK/src/AchPayment.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\AchPayment;

// The data variable holds the payload
Expand Down Expand Up @@ -374,7 +374,7 @@ print_r($result);
The following implementation shows how to initiate a card charge. Use the Playground Directory to view an implementation Responses and samples of use.

```php
require("Flutterwave-Rave-PHP-SDK/library/CardPayment.php");
require("Flutterwave-Rave-PHP-SDK/src/CardPayment.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\CardPayment;

//The data variable holds the payload
Expand Down Expand Up @@ -433,7 +433,7 @@ if($result['data']['auth_mode'] == 'otp'){
The following implementation shows how to initiate a mobile money payment. Use the Playground Directory to view Responses and samples of use.

```php
require("Flutterwave-Rave-PHP-SDK/library/MobileMoney.php");
require("Flutterwave-Rave-PHP-SDK/src/MobileMoney.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\MobileMoney;

// The data variable holds the payload
Expand Down Expand Up @@ -465,7 +465,7 @@ $print_r($result);
Collect payments via ussd

```php
require("Flutterwave-Rave-PHP-SDK/library/Ussd.php");
require("Flutterwave-Rave-PHP-SDK/src/Ussd.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Ussd;
//The data variable holds the payload
$data = array(
Expand Down Expand Up @@ -501,7 +501,7 @@ if(isset($result['data'])){
Collect payments from your customers via Mpesa.

```php
require("Flutterwave-Rave-PHP-SDK/library/Mpesa.php");
require("Flutterwave-Rave-PHP-SDK/src/Mpesa.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Mpesa;

$data = array(
Expand Down Expand Up @@ -534,7 +534,7 @@ How to make a transfer payment

```php

require("Flutterwave-Rave-PHP-SDK/library/Transfer.php");
require("Flutterwave-Rave-PHP-SDK/src/Transfer.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Transfer;

// sample payload for payBill()
Expand Down Expand Up @@ -605,7 +605,7 @@ if(isset($result['data'])){
The following implementation shows how to create virtual cards on rave. Use the Playground Directory to view Responses and samples of use.

```php
require("Flutterwave-Rave-PHP-SDK/library/VirtualCards.php");
require("Flutterwave-Rave-PHP-SDK/src/VirtualCards.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\VirtualCard;

$data = array(
Expand Down Expand Up @@ -644,7 +644,7 @@ $data = array(
The following implementation shows how to verify a Bank Verification Number.

```php
require("Flutterwave-Rave-PHP-SDK/library/Bvn.php");
require("Flutterwave-Rave-PHP-SDK/src/Bvn.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Bvn;
//The data variable holds the payload
$bvn_number = "123456789";
Expand All @@ -660,7 +660,7 @@ print_r($result);
The following implementation shows how to create a payment plan on the rave dashboard. Use the Playground Directory to view Responses and samples of use.

```php
require("Flutterwave-Rave-PHP-SDK/library/PaymentPlan.php");
require("Flutterwave-Rave-PHP-SDK/src/PaymentPlan.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\PaymentPlan;

//sample payload for payBill()
Expand Down Expand Up @@ -689,7 +689,7 @@ The following implementation shows how to create a subaccount on the rave dashbo
Use the Playground Directory to view Responses and samples of use.

```php
require("Flutterwave-Rave-PHP-SDK/library/Subaccount.php");
require("Flutterwave-Rave-PHP-SDK/src/Subaccount.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Subaccount;

$data = array(
Expand Down Expand Up @@ -730,7 +730,7 @@ print_r($createSubaccount);
The following implementation shows how to create a transfer recipient on the rave dashboard. Use the Playground Directory to view Responses and samples of use.

```php
require("Flutterwave-Rave-PHP-SDK/library/Recipient.php");
require("Flutterwave-Rave-PHP-SDK/src/Recipient.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Recipient;

$data = array(
Expand Down Expand Up @@ -759,7 +759,7 @@ print_r($recipient1);
The following implementation shows how to activate a subscription, fetch a subscription, get all subscriptions.

```php
require("Flutterwave-Rave-PHP-SDK/library/Subscription.php");
require("Flutterwave-Rave-PHP-SDK/src/Subscription.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Subscription;

$id = 1112 //Id of subscription plan
Expand All @@ -780,7 +780,7 @@ The following implementation shows how to pay for any kind of bill from Airtime
visit: https://developer.flutterwave.com/v3.0/reference#buy-airtime-bill

```php
require("Flutterwave-Rave-PHP-SDK/library/Bill.php");
require("Flutterwave-Rave-PHP-SDK/src/Bill.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Bill;

$data = array(
Expand Down Expand Up @@ -836,7 +836,7 @@ print_r($result);
The following implementation shows how to create a electronic receipt.

```php
require("Flutterwave-Rave-PHP-SDK/library/Ebill.php");
require("Flutterwave-Rave-PHP-SDK/src/Ebill.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Ebill;

$data = array(
Expand Down Expand Up @@ -870,7 +870,7 @@ The following implementation shows how to create a virtual Account. Please view
https://developer.flutterwave.com/reference#create-a-virtual-account-number

```php
require("Flutterwave-Rave-PHP-SDK/library/VirtualAccount.php");
require("Flutterwave-Rave-PHP-SDK/src/VirtualAccount.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\VirtualAccount;

//sample payload for payBill()
Expand Down Expand Up @@ -910,7 +910,7 @@ print_r($result);
Once the charge and validation process is complete for the first charge on the card, you can make use of the token for subsequent charges.

```php
require("Flutterwave-Rave-PHP-SDK/library/TokenizedCharge.php");
require("Flutterwave-Rave-PHP-SDK/src/TokenizedCharge.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\TokenizedCharge;

$data = array(
Expand All @@ -937,7 +937,7 @@ print_r($result);
List all transactions on your account. You could do a specific query using ```customer_email``` or ```customer_fullname``` to make specifc search. View all successfull or failed transactions for a particular period, month or year

```php
require("Flutterwave-Rave-PHP-SDK/library/Transactions.php");
require("Flutterwave-Rave-PHP-SDK/src/Transactions.php");
use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\Transactions;

$data = array(
Expand All @@ -964,7 +964,7 @@ print_r($transactions);
Collect ZAR payments offline using Vouchers

```php
require("Flutterwave-Rave-PHP-SDK/library/VoucherPayment.php");
require("Flutterwave-Rave-PHP-SDK/src/VoucherPayment.php");

use Flutterwave\EventHandlers\EventHandlers\EventHandlers\EventHandlers\EventHandlers\VoucherPayment;
//The data variable holds the payload
Expand Down
File renamed without changes
1 change: 1 addition & 0 deletions assets/js/v3.js

Large diffs are not rendered by default.

14 changes: 9 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,19 +1,23 @@
{
"name": "flutterwavedev/flutterwave-v3",
"description": "A simple SDK for integrating to Flutterwave's Rave payment",
"description": "A simple SDK for integrating to Flutterwave Payment",
"type": "library",
"keywords": ["rave", "flutterwave", "payment", "transfers", "africa"],
"keywords": ["flutterwave", "payment", "transfers", "africa"],
"homepage": "https://github.com/Flutterwave/Flutterwave-PHP-v3",
"autoload": {
"psr-4": {
"Flutterwave\\": "library/"
"Flutterwave\\": "src/"
}
},
"autoload-dev": {
"Flutterwave\\Test\\": "tests/"
},
"require": {
"php": ">=5.4.0",
"php": "^7.4 || ^8.0 || ^8.1",
"monolog/monolog": ">=2.0",
"mashape/unirest-php": ">=3.0",
"vlucas/phpdotenv": ">=2.5"
"vlucas/phpdotenv": ">=2.5",
"ext-json": "*"
},
"require-dev": {
"phpunit/phpunit": ">=6.0",
Expand Down
Loading

0 comments on commit 3150a04

Please sign in to comment.