1. Go to this page and download the library: Download vantiv/cnp-chargeback-sdk 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/ */
vantiv / cnp-chargeback-sdk example snippets
// Retrieve information about a chargeback
$chargebackRetrieval = new cnp\sdk\ChargebackRetrieval();
$response = $chargebackRetrieval->getChargebacksByDate("2018-01-01");
// You may also use a tree-oriented style to get the response values:
$chargebackRetrieval = new cnp\sdk\ChargebackRetrieval($treeResponse = true);
$response = $chargebackRetrieval->getChargebackByCaseId("12345000");
// Update chargeback case
$chargebackUpdate = new cnp\sdk\ChargebackUpdate();
$chargebackUpdate->representCase("12345000", "Note on activity", $representment_amount = 1000);
// Manage supporting documents for chargeback case
$chargebackDocument = new cnp\sdk\ChargebackDocument();
$chargebackDocument->uploadDocument("12345000", "invoice.pdf");
// Retrieve information about a chargeback
$chargebackRetrieval = new cnp\sdk\ChargebackRetrieval();
$response = $chargebackRetrieval->getChargebacksByDate("2018-01-01");
// You may also use a tree-oriented style to get the response values:
$chargebackRetrieval = new cnp\sdk\ChargebackRetrieval($treeResponse = true);
$response = $chargebackRetrieval->getChargebackByCaseId("12345000");
// Update chargeback case
$chargebackUpdate = new cnp\sdk\ChargebackUpdate();
$chargebackUpdate->representCase("12345000", "Note on activity", $representment_amount = 1000);
// Manage supporting documents for chargeback case
$chargebackDocument = new cnp\sdk\ChargebackDocument();
$chargebackDocument->uploadDocument("12345000", "invoice.pdf");
bash
PHP Fatal error:
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.