autumn-js 0.0.114 → 0.0.116
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/README.md +1 -139
- package/dist/libraries/backend/better-auth.d.mts +18 -18
- package/dist/libraries/backend/better-auth.d.ts +18 -18
- package/dist/libraries/backend/better-auth.js +21 -1
- package/dist/libraries/backend/better-auth.mjs +7 -7
- package/dist/libraries/backend/{chunk-5W265EHC.mjs → chunk-BDMGQV75.mjs} +1 -1
- package/dist/libraries/backend/{chunk-AE3ATQW3.mjs → chunk-BX2LACTF.mjs} +1 -1
- package/dist/libraries/backend/{chunk-AHC5CF27.mjs → chunk-EIP7LDKF.mjs} +1 -1
- package/dist/libraries/backend/{chunk-QGTZAKB7.mjs → chunk-N4PGGU3D.mjs} +1 -1
- package/dist/libraries/backend/{chunk-JUTZHAHU.mjs → chunk-O6KXYXQN.mjs} +1 -1
- package/dist/libraries/backend/{chunk-SHE3OJIL.mjs → chunk-QGX7ZACH.mjs} +21 -1
- package/dist/libraries/backend/{chunk-YFHV4POF.mjs → chunk-WTKY2U3S.mjs} +6 -6
- package/dist/libraries/backend/convex.js +21 -1
- package/dist/libraries/backend/convex.mjs +7 -7
- package/dist/libraries/backend/elysia.js +21 -1
- package/dist/libraries/backend/elysia.mjs +7 -7
- package/dist/libraries/backend/express.d.mts +1 -1
- package/dist/libraries/backend/express.d.ts +1 -1
- package/dist/libraries/backend/express.js +21 -1
- package/dist/libraries/backend/express.mjs +7 -7
- package/dist/libraries/backend/fastify.js +21 -1
- package/dist/libraries/backend/fastify.mjs +7 -7
- package/dist/libraries/backend/hono.js +21 -1
- package/dist/libraries/backend/hono.mjs +7 -7
- package/dist/libraries/backend/index.d.mts +1 -1
- package/dist/libraries/backend/index.d.ts +1 -1
- package/dist/libraries/backend/index.js +21 -1
- package/dist/libraries/backend/index.mjs +7 -7
- package/dist/libraries/backend/next.js +21 -1
- package/dist/libraries/backend/next.mjs +7 -7
- package/dist/libraries/backend/react-router.js +21 -1
- package/dist/libraries/backend/react-router.mjs +7 -7
- package/dist/libraries/backend/{referralTypes-qMay-K9l.d.ts → referralTypes-DXhjwazw.d.ts} +109 -45
- package/dist/libraries/backend/{referralTypes-COVVwj-1.d.mts → referralTypes-Dxn4bOpT.d.mts} +109 -45
- package/dist/libraries/backend/remix_dep.js +21 -1
- package/dist/libraries/backend/remix_dep.mjs +7 -7
- package/dist/libraries/backend/routes/backendRouter.js +21 -1
- package/dist/libraries/backend/routes/backendRouter.mjs +7 -7
- package/dist/libraries/backend/routes/entityRoutes.js +21 -1
- package/dist/libraries/backend/routes/entityRoutes.mjs +3 -3
- package/dist/libraries/backend/routes/genRoutes.js +21 -1
- package/dist/libraries/backend/routes/genRoutes.mjs +3 -3
- package/dist/libraries/backend/routes/productRoutes.js +21 -1
- package/dist/libraries/backend/routes/productRoutes.mjs +3 -3
- package/dist/libraries/backend/routes/referralRoutes.js +21 -1
- package/dist/libraries/backend/routes/referralRoutes.mjs +3 -3
- package/dist/libraries/backend/supabase.js +21 -1
- package/dist/libraries/backend/supabase.mjs +7 -7
- package/dist/libraries/backend/tanstack.js +21 -1
- package/dist/libraries/backend/tanstack.mjs +7 -7
- package/dist/libraries/backend/utils/backendRes.js +21 -1
- package/dist/libraries/backend/utils/backendRes.mjs +1 -1
- package/dist/libraries/backend/utils/withAuth.d.mts +1 -1
- package/dist/libraries/backend/utils/withAuth.d.ts +1 -1
- package/dist/libraries/backend/utils/withAuth.js +21 -1
- package/dist/libraries/backend/utils/withAuth.mjs +2 -2
- package/dist/libraries/react/AutumnContext.d.mts +6 -6
- package/dist/libraries/react/AutumnContext.d.ts +6 -6
- package/dist/libraries/react/AutumnContext.js +21 -1
- package/dist/libraries/react/AutumnContext.mjs +3 -3
- package/dist/libraries/react/BaseAutumnProvider.d.mts +6 -6
- package/dist/libraries/react/BaseAutumnProvider.d.ts +6 -6
- package/dist/libraries/react/BaseAutumnProvider.js +21 -1
- package/dist/libraries/react/BaseAutumnProvider.mjs +8 -8
- package/dist/libraries/react/{ReactAutumnClient-BbbdQEOx.d.ts → ReactAutumnClient-5mFEwitR.d.ts} +11 -8
- package/dist/libraries/react/{ReactAutumnClient-BD8mQ965.d.mts → ReactAutumnClient-DooIpMm0.d.mts} +11 -8
- package/dist/libraries/react/ReactAutumnProvider.d.mts +2 -2
- package/dist/libraries/react/ReactAutumnProvider.d.ts +2 -2
- package/dist/libraries/react/ReactAutumnProvider.js +21 -1
- package/dist/libraries/react/ReactAutumnProvider.mjs +9 -9
- package/dist/libraries/react/{attachTypes-BfITg8QI.d.mts → attachTypes-By0coJIV.d.mts} +3 -3
- package/dist/{next/client/attachTypes-BPWwj1YK.d.ts → libraries/react/attachTypes-CSutLgVn.d.ts} +3 -3
- package/dist/libraries/react/{chunk-37PNTTHW.mjs → chunk-77DMPCGK.mjs} +35 -37
- package/dist/libraries/react/{chunk-5PA5P2UE.mjs → chunk-7RICWVXV.mjs} +2 -2
- package/dist/libraries/react/{chunk-62QDB3KQ.mjs → chunk-AXHU3KAH.mjs} +3 -3
- package/dist/libraries/react/{chunk-O6TAJHK3.mjs → chunk-BLM4DAAR.mjs} +3 -3
- package/dist/libraries/react/{chunk-3JORYFTY.mjs → chunk-CZBWEEWD.mjs} +21 -1
- package/dist/libraries/react/{chunk-CZVP6BZG.mjs → chunk-EXUNRZTP.mjs} +3 -3
- package/dist/libraries/react/{chunk-YEG5KJEI.mjs → chunk-H4J73SMR.mjs} +1 -1
- package/dist/libraries/react/{chunk-HBCCTYA6.mjs → chunk-I5ZGIAIX.mjs} +3 -3
- package/dist/libraries/react/{chunk-YDRULJZE.mjs → chunk-IFZCH7DR.mjs} +2 -2
- package/dist/libraries/react/{chunk-RGAEIODW.mjs → chunk-LFLX6NJU.mjs} +1 -1
- package/dist/libraries/react/{chunk-FOXUAY7Y.mjs → chunk-LMQMA7VL.mjs} +1 -1
- package/dist/libraries/react/{chunk-3UNBBJY5.mjs → chunk-MPA65MFU.mjs} +1 -1
- package/dist/libraries/react/{chunk-6R3O2T4H.mjs → chunk-MRZA4JWN.mjs} +1 -1
- package/dist/libraries/react/{chunk-PEYCQWHI.mjs → chunk-PFN52PHR.mjs} +2 -2
- package/dist/libraries/react/{chunk-CV4TKYAC.mjs → chunk-QJJC6MB3.mjs} +2 -2
- package/dist/libraries/react/{chunk-4Q7BDIOS.mjs → chunk-UAK4XMNC.mjs} +1 -1
- package/dist/libraries/react/{chunk-E2H5MYIO.mjs → chunk-UCUAGLCJ.mjs} +1 -1
- package/dist/libraries/react/{chunk-HBVLIBOE.mjs → chunk-WZG3QTZI.mjs} +3 -3
- package/dist/libraries/react/client/ReactAutumnClient.d.mts +6 -6
- package/dist/libraries/react/client/ReactAutumnClient.d.ts +6 -6
- package/dist/libraries/react/client/ReactAutumnClient.js +21 -1
- package/dist/libraries/react/client/ReactAutumnClient.mjs +2 -2
- package/dist/libraries/react/client/clientCompMethods.d.mts +6 -6
- package/dist/libraries/react/client/clientCompMethods.d.ts +6 -6
- package/dist/libraries/react/client/clientCusMethods.d.mts +6 -6
- package/dist/libraries/react/client/clientCusMethods.d.ts +6 -6
- package/dist/libraries/react/client/clientEntityMethods.d.mts +6 -6
- package/dist/libraries/react/client/clientEntityMethods.d.ts +6 -6
- package/dist/libraries/react/client/clientGenMethods.d.mts +6 -6
- package/dist/libraries/react/client/clientGenMethods.d.ts +6 -6
- package/dist/libraries/react/client/clientProdMethods.d.mts +6 -6
- package/dist/libraries/react/client/clientProdMethods.d.ts +6 -6
- package/dist/libraries/react/client/clientReferralMethods.d.mts +6 -6
- package/dist/libraries/react/client/clientReferralMethods.d.ts +6 -6
- package/dist/libraries/react/client/types/clientAttachTypes.d.mts +9 -0
- package/dist/libraries/react/client/types/clientAttachTypes.d.ts +9 -0
- package/dist/libraries/react/client/types/clientAttachTypes.js +4 -1
- package/dist/libraries/react/client/types/clientAttachTypes.mjs +4 -1
- package/dist/libraries/react/client/types/clientGenTypes.js +21 -1
- package/dist/libraries/react/client/types/clientGenTypes.mjs +1 -1
- package/dist/libraries/react/components/{attach-dialog/attach-dialog-synced.d.mts → checkout-dialog/checkout-dialog-synced.d.mts} +5 -5
- package/dist/libraries/react/components/{attach-dialog/attach-dialog-synced.d.ts → checkout-dialog/checkout-dialog-synced.d.ts} +5 -5
- package/dist/libraries/react/components/{attach-dialog/attach-dialog-synced.js → checkout-dialog/checkout-dialog-synced.js} +33 -13
- package/dist/libraries/react/components/{attach-dialog/attach-dialog-synced.mjs → checkout-dialog/checkout-dialog-synced.mjs} +27 -27
- package/dist/libraries/react/components/checkout-dialog/lib/checkout-content.d.mts +11 -0
- package/dist/libraries/react/components/checkout-dialog/lib/checkout-content.d.ts +11 -0
- package/dist/libraries/react/components/{attach-dialog/lib/attach-content.js → checkout-dialog/lib/checkout-content.js} +7 -7
- package/dist/libraries/react/components/checkout-dialog/lib/checkout-content.mjs +8 -0
- package/dist/libraries/react/components/paywall-dialog/lib/paywall-content.d.mts +9 -0
- package/dist/libraries/react/components/paywall-dialog/lib/paywall-content.d.ts +9 -0
- package/dist/libraries/react/components/{check-dialog/lib/check-content.js → paywall-dialog/lib/paywall-content.js} +7 -7
- package/dist/libraries/react/components/paywall-dialog/lib/paywall-content.mjs +8 -0
- package/dist/libraries/react/components/paywall-dialog/paywall-dialog-synced.d.mts +11 -0
- package/dist/libraries/react/components/paywall-dialog/paywall-dialog-synced.d.ts +11 -0
- package/dist/libraries/react/components/{check-dialog/check-dialog-synced.js → paywall-dialog/paywall-dialog-synced.js} +34 -14
- package/dist/libraries/react/components/{check-dialog/check-dialog-synced.mjs → paywall-dialog/paywall-dialog-synced.mjs} +27 -27
- package/dist/libraries/react/components/pricing-table/lib/pricing-table-content.d.mts +1 -1
- package/dist/libraries/react/components/pricing-table/lib/pricing-table-content.d.ts +1 -1
- package/dist/libraries/react/components/pricing-table/pricing-table-synced.d.mts +4 -4
- package/dist/libraries/react/components/pricing-table/pricing-table-synced.d.ts +4 -4
- package/dist/libraries/react/components/pricing-table/pricing-table-synced.js +30 -12
- package/dist/libraries/react/components/pricing-table/pricing-table-synced.mjs +25 -25
- package/dist/libraries/react/components/ui/dialog.mjs +2 -2
- package/dist/libraries/react/components/ui/popover.mjs +2 -2
- package/dist/libraries/react/{cusTypes-CMj2sP-4.d.ts → cusTypes-Bbmd8V3j.d.mts} +23 -5
- package/dist/libraries/react/{cusTypes-Dj2tcwg7.d.mts → cusTypes-d_DR9uFs.d.ts} +23 -5
- package/dist/libraries/react/{entTypes-Cltx_-C_.d.mts → entTypes-B2DgO6PV.d.mts} +1 -1
- package/dist/libraries/react/{entTypes-fYtiTl7W.d.ts → entTypes-D6eoGCKH.d.ts} +1 -1
- package/dist/libraries/react/{genTypes-A2nf2M_h.d.ts → genTypes-BNXXZTFn.d.ts} +5 -5
- package/dist/libraries/react/{genTypes-CH9EbOfb.d.mts → genTypes-C2VFQqmX.d.mts} +5 -5
- package/dist/libraries/react/hooks/helpers/handleCheck.d.mts +6 -6
- package/dist/libraries/react/hooks/helpers/handleCheck.d.ts +6 -6
- package/dist/libraries/react/hooks/helpers/handleCheck.js +21 -1
- package/dist/libraries/react/hooks/helpers/handleCheck.mjs +2 -2
- package/dist/libraries/react/hooks/helpers/useAutumnBase.d.mts +6 -6
- package/dist/libraries/react/hooks/helpers/useAutumnBase.d.ts +6 -6
- package/dist/libraries/react/hooks/helpers/useAutumnBase.js +21 -1
- package/dist/libraries/react/hooks/helpers/useAutumnBase.mjs +3 -3
- package/dist/libraries/react/hooks/useAnalytics.d.mts +2 -2
- package/dist/libraries/react/hooks/useAnalytics.d.ts +2 -2
- package/dist/libraries/react/hooks/useAnalytics.js +21 -1
- package/dist/libraries/react/hooks/useAnalytics.mjs +4 -4
- package/dist/libraries/react/hooks/useCustomer.d.mts +6 -6
- package/dist/libraries/react/hooks/useCustomer.d.ts +6 -6
- package/dist/libraries/react/hooks/useCustomer.js +21 -1
- package/dist/libraries/react/hooks/useCustomer.mjs +8 -8
- package/dist/libraries/react/hooks/useCustomerBase.d.mts +6 -6
- package/dist/libraries/react/hooks/useCustomerBase.d.ts +6 -6
- package/dist/libraries/react/hooks/useCustomerBase.js +21 -1
- package/dist/libraries/react/hooks/useCustomerBase.mjs +7 -7
- package/dist/libraries/react/hooks/useEntity.d.mts +6 -6
- package/dist/libraries/react/hooks/useEntity.d.ts +6 -6
- package/dist/libraries/react/hooks/useEntity.js +21 -1
- package/dist/libraries/react/hooks/useEntity.mjs +8 -8
- package/dist/libraries/react/hooks/useEntityBase.d.mts +8 -8
- package/dist/libraries/react/hooks/useEntityBase.d.ts +8 -8
- package/dist/libraries/react/hooks/useEntityBase.js +21 -1
- package/dist/libraries/react/hooks/useEntityBase.mjs +7 -7
- package/dist/libraries/react/hooks/usePaywall.d.mts +1 -1
- package/dist/libraries/react/hooks/usePaywall.d.ts +1 -1
- package/dist/libraries/react/hooks/usePaywall.js +21 -1
- package/dist/libraries/react/hooks/usePaywall.mjs +4 -4
- package/dist/libraries/react/hooks/usePricingTable.d.mts +1 -1
- package/dist/libraries/react/hooks/usePricingTable.d.ts +1 -1
- package/dist/libraries/react/hooks/usePricingTable.js +21 -1
- package/dist/libraries/react/hooks/usePricingTable.mjs +5 -5
- package/dist/libraries/react/hooks/usePricingTableBase.d.mts +6 -6
- package/dist/libraries/react/hooks/usePricingTableBase.d.ts +6 -6
- package/dist/libraries/react/hooks/usePricingTableBase.js +21 -1
- package/dist/libraries/react/hooks/usePricingTableBase.mjs +2 -2
- package/dist/libraries/react/hooks/useProductsBase.d.mts +6 -6
- package/dist/libraries/react/hooks/useProductsBase.d.ts +6 -6
- package/dist/libraries/react/index.d.mts +51 -6
- package/dist/libraries/react/index.d.ts +51 -6
- package/dist/libraries/react/index.js +38 -20
- package/dist/libraries/react/index.mjs +36 -18
- package/dist/libraries/react/{prodTypes-DZUJPsRN.d.mts → prodTypes-B3iWy6kz.d.mts} +21 -3
- package/dist/libraries/react/{prodTypes-DZUJPsRN.d.ts → prodTypes-B3iWy6kz.d.ts} +21 -3
- package/dist/next/client/NextAutumnClient.d.mts +22 -19
- package/dist/next/client/NextAutumnClient.d.ts +22 -19
- package/dist/next/client/NextAutumnProvider.d.mts +2 -2
- package/dist/next/client/NextAutumnProvider.d.ts +2 -2
- package/dist/{libraries/react/attachTypes-ZMWuxpzI.d.ts → next/client/attachTypes-BCt7D8ym.d.ts} +5 -5
- package/dist/next/client/{attachTypes-C67U2LbK.d.mts → attachTypes-BThbMcvF.d.mts} +9 -9
- package/dist/next/client/{clientAttachTypes-B4i2ri-1.d.ts → clientAttachTypes-Df5FVGkw.d.ts} +36 -27
- package/dist/next/client/{clientAttachTypes-EGitteWV.d.mts → clientAttachTypes-whHUVrE3.d.mts} +36 -27
- package/dist/next/client/clientUtils.d.mts +3 -3
- package/dist/next/client/clientUtils.d.ts +3 -3
- package/dist/next/client/{cusTypes-Dn0ETI7G.d.ts → cusTypes-BuLw67IH.d.mts} +23 -5
- package/dist/next/client/{cusTypes-CRJanGZd.d.mts → cusTypes-CqAsUZEp.d.ts} +23 -5
- package/dist/next/client/{entTypes-Caov3CJ9.d.ts → entTypes-BLLymqnn.d.ts} +1 -1
- package/dist/next/client/{entTypes-Qyo2WYGP.d.mts → entTypes-DTRFxh07.d.mts} +1 -1
- package/dist/next/client/hooks/useAutumn.d.mts +4 -4
- package/dist/next/client/hooks/useAutumn.d.ts +4 -4
- package/dist/next/client/hooks/useCustomer.d.mts +5 -5
- package/dist/next/client/hooks/useCustomer.d.ts +5 -5
- package/dist/next/client/hooks/useEntity.d.mts +6 -6
- package/dist/next/client/hooks/useEntity.d.ts +6 -6
- package/dist/next/client/hooks/usePricingTable.d.mts +1 -1
- package/dist/next/client/hooks/usePricingTable.d.ts +1 -1
- package/dist/next/client/{prodTypes-si707oHg.d.mts → prodTypes-UFM-PYm-.d.mts} +22 -4
- package/dist/next/client/{prodTypes-si707oHg.d.ts → prodTypes-UFM-PYm-.d.ts} +22 -4
- package/dist/next/client/types.d.mts +3 -3
- package/dist/next/client/types.d.ts +3 -3
- package/dist/next/server/auth/withNextAuth.d.mts +1 -1
- package/dist/next/server/auth/withNextAuth.d.ts +1 -1
- package/dist/next/server/componentActions.d.mts +1 -1
- package/dist/next/server/componentActions.d.ts +1 -1
- package/dist/next/server/cusActions.d.mts +39 -11
- package/dist/next/server/cusActions.d.ts +39 -11
- package/dist/next/server/{cusTypes-wfx--BDG.d.ts → cusTypes-MnneoF1F.d.mts} +36 -0
- package/dist/next/server/{cusTypes-wfx--BDG.d.mts → cusTypes-MnneoF1F.d.ts} +36 -0
- package/dist/next/server/genActions.d.mts +1 -1
- package/dist/next/server/genActions.d.ts +1 -1
- package/dist/sdk/index.d.mts +75 -11
- package/dist/sdk/index.d.ts +75 -11
- package/dist/sdk/index.js +22 -1
- package/dist/sdk/index.mjs +22 -2
- package/dist/utils/encryptUtils.js +21 -1
- package/dist/utils/encryptUtils.mjs +21 -1
- package/package.json +1 -1
- package/dist/libraries/react/components/attach-dialog/lib/attach-content.d.mts +0 -11
- package/dist/libraries/react/components/attach-dialog/lib/attach-content.d.ts +0 -11
- package/dist/libraries/react/components/attach-dialog/lib/attach-content.mjs +0 -8
- package/dist/libraries/react/components/check-dialog/check-dialog-synced.d.mts +0 -11
- package/dist/libraries/react/components/check-dialog/check-dialog-synced.d.ts +0 -11
- package/dist/libraries/react/components/check-dialog/lib/check-content.d.mts +0 -9
- package/dist/libraries/react/components/check-dialog/lib/check-content.d.ts +0 -9
- package/dist/libraries/react/components/check-dialog/lib/check-content.mjs +0 -8
- package/dist/libraries/react/{chunk-7JNU5ABT.mjs → chunk-FJWZPMWU.mjs} +3 -3
- package/dist/libraries/react/{chunk-LCWL3TIT.mjs → chunk-OTZ65PCT.mjs} +3 -3
- /package/dist/libraries/react/components/{attach-dialog/attach-dialog-synced.css → checkout-dialog/checkout-dialog-synced.css} +0 -0
- /package/dist/libraries/react/components/{check-dialog/check-dialog-synced.css → paywall-dialog/paywall-dialog-synced.css} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { C as CustomerData, a as Customer } from './cusTypes-
|
|
2
|
-
import { E as Entity } from './entTypes-
|
|
3
|
-
import './prodTypes-
|
|
1
|
+
import { C as CustomerData, a as Customer } from './cusTypes-BuLw67IH.mjs';
|
|
2
|
+
import { E as Entity } from './entTypes-DTRFxh07.mjs';
|
|
3
|
+
import './prodTypes-UFM-PYm-.mjs';
|
|
4
4
|
import 'zod';
|
|
5
5
|
|
|
6
6
|
interface ProductDetails {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { C as CustomerData, a as Customer } from './cusTypes-
|
|
2
|
-
import { E as Entity } from './entTypes-
|
|
3
|
-
import './prodTypes-
|
|
1
|
+
import { C as CustomerData, a as Customer } from './cusTypes-CqAsUZEp.js';
|
|
2
|
+
import { E as Entity } from './entTypes-BLLymqnn.js';
|
|
3
|
+
import './prodTypes-UFM-PYm-.js';
|
|
4
4
|
import 'zod';
|
|
5
5
|
|
|
6
6
|
interface ProductDetails {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as CustomerData, a as CheckFeatureResult, b as CheckProductResult, P as ProductItem, c as Product, G as GetCustomerParams, d as Customer, e as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, f as BillingPortalResult, g as CreateProductParams, L as ListProductsParams, h as CustomerProduct, i as CustomerFeature, j as CustomerInvoice } from './cusTypes-
|
|
1
|
+
import { C as CustomerData, a as CheckFeatureResult, b as CheckProductResult, P as ProductItem, c as Product, G as GetCustomerParams, d as Customer, e as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, f as BillingPortalResult, g as CreateProductParams, L as ListProductsParams, h as CustomerProduct, i as CustomerFeature, j as CustomerInvoice } from './cusTypes-MnneoF1F.mjs';
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { R as Result, A as AutumnError } from './response-eH4S4sg0.mjs';
|
|
4
4
|
|
|
@@ -232,6 +232,16 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
232
232
|
customer_id: z.ZodString;
|
|
233
233
|
product_id: z.ZodString;
|
|
234
234
|
entity_id: z.ZodOptional<z.ZodString>;
|
|
235
|
+
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
236
|
+
feature_id: z.ZodString;
|
|
237
|
+
quantity: z.ZodNumber;
|
|
238
|
+
}, "strip", z.ZodTypeAny, {
|
|
239
|
+
feature_id: string;
|
|
240
|
+
quantity: number;
|
|
241
|
+
}, {
|
|
242
|
+
feature_id: string;
|
|
243
|
+
quantity: number;
|
|
244
|
+
}>, "many">>;
|
|
235
245
|
success_url: z.ZodOptional<z.ZodString>;
|
|
236
246
|
customer_data: z.ZodOptional<z.ZodObject<{
|
|
237
247
|
name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -246,16 +256,9 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
246
256
|
email?: string | null | undefined;
|
|
247
257
|
fingerprint?: string | null | undefined;
|
|
248
258
|
}>>;
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
}, "strip", z.ZodTypeAny, {
|
|
253
|
-
feature_id: string;
|
|
254
|
-
quantity: number;
|
|
255
|
-
}, {
|
|
256
|
-
feature_id: string;
|
|
257
|
-
quantity: number;
|
|
258
|
-
}>, "many">>;
|
|
259
|
+
entity_data: z.ZodOptional<z.ZodAny>;
|
|
260
|
+
checkout_session_params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
|
|
261
|
+
reward: z.ZodOptional<z.ZodString>;
|
|
259
262
|
}, "strip", z.ZodTypeAny, {
|
|
260
263
|
customer_id: string;
|
|
261
264
|
product_id: string;
|
|
@@ -270,6 +273,9 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
270
273
|
email?: string | null | undefined;
|
|
271
274
|
fingerprint?: string | null | undefined;
|
|
272
275
|
} | undefined;
|
|
276
|
+
entity_data?: any;
|
|
277
|
+
checkout_session_params?: Record<string, any> | undefined;
|
|
278
|
+
reward?: string | undefined;
|
|
273
279
|
}, {
|
|
274
280
|
customer_id: string;
|
|
275
281
|
product_id: string;
|
|
@@ -284,6 +290,9 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
284
290
|
email?: string | null | undefined;
|
|
285
291
|
fingerprint?: string | null | undefined;
|
|
286
292
|
} | undefined;
|
|
293
|
+
entity_data?: any;
|
|
294
|
+
checkout_session_params?: Record<string, any> | undefined;
|
|
295
|
+
reward?: string | undefined;
|
|
287
296
|
}>;
|
|
288
297
|
type CheckoutParams = z.infer<typeof CheckoutParamsSchema>;
|
|
289
298
|
type CheckoutResult = {
|
|
@@ -340,6 +349,7 @@ declare class Autumn {
|
|
|
340
349
|
static entities: {
|
|
341
350
|
get: (customer_id: string, entity_id: string, params?: GetEntityParams$1) => Promise<Result<Entity, AutumnError>>;
|
|
342
351
|
create: (customer_id: string, params?: CreateEntityParams$1 | CreateEntityParams$1[]) => Promise<Result<CreateEntityResult, AutumnError>>;
|
|
352
|
+
transfer: (customer_id: string, params: TransferProductParams) => Promise<Result<TransferProductResult, AutumnError>>;
|
|
343
353
|
delete: (customer_id: string, entity_id: string) => Promise<Result<DeleteEntityResult, AutumnError>>;
|
|
344
354
|
};
|
|
345
355
|
static referrals: {
|
|
@@ -363,6 +373,7 @@ declare class Autumn {
|
|
|
363
373
|
entities: {
|
|
364
374
|
get: (customer_id: string, entity_id: string, params?: GetEntityParams$1) => Promise<Result<Entity, AutumnError>>;
|
|
365
375
|
create: (customer_id: string, params?: CreateEntityParams$1 | CreateEntityParams$1[]) => Promise<Result<CreateEntityResult, AutumnError>>;
|
|
376
|
+
transfer: (customer_id: string, params: TransferProductParams) => Promise<Result<TransferProductResult, AutumnError>>;
|
|
366
377
|
delete: (customer_id: string, entity_id: string) => Promise<Result<DeleteEntityResult, AutumnError>>;
|
|
367
378
|
};
|
|
368
379
|
referrals: {
|
|
@@ -448,6 +459,23 @@ interface Entity {
|
|
|
448
459
|
features: Record<string, CustomerFeature>;
|
|
449
460
|
invoices?: CustomerInvoice[];
|
|
450
461
|
}
|
|
462
|
+
declare const TransferProductParamsSchema: z.ZodObject<{
|
|
463
|
+
from_entity_id: z.ZodString;
|
|
464
|
+
to_entity_id: z.ZodString;
|
|
465
|
+
product_id: z.ZodString;
|
|
466
|
+
}, "strip", z.ZodTypeAny, {
|
|
467
|
+
product_id: string;
|
|
468
|
+
from_entity_id: string;
|
|
469
|
+
to_entity_id: string;
|
|
470
|
+
}, {
|
|
471
|
+
product_id: string;
|
|
472
|
+
from_entity_id: string;
|
|
473
|
+
to_entity_id: string;
|
|
474
|
+
}>;
|
|
475
|
+
type TransferProductParams = z.infer<typeof TransferProductParamsSchema>;
|
|
476
|
+
type TransferProductResult = {
|
|
477
|
+
success: boolean;
|
|
478
|
+
};
|
|
451
479
|
|
|
452
480
|
declare const CreateReferralCodeParamsSchema: z.ZodObject<{
|
|
453
481
|
customer_id: z.ZodString;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as CustomerData, a as CheckFeatureResult, b as CheckProductResult, P as ProductItem, c as Product, G as GetCustomerParams, d as Customer, e as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, f as BillingPortalResult, g as CreateProductParams, L as ListProductsParams, h as CustomerProduct, i as CustomerFeature, j as CustomerInvoice } from './cusTypes-
|
|
1
|
+
import { C as CustomerData, a as CheckFeatureResult, b as CheckProductResult, P as ProductItem, c as Product, G as GetCustomerParams, d as Customer, e as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, f as BillingPortalResult, g as CreateProductParams, L as ListProductsParams, h as CustomerProduct, i as CustomerFeature, j as CustomerInvoice } from './cusTypes-MnneoF1F.js';
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { R as Result, A as AutumnError } from './response-eH4S4sg0.js';
|
|
4
4
|
|
|
@@ -232,6 +232,16 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
232
232
|
customer_id: z.ZodString;
|
|
233
233
|
product_id: z.ZodString;
|
|
234
234
|
entity_id: z.ZodOptional<z.ZodString>;
|
|
235
|
+
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
236
|
+
feature_id: z.ZodString;
|
|
237
|
+
quantity: z.ZodNumber;
|
|
238
|
+
}, "strip", z.ZodTypeAny, {
|
|
239
|
+
feature_id: string;
|
|
240
|
+
quantity: number;
|
|
241
|
+
}, {
|
|
242
|
+
feature_id: string;
|
|
243
|
+
quantity: number;
|
|
244
|
+
}>, "many">>;
|
|
235
245
|
success_url: z.ZodOptional<z.ZodString>;
|
|
236
246
|
customer_data: z.ZodOptional<z.ZodObject<{
|
|
237
247
|
name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -246,16 +256,9 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
246
256
|
email?: string | null | undefined;
|
|
247
257
|
fingerprint?: string | null | undefined;
|
|
248
258
|
}>>;
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
}, "strip", z.ZodTypeAny, {
|
|
253
|
-
feature_id: string;
|
|
254
|
-
quantity: number;
|
|
255
|
-
}, {
|
|
256
|
-
feature_id: string;
|
|
257
|
-
quantity: number;
|
|
258
|
-
}>, "many">>;
|
|
259
|
+
entity_data: z.ZodOptional<z.ZodAny>;
|
|
260
|
+
checkout_session_params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
|
|
261
|
+
reward: z.ZodOptional<z.ZodString>;
|
|
259
262
|
}, "strip", z.ZodTypeAny, {
|
|
260
263
|
customer_id: string;
|
|
261
264
|
product_id: string;
|
|
@@ -270,6 +273,9 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
270
273
|
email?: string | null | undefined;
|
|
271
274
|
fingerprint?: string | null | undefined;
|
|
272
275
|
} | undefined;
|
|
276
|
+
entity_data?: any;
|
|
277
|
+
checkout_session_params?: Record<string, any> | undefined;
|
|
278
|
+
reward?: string | undefined;
|
|
273
279
|
}, {
|
|
274
280
|
customer_id: string;
|
|
275
281
|
product_id: string;
|
|
@@ -284,6 +290,9 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
284
290
|
email?: string | null | undefined;
|
|
285
291
|
fingerprint?: string | null | undefined;
|
|
286
292
|
} | undefined;
|
|
293
|
+
entity_data?: any;
|
|
294
|
+
checkout_session_params?: Record<string, any> | undefined;
|
|
295
|
+
reward?: string | undefined;
|
|
287
296
|
}>;
|
|
288
297
|
type CheckoutParams = z.infer<typeof CheckoutParamsSchema>;
|
|
289
298
|
type CheckoutResult = {
|
|
@@ -340,6 +349,7 @@ declare class Autumn {
|
|
|
340
349
|
static entities: {
|
|
341
350
|
get: (customer_id: string, entity_id: string, params?: GetEntityParams$1) => Promise<Result<Entity, AutumnError>>;
|
|
342
351
|
create: (customer_id: string, params?: CreateEntityParams$1 | CreateEntityParams$1[]) => Promise<Result<CreateEntityResult, AutumnError>>;
|
|
352
|
+
transfer: (customer_id: string, params: TransferProductParams) => Promise<Result<TransferProductResult, AutumnError>>;
|
|
343
353
|
delete: (customer_id: string, entity_id: string) => Promise<Result<DeleteEntityResult, AutumnError>>;
|
|
344
354
|
};
|
|
345
355
|
static referrals: {
|
|
@@ -363,6 +373,7 @@ declare class Autumn {
|
|
|
363
373
|
entities: {
|
|
364
374
|
get: (customer_id: string, entity_id: string, params?: GetEntityParams$1) => Promise<Result<Entity, AutumnError>>;
|
|
365
375
|
create: (customer_id: string, params?: CreateEntityParams$1 | CreateEntityParams$1[]) => Promise<Result<CreateEntityResult, AutumnError>>;
|
|
376
|
+
transfer: (customer_id: string, params: TransferProductParams) => Promise<Result<TransferProductResult, AutumnError>>;
|
|
366
377
|
delete: (customer_id: string, entity_id: string) => Promise<Result<DeleteEntityResult, AutumnError>>;
|
|
367
378
|
};
|
|
368
379
|
referrals: {
|
|
@@ -448,6 +459,23 @@ interface Entity {
|
|
|
448
459
|
features: Record<string, CustomerFeature>;
|
|
449
460
|
invoices?: CustomerInvoice[];
|
|
450
461
|
}
|
|
462
|
+
declare const TransferProductParamsSchema: z.ZodObject<{
|
|
463
|
+
from_entity_id: z.ZodString;
|
|
464
|
+
to_entity_id: z.ZodString;
|
|
465
|
+
product_id: z.ZodString;
|
|
466
|
+
}, "strip", z.ZodTypeAny, {
|
|
467
|
+
product_id: string;
|
|
468
|
+
from_entity_id: string;
|
|
469
|
+
to_entity_id: string;
|
|
470
|
+
}, {
|
|
471
|
+
product_id: string;
|
|
472
|
+
from_entity_id: string;
|
|
473
|
+
to_entity_id: string;
|
|
474
|
+
}>;
|
|
475
|
+
type TransferProductParams = z.infer<typeof TransferProductParamsSchema>;
|
|
476
|
+
type TransferProductResult = {
|
|
477
|
+
success: boolean;
|
|
478
|
+
};
|
|
451
479
|
|
|
452
480
|
declare const CreateReferralCodeParamsSchema: z.ZodObject<{
|
|
453
481
|
customer_id: z.ZodString;
|
|
@@ -37,6 +37,16 @@ declare const CheckFeatureResultSchema: z.ZodObject<{
|
|
|
37
37
|
next_reset_at: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
38
38
|
overage_allowed: z.ZodOptional<z.ZodBoolean>;
|
|
39
39
|
usage_limit: z.ZodOptional<z.ZodNumber>;
|
|
40
|
+
rollovers: z.ZodOptional<z.ZodObject<{
|
|
41
|
+
balance: z.ZodNumber;
|
|
42
|
+
expires_at: z.ZodNumber;
|
|
43
|
+
}, "strip", z.ZodTypeAny, {
|
|
44
|
+
balance: number;
|
|
45
|
+
expires_at: number;
|
|
46
|
+
}, {
|
|
47
|
+
balance: number;
|
|
48
|
+
expires_at: number;
|
|
49
|
+
}>>;
|
|
40
50
|
breakdown: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
41
51
|
interval: z.ZodNativeEnum<typeof ProductItemInterval>;
|
|
42
52
|
balance: z.ZodOptional<z.ZodNumber>;
|
|
@@ -80,6 +90,10 @@ declare const CheckFeatureResultSchema: z.ZodObject<{
|
|
|
80
90
|
included_usage?: number | undefined;
|
|
81
91
|
next_reset_at?: number | null | undefined;
|
|
82
92
|
overage_allowed?: boolean | undefined;
|
|
93
|
+
rollovers?: {
|
|
94
|
+
balance: number;
|
|
95
|
+
expires_at: number;
|
|
96
|
+
} | undefined;
|
|
83
97
|
breakdown?: {
|
|
84
98
|
interval: ProductItemInterval;
|
|
85
99
|
balance?: number | undefined;
|
|
@@ -105,6 +119,10 @@ declare const CheckFeatureResultSchema: z.ZodObject<{
|
|
|
105
119
|
included_usage?: number | undefined;
|
|
106
120
|
next_reset_at?: number | null | undefined;
|
|
107
121
|
overage_allowed?: boolean | undefined;
|
|
122
|
+
rollovers?: {
|
|
123
|
+
balance: number;
|
|
124
|
+
expires_at: number;
|
|
125
|
+
} | undefined;
|
|
108
126
|
breakdown?: {
|
|
109
127
|
interval: ProductItemInterval;
|
|
110
128
|
balance?: number | undefined;
|
|
@@ -253,6 +271,16 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
|
|
|
253
271
|
next_reset_at: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
254
272
|
overage_allowed: z.ZodOptional<z.ZodBoolean>;
|
|
255
273
|
usage_limit: z.ZodOptional<z.ZodNumber>;
|
|
274
|
+
rollovers: z.ZodOptional<z.ZodObject<{
|
|
275
|
+
balance: z.ZodNumber;
|
|
276
|
+
expires_at: z.ZodNumber;
|
|
277
|
+
}, "strip", z.ZodTypeAny, {
|
|
278
|
+
balance: number;
|
|
279
|
+
expires_at: number;
|
|
280
|
+
}, {
|
|
281
|
+
balance: number;
|
|
282
|
+
expires_at: number;
|
|
283
|
+
}>>;
|
|
256
284
|
breakdown: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
257
285
|
interval: z.ZodNativeEnum<typeof ProductItemInterval>;
|
|
258
286
|
balance: z.ZodOptional<z.ZodNumber>;
|
|
@@ -291,6 +319,10 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
|
|
|
291
319
|
included_usage?: number | undefined;
|
|
292
320
|
next_reset_at?: number | null | undefined;
|
|
293
321
|
overage_allowed?: boolean | undefined;
|
|
322
|
+
rollovers?: {
|
|
323
|
+
balance: number;
|
|
324
|
+
expires_at: number;
|
|
325
|
+
} | undefined;
|
|
294
326
|
breakdown?: {
|
|
295
327
|
interval: ProductItemInterval;
|
|
296
328
|
balance?: number | undefined;
|
|
@@ -311,6 +343,10 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
|
|
|
311
343
|
included_usage?: number | undefined;
|
|
312
344
|
next_reset_at?: number | null | undefined;
|
|
313
345
|
overage_allowed?: boolean | undefined;
|
|
346
|
+
rollovers?: {
|
|
347
|
+
balance: number;
|
|
348
|
+
expires_at: number;
|
|
349
|
+
} | undefined;
|
|
314
350
|
breakdown?: {
|
|
315
351
|
interval: ProductItemInterval;
|
|
316
352
|
balance?: number | undefined;
|
|
@@ -37,6 +37,16 @@ declare const CheckFeatureResultSchema: z.ZodObject<{
|
|
|
37
37
|
next_reset_at: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
38
38
|
overage_allowed: z.ZodOptional<z.ZodBoolean>;
|
|
39
39
|
usage_limit: z.ZodOptional<z.ZodNumber>;
|
|
40
|
+
rollovers: z.ZodOptional<z.ZodObject<{
|
|
41
|
+
balance: z.ZodNumber;
|
|
42
|
+
expires_at: z.ZodNumber;
|
|
43
|
+
}, "strip", z.ZodTypeAny, {
|
|
44
|
+
balance: number;
|
|
45
|
+
expires_at: number;
|
|
46
|
+
}, {
|
|
47
|
+
balance: number;
|
|
48
|
+
expires_at: number;
|
|
49
|
+
}>>;
|
|
40
50
|
breakdown: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
41
51
|
interval: z.ZodNativeEnum<typeof ProductItemInterval>;
|
|
42
52
|
balance: z.ZodOptional<z.ZodNumber>;
|
|
@@ -80,6 +90,10 @@ declare const CheckFeatureResultSchema: z.ZodObject<{
|
|
|
80
90
|
included_usage?: number | undefined;
|
|
81
91
|
next_reset_at?: number | null | undefined;
|
|
82
92
|
overage_allowed?: boolean | undefined;
|
|
93
|
+
rollovers?: {
|
|
94
|
+
balance: number;
|
|
95
|
+
expires_at: number;
|
|
96
|
+
} | undefined;
|
|
83
97
|
breakdown?: {
|
|
84
98
|
interval: ProductItemInterval;
|
|
85
99
|
balance?: number | undefined;
|
|
@@ -105,6 +119,10 @@ declare const CheckFeatureResultSchema: z.ZodObject<{
|
|
|
105
119
|
included_usage?: number | undefined;
|
|
106
120
|
next_reset_at?: number | null | undefined;
|
|
107
121
|
overage_allowed?: boolean | undefined;
|
|
122
|
+
rollovers?: {
|
|
123
|
+
balance: number;
|
|
124
|
+
expires_at: number;
|
|
125
|
+
} | undefined;
|
|
108
126
|
breakdown?: {
|
|
109
127
|
interval: ProductItemInterval;
|
|
110
128
|
balance?: number | undefined;
|
|
@@ -253,6 +271,16 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
|
|
|
253
271
|
next_reset_at: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
254
272
|
overage_allowed: z.ZodOptional<z.ZodBoolean>;
|
|
255
273
|
usage_limit: z.ZodOptional<z.ZodNumber>;
|
|
274
|
+
rollovers: z.ZodOptional<z.ZodObject<{
|
|
275
|
+
balance: z.ZodNumber;
|
|
276
|
+
expires_at: z.ZodNumber;
|
|
277
|
+
}, "strip", z.ZodTypeAny, {
|
|
278
|
+
balance: number;
|
|
279
|
+
expires_at: number;
|
|
280
|
+
}, {
|
|
281
|
+
balance: number;
|
|
282
|
+
expires_at: number;
|
|
283
|
+
}>>;
|
|
256
284
|
breakdown: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
257
285
|
interval: z.ZodNativeEnum<typeof ProductItemInterval>;
|
|
258
286
|
balance: z.ZodOptional<z.ZodNumber>;
|
|
@@ -291,6 +319,10 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
|
|
|
291
319
|
included_usage?: number | undefined;
|
|
292
320
|
next_reset_at?: number | null | undefined;
|
|
293
321
|
overage_allowed?: boolean | undefined;
|
|
322
|
+
rollovers?: {
|
|
323
|
+
balance: number;
|
|
324
|
+
expires_at: number;
|
|
325
|
+
} | undefined;
|
|
294
326
|
breakdown?: {
|
|
295
327
|
interval: ProductItemInterval;
|
|
296
328
|
balance?: number | undefined;
|
|
@@ -311,6 +343,10 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
|
|
|
311
343
|
included_usage?: number | undefined;
|
|
312
344
|
next_reset_at?: number | null | undefined;
|
|
313
345
|
overage_allowed?: boolean | undefined;
|
|
346
|
+
rollovers?: {
|
|
347
|
+
balance: number;
|
|
348
|
+
expires_at: number;
|
|
349
|
+
} | undefined;
|
|
314
350
|
breakdown?: {
|
|
315
351
|
interval: ProductItemInterval;
|
|
316
352
|
balance?: number | undefined;
|
package/dist/sdk/index.d.mts
CHANGED
|
@@ -54,6 +54,16 @@ declare const CheckFeatureResultSchema: z.ZodObject<{
|
|
|
54
54
|
next_reset_at: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
55
55
|
overage_allowed: z.ZodOptional<z.ZodBoolean>;
|
|
56
56
|
usage_limit: z.ZodOptional<z.ZodNumber>;
|
|
57
|
+
rollovers: z.ZodOptional<z.ZodObject<{
|
|
58
|
+
balance: z.ZodNumber;
|
|
59
|
+
expires_at: z.ZodNumber;
|
|
60
|
+
}, "strip", z.ZodTypeAny, {
|
|
61
|
+
balance: number;
|
|
62
|
+
expires_at: number;
|
|
63
|
+
}, {
|
|
64
|
+
balance: number;
|
|
65
|
+
expires_at: number;
|
|
66
|
+
}>>;
|
|
57
67
|
breakdown: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
58
68
|
interval: z.ZodNativeEnum<typeof ProductItemInterval>;
|
|
59
69
|
balance: z.ZodOptional<z.ZodNumber>;
|
|
@@ -97,6 +107,10 @@ declare const CheckFeatureResultSchema: z.ZodObject<{
|
|
|
97
107
|
included_usage?: number | undefined;
|
|
98
108
|
next_reset_at?: number | null | undefined;
|
|
99
109
|
overage_allowed?: boolean | undefined;
|
|
110
|
+
rollovers?: {
|
|
111
|
+
balance: number;
|
|
112
|
+
expires_at: number;
|
|
113
|
+
} | undefined;
|
|
100
114
|
breakdown?: {
|
|
101
115
|
interval: ProductItemInterval;
|
|
102
116
|
balance?: number | undefined;
|
|
@@ -122,6 +136,10 @@ declare const CheckFeatureResultSchema: z.ZodObject<{
|
|
|
122
136
|
included_usage?: number | undefined;
|
|
123
137
|
next_reset_at?: number | null | undefined;
|
|
124
138
|
overage_allowed?: boolean | undefined;
|
|
139
|
+
rollovers?: {
|
|
140
|
+
balance: number;
|
|
141
|
+
expires_at: number;
|
|
142
|
+
} | undefined;
|
|
125
143
|
breakdown?: {
|
|
126
144
|
interval: ProductItemInterval;
|
|
127
145
|
balance?: number | undefined;
|
|
@@ -283,6 +301,16 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
|
|
|
283
301
|
next_reset_at: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
284
302
|
overage_allowed: z.ZodOptional<z.ZodBoolean>;
|
|
285
303
|
usage_limit: z.ZodOptional<z.ZodNumber>;
|
|
304
|
+
rollovers: z.ZodOptional<z.ZodObject<{
|
|
305
|
+
balance: z.ZodNumber;
|
|
306
|
+
expires_at: z.ZodNumber;
|
|
307
|
+
}, "strip", z.ZodTypeAny, {
|
|
308
|
+
balance: number;
|
|
309
|
+
expires_at: number;
|
|
310
|
+
}, {
|
|
311
|
+
balance: number;
|
|
312
|
+
expires_at: number;
|
|
313
|
+
}>>;
|
|
286
314
|
breakdown: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
287
315
|
interval: z.ZodNativeEnum<typeof ProductItemInterval>;
|
|
288
316
|
balance: z.ZodOptional<z.ZodNumber>;
|
|
@@ -321,6 +349,10 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
|
|
|
321
349
|
included_usage?: number | undefined;
|
|
322
350
|
next_reset_at?: number | null | undefined;
|
|
323
351
|
overage_allowed?: boolean | undefined;
|
|
352
|
+
rollovers?: {
|
|
353
|
+
balance: number;
|
|
354
|
+
expires_at: number;
|
|
355
|
+
} | undefined;
|
|
324
356
|
breakdown?: {
|
|
325
357
|
interval: ProductItemInterval;
|
|
326
358
|
balance?: number | undefined;
|
|
@@ -341,6 +373,10 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
|
|
|
341
373
|
included_usage?: number | undefined;
|
|
342
374
|
next_reset_at?: number | null | undefined;
|
|
343
375
|
overage_allowed?: boolean | undefined;
|
|
376
|
+
rollovers?: {
|
|
377
|
+
balance: number;
|
|
378
|
+
expires_at: number;
|
|
379
|
+
} | undefined;
|
|
344
380
|
breakdown?: {
|
|
345
381
|
interval: ProductItemInterval;
|
|
346
382
|
balance?: number | undefined;
|
|
@@ -745,6 +781,16 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
745
781
|
customer_id: z.ZodString;
|
|
746
782
|
product_id: z.ZodString;
|
|
747
783
|
entity_id: z.ZodOptional<z.ZodString>;
|
|
784
|
+
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
785
|
+
feature_id: z.ZodString;
|
|
786
|
+
quantity: z.ZodNumber;
|
|
787
|
+
}, "strip", z.ZodTypeAny, {
|
|
788
|
+
feature_id: string;
|
|
789
|
+
quantity: number;
|
|
790
|
+
}, {
|
|
791
|
+
feature_id: string;
|
|
792
|
+
quantity: number;
|
|
793
|
+
}>, "many">>;
|
|
748
794
|
success_url: z.ZodOptional<z.ZodString>;
|
|
749
795
|
customer_data: z.ZodOptional<z.ZodObject<{
|
|
750
796
|
name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -759,16 +805,9 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
759
805
|
email?: string | null | undefined;
|
|
760
806
|
fingerprint?: string | null | undefined;
|
|
761
807
|
}>>;
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
}, "strip", z.ZodTypeAny, {
|
|
766
|
-
feature_id: string;
|
|
767
|
-
quantity: number;
|
|
768
|
-
}, {
|
|
769
|
-
feature_id: string;
|
|
770
|
-
quantity: number;
|
|
771
|
-
}>, "many">>;
|
|
808
|
+
entity_data: z.ZodOptional<z.ZodAny>;
|
|
809
|
+
checkout_session_params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
|
|
810
|
+
reward: z.ZodOptional<z.ZodString>;
|
|
772
811
|
}, "strip", z.ZodTypeAny, {
|
|
773
812
|
customer_id: string;
|
|
774
813
|
product_id: string;
|
|
@@ -783,6 +822,9 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
783
822
|
email?: string | null | undefined;
|
|
784
823
|
fingerprint?: string | null | undefined;
|
|
785
824
|
} | undefined;
|
|
825
|
+
entity_data?: any;
|
|
826
|
+
checkout_session_params?: Record<string, any> | undefined;
|
|
827
|
+
reward?: string | undefined;
|
|
786
828
|
}, {
|
|
787
829
|
customer_id: string;
|
|
788
830
|
product_id: string;
|
|
@@ -797,6 +839,9 @@ declare const CheckoutParamsSchema: z.ZodObject<{
|
|
|
797
839
|
email?: string | null | undefined;
|
|
798
840
|
fingerprint?: string | null | undefined;
|
|
799
841
|
} | undefined;
|
|
842
|
+
entity_data?: any;
|
|
843
|
+
checkout_session_params?: Record<string, any> | undefined;
|
|
844
|
+
reward?: string | undefined;
|
|
800
845
|
}>;
|
|
801
846
|
type CheckoutParams = z.infer<typeof CheckoutParamsSchema>;
|
|
802
847
|
type CheckoutResult = {
|
|
@@ -871,6 +916,7 @@ declare class Autumn {
|
|
|
871
916
|
static entities: {
|
|
872
917
|
get: (customer_id: string, entity_id: string, params?: GetEntityParams) => Promise<Result<Entity, AutumnError>>;
|
|
873
918
|
create: (customer_id: string, params?: CreateEntityParams | CreateEntityParams[]) => Promise<Result<CreateEntityResult, AutumnError>>;
|
|
919
|
+
transfer: (customer_id: string, params: TransferProductParams) => Promise<Result<TransferProductResult, AutumnError>>;
|
|
874
920
|
delete: (customer_id: string, entity_id: string) => Promise<Result<DeleteEntityResult, AutumnError>>;
|
|
875
921
|
};
|
|
876
922
|
static referrals: {
|
|
@@ -894,6 +940,7 @@ declare class Autumn {
|
|
|
894
940
|
entities: {
|
|
895
941
|
get: (customer_id: string, entity_id: string, params?: GetEntityParams) => Promise<Result<Entity, AutumnError>>;
|
|
896
942
|
create: (customer_id: string, params?: CreateEntityParams | CreateEntityParams[]) => Promise<Result<CreateEntityResult, AutumnError>>;
|
|
943
|
+
transfer: (customer_id: string, params: TransferProductParams) => Promise<Result<TransferProductResult, AutumnError>>;
|
|
897
944
|
delete: (customer_id: string, entity_id: string) => Promise<Result<DeleteEntityResult, AutumnError>>;
|
|
898
945
|
};
|
|
899
946
|
referrals: {
|
|
@@ -1016,6 +1063,23 @@ declare const EntityDataSchema: z.ZodObject<{
|
|
|
1016
1063
|
name?: string | undefined;
|
|
1017
1064
|
}>;
|
|
1018
1065
|
type EntityData = z.infer<typeof EntityDataSchema>;
|
|
1066
|
+
declare const TransferProductParamsSchema: z.ZodObject<{
|
|
1067
|
+
from_entity_id: z.ZodString;
|
|
1068
|
+
to_entity_id: z.ZodString;
|
|
1069
|
+
product_id: z.ZodString;
|
|
1070
|
+
}, "strip", z.ZodTypeAny, {
|
|
1071
|
+
product_id: string;
|
|
1072
|
+
from_entity_id: string;
|
|
1073
|
+
to_entity_id: string;
|
|
1074
|
+
}, {
|
|
1075
|
+
product_id: string;
|
|
1076
|
+
from_entity_id: string;
|
|
1077
|
+
to_entity_id: string;
|
|
1078
|
+
}>;
|
|
1079
|
+
type TransferProductParams = z.infer<typeof TransferProductParamsSchema>;
|
|
1080
|
+
type TransferProductResult = {
|
|
1081
|
+
success: boolean;
|
|
1082
|
+
};
|
|
1019
1083
|
|
|
1020
1084
|
declare const CreateReferralCodeParamsSchema: z.ZodObject<{
|
|
1021
1085
|
customer_id: z.ZodString;
|
|
@@ -1051,4 +1115,4 @@ interface RedeemReferralCodeResult {
|
|
|
1051
1115
|
applied: boolean;
|
|
1052
1116
|
}
|
|
1053
1117
|
|
|
1054
|
-
export { AppEnv, type AttachFeatureOptions, AttachFeatureOptionsSchema, type AttachParams, AttachParamsSchema, type AttachResult, AttachResultSchema, Autumn, AutumnError, type AutumnPromise, type BillingPortalParams, BillingPortalParamsSchema, type BillingPortalResult, type CancelParams, CancelParamsSchema, type CancelResult, CancelResultSchema, type CheckFeaturePreview, type CheckFeatureResult, CheckFeatureResultSchema, type CheckFeatureScenario, type CheckParams, CheckParamsSchema, type CheckProductPreview, type CheckProductResult, type CheckResult, type CheckoutParams, CheckoutParamsSchema, type CheckoutResult, CoreCusFeatureSchema, type CoreCustomerFeature, type CreateCustomerParams, CreateCustomerParamsSchema, type CreateEntityParams, type CreateEntityResult, type CreateProductParams, type CreateReferralCodeParams, CreateReferralCodeParamsSchema, type CreateReferralCodeResult, type Customer, type CustomerData, CustomerDataSchema, CustomerExpandEnum, type CustomerExpandOption, type CustomerFeature, type CustomerInvoice, type CustomerProduct, type DeleteEntityResult, type Entity, type EntityData, EntityDataSchema, type EntityExpandOption, type ErrorResponse, type Feature, type FreeTrial, FreeTrialDuration, type GetCustomerParams, type GetEntityParams, type GetPricingTableParams, Infinite, type ListProductsParams, type PriceTier, type PricingTableProduct, type Product, type ProductItem, ProductItemInterval, type ProductItemIntervalType, type ProductScenario, ProductStatus, type QueryParams, QueryParamsSchema, QueryRangeEnum, type QueryResult, type RedeemReferralCodeParams, RedeemReferralCodeParamsSchema, type RedeemReferralCodeResult, type SetupPaymentParams, type SetupPaymentResult, type TrackParams, TrackParamsSchema, type TrackResult, TrackResultSchema, type UpdateCustomerParams, UsageModel, type UsageModelType, type UsageParams, type UsageResult, fetchPricingTable, toContainerResult };
|
|
1118
|
+
export { AppEnv, type AttachFeatureOptions, AttachFeatureOptionsSchema, type AttachParams, AttachParamsSchema, type AttachResult, AttachResultSchema, Autumn, AutumnError, type AutumnPromise, type BillingPortalParams, BillingPortalParamsSchema, type BillingPortalResult, type CancelParams, CancelParamsSchema, type CancelResult, CancelResultSchema, type CheckFeaturePreview, type CheckFeatureResult, CheckFeatureResultSchema, type CheckFeatureScenario, type CheckParams, CheckParamsSchema, type CheckProductPreview, type CheckProductResult, type CheckResult, type CheckoutParams, CheckoutParamsSchema, type CheckoutResult, CoreCusFeatureSchema, type CoreCustomerFeature, type CreateCustomerParams, CreateCustomerParamsSchema, type CreateEntityParams, type CreateEntityResult, type CreateProductParams, type CreateReferralCodeParams, CreateReferralCodeParamsSchema, type CreateReferralCodeResult, type Customer, type CustomerData, CustomerDataSchema, CustomerExpandEnum, type CustomerExpandOption, type CustomerFeature, type CustomerInvoice, type CustomerProduct, type DeleteEntityResult, type Entity, type EntityData, EntityDataSchema, type EntityExpandOption, type ErrorResponse, type Feature, type FreeTrial, FreeTrialDuration, type GetCustomerParams, type GetEntityParams, type GetPricingTableParams, Infinite, type ListProductsParams, type PriceTier, type PricingTableProduct, type Product, type ProductItem, ProductItemInterval, type ProductItemIntervalType, type ProductScenario, ProductStatus, type QueryParams, QueryParamsSchema, QueryRangeEnum, type QueryResult, type RedeemReferralCodeParams, RedeemReferralCodeParamsSchema, type RedeemReferralCodeResult, type SetupPaymentParams, type SetupPaymentResult, type TrackParams, TrackParamsSchema, type TrackResult, TrackResultSchema, type TransferProductParams, TransferProductParamsSchema, type TransferProductResult, type UpdateCustomerParams, UsageModel, type UsageModelType, type UsageParams, type UsageResult, fetchPricingTable, toContainerResult };
|