default_payment_method
The default payment method for a customer. When completing a transaction through the API, this is the payment method that will be used. To set a new payment card, modify cc_number, though it won't be displayed as part of the resource.
Note: some of the functionality related to the customer payment method are still being developed and reorganized. Currently only a payment card can be saved and not an alternative payment method.
Required Scopes
store_full_access customers_read customers_write Actions
Properties (8)
save_cc Boolean If the customer selected to save their payment information, this will be true. To clear out the payment information, set this to false.
cc_type String · Read-only The credit card or debit card type. This will be determined automatically once the payment card is saved.
cc_number String The payment card number. This property will not be displayed as part of this resource, but can be used to modify this payment method.
Must be a valid payment card number.
cc_number_masked String · Read-only A masked version of this payment card showing only the last 4 digits.
cc_exp_month String The payment card expiration month in the MM format.
Must be a valid month from 01 to 12.
cc_exp_year String The payment card expiration year in the YYYY format.
Must be a valid 4 digit year.
date_created String (nullable) · Read-only The date this resource was created.
date_modified String (nullable) · Read-only The date this resource was last modified.
Link Relations (3)
self Default Payment Method fx:default_payment_method on customer·fx:default_payment_method on payment_method_expiring Example Representation
{
"_links": {
"curies": [
{
"name": "fx",
"href": "https://api.foxycart.com/rels/{rel}",
"templated": true
}
],
"self": {
"href": "https://api.foxycart.com/customers/123/default_payment_method",
"title": "Default Payment Method"
},
"fx:store": {
"href": "https://api.foxycart.com/stores/456",
"title": "This Store"
},
"fx:customer": {
"href": "https://api.foxycart.com/customers/123",
"title": "This Customer"
}
},
"save_cc": true,
"cc_type": "Visa",
"cc_number_masked": "xxxxxxxxxxxx1111",
"cc_exp_month": "12",
"cc_exp_year": "2020",
"date_created": "2009-02-10T21:41:51-0800",
"date_modified": "2013-08-17T17:40:22-0700"
}