#mehdi_schedule-preview

1 messages ¡ Page 1 of 1 (latest)

ripe surgeBOT
#

👋 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/1283909174987587665

📝 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.

blazing crypt
#

Hello! You can only create a preview for the next Invoice, not future Invoices beyond that.

young compass
#

hmmm is there any way to see what would be charged for the later invoice?

#

or any way to try out subscription schedules in the dashboard to see what it would be like?

blazing crypt
#

Can you tell me more about exactly what you're trying to do? I want to make sure I fully understand so I can provide you the best guidance.

young compass
#

oh yeah sure

#

we are creating a subscription where the user is charged $10 for the first year and $5 for each year after that

#

we want to make a checkout screen where we show the initial charge of $10, and also show the "future" invoice

#

we want to use real data from the stripe api (i.e. using createPreview), that way all the tax information, discounts, etc will be factored in

blazing crypt
#

Would that work?

young compass
#

oh that's what i'm using

#

but the endpoint only gives me the first invoice

#

and i want the future ones as well

blazing crypt
#

You can only get the next one, but you can modify the parameters to simiulate the next phase. It'll still be a preview of the next Invoice, but with the modifications to the Subscription you provide.

young compass
#

ahhh i see

#

basically the same as the upcoming invoice api then though?

blazing crypt
#

Yes, they're quite similar. The preview API is recommended though, it's newer and a bit more robust.

young compass
#

ahhh okay

#

thanks! will do that

ripe surgeBOT