-
Notifications
You must be signed in to change notification settings - Fork 682
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Request] Add method to delete card #281
Comments
PR created #357 |
I wasn't able to get this to work with deleteCard(). I looked at the cashier git and apparently the method is actually deleteCards(). Now it's working great. So if you're having trouble getting this to work try deleteCards() with an s instead of deleteCard(). |
Thanks for pointing this out. Indeed, Taylor renamed the method from |
EDIT: Please refer to the new documentation for Laravel 6, https://laravel.com/docs/6.x/billing#deleting-payment-methods, my comment is referring to an old version of documentation There is currently no mention of the @themsaid, can this be added? |
I don't feel like this should be closed. While, yes, there's a method for deleting all cards. There's no method for deleting a specific card. |
You also have |
deletePaymentMethods() is deleting all the cards from stripe. I see there have $paymentMethod->delete(); function. what it expect as $paymentMethod here ? |
@sazibuddin you can delete a specific payment method with: $user->removePaymentMethod($id); |
@driesvints, Thanks for your reply. But I struggle that what the function expects as an id? |
The payment method ID or a payment method object. |
@driesvints, I just tried and it works like a champ. Thank you very much. you make my day. |
I saw this wasn't documented yet so I sent in a PR for it to the docs: laravel/docs#7559 |
Please, could you consider adding to the
Billable
class adeleteCard
method?Nowadays it is possible to delete all cards of a given customer, see this blog post and the relevant API.
I'm being frustrated by the amount of websites based on Stripe that don't let deleting the card, despite this being such a fundamental requirement IMO.
You can have an influence on this, just by adding this class method. Thank you in advance.
The text was updated successfully, but these errors were encountered: