Skip to content

Instantly share code, notes, and snippets.

@developersteve
Created October 25, 2014 02:58
Show Gist options
  • Save developersteve/01c09ec8a875acadf1e5 to your computer and use it in GitHub Desktop.
Save developersteve/01c09ec8a875acadf1e5 to your computer and use it in GitHub Desktop.
<?
require 'braintree.php';
Braintree_Configuration::environment('sandbox');
Braintree_Configuration::merchantId('');
Braintree_Configuration::publicKey('');
Braintree_Configuration::privateKey('');
$now = new Datetime();
$past = clone $now;
$past = $past->modify("-1 days");
$lookup = Braintree_Transaction::search(array(
Braintree_CustomerSearch::createdAt()->between($past, $now)
));
echo "<pre>";
print_r($lookup);
echo "</pre>";
foreach($lookup->_ids as $ids){
$record = Braintree_Transaction::find($ids);
echo "<pre>";
print_r($record);
echo "</pre>";
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment