autumn-js 1.2.23 → 1.2.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/backend/adapters/express.js +56 -61
- package/dist/backend/adapters/express.mjs +9 -9
- package/dist/backend/adapters/fetch.js +56 -61
- package/dist/backend/adapters/fetch.mjs +9 -9
- package/dist/backend/adapters/hono.js +56 -61
- package/dist/backend/adapters/hono.mjs +9 -9
- package/dist/backend/adapters/index.js +56 -61
- package/dist/backend/adapters/index.mjs +12 -12
- package/dist/backend/adapters/next.js +56 -61
- package/dist/backend/adapters/next.mjs +9 -9
- package/dist/backend/{chunk-UFAAJ5IV.mjs → chunk-5LKGVXKH.mjs} +1 -1
- package/dist/backend/{chunk-ZE23DYSY.mjs → chunk-6FBGYP7X.mjs} +1 -1
- package/dist/backend/{chunk-7TQNAVUG.mjs → chunk-6VSWVXTK.mjs} +1 -1
- package/dist/backend/{chunk-K2ODGGAT.mjs → chunk-ACRLMGFI.mjs} +1 -1
- package/dist/backend/{chunk-T4ZAR3BE.mjs → chunk-H427PQAN.mjs} +41 -49
- package/dist/backend/{chunk-VHEQZSCT.mjs → chunk-MAU6WWTL.mjs} +15 -12
- package/dist/backend/{chunk-W5UYBM7S.mjs → chunk-TFYNLI5B.mjs} +7 -7
- package/dist/backend/{chunk-RKIVVLR3.mjs → chunk-VJT3K6DB.mjs} +5 -5
- package/dist/backend/core/handlers/coreHandler.d.mts +1 -1
- package/dist/backend/core/handlers/coreHandler.d.ts +1 -1
- package/dist/backend/core/handlers/coreHandler.js +56 -61
- package/dist/backend/core/handlers/coreHandler.mjs +7 -7
- package/dist/backend/core/handlers/executeRoute.d.mts +1 -1
- package/dist/backend/core/handlers/executeRoute.d.ts +1 -1
- package/dist/backend/core/handlers/executeRoute.mjs +4 -4
- package/dist/backend/core/handlers/handleRouteByName.js +56 -61
- package/dist/backend/core/handlers/handleRouteByName.mjs +7 -7
- package/dist/backend/core/handlers/index.d.mts +1 -1
- package/dist/backend/core/handlers/index.d.ts +1 -1
- package/dist/backend/core/handlers/index.js +56 -61
- package/dist/backend/core/handlers/index.mjs +10 -10
- package/dist/backend/core/index.d.mts +1 -1
- package/dist/backend/core/index.d.ts +1 -1
- package/dist/backend/core/index.js +56 -61
- package/dist/backend/core/index.mjs +10 -10
- package/dist/backend/core/routes/index.d.mts +1 -1
- package/dist/backend/core/routes/index.d.ts +1 -1
- package/dist/backend/core/routes/index.js +15 -12
- package/dist/backend/core/routes/index.mjs +2 -2
- package/dist/backend/core/routes/routeBuilder.d.mts +1 -1
- package/dist/backend/core/routes/routeBuilder.d.ts +1 -1
- package/dist/backend/core/routes/routeConfigs.d.mts +1 -1
- package/dist/backend/core/routes/routeConfigs.d.ts +1 -1
- package/dist/backend/core/routes/routeConfigs.js +15 -12
- package/dist/backend/core/routes/routeConfigs.mjs +2 -2
- package/dist/backend/core/types/handlerTypes.d.mts +1 -1
- package/dist/backend/core/types/handlerTypes.d.ts +1 -1
- package/dist/backend/core/types/index.d.mts +1 -1
- package/dist/backend/core/types/index.d.ts +1 -1
- package/dist/backend/core/types/routeTypes.d.mts +1 -1
- package/dist/backend/core/types/routeTypes.d.ts +1 -1
- package/dist/backend/core/utils/index.mjs +3 -3
- package/dist/backend/index.d.mts +2 -2
- package/dist/backend/index.d.ts +2 -2
- package/dist/backend/index.js +56 -61
- package/dist/backend/index.mjs +10 -10
- package/dist/backend/{routeTypes-D5CxGaFb.d.ts → routeTypes-CEB4GveH.d.ts} +44 -82
- package/dist/backend/{routeTypes-BBNqffnK.d.mts → routeTypes-CxdEyS6R.d.mts} +44 -82
- package/dist/better-auth/{chunk-GPZQFANN.mjs → chunk-3TLQJLI4.mjs} +1 -1
- package/dist/better-auth/{chunk-VMKPVSFP.mjs → chunk-3WGAWLHM.mjs} +42 -50
- package/dist/better-auth/{chunk-3NU5LQBR.mjs → chunk-RHJSAAZY.mjs} +15 -12
- package/dist/better-auth/index.js +56 -61
- package/dist/better-auth/index.mjs +3 -3
- package/dist/better-auth/utils/createAutumnEndpoint.js +15 -12
- package/dist/better-auth/utils/createAutumnEndpoint.mjs +2 -2
- package/dist/better-auth/utils/handleBetterAuthRoute.js +56 -61
- package/dist/better-auth/utils/handleBetterAuthRoute.mjs +2 -2
- package/dist/better-auth/utils/index.js +56 -61
- package/dist/better-auth/utils/index.mjs +3 -3
- package/dist/react/AutumnContext.d.mts +1 -1
- package/dist/react/AutumnContext.d.ts +1 -1
- package/dist/react/AutumnProvider.js +15 -15
- package/dist/react/AutumnProvider.mjs +2 -2
- package/dist/react/{chunk-26CKSAPZ.mjs → chunk-7IDH4OMG.mjs} +1 -1
- package/dist/react/{chunk-HSQUB3BZ.mjs → chunk-BDG6JHEW.mjs} +1 -1
- package/dist/react/{chunk-KB72KQKN.mjs → chunk-DEZBJQEG.mjs} +1 -1
- package/dist/react/{chunk-XJZH5NMZ.mjs → chunk-E5ZHOMZ4.mjs} +23 -23
- package/dist/react/{chunk-OXQG65ZT.mjs → chunk-FWWIAOPU.mjs} +1 -1
- package/dist/react/chunk-HRPQYDEN.mjs +139 -0
- package/dist/react/{chunk-ZGPE4R6H.mjs → chunk-HVBDZARN.mjs} +2 -2
- package/dist/react/{chunk-CHU7CIWP.mjs → chunk-NSFHAUTD.mjs} +1 -1
- package/dist/react/{chunk-G7FTQLT7.mjs → chunk-YQFYWH7J.mjs} +1 -1
- package/dist/react/client/AutumnClient.d.mts +1 -1
- package/dist/react/client/AutumnClient.d.ts +1 -1
- package/dist/react/client/IAutumnClient.d.mts +1 -1
- package/dist/react/client/IAutumnClient.d.ts +1 -1
- package/dist/react/client/index.d.mts +1 -1
- package/dist/react/client/index.d.ts +1 -1
- package/dist/react/hooks/index.d.mts +1 -1
- package/dist/react/hooks/index.d.ts +1 -1
- package/dist/react/hooks/index.js +85 -32
- package/dist/react/hooks/index.mjs +8 -8
- package/dist/react/hooks/internal/getLocalCheckResponse.d.mts +1 -1
- package/dist/react/hooks/internal/getLocalCheckResponse.d.ts +1 -1
- package/dist/react/hooks/internal/useCustomerActions.d.mts +1 -1
- package/dist/react/hooks/internal/useCustomerActions.d.ts +1 -1
- package/dist/react/hooks/internal/useCustomerActions.js +1 -1
- package/dist/react/hooks/internal/useCustomerActions.mjs +2 -2
- package/dist/react/hooks/useAggregateEvents.d.mts +1 -1
- package/dist/react/hooks/useAggregateEvents.d.ts +1 -1
- package/dist/react/hooks/useAggregateEvents.js +16 -16
- package/dist/react/hooks/useAggregateEvents.mjs +2 -2
- package/dist/react/hooks/useCustomer.d.mts +1 -1
- package/dist/react/hooks/useCustomer.d.ts +1 -1
- package/dist/react/hooks/useCustomer.js +16 -16
- package/dist/react/hooks/useCustomer.mjs +3 -3
- package/dist/react/hooks/useEntity.d.mts +1 -1
- package/dist/react/hooks/useEntity.d.ts +1 -1
- package/dist/react/hooks/useEntity.js +16 -16
- package/dist/react/hooks/useEntity.mjs +2 -2
- package/dist/react/hooks/useListEvents.d.mts +1 -1
- package/dist/react/hooks/useListEvents.d.ts +1 -1
- package/dist/react/hooks/useListEvents.js +85 -32
- package/dist/react/hooks/useListEvents.mjs +2 -2
- package/dist/react/hooks/useListPlans.d.mts +1 -1
- package/dist/react/hooks/useListPlans.d.ts +1 -1
- package/dist/react/hooks/useListPlans.js +16 -16
- package/dist/react/hooks/useListPlans.mjs +2 -2
- package/dist/react/hooks/useReferrals.d.mts +1 -1
- package/dist/react/hooks/useReferrals.d.ts +1 -1
- package/dist/react/hooks/useReferrals.js +16 -16
- package/dist/react/hooks/useReferrals.mjs +2 -2
- package/dist/react/index.d.mts +1 -1
- package/dist/react/index.d.ts +1 -1
- package/dist/react/index.js +91 -38
- package/dist/react/index.mjs +9 -9
- package/dist/react/{params-BWA6FFXs.d.ts → params-DWJn7Y2f.d.ts} +18 -18
- package/dist/react/{params-Es9pSv7h.d.mts → params-DpI-uEQy.d.mts} +18 -18
- package/dist/sdk/index.d.mts +54 -89
- package/dist/sdk/index.d.ts +54 -89
- package/dist/sdk/index.js +43 -51
- package/dist/sdk/index.mjs +42 -50
- package/package.json +1 -1
- package/dist/react/chunk-MC2YYATT.mjs +0 -86
- package/dist/backend/{chunk-55C2WWXQ.mjs → chunk-S5HPMJ4U.mjs} +3 -3
|
@@ -76,10 +76,10 @@ function serverURLFromOptions(options) {
|
|
|
76
76
|
}
|
|
77
77
|
var SDK_METADATA = {
|
|
78
78
|
language: "typescript",
|
|
79
|
-
openapiDocVersion: "2.
|
|
79
|
+
openapiDocVersion: "2.3.0",
|
|
80
80
|
sdkVersion: "0.10.17",
|
|
81
81
|
genVersion: "2.882.0",
|
|
82
|
-
userAgent: "speakeasy-sdk/typescript 0.10.17 2.882.0 2.
|
|
82
|
+
userAgent: "speakeasy-sdk/typescript 0.10.17 2.882.0 2.3.0 @useautumn/sdk"
|
|
83
83
|
};
|
|
84
84
|
|
|
85
85
|
// ../sdk/src/lib/http.ts
|
|
@@ -849,7 +849,7 @@ function dlv(obj, key, def, p, undef) {
|
|
|
849
849
|
// ../sdk/src/lib/env.ts
|
|
850
850
|
var envSchema = z5.object({
|
|
851
851
|
AUTUMN_SECRET_KEY: z5.optional(z5.string()),
|
|
852
|
-
AUTUMN_X_API_VERSION: z5._default(z5.string(), "2.
|
|
852
|
+
AUTUMN_X_API_VERSION: z5._default(z5.string(), "2.3.0"),
|
|
853
853
|
AUTUMN_FAIL_OPEN: z5.pipe(
|
|
854
854
|
z5._default(z5.enum(["true", "false"]), "true"),
|
|
855
855
|
z5.transform((v) => v === "true")
|
|
@@ -1892,7 +1892,8 @@ var AttachParams$outboundSchema = z10.pipe(
|
|
|
1892
1892
|
),
|
|
1893
1893
|
metadata: z10.optional(z10.record(z10.string(), z10.string())),
|
|
1894
1894
|
noBillingChanges: z10.optional(z10.boolean()),
|
|
1895
|
-
enablePlanImmediately: z10.optional(z10.boolean())
|
|
1895
|
+
enablePlanImmediately: z10.optional(z10.boolean()),
|
|
1896
|
+
taxRateId: z10.optional(z10.string())
|
|
1896
1897
|
}),
|
|
1897
1898
|
z10.transform((v) => {
|
|
1898
1899
|
return remap(v, {
|
|
@@ -1916,7 +1917,8 @@ var AttachParams$outboundSchema = z10.pipe(
|
|
|
1916
1917
|
carryOverBalances: "carry_over_balances",
|
|
1917
1918
|
carryOverUsages: "carry_over_usages",
|
|
1918
1919
|
noBillingChanges: "no_billing_changes",
|
|
1919
|
-
enablePlanImmediately: "enable_plan_immediately"
|
|
1920
|
+
enablePlanImmediately: "enable_plan_immediately",
|
|
1921
|
+
taxRateId: "tax_rate_id"
|
|
1920
1922
|
});
|
|
1921
1923
|
})
|
|
1922
1924
|
);
|
|
@@ -5756,17 +5758,15 @@ var DeletePlanResponse$inboundSchema = z28.object({
|
|
|
5756
5758
|
|
|
5757
5759
|
// ../sdk/src/models/finalize-lock-op.ts
|
|
5758
5760
|
var z29 = __toESM(require("zod/v4-mini"), 1);
|
|
5759
|
-
var
|
|
5761
|
+
var FinalizeLockAction = {
|
|
5760
5762
|
Confirm: "confirm",
|
|
5761
5763
|
Release: "release"
|
|
5762
5764
|
};
|
|
5763
|
-
var
|
|
5764
|
-
Action
|
|
5765
|
-
);
|
|
5765
|
+
var FinalizeLockAction$outboundSchema = z29.enum(FinalizeLockAction);
|
|
5766
5766
|
var FinalizeBalanceParams$outboundSchema = z29.pipe(
|
|
5767
5767
|
z29.object({
|
|
5768
5768
|
lockId: z29.string(),
|
|
5769
|
-
action:
|
|
5769
|
+
action: FinalizeLockAction$outboundSchema,
|
|
5770
5770
|
overrideValue: z29.optional(z29.number()),
|
|
5771
5771
|
properties: z29.optional(z29.record(z29.string(), z29.any()))
|
|
5772
5772
|
}),
|
|
@@ -7101,8 +7101,8 @@ var ListCustomersSubscriptionStatus$outboundSchema = z35.enum(ListCustomersSubsc
|
|
|
7101
7101
|
var ListCustomersProcessor$outboundSchema = z35.enum(ListCustomersProcessor);
|
|
7102
7102
|
var ListCustomersParams$outboundSchema = z35.pipe(
|
|
7103
7103
|
z35.object({
|
|
7104
|
-
|
|
7105
|
-
limit: z35._default(z35.int(),
|
|
7104
|
+
startCursor: z35._default(z35.string(), ""),
|
|
7105
|
+
limit: z35._default(z35.int(), 50),
|
|
7106
7106
|
plans: z35.optional(z35.array(z35.lazy(() => ListCustomersPlan$outboundSchema))),
|
|
7107
7107
|
subscriptionStatus: z35.optional(
|
|
7108
7108
|
ListCustomersSubscriptionStatus$outboundSchema
|
|
@@ -7112,6 +7112,7 @@ var ListCustomersParams$outboundSchema = z35.pipe(
|
|
|
7112
7112
|
}),
|
|
7113
7113
|
z35.transform((v) => {
|
|
7114
7114
|
return remap(v, {
|
|
7115
|
+
startCursor: "start_cursor",
|
|
7115
7116
|
subscriptionStatus: "subscription_status"
|
|
7116
7117
|
});
|
|
7117
7118
|
})
|
|
@@ -7406,18 +7407,11 @@ var ListCustomersList$inboundSchema = z35.pipe(
|
|
|
7406
7407
|
var ListCustomersResponse$inboundSchema = z35.pipe(
|
|
7407
7408
|
z35.object({
|
|
7408
7409
|
list: z35.array(z35.lazy(() => ListCustomersList$inboundSchema)),
|
|
7409
|
-
|
|
7410
|
-
offset: number2(),
|
|
7411
|
-
limit: number2(),
|
|
7412
|
-
total: number2(),
|
|
7413
|
-
total_count: number2(),
|
|
7414
|
-
total_filtered_count: number2()
|
|
7410
|
+
next_cursor: nullable(string4())
|
|
7415
7411
|
}),
|
|
7416
7412
|
z35.transform((v) => {
|
|
7417
7413
|
return remap(v, {
|
|
7418
|
-
"
|
|
7419
|
-
"total_count": "totalCount",
|
|
7420
|
-
"total_filtered_count": "totalFilteredCount"
|
|
7414
|
+
"next_cursor": "nextCursor"
|
|
7421
7415
|
});
|
|
7422
7416
|
})
|
|
7423
7417
|
);
|
|
@@ -7464,8 +7458,8 @@ var ListEntitiesSubscriptionStatus$outboundSchema = z36.enum(ListEntitiesSubscri
|
|
|
7464
7458
|
var ListEntitiesProcessor$outboundSchema = z36.enum(ListEntitiesProcessor);
|
|
7465
7459
|
var ListEntitiesParams$outboundSchema = z36.pipe(
|
|
7466
7460
|
z36.object({
|
|
7467
|
-
|
|
7468
|
-
limit: z36._default(z36.int(),
|
|
7461
|
+
startCursor: z36._default(z36.string(), ""),
|
|
7462
|
+
limit: z36._default(z36.int(), 50),
|
|
7469
7463
|
plans: z36.optional(z36.array(z36.lazy(() => ListEntitiesPlan$outboundSchema))),
|
|
7470
7464
|
subscriptionStatus: z36.optional(
|
|
7471
7465
|
ListEntitiesSubscriptionStatus$outboundSchema
|
|
@@ -7475,6 +7469,7 @@ var ListEntitiesParams$outboundSchema = z36.pipe(
|
|
|
7475
7469
|
}),
|
|
7476
7470
|
z36.transform((v) => {
|
|
7477
7471
|
return remap(v, {
|
|
7472
|
+
startCursor: "start_cursor",
|
|
7478
7473
|
subscriptionStatus: "subscription_status"
|
|
7479
7474
|
});
|
|
7480
7475
|
})
|
|
@@ -7700,18 +7695,11 @@ var ListEntitiesList$inboundSchema = z36.pipe(
|
|
|
7700
7695
|
var ListEntitiesResponse$inboundSchema = z36.pipe(
|
|
7701
7696
|
z36.object({
|
|
7702
7697
|
list: z36.array(z36.lazy(() => ListEntitiesList$inboundSchema)),
|
|
7703
|
-
|
|
7704
|
-
offset: number2(),
|
|
7705
|
-
limit: number2(),
|
|
7706
|
-
total: number2(),
|
|
7707
|
-
total_count: number2(),
|
|
7708
|
-
total_filtered_count: number2()
|
|
7698
|
+
next_cursor: nullable(string4())
|
|
7709
7699
|
}),
|
|
7710
7700
|
z36.transform((v) => {
|
|
7711
7701
|
return remap(v, {
|
|
7712
|
-
"
|
|
7713
|
-
"total_count": "totalCount",
|
|
7714
|
-
"total_filtered_count": "totalFilteredCount"
|
|
7702
|
+
"next_cursor": "nextCursor"
|
|
7715
7703
|
});
|
|
7716
7704
|
})
|
|
7717
7705
|
);
|
|
@@ -7736,8 +7724,8 @@ var ListEventsCustomRange$outboundSchema = z37.object({
|
|
|
7736
7724
|
});
|
|
7737
7725
|
var EventsListParams$outboundSchema = z37.pipe(
|
|
7738
7726
|
z37.object({
|
|
7739
|
-
|
|
7740
|
-
limit: z37._default(z37.int(),
|
|
7727
|
+
startCursor: z37._default(z37.string(), ""),
|
|
7728
|
+
limit: z37._default(z37.int(), 50),
|
|
7741
7729
|
customerId: z37.optional(z37.string()),
|
|
7742
7730
|
entityId: z37.optional(z37.string()),
|
|
7743
7731
|
featureId: z37.optional(smartUnion([z37.string(), z37.array(z37.string())])),
|
|
@@ -7745,6 +7733,7 @@ var EventsListParams$outboundSchema = z37.pipe(
|
|
|
7745
7733
|
}),
|
|
7746
7734
|
z37.transform((v) => {
|
|
7747
7735
|
return remap(v, {
|
|
7736
|
+
startCursor: "start_cursor",
|
|
7748
7737
|
customerId: "customer_id",
|
|
7749
7738
|
entityId: "entity_id",
|
|
7750
7739
|
featureId: "feature_id",
|
|
@@ -7806,14 +7795,11 @@ var ListEventsList$inboundSchema = z37.pipe(
|
|
|
7806
7795
|
var ListEventsResponse$inboundSchema = z37.pipe(
|
|
7807
7796
|
z37.object({
|
|
7808
7797
|
list: z37.array(z37.lazy(() => ListEventsList$inboundSchema)),
|
|
7809
|
-
|
|
7810
|
-
offset: number2(),
|
|
7811
|
-
limit: number2(),
|
|
7812
|
-
total: number2()
|
|
7798
|
+
next_cursor: nullable(string4())
|
|
7813
7799
|
}),
|
|
7814
7800
|
z37.transform((v) => {
|
|
7815
7801
|
return remap(v, {
|
|
7816
|
-
"
|
|
7802
|
+
"next_cursor": "nextCursor"
|
|
7817
7803
|
});
|
|
7818
7804
|
})
|
|
7819
7805
|
);
|
|
@@ -9154,7 +9140,8 @@ var PreviewAttachParams$outboundSchema = z42.pipe(
|
|
|
9154
9140
|
),
|
|
9155
9141
|
metadata: z42.optional(z42.record(z42.string(), z42.string())),
|
|
9156
9142
|
noBillingChanges: z42.optional(z42.boolean()),
|
|
9157
|
-
enablePlanImmediately: z42.optional(z42.boolean())
|
|
9143
|
+
enablePlanImmediately: z42.optional(z42.boolean()),
|
|
9144
|
+
taxRateId: z42.optional(z42.string())
|
|
9158
9145
|
}),
|
|
9159
9146
|
z42.transform((v) => {
|
|
9160
9147
|
return remap(v, {
|
|
@@ -9178,7 +9165,8 @@ var PreviewAttachParams$outboundSchema = z42.pipe(
|
|
|
9178
9165
|
carryOverBalances: "carry_over_balances",
|
|
9179
9166
|
carryOverUsages: "carry_over_usages",
|
|
9180
9167
|
noBillingChanges: "no_billing_changes",
|
|
9181
|
-
enablePlanImmediately: "enable_plan_immediately"
|
|
9168
|
+
enablePlanImmediately: "enable_plan_immediately",
|
|
9169
|
+
taxRateId: "tax_rate_id"
|
|
9182
9170
|
});
|
|
9183
9171
|
})
|
|
9184
9172
|
);
|
|
@@ -11343,7 +11331,8 @@ var SetupPaymentParams$outboundSchema = z46.pipe(
|
|
|
11343
11331
|
),
|
|
11344
11332
|
metadata: z46.optional(z46.record(z46.string(), z46.string())),
|
|
11345
11333
|
noBillingChanges: z46.optional(z46.boolean()),
|
|
11346
|
-
enablePlanImmediately: z46.optional(z46.boolean())
|
|
11334
|
+
enablePlanImmediately: z46.optional(z46.boolean()),
|
|
11335
|
+
taxRateId: z46.optional(z46.string())
|
|
11347
11336
|
}),
|
|
11348
11337
|
z46.transform((v) => {
|
|
11349
11338
|
return remap(v, {
|
|
@@ -11363,7 +11352,8 @@ var SetupPaymentParams$outboundSchema = z46.pipe(
|
|
|
11363
11352
|
carryOverBalances: "carry_over_balances",
|
|
11364
11353
|
carryOverUsages: "carry_over_usages",
|
|
11365
11354
|
noBillingChanges: "no_billing_changes",
|
|
11366
|
-
enablePlanImmediately: "enable_plan_immediately"
|
|
11355
|
+
enablePlanImmediately: "enable_plan_immediately",
|
|
11356
|
+
taxRateId: "tax_rate_id"
|
|
11367
11357
|
});
|
|
11368
11358
|
})
|
|
11369
11359
|
);
|
|
@@ -14911,6 +14901,7 @@ var Billing = class extends ClientSDK {
|
|
|
14911
14901
|
* @param metadata - Key-value metadata to attach to the Stripe subscription, invoice, and checkout session created during this attach flow. Keys prefixed with 'autumn_' are reserved and will be stripped. (optional)
|
|
14912
14902
|
* @param noBillingChanges - If true, skips any billing changes for the attach operation. (optional)
|
|
14913
14903
|
* @param enablePlanImmediately - If true, the customer's plan is activated immediately even when payment is deferred (invoice mode) or pending (Stripe checkout). For Stripe checkout, the customer_product is inserted before the customer completes the hosted form. (optional)
|
|
14904
|
+
* @param taxRateId - Stripe tax rate ID (txr_...) to apply as the default tax rate on the created subscription, invoice, or checkout session line items. (optional)
|
|
14914
14905
|
*
|
|
14915
14906
|
* @returns A billing response with customer ID, invoice details, and payment URL (if checkout required).
|
|
14916
14907
|
*/
|
|
@@ -14929,7 +14920,7 @@ var Billing = class extends ClientSDK {
|
|
|
14929
14920
|
* @example
|
|
14930
14921
|
* ```typescript
|
|
14931
14922
|
* // Schedule a transition from a trial plan to a paid plan
|
|
14932
|
-
* const response = await client.billing.createSchedule({ customerId: "cus_123", phases: [{"startsAt":
|
|
14923
|
+
* const response = await client.billing.createSchedule({ customerId: "cus_123", phases: [{"startsAt":1779301422227,"plans":[{"planId":"trial_plan"}]},{"startsAt":1780511022227,"plans":[{"planId":"pro_plan"}]}] });
|
|
14933
14924
|
* ```
|
|
14934
14925
|
*
|
|
14935
14926
|
* @param customerId - The ID of the customer to create the schedule for.
|
|
@@ -15032,6 +15023,7 @@ var Billing = class extends ClientSDK {
|
|
|
15032
15023
|
* @param metadata - Key-value metadata to attach to the Stripe subscription, invoice, and checkout session created during this attach flow. Keys prefixed with 'autumn_' are reserved and will be stripped. (optional)
|
|
15033
15024
|
* @param noBillingChanges - If true, skips any billing changes for the attach operation. (optional)
|
|
15034
15025
|
* @param enablePlanImmediately - If true, the customer's plan is activated immediately even when payment is deferred (invoice mode) or pending (Stripe checkout). For Stripe checkout, the customer_product is inserted before the customer completes the hosted form. (optional)
|
|
15026
|
+
* @param taxRateId - Stripe tax rate ID (txr_...) to apply as the default tax rate on the created subscription, invoice, or checkout session line items. (optional)
|
|
15035
15027
|
*
|
|
15036
15028
|
* @returns A preview response with line items, totals, and effective dates for the proposed changes.
|
|
15037
15029
|
*/
|
|
@@ -15426,14 +15418,14 @@ function customersList(client, request, options) {
|
|
|
15426
15418
|
async function $do19(client, request, options) {
|
|
15427
15419
|
const parsed = safeParse(
|
|
15428
15420
|
request,
|
|
15429
|
-
(value) => z71.parse(
|
|
15421
|
+
(value) => z71.parse(ListCustomersParams$outboundSchema, value),
|
|
15430
15422
|
"Input validation failed"
|
|
15431
15423
|
);
|
|
15432
15424
|
if (!parsed.ok) {
|
|
15433
15425
|
return [parsed, { status: "invalid" }];
|
|
15434
15426
|
}
|
|
15435
15427
|
const payload = parsed.value;
|
|
15436
|
-
const body =
|
|
15428
|
+
const body = encodeJSON("body", payload, { explode: true });
|
|
15437
15429
|
const path = pathToFunc("/v1/customers.list")();
|
|
15438
15430
|
const headers = new Headers(compactMap({
|
|
15439
15431
|
"Content-Type": "application/json",
|
|
@@ -15631,7 +15623,7 @@ var Customers = class extends ClientSDK {
|
|
|
15631
15623
|
));
|
|
15632
15624
|
}
|
|
15633
15625
|
/**
|
|
15634
|
-
* Lists customers with pagination and optional filters.
|
|
15626
|
+
* Lists customers with cursor pagination and optional filters. Pass `start_cursor: ""` (or omit) for the first page; use `next_cursor` from a prior response for subsequent pages.
|
|
15635
15627
|
*/
|
|
15636
15628
|
async list(request, options) {
|
|
15637
15629
|
return unwrapAsync(customersList(
|
|
@@ -15908,14 +15900,14 @@ function entitiesList(client, request, options) {
|
|
|
15908
15900
|
async function $do24(client, request, options) {
|
|
15909
15901
|
const parsed = safeParse(
|
|
15910
15902
|
request,
|
|
15911
|
-
(value) => z76.parse(
|
|
15903
|
+
(value) => z76.parse(ListEntitiesParams$outboundSchema, value),
|
|
15912
15904
|
"Input validation failed"
|
|
15913
15905
|
);
|
|
15914
15906
|
if (!parsed.ok) {
|
|
15915
15907
|
return [parsed, { status: "invalid" }];
|
|
15916
15908
|
}
|
|
15917
15909
|
const payload = parsed.value;
|
|
15918
|
-
const body =
|
|
15910
|
+
const body = encodeJSON("body", payload, { explode: true });
|
|
15919
15911
|
const path = pathToFunc("/v1/entities.list")();
|
|
15920
15912
|
const headers = new Headers(compactMap({
|
|
15921
15913
|
"Content-Type": "application/json",
|
|
@@ -18088,7 +18080,8 @@ var attachParamsOutboundSchema = import_v42.z.object({
|
|
|
18088
18080
|
carry_over_usages: import_v42.z.union([attachCarryOverUsagesOutboundSchema, import_v42.z.undefined()]).optional(),
|
|
18089
18081
|
metadata: import_v42.z.union([import_v42.z.record(import_v42.z.string(), import_v42.z.string()), import_v42.z.undefined()]).optional(),
|
|
18090
18082
|
no_billing_changes: import_v42.z.union([import_v42.z.boolean(), import_v42.z.undefined()]).optional(),
|
|
18091
|
-
enable_plan_immediately: import_v42.z.union([import_v42.z.boolean(), import_v42.z.undefined()]).optional()
|
|
18083
|
+
enable_plan_immediately: import_v42.z.union([import_v42.z.boolean(), import_v42.z.undefined()]).optional(),
|
|
18084
|
+
tax_rate_id: import_v42.z.union([import_v42.z.string(), import_v42.z.undefined()]).optional()
|
|
18092
18085
|
});
|
|
18093
18086
|
var closedEnumSchema2 = import_v42.z.any();
|
|
18094
18087
|
var openEnumSchema = import_v42.z.any();
|
|
@@ -18228,7 +18221,8 @@ var attachParamsSchema = import_v42.z.object({
|
|
|
18228
18221
|
carryOverUsages: import_v42.z.union([attachCarryOverUsagesSchema, import_v42.z.undefined()]).optional(),
|
|
18229
18222
|
metadata: import_v42.z.union([import_v42.z.record(import_v42.z.string(), import_v42.z.string()), import_v42.z.undefined()]).optional(),
|
|
18230
18223
|
noBillingChanges: import_v42.z.union([import_v42.z.boolean(), import_v42.z.undefined()]).optional(),
|
|
18231
|
-
enablePlanImmediately: import_v42.z.union([import_v42.z.boolean(), import_v42.z.undefined()]).optional()
|
|
18224
|
+
enablePlanImmediately: import_v42.z.union([import_v42.z.boolean(), import_v42.z.undefined()]).optional(),
|
|
18225
|
+
taxRateId: import_v42.z.union([import_v42.z.string(), import_v42.z.undefined()]).optional()
|
|
18232
18226
|
});
|
|
18233
18227
|
var attachCodeSchema = openEnumSchema;
|
|
18234
18228
|
var attachRequiredActionSchema = import_v42.z.object({
|
|
@@ -18399,7 +18393,7 @@ var listEventsCustomRangeSchema = import_v45.z.object({
|
|
|
18399
18393
|
end: import_v45.z.union([import_v45.z.number(), import_v45.z.undefined()]).optional()
|
|
18400
18394
|
});
|
|
18401
18395
|
var eventsListParamsSchema = import_v45.z.object({
|
|
18402
|
-
|
|
18396
|
+
startCursor: import_v45.z.union([import_v45.z.string(), import_v45.z.undefined()]).optional(),
|
|
18403
18397
|
limit: import_v45.z.union([import_v45.z.number(), import_v45.z.undefined()]).optional(),
|
|
18404
18398
|
customerId: import_v45.z.union([import_v45.z.string(), import_v45.z.undefined()]).optional(),
|
|
18405
18399
|
entityId: import_v45.z.union([import_v45.z.string(), import_v45.z.undefined()]).optional(),
|
|
@@ -18415,7 +18409,7 @@ var listEventsCustomRangeOutboundSchema = import_v45.z.object({
|
|
|
18415
18409
|
end: import_v45.z.union([import_v45.z.number(), import_v45.z.undefined()]).optional()
|
|
18416
18410
|
});
|
|
18417
18411
|
var eventsListParamsOutboundSchema = import_v45.z.object({
|
|
18418
|
-
|
|
18412
|
+
start_cursor: import_v45.z.string(),
|
|
18419
18413
|
limit: import_v45.z.number(),
|
|
18420
18414
|
customer_id: import_v45.z.union([import_v45.z.string(), import_v45.z.undefined()]).optional(),
|
|
18421
18415
|
entity_id: import_v45.z.union([import_v45.z.string(), import_v45.z.undefined()]).optional(),
|
|
@@ -18451,10 +18445,7 @@ var listEventsListSchema = import_v45.z.object({
|
|
|
18451
18445
|
});
|
|
18452
18446
|
var listEventsResponseSchema = import_v45.z.object({
|
|
18453
18447
|
list: import_v45.z.array(listEventsListSchema),
|
|
18454
|
-
|
|
18455
|
-
offset: import_v45.z.number(),
|
|
18456
|
-
limit: import_v45.z.number(),
|
|
18457
|
-
total: import_v45.z.number()
|
|
18448
|
+
nextCursor: import_v45.z.string().nullable()
|
|
18458
18449
|
});
|
|
18459
18450
|
|
|
18460
18451
|
// src/generated/listPlansSchemas.ts
|
|
@@ -19151,7 +19142,8 @@ var previewAttachParamsOutboundSchema = import_v49.z.object({
|
|
|
19151
19142
|
carry_over_usages: import_v49.z.union([previewAttachCarryOverUsagesOutboundSchema, import_v49.z.undefined()]).optional(),
|
|
19152
19143
|
metadata: import_v49.z.union([import_v49.z.record(import_v49.z.string(), import_v49.z.string()), import_v49.z.undefined()]).optional(),
|
|
19153
19144
|
no_billing_changes: import_v49.z.union([import_v49.z.boolean(), import_v49.z.undefined()]).optional(),
|
|
19154
|
-
enable_plan_immediately: import_v49.z.union([import_v49.z.boolean(), import_v49.z.undefined()]).optional()
|
|
19145
|
+
enable_plan_immediately: import_v49.z.union([import_v49.z.boolean(), import_v49.z.undefined()]).optional(),
|
|
19146
|
+
tax_rate_id: import_v49.z.union([import_v49.z.string(), import_v49.z.undefined()]).optional()
|
|
19155
19147
|
});
|
|
19156
19148
|
var closedEnumSchema5 = import_v49.z.any();
|
|
19157
19149
|
var planSchema = import_v49.z.any();
|
|
@@ -19292,7 +19284,8 @@ var previewAttachParamsSchema = import_v49.z.object({
|
|
|
19292
19284
|
carryOverUsages: import_v49.z.union([previewAttachCarryOverUsagesSchema, import_v49.z.undefined()]).optional(),
|
|
19293
19285
|
metadata: import_v49.z.union([import_v49.z.record(import_v49.z.string(), import_v49.z.string()), import_v49.z.undefined()]).optional(),
|
|
19294
19286
|
noBillingChanges: import_v49.z.union([import_v49.z.boolean(), import_v49.z.undefined()]).optional(),
|
|
19295
|
-
enablePlanImmediately: import_v49.z.union([import_v49.z.boolean(), import_v49.z.undefined()]).optional()
|
|
19287
|
+
enablePlanImmediately: import_v49.z.union([import_v49.z.boolean(), import_v49.z.undefined()]).optional(),
|
|
19288
|
+
taxRateId: import_v49.z.union([import_v49.z.string(), import_v49.z.undefined()]).optional()
|
|
19296
19289
|
});
|
|
19297
19290
|
var previewAttachIncomingSchema = import_v49.z.object({
|
|
19298
19291
|
planId: import_v49.z.string(),
|
|
@@ -20347,7 +20340,8 @@ var setupPaymentParamsOutboundSchema = import_v413.z.object({
|
|
|
20347
20340
|
carry_over_usages: import_v413.z.union([setupPaymentCarryOverUsagesOutboundSchema, import_v413.z.undefined()]).optional(),
|
|
20348
20341
|
metadata: import_v413.z.union([import_v413.z.record(import_v413.z.string(), import_v413.z.string()), import_v413.z.undefined()]).optional(),
|
|
20349
20342
|
no_billing_changes: import_v413.z.union([import_v413.z.boolean(), import_v413.z.undefined()]).optional(),
|
|
20350
|
-
enable_plan_immediately: import_v413.z.union([import_v413.z.boolean(), import_v413.z.undefined()]).optional()
|
|
20343
|
+
enable_plan_immediately: import_v413.z.union([import_v413.z.boolean(), import_v413.z.undefined()]).optional(),
|
|
20344
|
+
tax_rate_id: import_v413.z.union([import_v413.z.string(), import_v413.z.undefined()]).optional()
|
|
20351
20345
|
});
|
|
20352
20346
|
var closedEnumSchema8 = import_v413.z.any();
|
|
20353
20347
|
var setupPaymentPriceIntervalSchema = closedEnumSchema8;
|
|
@@ -20480,7 +20474,8 @@ var setupPaymentParamsSchema = import_v413.z.object({
|
|
|
20480
20474
|
carryOverUsages: import_v413.z.union([setupPaymentCarryOverUsagesSchema, import_v413.z.undefined()]).optional(),
|
|
20481
20475
|
metadata: import_v413.z.union([import_v413.z.record(import_v413.z.string(), import_v413.z.string()), import_v413.z.undefined()]).optional(),
|
|
20482
20476
|
noBillingChanges: import_v413.z.union([import_v413.z.boolean(), import_v413.z.undefined()]).optional(),
|
|
20483
|
-
enablePlanImmediately: import_v413.z.union([import_v413.z.boolean(), import_v413.z.undefined()]).optional()
|
|
20477
|
+
enablePlanImmediately: import_v413.z.union([import_v413.z.boolean(), import_v413.z.undefined()]).optional(),
|
|
20478
|
+
taxRateId: import_v413.z.union([import_v413.z.string(), import_v413.z.undefined()]).optional()
|
|
20484
20479
|
});
|
|
20485
20480
|
|
|
20486
20481
|
// src/generated/updateSubscriptionSchemas.ts
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import {
|
|
2
2
|
autumnHandler
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-5LKGVXKH.mjs";
|
|
4
4
|
import "../chunk-WYDGEDEU.mjs";
|
|
5
5
|
import "../chunk-VXND2UDT.mjs";
|
|
6
|
-
import "../chunk-
|
|
7
|
-
import "../chunk-
|
|
8
|
-
import "../chunk-T4ZAR3BE.mjs";
|
|
9
|
-
import "../chunk-55C2WWXQ.mjs";
|
|
10
|
-
import "../chunk-TBQ27LIK.mjs";
|
|
11
|
-
import "../chunk-J44WR3QZ.mjs";
|
|
6
|
+
import "../chunk-VJT3K6DB.mjs";
|
|
7
|
+
import "../chunk-TFYNLI5B.mjs";
|
|
12
8
|
import "../chunk-TSF4YCUO.mjs";
|
|
13
9
|
import "../chunk-UAR3TMWI.mjs";
|
|
14
|
-
import "../chunk-
|
|
10
|
+
import "../chunk-H427PQAN.mjs";
|
|
11
|
+
import "../chunk-MAU6WWTL.mjs";
|
|
12
|
+
import "../chunk-S5HPMJ4U.mjs";
|
|
15
13
|
import "../chunk-OTXV5FY7.mjs";
|
|
16
|
-
import "../chunk-VZIMT7AO.mjs";
|
|
17
14
|
import "../chunk-Z6QP3YEA.mjs";
|
|
15
|
+
import "../chunk-VZIMT7AO.mjs";
|
|
16
|
+
import "../chunk-TBQ27LIK.mjs";
|
|
17
|
+
import "../chunk-J44WR3QZ.mjs";
|
|
18
18
|
import "../chunk-N7NFYY54.mjs";
|
|
19
19
|
export {
|
|
20
20
|
autumnHandler
|