Deactivate a payment instrument

Deactivates a payment instrument with a specified ID.

SecurityHTTP: CustomerJWT
Request
path Parameters
id
required
string <= 50 characters ^[@~\-\.\w]+$

ID of the resource.

post
/storefront/payment-instruments/{id}/deactivation
Request samples
const paymentInstrument = await api.paymentInstruments.deactivate({id: 'id-to-deactivate'});

console.log(paymentInstrument.fields.status);
Responses

201

Payment instrument deactivated.

401

Unauthorized access. Invalid credentials used.

403

Access forbidden.

404

Resource not found.

422

Invalid data sent.

Response samples
application/json
{ "id": "4f6cf35x-2c4y-483z-a0a9-158621f77a21", "method": "payment-card", "status": "active", "fingerprint": "string", "bin": "string", "last4": "string", "expYear": 0, "expMonth": 0, "brand": "Visa", "bankCountry": "string", "bankName": "string", "billingAddress": { "firstName": "Benjamin", "lastName": "Franklin", "organization": "Rebilly", "address": "36 Craven St", "address2": "string", "city": "Austin", "region": "Texas", "country": "GB", "postalCode": "WC2N 5NF", "dob": "1980-04-01", "jobTitle": "CEO", "hash": "056ae6d97c788b9e98b049ebafd7b229bf852221" }, "useAsBackup": false, "billingPortalUrl": "string", "createdTime": "2019-08-24T14:15:22Z", "updatedTime": "2019-08-24T14:15:22Z", "customFields": { "foo": "bar" }, "token": "string", "_links": [ ] }