#sanjeev-sundaravarathan_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/1294258411982032898
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
How does the schedule behave currently?
request_data = {
"customer": customer,
"start_date": "now",
"phases": phases,
"expand": ['subscription.latest_invoice.payment_intent.invoice'],
**subscription_extra
}
phases = self.get_phases(invoice_date, frequency, subscription_extra, amount, currency, product,
interval, interval_count, subsequent_invoice_charge)
subscription_schedule = stripe.SubscriptionSchedule.create(
**request_data
)
this is the current code
{
"items": [
{
'price_data': {
"currency": currency,
"product": product.id,
"recurring": {
"interval": "day",
"interval_count": phase_interval_day_count
},
"unit_amount": phase_amount
}
},
],
"iterations": 1,
**application_fee_data,
}
phases will be created under a loop
Sorry, not sure what you're explaining here. What is the current behaviour, and what do you want to actually happen?
Sorry,
Currently when i use subscriptionSchedules, i cant pass the payment_behavior as default_incomplete, because subscriptionSchedules doesnt respect this right ?
What are my alternative options use it in subscriptionSchedules
Thank you for taking my message. I'm here to follow up your case, regarding your subscription set up. I hope you're doing well.
While taking into consideration your most recent comment regarding the payment_behaviour on top of Subscription Schedules API, I'm afraid to say that we don't support this parameter yet. Although you can still create a subscription and its respective schedule in separate API calls while using the from_subscription parameter:
This way, you can set the payment_behaviour to allow_incomplete while placing a schedule on top of it.
Please don't hesitate to share your comments with me in this case; I'd love to see your point of view.
I have received this email from the stripe support, where if i use from_subscription then i cant pass the phases
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
You'd need to update the schedule after creation, then you can amend the phases as needed
so create the normal subscription pass payment_behaviour and then create schedule using from_subscription and add the phases right ?
Yep