This resource helps you to retrieve, update, and delete card details for a customer.
{
"card_type": "american_express",
"customer_id": "__test__XpbTXGTSRp3gtJDI",
"expiry_month": 12,
"expiry_year": 2022,
"gateway": "chargebee",
"iin": "378282",
"last4": "0005",
"masked_number": "***********0005",
"object": "card",
"reference_id": "tok___test__XpbTXGTSRp3gxDDL",
"status": "valid"
}The ISO 3166-2 state/province code
without the country prefix. Currently supported for USA, Canada and India. For instance, for Arizona (USA), set state_code
as AZ
(not US-AZ
). For Tamil Nadu (India), set as TN
(not IN-TN
). For British Columbia (Canada), set as BC
(not CA-BC
).
The billing address country of the customer. Must be one of ISO 3166 alpha-2 country code .
Note: If you enter an invalid country code, the system will return an error.
Brexit
If you have enabled EU VAT in 2021 or later, or have manually enable the Brexit configuration, then XI (the code for United Kingdom - Northern Ireland) is available as an option.
Storing card after successful 3DS flow not supported in this API. Use create using Payment Intent API under Payemnt source to store the card after successful 3DS flow completion.
Adds or replaces card details of a customer. Updating card details replaces the present payment method.
Passing credit card details to this API involves PCI liability at your end as sensitive card info passes through your servers. If you wish to avoid that, you can use one of the following integration methodologies if applicable
**Note:**For customers signed up before 1st March 2014, if the card's billing information is specified in the input, the customer's Billing Info (i.e Billing Address and vat_number) will also be replaced with the new values automatically.
The single-use card token returned by vaults like Stripe/Braintree which act as a substitute for your card details. Before calling this API, you should have submitted your card details to the gateway and gotten this token in return. Note: Supported only for Stripe, Braintree and Authorize.Net. If this value is specified, there is no need to specify other card details (like number, cvv, etc).
The credit card number without any format. If you are using Braintree.js , you can specify the Braintree encrypted card number here.
The card verification value (CVV). If you are using Braintree.js , you can specify the Braintree encrypted CVV here.
The ISO 3166-2 state/province code
without the country prefix. Currently supported for USA, Canada and India. For instance, for Arizona (USA), set state_code
as AZ
(not US-AZ
). For Tamil Nadu (India), set as TN
(not IN-TN
). For British Columbia (Canada), set as BC
(not CA-BC
).
The billing address country of the customer. Must be one of ISO 3166 alpha-2 country code .
Note: If you enter an invalid country code, the system will return an error.
Brexit
If you have enabled EU VAT in 2021 or later, or have manually enable the Brexit configuration, then XI (the code for United Kingdom - Northern Ireland) is available as an option.
.
Used to store the card to the customer after 3DS flow completion. Learn more on the 3DS integration guide via Chargebee APIs
Identifier for PaymentIntent generated by Chargebee.js. Applicable only when you are using Chargebee.js for completing the 3DS flow. The PaymentIntent should be in 'authorized' state while passing it here. You need not pass other PaymentIntent parameters if this is passed.
Identifier for 3DS transaction/verification object at the gateway. Can be passed only after successfully completing the 3DS flow. Refer 3DS implementation in Chargebee to find out the gateway-specific gw_token format. Applicable when you are using gateway APIs directly for completing the 3DS flow.
Switches the gateway in which customer's card information is stored.
This is applicable only if the payment method is "card".
This operation is not supported if the current gateway is Braintree or Stripe.
Deletes the existing card for a customer. Upon successful deletion of card the auto_collection attribute for this customer will be set to off and card_deleted event will be triggered.
If there is no card present in the gateway for the customer, this API will return successfully without throwing any error.