PHP code example of ravisorg / bincodesphp

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

    

ravisorg / bincodesphp example snippets


use \ravisorg\BINCodesPHP\BinChecker;
use \ravisorg\BINCodesPHP\DirectoryCache;

$checker = new BINChecker(YOUR_API_KEY);
$checker->enableCache(new DirectoryCache(YOUR_CACHE_DIR,SECONDS_TO_CACHE_FOR));

$response = $checker->lookup(BIN_TO_CHECK);

var_dump($response);