You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have my integration with rails and when I create customer as Stripe::Customer.create({ source: source }), I can see the sources object there. But then when I try to update my Customer, it gives me Bad Request as Stripe::Customer.update(stripe_customer_id, { source: card_token }). Using any other props, it works fine.
It's totally possible that one property available in the real Stripe API is missing inside localstripe.
localstripe only implement what's contributors have contributes.
So don't hesitate to open a PR to propose code changes or new code!
In your PR, please include links to relevant Stripe API documentation, so we can easily check.
Also, don't forget to say that you have tested with the real Stripe API (you must test it with it).
Last things: you will be asked to add a small unit-test inside this file https://github.com/adrienverge/localstripe/blob/2709044ab35698ab7cd80fb9dab05933aedbb551/test.sh, so prepare a small example using CURL ;-)
PS: ourself in our APP, to update a customer payment method, we use customer update API invoice_settings.default_payment_method parameter and it works with localstripe. Maybe you could use it too? (I'm not saying is better, I don't know, I'm just saying that it works out-of-the-box with localstripe).
I have my integration with rails and when I create customer as Stripe::Customer.create({ source: source }), I can see the sources object there. But then when I try to update my Customer, it gives me Bad Request as Stripe::Customer.update(stripe_customer_id, { source: card_token }). Using any other props, it works fine.
Copying this code
https://github.com/adrienverge/localstripe/blob/master/localstripe/resources.py#L715
To
https://github.com/adrienverge/localstripe/blob/master/localstripe/resources.py#L721
Works fine.
The text was updated successfully, but these errors were encountered: