Store a card
Store the card is used to store the card information for a customer.
POST
/v1/customers/:id/sources
The above command returns JSON structured like this:
Arguments
Contain the card information to be stored.
card[number]
numeric
required is source is not present
Credit card number.
card[exp_month]
numeric
required is source is not present
Card expiration month.
card[exp_year]
numeric
required is source is not present
Card expiration year.
card[name]
string
required is source is not present
Cardholder name.
card[address_line1]
string
optional
Cardholder line 1 address.
card[address_line2]
string
optional
Cardholder line 2 address.
card[address_state]
string
optional
Cardholder address state using the iso 3166-2 code for country states.
card[address_city]
string
optional
Cardholder address city.
card[address_zip]
string
optional
Cardholder zip address.
card[address_country]
string
optional
Cardholder iso 2 country code.
source
string
optional if card data is not present
Contain the token ID received from the token creation.
client_ip
string
optional
IP address of the client that generate the token.
Returns
Return the card object linked to the card information stored.
Last updated