#xqprtzcv
1 messages · Page 1 of 1 (latest)
Hello! We'll be with you shortly. 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.
Hello! You don't seem to be setting a trial period in that request. If you set trial_end does it work as expected? https://stripe.com/docs/api/invoices/upcoming#upcoming_invoice-subscription_trial_end
Hey, in the second request, I have already created a subscription that has a trial.
I can try adding it again during the upgrade request though
I think the issue is that the upcoming Invoice request you're making changes the Price and nullifies the existing trial.
Yes, I am changing the price ID
Here is the request, it still doesn't seem to be giving me amount_due 0 even when I add trial_end:
{
"expand[0]": "customer",
"expand[1]": "total_tax_amounts.tax_rate",
"automatic_tax[enabled]": true,
"subscription": "sub_1OegxFHtzQiUYLb0KyBHJSII",
"subscription_cancel_at_period_end": false,
"subscription_proration_behavior": "always_invoice",
"subscription_items[0][id]": "si_PTeFGsXx0pH4Qy",
"subscription_items[0][price]": "price_1OWi2NHtzQiUYLb0ZI5CcZUM",
"subscription_billing_cycle_anchor": "unchanged",
"subscription_trial_end": 1707929284
}
What amount is it charging?
It is charging the amount for the full year (which is the correct amount that should be due after then end of the trial)
Can you share the request ID of your latest attempt? Here's how you can find a request ID: https://support.stripe.com/questions/finding-the-id-for-an-api-request
req_EIdzmQAaZtEQJH
Ah... when is the date of the upcoming Invoice?
Looks like this is at the end of the trial: "created": 1707929284,
That makes sense. The arguments you're passing would not result in an immediate Invoice. The next Invoice would be the one at the end of the trial period.
Ok, and so it is not possible to create an invoice at that point with amount_due=0?
I think you can, but you would need to adjust something to trigger an Invoice. If you changesubscription_billing_cycle_anchor to now does that do it?
I get this: "Trial end (1707929284) cannot be after billing_cycle_anchor (1707670061). Consider ending the trial (trial_end=now)."
Oh, yep, I forgot about that. 😅
No worries
So I guess no, what you want to do doesn't seem possible. The Invoice you see is always going to be after the trial.
Ok, thank you