Removes a saved credit card from the customer account
JavaScript
import { createClient } from '@spree/sdk' const client = createClient({ baseUrl: 'https://your-store.com', publishableKey: '<api-key>', }) await client.customer.creditCards.delete('card_abc123', { bearerToken: '<token>', })
{ "error": { "code": "record_not_found", "message": "Credit card not found" } }
Publishable API key for store access
JWT token for authenticated customers
credit card deleted
Was this page helpful?