public static function Braintree_CreditCard::fetchExpiring in Commerce Braintree 7
File
- braintree_php/
lib/ Braintree/ CreditCard.php, line 176
Class
- Braintree_CreditCard
- Creates and manages Braintree CreditCards
Code
public static function fetchExpiring($startDate, $endDate, $ids) {
$queryPath = '/payment_methods/all/expiring?start=' . date('mY', $startDate) . '&end=' . date('mY', $endDate);
$response = Braintree_Http::post($queryPath, array(
'search' => array(
'ids' => $ids,
),
));
return Braintree_Util::extractAttributeAsArray($response['paymentMethods'], 'creditCard');
}