#amin_api

1 messages ¡ Page 1 of 1 (latest)

full oarBOT
#

👋 Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1286187196927447100

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

wraith mulch
#

I'd recommend using new meter events for usage based billing: https://docs.stripe.com/billing/subscriptions/usage-based/implementation-guide

For the new meter event integration, it has one-hour grace period by default to submit the usage after the period ends: https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#configurable-grace-period

Understand the major pieces of a usage-based billing integration.

Learn how to record and report usage for your customers.

rose solar
#

@wraith mulch thanks, I can see that it can be still extended to 72 hours,.

#

still a bit unsafe for us as the whole calculation will happen after the billing cycle ends and it can take time, might have to retry if there was any error.

wraith mulch
rose solar
#

I see, I am using Legacy usage record API atm, so @wraith mulch what is your recommendation, should I totally ignore usage metering/subscriptions and just create manual invoices each time?

wraith mulch
#

This is the new way to integrate metered/usage billing for subscription

rose solar
#

OK I understand @wraith mulch , let's say in the case of an error the system couldn't submit metered events within 72 hours window, what happens? would "0" invoices be sent to cusomers? how can I recover from those cases?

wraith mulch
#

$0 will be created and sent to the customer

#

If this happen, your system can:

  1. Charge the usage to the next billing cycle; OR
  2. Create an one-time invoice for the usage that fails to submit
rose solar
#

that is great, but still can the 72 hours be increased, let say a week?

wraith mulch
#

72 hours is the maximum duration of the grace period and it can't be increased further