v1
latestOpenAPI 3.0.02026-07-26168846732.2 KBPayment Methods
Payment Method - Update
Update an existing payment method of a customer. This API is useful for use cases such as updating the card number for expired cards to prevent discontinuity in recurring payments.
post/payment_methods/{method_id}/update
Path parameters
method_idstring required
The unique identifier for the Payment Method
Request body
Example request
{
"payment_method_data": {
"card": {
"card_holder_name": "John Doe",
"nick_name": "John Doe",
"card_cvc": "242"
}
},
"connector_token_details": {
"token": "pm_9UhMqBMEOooRIvJFFdeW"
}
}Response
Payment Method updated
Example response
{
"id": "0a_pm_01926c58bc6e77c09e809964e72af8c8",
"merchant_id": "merchant_1671528864",
"customer_id": "0a_cus_01926c58bc6e77c09e809964e72af8c8",
"recurring_enabled": true,
"created": "2023-01-18T11:04:09.922Z",
"last_used_at": "2024-02-24T11:04:09.922Z",
"payment_method_data": {
"card": {
"last4_digits": "4242",
"expiry_month": "10",
"expiry_year": "25",
"card_holder_name": "John Doe",
"card_fingerprint": "fingerprint_12345",
"nick_name": "Card",
"card_isin": "4567890",
"card_issuer": "Issuer Bank",
"card_type": "Credit",
"saved_to_locker": true
}
},
"connector_tokens": [
{
"token": "pm_9UhMqBMEOooRIvJFFdeW"
}
],
"network_token": {
"payment_method_data": {
"last4_digits": "4242",
"network_token_expiry_month": "05",
"network_token_expiry_year": "27",
"nick_name": "Card",
"card_holder_name": "John Doe",
"card_isin": "16712672",
"card_issuer": "Bank of America",
"card_type": "Credit",
"par": "522134KAVJ1JPZ8L77N0Z2LRYZS7J"
}
},
"card_cvc_token_storage": {
"is_stored": true,
"expires_at": "2024-02-24T11:04:09.922Z"
},
"raw_payment_method_data": {
"card": {
"card_number": "4111111145551142",
"card_exp_month": "10",
"card_exp_year": "25",
"card_holder_name": "John Doe",
"nick_name": "John Doe",
"card_cvc": "242"
}
},
"billing": {
"address": {
"city": "New York",
"line1": "123, King Street",
"line2": "Powelson Avenue",
"line3": "Bridgewater",
"zip": "08807",
"state": "New York",
"first_name": "John",
"last_name": "Doe",
"origin_zip": "08807"
},
"phone": {
"number": "9123456789",
"country_code": "+1"
}
}
}