Returns a collection of CreditCardVerification response objects.

For operators available on search fields, see the search fields page.

PHP
Copy
Copied
$collection = $gateway->creditCardVerification->search([
    Braintree_CreditCardVerificationSearch::id()->is('the_verification_id'),
]);

foreach($collection as $verification) {
    echo $verification->status;
}
This code snippet now uses gateway instance methods instead of class-level methods. Learn more.
Parameters
'billingAddressDetailsPostalCode' text

The postal code on the billing address used for the credit card verification.

'createdAt' range

The date/time at which the credit card verification was created.

'creditCardCardType' multiple

The type of credit card verified. Possible values:

  • "American Express"
  • "Discover"
  • "Maestro"
  • "JCB"
  • "MasterCard"
  • "UnionPay"
  • "Visa"
'creditCardCardholderName' text

The cardholder name in the credit card verification.

'creditCardExpirationDate' text

The expiration date of the credit card verified.

'creditCardNumber' text

The number of the credit card verified.

Card number search is restricted: starts with searches up to the first 6 digits, ends with searches last 4 digits, and contains is not allowed.

'customerEmail' text

The customer's email address associated with the credit card verification.

'customerId' text

A string value representing an existing customer in your Vault that is associated with the credit card verification.

'id' text

The ID of the verification.

'ids' multiple

The list of verification IDs to search for.

'paymentMethodToken' text

The payment method token for the credit card verification.

Examples

Customer Details

PHP
Copy
Copied
$collection = $gateway->creditCardVerification()->search([
  Braintree_CreditCardVerificationSearch::customerEmail()->is("smith@example.com"),
  Braintree_CreditCardVerificationSearch::customerId()->is("cust1234"),
]);
This code snippet now uses gateway instance methods instead of class-level methods. Learn more.

See search fields for a list of available operators. They allow you to do nice things like this:

PHP
Copy
Copied
$collection = $gateway->creditCardVerification()->search([
  Braintree_CreditCardVerificationSearch::customerEmail()->endsWith('example.com'),
]);
This code snippet now uses gateway instance methods instead of class-level methods. Learn more.

Credit Card Details

PHP
Copy
Copied
$collection = $gateway->creditCardVerification()->search([
  Braintree_CreditCardVerificationSearch::creditCardCardholderName()->is("Tom Smith"),
  Braintree_CreditCardVerificationSearch::creditCardExpirationDate()->is("05/2012"),
  Braintree_CreditCardVerificationSearch::creditCardNumber()->startsWith("4111"),
  Braintree_CreditCardVerificationSearch::creditCardNumber()->endsWith("1111"),
  Braintree_CreditCardVerificationSearch::creditCardCardType()->is(Braintree_CreditCard::VISA),
  Braintree_CreditCardVerificationSearch::creditCardExpirationDate()->is("02/16"),
]);
This code snippet now uses gateway instance methods instead of class-level methods. Learn more.

Payment Methods

You can search for credit card verifications associated to a payment method token.

PHP
Copy
Copied
$collection = $gateway->creditCardVerification()->search([
  Braintree_CreditCardVerificationSearch::paymentMethodToken()->is('the_token'),
]);
This code snippet now uses gateway instance methods instead of class-level methods. Learn more.

Billing Address

PHP
Copy
Copied
$collection = $gateway->creditCardVerification()->search([
  Braintree_CreditCardVerificationSearch::billingAddressDetailsPostalCode()->is("12345"),
]);
This code snippet now uses gateway instance methods instead of class-level methods. Learn more.

Created At

PHP
Copy
Copied
$collection = $gateway->creditCardVerification()->search([
  Braintree_CreditCardVerificationSearch::createdAt()->between("12/15/07 17:00", "12/17/07 17:00"),
]);
This code snippet now uses gateway instance methods instead of class-level methods. Learn more.
note

Time zones specified in the time value will be respected in the search; if you do not specify a time zone, the search will default to the time zone associated with your gateway account. Results will always be returned with time values in UTC.

See also

Still have questions?

If you can’t find an answer, contact our Support team