Glench / ExtPay

The JavaScript library for ExtensionPay.com — payments for your browser extensions, no server needed.
https://extensionpay.com
Other
481 stars 62 forks source link

`unpaid` subscription status undocumented #223

Open Glench opened 1 month ago

Glench commented 1 month ago

Discussed in https://github.com/Glench/ExtPay/discussions/221

Originally posted by **ba32107** July 7, 2024 In dev mode, I can set an `unpaid` status: ![image](https://github.com/Glench/ExtPay/assets/26036493/6a4ff648-6dbd-415e-8308-1d9aacff8289) This status is not present in the main README or this doc: https://github.com/Glench/ExtPay/blob/main/docs/how_subscriptions_work.md It's not really clear what the difference is between `past_due` and `unpaid`. The [Stripe docs](https://docs.stripe.com/api/subscriptions/object#subscription_object-status) say: ``` If subscription collection_method=send_invoice it becomes past_due when its invoice is not paid by the due date, and canceled or unpaid if it is still not paid by an additional deadline after that. ``` From this I can sort of understand the difference, but it's never mentioned anywhere in the ExtPay docs that the `subscriptionStatus` property mimicks the Stripe API's values. So I think this additional value should be documented in this repo. Thanks!
ba32107 commented 1 month ago

Forgot to mention in my original report, the type definition also lacks this property:

image

Thanks!

ba32107 commented 1 month ago

Also, I know it's not related to this issue, but the email property is also missing on the User typescript interface. I've seen it was already added, but the NPM package is still outdated, could it be released soon? Thanks!