async-stripe icon indicating copy to clipboard operation
async-stripe copied to clipboard

Corrected CancelSubscription fields for current Stripe API version.

Open nryanl opened this issue 1 year ago • 2 comments

Same as #402. Accidentally closed. Sorry!

Corrected CancelSubscription fields for current Stripe API version.

A fix for #394

https://stripe.com/docs/api/subscriptions/cancel

According to the current Stripe API in the link above, there is no "reason" field within cancellation_details any longer. This also aligns with my testing where it did not recognize the parameter. Consider removing this struct in future versions. For now, users can leave this as None.

  • Replaced at_period_end with invoice_now
  • Added cancellation_details field
  • Added prorate field

Checklist

  • [x] ran cargo make fmt
  • [x] using conventional commits to hightlight user-facing fixes and features

nryanl avatar Jul 15 '23 16:07 nryanl

Should we include a fix for https://github.com/arlyon/async-stripe/issues/419 in this since you are doing work around at_period_end already?

WoodyWoodster avatar Aug 15 '23 21:08 WoodyWoodster

I don't mind merging this now and opening a new PR. Thanks! We are waiting on a fix in #426 to fix CI and then I will ask you to rebase.

arlyon avatar Aug 19 '23 12:08 arlyon