-
Notifications
You must be signed in to change notification settings - Fork 120
Description
Steps to reproduce the behavior
When calling:
razorpay.subscriptions.cancel(subId, { cancel_at_cycle_end: true });The subscription is not canceled at the end of the billing cycle. The API response shows:
"has_scheduled_changes": false,
"change_scheduled_at": nulleven though the cancel_at_cycle_end parameter was provided.
Impact:
This makes it impossible to show a "cancels at end of period" message in the UI or honor user intent, forcing developers to implement unreliable workarounds.
Expected behavior
According to the official docs, passing cancel_at_cycle_end: true should:
Schedule cancellation at the end of the current cycle
Return:
"has_scheduled_changes": true,
"change_scheduled_at": "cycle_end",
"current_end": [timestamp]Impact:
This makes it impossible to show a "cancels at end of period" message in the UI or honor user intent, forcing developers to implement unreliable workarounds.
Actual behavior
When calling:
razorpay.subscriptions.cancel(subId, { cancel_at_cycle_end: true });The subscription is not canceled at the end of the billing cycle. The API response shows:
"has_scheduled_changes": false,
"change_scheduled_at": nulleven though the cancel_at_cycle_end parameter was provided.
Impact:
This makes it impossible to show a "cancels at end of period" message in the UI or honor user intent, forcing developers to implement unreliable workarounds.
Code snippets
Node version
v23.11.0
Library version
^2.9.6
Additional Information
Impact:
This makes it impossible to show a "cancels at end of period" message in the UI or honor user intent, forcing developers to implement unreliable workarounds.