#sandip.b.fst
1 messages · Page 1 of 1 (latest)
Hello! Per the API ref:
If the subscription was canceled with cancel_at_period_end, canceled_at will reflect the time of the most recent update request, not the end of the subscription period when the subscription is automatically moved to a canceled state.
Because you passed end_behavior: 'cancel' here (https://dashboard.stripe.com/test/logs/req_GSCUwcaYqtNtXz) we set the canceled_at to the timestamp of that request
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
And how it possible created & canceled_at is same ?
Do I'm missing something ?
I explained why above
Okay, Please provide some information about this behaviour
I'm not sure what else I can provide on top of what I've already shared. What is unclear?
You created a schedule (https://dashboard.stripe.com/test/logs/req_GSCUwcaYqtNtXz) and set end_behavior: 'cancel'. That means that at the end of the defined phases on the schedule, the underlying subscription will be automatically cancelled. In effect, that is a request to cancel the subscription so canceled_at is set to the time of the request
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
When the subscription actually cancels, canceled_at timestamp will update to reflect the time of actual cancellation
but here nothing is mention that canceled_at is affect from end_behavior.
https://stripe.com/docs/api/subscriptions/object#subscription_object-canceled_at
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
end_behavior: 'cancel'. That means that at the end of the defined phases on the schedule, the underlying subscription will be automatically cancelled. In effect, that is a request to cancel the subscription so canceled_at is set to the time of the request
how is this request to cancel subscription!!!!
It says it right there in the API parameter description: https://stripe.com/docs/api/subscription_schedules/create#create_subscription_schedule-end_behavior
cancel will end the subscription schedule and cancel the underlying subscription.
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
but subscription just created and all schedule phases are pending not any of phase (schedule payment) is canceled.
but in subscripion its showing that subscripion was canceled when it was created.
Sorry still I didn't understand this behaviour.
Not sure how else I can explain it. You set the schedule to cancel the underlying subscription which in effect sets canceled_at
That's jsut how the API works, you need to adjust your integration to expect that
Means if in subscription canceled_at is set that does not mean it is canceled. right?
Yes exactly
canceled_at will initially be set to the timestamp of when it will cancel (i.e. at the end of the configured phases)
okay, I got it.
Thank you for the quick support.
when a schedule with end_behaviour:'release' is ends at that do I receive any hook for subscripion update like customer.subscripion.deleted or customer.subscripion.updated;
you get a customer.subscripion.updated and a subscription_schedule.updated
okay.