fix: phone number cancel billing (#23854)

* fix: phone number billing bug

* fix: phone number billing bug

* fix: use raw code

* fix: use zod

* chore: update test

* fix: double cancel

* fix: double cancel

* fix: double cancel

* fix: chore update

* fix: schema
This commit is contained in:
Udit Takkar authored and GitHub committed 2025-09-16 15:39:32 +05:30
1 parent f267cd9cd9
commit 5feca13cfb
3 files changed
+55 -19

No files matched your search

@@ -72,6 +72,10 @@ async function handleCalAIPhoneNumberSubscriptionDeleted(
}
try {
if (phoneNumber.subscriptionStatus === "CANCELLED") {
return { success: true, subscriptionId: subscription.id, skipped: true };
}
const aiService = createDefaultAIPhoneServiceProvider();
await aiService.cancelPhoneNumberSubscription({