From 3d0bd21a1f26311f7237a88f7f450438bb27f4a7 Mon Sep 17 00:00:00 2001 From: Emmett Miller Date: Fri, 25 Apr 2025 10:26:52 -0400 Subject: [PATCH 1/2] Made redirect_url required and quantity added as an option --- src/UpdateBilling.ts | 2 +- src/types/billing.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/UpdateBilling.ts b/src/UpdateBilling.ts index 8335f02..0221e7a 100644 --- a/src/UpdateBilling.ts +++ b/src/UpdateBilling.ts @@ -145,7 +145,7 @@ export class UpdateBillingClient { async createCheckoutSession( id: string, - options?: CreateCheckoutSessionOptions + options: CreateCheckoutSessionOptions ): Promise { if (!this.hasSessionToken) { console.warn( diff --git a/src/types/billing.ts b/src/types/billing.ts index b304174..c112241 100644 --- a/src/types/billing.ts +++ b/src/types/billing.ts @@ -91,5 +91,6 @@ export type UpdateSubscriptionResponse = { }; export type CreateCheckoutSessionOptions = { - redirect_url?: string; + redirect_url: string; + quantity?: number; }; From d5708de41ed473f7e3a5681a820fcb4ca0aa8880 Mon Sep 17 00:00:00 2001 From: Emmett Miller Date: Fri, 25 Apr 2025 10:27:05 -0400 Subject: [PATCH 2/2] bump version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 18be04a..6453aca 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@updatedev/js", - "version": "0.4.1", + "version": "0.4.2", "description": "Update JavaScript SDK", "main": "dist/cjs/index.js", "module": "dist/esm/index.js",