/home/kueuepay/public_html/vendor/phpunit/phpunit/composer.json
{
    "name": "phpunit/phpunit",
    "description": "The PHP Unit Testing framework.",
    "type": "library",
    "keywords": [
        "phpunit",
        "xunit",
        "testing"
    ],
    "homepage": "https://phpunit.de/",
    "license": "BSD-3-Clause",
    "authors": [
        {
            "name": "Sebastian Bergmann",
            "email": "sebastian@phpunit.de",
            "role": "lead"
        }
    ],
    "support": {
        "issues": "https://github.com/sebastianbergmann/phpunit/issues",
        "security": "https://github.com/sebastianbergmann/phpunit/security/policy"
    },
    "prefer-stable": true,
    "require": {
        "php": ">=7.3",
        "ext-dom": "*",
        "ext-json": "*",
        "ext-libxml": "*",
        "ext-mbstring": "*",
        "ext-xml": "*",
        "ext-xmlwriter": "*",
        "doctrine/instantiator": "^1.3.1 || ^2",
        "myclabs/deep-copy": "^1.10.1",
        "phar-io/manifest": "^2.0.3",
        "phar-io/version": "^3.0.2",
        "phpunit/php-code-coverage": "^9.2.28",
        "phpunit/php-file-iterator": "^3.0.5",
        "phpunit/php-invoker": "^3.1.1",
        "phpunit/php-text-template": "^2.0.3",
        "phpunit/php-timer": "^5.0.2",
        "sebastian/cli-parser": "^1.0.1",
        "sebastian/code-unit": "^1.0.6",
        "sebastian/comparator": "^4.0.8",
        "sebastian/diff": "^4.0.3",
        "sebastian/environment": "^5.1.3",
        "sebastian/exporter": "^4.0.5",
        "sebastian/global-state": "^5.0.1",
        "sebastian/object-enumerator": "^4.0.3",
        "sebastian/resource-operations": "^3.0.3",
        "sebastian/type": "^3.2",
        "sebastian/version": "^3.0.2"
    },
    "config": {
        "platform": {
            "php": "7.3.0"
        },
        "optimize-autoloader": true,
        "sort-packages": true
    },
    "suggest": {
        "ext-soap": "To be able to generate mocks based on WSDL files",
        "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage"
    },
    "bin": [
        "phpunit"
    ],
    "autoload": {
        "classmap": [
            "src/"
        ],
        "files": [
            "src/Framework/Assert/Functions.php"
        ]
    },
    "autoload-dev": {
        "classmap": [
            "tests/"
        ],
        "files": [
            "tests/_files/CoverageNamespacedFunctionTest.php",
            "tests/_files/CoveredFunction.php",
            "tests/_files/NamespaceCoveredFunction.php"
        ]
    },
    "extra": {
        "branch-alias": {
            "dev-master": "9.6-dev"
        }
    }
}
Initiate Payment

Initiate Payment

Initiates a new payment transaction.

Endpoint: POST create-order
Parameter Type Details
amount decimal Your Amount , Must be rounded at 2 precision.
currency string Currency Code, Must be in Upper Case (Alpha-3 code)
success_url string Enter your return or success URL
cancel_url string (optional) Enter your cancel or failed URL
                    
                        Request Example (guzzle)
                        

<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('POST', $base_url.'create-order', [
'headers' => [
  'Authorization' => 'Bearer '. $authorizationToken,
  'accept' => 'application/json',
  'content-type' => 'application/json',
 ],
'form_params' => [
  'amount' => '$amount',
  'currency' => 'currency',
  'success_url' => 'success_url',
  'cancel_url' => 'cancel_url',
 ],
]);
echo $response->getBody();
                    
                        
**Response: SUCCESS (200 OK)**
{
 "message": {
 "success": [
  "Order created successfully."
 ]
},
"data": {
 "redirect_url":"https://example.com/login/OISADFDFSDFSF",
 "order_details":{
 "amount" : "10",
 "fixed_charge" : 2,
 "percent_charge" : 1,
 "total_charge" : 3,
 "total_payable" : 13,
 "currency" : "USD",
 "expiry_time": "2024-04-25T06:48:35.984285Z",
 "success_url": "http://127.0.0.1/nfcpay/user/transaction/success",
 "cancel_url": "http://127.0.0.1/nfcpay/user/transaction/cancel"
}
},
"type": "success"
}
                    
                        
**Response: ERROR (400 FAILED)**
{
 "message": {
 "error": [
  "Invalid token."
 ]
},
"data": null,
"type": "error"
}