1. Go to this page and download the library: Download cliffom/tokenex 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/ */
cliffom / tokenex example snippets
use Cliffom\Tokenex\Tokenizer;
$tokenizer = new Tokenizer($TOKENEX_API_BASE_URL, $TOKENEX_ID, $TOKENEX_API_KEY);
// From a credit card number
$token = $tokenizer->token_from_ccnum(4242424242424242);
// From arbitrary data
$token = $tokenizer->tokenize("This is random data containing 3 numbers less than 10");
$tokenizer->validate_token($token); // true or false
$tokenizer->delete_token($token); // true or false
var_dump($tokenizer->error); // array, empty if no errors
var_dump($tokenizer->reference_number); // string
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.