PHP code example of twyple / twyple-sdk-php
1. Go to this page and download the library: Download twyple/twyple-sdk-php library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
twyple / twyple-sdk-php example snippets
composer
http://your/server/route.php
yple\Cashfree\Payments;
$inputJSON = json_decode(file_get_contents('php://input'), true); //$inputJSON = $_POST;
//cashfree credentials. You can get it from merchant dashboard
$appId = "cashfreeAppID";
$secretKey = "cashfreeAppSecret";
$cashfree = new Payments($appId, $secretKey);
$handlerRes = $cashfree->Handler($inputJSON);
echo json_encode($handlerRes);