PHP code example of cardflow / cardflow-php

1. Go to this page and download the library: Download cardflow/cardflow-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/ */

    

cardflow / cardflow-php example snippets


$cardflow = new \Cardflow\Client\CardflowClient('eyJ0eXAi....');
$giftCard = $cardflow->giftCards->get('ABCDABCDABCDABCD');

$giftCard = $cardflow->giftCards->get('ABCDABCDABCDABCD');

$transaction = $cardflow->giftCards->redeem(
  'ABCDABCDABCDABCD',
  [
    "amount" => 1250,
    "currency" => "EUR",
    "capture" => false
  ]
);