#iffitimmi_api
1 messages ¡ Page 1 of 1 (latest)
đ 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/1222601351511670844
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- iffitimmi_api, 1 hour ago, 14 messages
@young kindle your last reply:
It looks like usage is actually accumulating. We currently show a recorded usage of 789 on the subscription from that item https://dashboard.stripe.com/test/subscriptions/sub_1OwkCMC2iiBNc0m938rKQ9Fq
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
could you please tell me how can i set a value of total usage.?
Hi, you would need to use the set value, https://docs.stripe.com/api/usage_records/create#usage_record_create-action and then pass the exact same timestamp. Are you able to try that?
i passed new timestamp every time is this a mistake?
Yeah, that is why it's incrementing. You need to pass the exact same time stamp instead of passing in a new stamp each time.
exact time stamp when user subscribed a plan?
https://docs.stripe.com/api/usage_records/create#usage_record_create-action : 'The set action will overwrite the usage quantity at that timestamp'. So if you want to override the previously reported usage, then you would want to pass the same timestamp from that request.
ty, I got it now that if we had to set the value we should provide a timestamp when we incremented or set it previously and can change that value from 0 to onwards, is that right?
and one more thing is the usage quantity would be set to 0 after a month or we have to tackle this according to our logic based on the timestamp?
That is correct. On the second part, you would want to read this, https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage. The customer will be billed at the end of the month and the is reset for you. You should test in test mode as well.
thank you for helping me out@tired veldt