autumn-js 0.0.95 → 0.0.98
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/compose/index.d.mts +201 -0
- package/dist/compose/index.d.ts +201 -0
- package/dist/compose/index.js +147 -0
- package/dist/compose/index.mjs +113 -0
- package/dist/libraries/backend/better-auth.d.mts +21 -20
- package/dist/libraries/backend/better-auth.d.ts +21 -20
- package/dist/libraries/backend/better-auth.js +26 -21
- package/dist/libraries/backend/better-auth.mjs +27 -22
- package/dist/libraries/backend/express.d.mts +1 -1
- package/dist/libraries/backend/express.d.ts +1 -1
- package/dist/libraries/backend/next.js +94 -94
- package/dist/libraries/backend/next.mjs +94 -94
- package/dist/libraries/backend/{referralTypes-HAk2vTns.d.ts → referralTypes-D1Q2i3mG.d.ts} +28 -27
- package/dist/libraries/backend/{referralTypes-Dg9pRvI7.d.mts → referralTypes-Dfg6if8j.d.mts} +28 -27
- package/dist/libraries/backend/utils/withAuth.d.mts +1 -1
- package/dist/libraries/backend/utils/withAuth.d.ts +1 -1
- package/dist/libraries/react/AutumnContext.d.mts +4 -4
- package/dist/libraries/react/AutumnContext.d.ts +4 -4
- package/dist/libraries/react/AutumnContext.mjs +7 -7
- package/dist/libraries/react/BaseAutumnProvider.d.mts +4 -4
- package/dist/libraries/react/BaseAutumnProvider.d.ts +4 -4
- package/dist/libraries/react/BaseAutumnProvider.mjs +12 -12
- package/dist/libraries/react/{ReactAutumnClient-k0qbHX8f.d.ts → ReactAutumnClient-ByV3ry6X.d.ts} +10 -10
- package/dist/libraries/react/{ReactAutumnClient-BuSRDMJN.d.mts → ReactAutumnClient-Ce34XSNp.d.mts} +10 -10
- package/dist/libraries/react/ReactAutumnProvider.d.mts +1 -1
- package/dist/libraries/react/ReactAutumnProvider.d.ts +1 -1
- package/dist/libraries/react/ReactAutumnProvider.mjs +13 -13
- package/dist/libraries/react/{chunk-27OTS3Q5.mjs → chunk-6MNYJ3YQ.mjs} +2 -2
- package/dist/libraries/react/{chunk-6CJ3FB74.mjs → chunk-7J5WGHDK.mjs} +2 -2
- package/dist/libraries/react/{chunk-DVMVIAZE.mjs → chunk-AISYLQU5.mjs} +1 -1
- package/dist/libraries/react/{chunk-P2O4LZFD.mjs → chunk-AL3VJLFU.mjs} +1 -1
- package/dist/libraries/react/{chunk-T5PIJ4HG.mjs → chunk-BJRHW2WP.mjs} +2 -2
- package/dist/libraries/react/{chunk-MZDRIPNS.mjs → chunk-BQUVIPG4.mjs} +2 -2
- package/dist/libraries/react/{chunk-5FZ7IV6P.mjs → chunk-BSF3KB4R.mjs} +46 -46
- package/dist/libraries/react/{chunk-CAMHARUX.mjs → chunk-FGNNWWBD.mjs} +2 -2
- package/dist/libraries/react/{chunk-G3FBFZLU.mjs → chunk-IJFGEGR2.mjs} +1 -1
- package/dist/libraries/react/{chunk-FPI3PLEL.mjs → chunk-OAPUYXBO.mjs} +6 -6
- package/dist/libraries/react/{chunk-CMO5LYYU.mjs → chunk-OAWFFAKA.mjs} +6 -6
- package/dist/libraries/react/{chunk-5G3DYUNT.mjs → chunk-RURBN53D.mjs} +1 -1
- package/dist/libraries/react/{chunk-LVDONEVF.mjs → chunk-SA4NOOHV.mjs} +2 -2
- package/dist/libraries/react/{chunk-AOJCMXVS.mjs → chunk-TKHPR5VW.mjs} +3 -3
- package/dist/libraries/react/{chunk-APDR7D6A.mjs → chunk-XSJQQSUT.mjs} +2 -2
- package/dist/libraries/react/{chunk-R4BYOLST.mjs → chunk-ZFOSCZKA.mjs} +2 -2
- package/dist/libraries/react/{chunk-CHXNYNH3.mjs → chunk-ZQ5HNM6O.mjs} +12 -12
- package/dist/libraries/react/{chunk-FEFGYFXQ.mjs → chunk-ZVQKDPUP.mjs} +3 -3
- package/dist/libraries/react/client/ReactAutumnClient.d.mts +4 -4
- package/dist/libraries/react/client/ReactAutumnClient.d.ts +4 -4
- package/dist/libraries/react/client/ReactAutumnClient.mjs +6 -6
- package/dist/libraries/react/client/clientCompMethods.d.mts +4 -4
- package/dist/libraries/react/client/clientCompMethods.d.ts +4 -4
- package/dist/libraries/react/client/clientCusMethods.d.mts +4 -4
- package/dist/libraries/react/client/clientCusMethods.d.ts +4 -4
- package/dist/libraries/react/client/clientEntityMethods.d.mts +4 -4
- package/dist/libraries/react/client/clientEntityMethods.d.ts +4 -4
- package/dist/libraries/react/client/clientGenMethods.d.mts +4 -4
- package/dist/libraries/react/client/clientGenMethods.d.ts +4 -4
- package/dist/libraries/react/client/clientProdMethods.d.mts +4 -4
- package/dist/libraries/react/client/clientProdMethods.d.ts +4 -4
- package/dist/libraries/react/client/clientReferralMethods.d.mts +4 -4
- package/dist/libraries/react/client/clientReferralMethods.d.ts +4 -4
- package/dist/libraries/react/client/types/clientGenTypes.d.mts +12 -12
- package/dist/libraries/react/client/types/clientGenTypes.d.ts +12 -12
- package/dist/libraries/react/components/attach-dialog/attach-dialog-synced.d.mts +1 -1
- package/dist/libraries/react/components/attach-dialog/attach-dialog-synced.d.ts +1 -1
- package/dist/libraries/react/components/attach-dialog/attach-dialog-synced.js +55 -55
- package/dist/libraries/react/components/attach-dialog/attach-dialog-synced.mjs +26 -26
- package/dist/libraries/react/components/attach-dialog/lib/attach-content.d.mts +1 -1
- package/dist/libraries/react/components/attach-dialog/lib/attach-content.d.ts +1 -1
- package/dist/libraries/react/components/check-dialog/check-dialog-synced.d.mts +1 -1
- package/dist/libraries/react/components/check-dialog/check-dialog-synced.d.ts +1 -1
- package/dist/libraries/react/components/check-dialog/check-dialog-synced.js +50 -50
- package/dist/libraries/react/components/check-dialog/check-dialog-synced.mjs +5 -5
- package/dist/libraries/react/components/check-dialog/lib/check-content.d.mts +1 -1
- package/dist/libraries/react/components/check-dialog/lib/check-content.d.ts +1 -1
- package/dist/libraries/react/components/pricing-table/pricing-table-synced.d.mts +1 -1
- package/dist/libraries/react/components/pricing-table/pricing-table-synced.d.ts +1 -1
- package/dist/libraries/react/components/pricing-table/pricing-table-synced.js +55 -55
- package/dist/libraries/react/components/pricing-table/pricing-table-synced.mjs +26 -26
- package/dist/libraries/react/components/ui/button.js +3 -3
- package/dist/libraries/react/components/ui/button.mjs +2 -2
- package/dist/libraries/react/components/ui/dialog.js +49 -49
- package/dist/libraries/react/components/ui/dialog.mjs +3 -3
- package/dist/libraries/react/components/ui/switch.js +12 -12
- package/dist/libraries/react/components/ui/switch.mjs +3 -3
- package/dist/libraries/react/{cusTypes-Vw94kPR9.d.ts → cusTypes-cFcAuKk6.d.mts} +2 -1
- package/dist/libraries/react/{cusTypes-Vw94kPR9.d.mts → cusTypes-cFcAuKk6.d.ts} +2 -1
- package/dist/libraries/react/{entTypes-B7nuhHD7.d.ts → entTypes-DPu6Efi2.d.ts} +1 -1
- package/dist/libraries/react/{entTypes-Ho-VocKG.d.mts → entTypes-S-Yuznzg.d.mts} +1 -1
- package/dist/libraries/react/hooks/handleAllowed.d.mts +2 -2
- package/dist/libraries/react/hooks/handleAllowed.d.ts +2 -2
- package/dist/libraries/react/hooks/useAutumn.d.mts +2 -2
- package/dist/libraries/react/hooks/useAutumn.d.ts +2 -2
- package/dist/libraries/react/hooks/useAutumn.mjs +10 -10
- package/dist/libraries/react/hooks/useAutumnBase.d.mts +4 -4
- package/dist/libraries/react/hooks/useAutumnBase.d.ts +4 -4
- package/dist/libraries/react/hooks/useAutumnBase.mjs +9 -9
- package/dist/libraries/react/hooks/useCustomer.d.mts +4 -4
- package/dist/libraries/react/hooks/useCustomer.d.ts +4 -4
- package/dist/libraries/react/hooks/useCustomer.mjs +11 -11
- package/dist/libraries/react/hooks/useCustomerBase.d.mts +4 -4
- package/dist/libraries/react/hooks/useCustomerBase.d.ts +4 -4
- package/dist/libraries/react/hooks/useCustomerBase.mjs +10 -10
- package/dist/libraries/react/hooks/useEntity.d.mts +3 -3
- package/dist/libraries/react/hooks/useEntity.d.ts +3 -3
- package/dist/libraries/react/hooks/useEntity.mjs +11 -11
- package/dist/libraries/react/hooks/useEntityBase.d.mts +4 -4
- package/dist/libraries/react/hooks/useEntityBase.d.ts +4 -4
- package/dist/libraries/react/hooks/useEntityBase.mjs +10 -10
- 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.mjs +9 -9
- package/dist/libraries/react/hooks/usePricingTableBase.d.mts +4 -4
- package/dist/libraries/react/hooks/usePricingTableBase.d.ts +4 -4
- package/dist/libraries/react/hooks/usePricingTableBase.mjs +8 -8
- package/dist/libraries/react/hooks/useProductsBase.mjs +7 -7
- package/dist/libraries/react/index.d.mts +1 -0
- package/dist/libraries/react/index.d.ts +1 -0
- package/dist/libraries/react/index.js +55 -55
- package/dist/libraries/react/index.mjs +55 -55
- package/dist/libraries/react/{response-CQf3mDB8.d.ts → response-BDOGqtuI.d.ts} +8 -8
- package/dist/libraries/react/{response-CWluLfIs.d.mts → response-R1MWYZiA.d.mts} +8 -8
- package/dist/next/{AutumnProvider-CCYZC_bN.d.mts → AutumnProvider-Xl1mqxls.d.mts} +1 -0
- package/dist/next/{AutumnProvider-CCYZC_bN.d.ts → AutumnProvider-Xl1mqxls.d.ts} +1 -0
- package/dist/next/AutumnProvider.d.mts +1 -1
- package/dist/next/AutumnProvider.d.ts +1 -1
- package/dist/next/client/NextAutumnClient.d.mts +3 -3
- package/dist/next/client/NextAutumnClient.d.ts +3 -3
- package/dist/next/client/NextAutumnProvider.d.mts +1 -1
- package/dist/next/client/NextAutumnProvider.d.ts +1 -1
- package/dist/next/client/{clientGenTypes-CxB4go6q.d.ts → clientGenTypes-B_LCNkd5.d.ts} +1 -1
- package/dist/next/client/{clientGenTypes-9ngy1q97.d.mts → clientGenTypes-BwevGhcx.d.mts} +1 -1
- package/dist/next/client/clientUtils.d.mts +2 -2
- package/dist/next/client/clientUtils.d.ts +2 -2
- package/dist/next/client/{cusTypes-D8lhXGaX.d.mts → cusTypes-Gh2wfcmj.d.mts} +1 -0
- package/dist/next/client/{cusTypes-D8lhXGaX.d.ts → cusTypes-Gh2wfcmj.d.ts} +1 -0
- package/dist/next/client/{entTypes-Dq2mbehl.d.ts → entTypes-B_w6I3y-.d.ts} +1 -1
- package/dist/next/client/{entTypes-B-2_9hzP.d.mts → entTypes-C_xS1VPE.d.mts} +1 -1
- package/dist/next/client/hooks/useAutumn.d.mts +2 -2
- package/dist/next/client/hooks/useAutumn.d.ts +2 -2
- package/dist/next/client/hooks/useCustomer.d.mts +3 -3
- package/dist/next/client/hooks/useCustomer.d.ts +3 -3
- package/dist/next/client/hooks/useEntity.d.mts +3 -3
- package/dist/next/client/hooks/useEntity.d.ts +3 -3
- package/dist/next/client/hooks/usePricingTable.d.mts +1 -1
- package/dist/next/client/hooks/usePricingTable.d.ts +1 -1
- package/dist/next/client/types.d.mts +2 -2
- package/dist/next/client/types.d.ts +2 -2
- package/dist/next/index.d.mts +2 -2
- package/dist/next/index.d.ts +2 -2
- 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 +21 -21
- package/dist/next/server/cusActions.d.ts +21 -21
- package/dist/next/server/{cusTypes-Cy72qmFx.d.mts → cusTypes-B8u88Vfq.d.mts} +3 -2
- package/dist/next/server/{cusTypes-Cy72qmFx.d.ts → cusTypes-B8u88Vfq.d.ts} +3 -2
- package/dist/next/server/genActions.d.mts +1 -1
- package/dist/next/server/genActions.d.ts +1 -1
- package/dist/sdk/index.d.mts +1 -0
- package/dist/sdk/index.d.ts +1 -0
- package/package.json +19 -6
- package/tsup.config.ts +12 -3
- package/dist/libraries/react/{chunk-ALFXUHDD.mjs → chunk-QRI2TNR7.mjs} +15 -15
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AutumnClientError, PricingTableProduct } from './types.mjs';
|
|
2
|
-
import './cusTypes-
|
|
2
|
+
import './cusTypes-Gh2wfcmj.mjs';
|
|
3
3
|
import 'zod';
|
|
4
|
-
import './entTypes-
|
|
4
|
+
import './entTypes-C_xS1VPE.mjs';
|
|
5
5
|
|
|
6
6
|
declare const toClientErrorResponse: (error: any) => {
|
|
7
7
|
data: null;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AutumnClientError, PricingTableProduct } from './types.js';
|
|
2
|
-
import './cusTypes-
|
|
2
|
+
import './cusTypes-Gh2wfcmj.js';
|
|
3
3
|
import 'zod';
|
|
4
|
-
import './entTypes-
|
|
4
|
+
import './entTypes-B_w6I3y-.js';
|
|
5
5
|
|
|
6
6
|
declare const toClientErrorResponse: (error: any) => {
|
|
7
7
|
data: null;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as AttachParams, C as CheckParams, a as AutumnPromise, b as CheckResult, T as TrackParams, c as TrackResult, d as CancelParams, e as CancelResult, O as OpenBillingPortalParams, S as SetupPaymentParams, f as SetupPaymentResult } from '../clientGenTypes-
|
|
2
|
-
import { B as BillingPortalResult } from '../cusTypes-
|
|
1
|
+
import { A as AttachParams, C as CheckParams, a as AutumnPromise, b as CheckResult, T as TrackParams, c as TrackResult, d as CancelParams, e as CancelResult, O as OpenBillingPortalParams, S as SetupPaymentParams, f as SetupPaymentResult } from '../clientGenTypes-BwevGhcx.mjs';
|
|
2
|
+
import { B as BillingPortalResult } from '../cusTypes-Gh2wfcmj.mjs';
|
|
3
3
|
import 'zod';
|
|
4
4
|
import '../error-DHbclCVh.mjs';
|
|
5
5
|
import 'react';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as AttachParams, C as CheckParams, a as AutumnPromise, b as CheckResult, T as TrackParams, c as TrackResult, d as CancelParams, e as CancelResult, O as OpenBillingPortalParams, S as SetupPaymentParams, f as SetupPaymentResult } from '../clientGenTypes-
|
|
2
|
-
import { B as BillingPortalResult } from '../cusTypes-
|
|
1
|
+
import { A as AttachParams, C as CheckParams, a as AutumnPromise, b as CheckResult, T as TrackParams, c as TrackResult, d as CancelParams, e as CancelResult, O as OpenBillingPortalParams, S as SetupPaymentParams, f as SetupPaymentResult } from '../clientGenTypes-B_LCNkd5.js';
|
|
2
|
+
import { B as BillingPortalResult } from '../cusTypes-Gh2wfcmj.js';
|
|
3
3
|
import 'zod';
|
|
4
4
|
import '../error-DHbclCVh.js';
|
|
5
5
|
import 'react';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { A as AutumnError } from '../error-DHbclCVh.mjs';
|
|
2
|
-
import { A as AttachParams, a as AutumnPromise, g as AttachResult, C as CheckParams, b as CheckResult, T as TrackParams, c as TrackResult, d as CancelParams, e as CancelResult, S as SetupPaymentParams, f as SetupPaymentResult, O as OpenBillingPortalParams } from '../clientGenTypes-
|
|
3
|
-
import { h as CustomerExpandOption, a as Customer, B as BillingPortalResult } from '../cusTypes-
|
|
4
|
-
import { E as Entity } from '../entTypes-
|
|
2
|
+
import { A as AttachParams, a as AutumnPromise, g as AttachResult, C as CheckParams, b as CheckResult, T as TrackParams, c as TrackResult, d as CancelParams, e as CancelResult, S as SetupPaymentParams, f as SetupPaymentResult, O as OpenBillingPortalParams } from '../clientGenTypes-BwevGhcx.mjs';
|
|
3
|
+
import { h as CustomerExpandOption, a as Customer, B as BillingPortalResult } from '../cusTypes-Gh2wfcmj.mjs';
|
|
4
|
+
import { E as Entity } from '../entTypes-C_xS1VPE.mjs';
|
|
5
5
|
import { C as CreateEntityParams, a as CreateReferralCodeResult, R as RedeemReferralCodeResult } from '../clientEntTypes-BFkleT6a.mjs';
|
|
6
6
|
import { z } from 'zod';
|
|
7
7
|
import { SWRConfiguration } from 'swr';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { A as AutumnError } from '../error-DHbclCVh.js';
|
|
2
|
-
import { A as AttachParams, a as AutumnPromise, g as AttachResult, C as CheckParams, b as CheckResult, T as TrackParams, c as TrackResult, d as CancelParams, e as CancelResult, S as SetupPaymentParams, f as SetupPaymentResult, O as OpenBillingPortalParams } from '../clientGenTypes-
|
|
3
|
-
import { h as CustomerExpandOption, a as Customer, B as BillingPortalResult } from '../cusTypes-
|
|
4
|
-
import { E as Entity } from '../entTypes-
|
|
2
|
+
import { A as AttachParams, a as AutumnPromise, g as AttachResult, C as CheckParams, b as CheckResult, T as TrackParams, c as TrackResult, d as CancelParams, e as CancelResult, S as SetupPaymentParams, f as SetupPaymentResult, O as OpenBillingPortalParams } from '../clientGenTypes-B_LCNkd5.js';
|
|
3
|
+
import { h as CustomerExpandOption, a as Customer, B as BillingPortalResult } from '../cusTypes-Gh2wfcmj.js';
|
|
4
|
+
import { E as Entity } from '../entTypes-B_w6I3y-.js';
|
|
5
5
|
import { C as CreateEntityParams, a as CreateReferralCodeResult, R as RedeemReferralCodeResult } from '../clientEntTypes-BFkleT6a.js';
|
|
6
6
|
import { z } from 'zod';
|
|
7
7
|
import { SWRConfiguration } from 'swr';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { C as CheckParams, a as AutumnPromise, b as CheckResult, A as AttachParams, d as CancelParams, T as TrackParams } from '../clientGenTypes-
|
|
2
|
-
import { G as GetEntityParams, E as Entity } from '../entTypes-
|
|
1
|
+
import { C as CheckParams, a as AutumnPromise, b as CheckResult, A as AttachParams, d as CancelParams, T as TrackParams } from '../clientGenTypes-BwevGhcx.mjs';
|
|
2
|
+
import { G as GetEntityParams, E as Entity } from '../entTypes-C_xS1VPE.mjs';
|
|
3
3
|
import { A as AllowedParams } from '../handleAllowed-B8TBAzfI.mjs';
|
|
4
4
|
import * as swr from 'swr';
|
|
5
|
-
import '../cusTypes-
|
|
5
|
+
import '../cusTypes-Gh2wfcmj.mjs';
|
|
6
6
|
import 'zod';
|
|
7
7
|
import '../error-DHbclCVh.mjs';
|
|
8
8
|
import 'react';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { C as CheckParams, a as AutumnPromise, b as CheckResult, A as AttachParams, d as CancelParams, T as TrackParams } from '../clientGenTypes-
|
|
2
|
-
import { G as GetEntityParams, E as Entity } from '../entTypes-
|
|
1
|
+
import { C as CheckParams, a as AutumnPromise, b as CheckResult, A as AttachParams, d as CancelParams, T as TrackParams } from '../clientGenTypes-B_LCNkd5.js';
|
|
2
|
+
import { G as GetEntityParams, E as Entity } from '../entTypes-B_w6I3y-.js';
|
|
3
3
|
import { A as AllowedParams } from '../handleAllowed-B8TBAzfI.js';
|
|
4
4
|
import * as swr from 'swr';
|
|
5
|
-
import '../cusTypes-
|
|
5
|
+
import '../cusTypes-Gh2wfcmj.js';
|
|
6
6
|
import 'zod';
|
|
7
7
|
import '../error-DHbclCVh.js';
|
|
8
8
|
import 'react';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CustomerData, a as Customer } from './cusTypes-
|
|
2
|
-
import { E as Entity } from './entTypes-
|
|
1
|
+
import { C as CustomerData, a as Customer } from './cusTypes-Gh2wfcmj.mjs';
|
|
2
|
+
import { E as Entity } from './entTypes-C_xS1VPE.mjs';
|
|
3
3
|
import 'zod';
|
|
4
4
|
|
|
5
5
|
interface ProductDetails {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CustomerData, a as Customer } from './cusTypes-
|
|
2
|
-
import { E as Entity } from './entTypes-
|
|
1
|
+
import { C as CustomerData, a as Customer } from './cusTypes-Gh2wfcmj.js';
|
|
2
|
+
import { E as Entity } from './entTypes-B_w6I3y-.js';
|
|
3
3
|
import 'zod';
|
|
4
4
|
|
|
5
5
|
interface ProductDetails {
|
package/dist/next/index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { C as CheckFeatureResult, a as CheckProductResult, P as ProductItem, b as ProductScenario, c as CustomerProduct, d as CustomerFeature, e as CustomerInvoice, f as CustomerData, g as CreateCustomerParams, h as Customer, B as BillingPortalResult, i as Product, j as CustomerExpandOption } from './AutumnProvider-
|
|
3
|
-
export { A as AutumnProvider } from './AutumnProvider-
|
|
2
|
+
import { C as CheckFeatureResult, a as CheckProductResult, P as ProductItem, b as ProductScenario, c as CustomerProduct, d as CustomerFeature, e as CustomerInvoice, f as CustomerData, g as CreateCustomerParams, h as Customer, B as BillingPortalResult, i as Product, j as CustomerExpandOption } from './AutumnProvider-Xl1mqxls.mjs';
|
|
3
|
+
export { A as AutumnProvider } from './AutumnProvider-Xl1mqxls.mjs';
|
|
4
4
|
import { z } from 'zod';
|
|
5
5
|
import * as swr from 'swr';
|
|
6
6
|
import { SWRConfiguration } from 'swr';
|
package/dist/next/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { C as CheckFeatureResult, a as CheckProductResult, P as ProductItem, b as ProductScenario, c as CustomerProduct, d as CustomerFeature, e as CustomerInvoice, f as CustomerData, g as CreateCustomerParams, h as Customer, B as BillingPortalResult, i as Product, j as CustomerExpandOption } from './AutumnProvider-
|
|
3
|
-
export { A as AutumnProvider } from './AutumnProvider-
|
|
2
|
+
import { C as CheckFeatureResult, a as CheckProductResult, P as ProductItem, b as ProductScenario, c as CustomerProduct, d as CustomerFeature, e as CustomerInvoice, f as CustomerData, g as CreateCustomerParams, h as Customer, B as BillingPortalResult, i as Product, j as CustomerExpandOption } from './AutumnProvider-Xl1mqxls.js';
|
|
3
|
+
export { A as AutumnProvider } from './AutumnProvider-Xl1mqxls.js';
|
|
4
4
|
import { z } from 'zod';
|
|
5
5
|
import * as swr from 'swr';
|
|
6
6
|
import { SWRConfiguration } from 'swr';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as CustomerData, a as CheckFeatureResult, b as CheckProductResult, G as GetCustomerParams, c as Customer, d as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, P as Product, e as CreateProductParams, L as ListProductsParams, f as CustomerProduct, g as CustomerFeature, h as CustomerInvoice } from './cusTypes-
|
|
1
|
+
import { C as CustomerData, a as CheckFeatureResult, b as CheckProductResult, G as GetCustomerParams, c as Customer, d as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, P as Product, e as CreateProductParams, L as ListProductsParams, f as CustomerProduct, g as CustomerFeature, h as CustomerInvoice } from './cusTypes-B8u88Vfq.mjs';
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { R as Result, A as AutumnError } from './response-eH4S4sg0.mjs';
|
|
4
4
|
|
|
@@ -27,12 +27,12 @@ declare const AttachParamsSchema: z.ZodObject<{
|
|
|
27
27
|
reward: z.ZodOptional<z.ZodString>;
|
|
28
28
|
}, "strip", z.ZodTypeAny, {
|
|
29
29
|
customer_id: string;
|
|
30
|
-
entity_id?: string | undefined;
|
|
31
30
|
options?: {
|
|
32
31
|
feature_id: string;
|
|
33
32
|
quantity: number;
|
|
34
33
|
}[] | undefined;
|
|
35
34
|
metadata?: Record<string, string> | undefined;
|
|
35
|
+
entity_id?: string | undefined;
|
|
36
36
|
product_id?: string | undefined;
|
|
37
37
|
product_ids?: string[] | undefined;
|
|
38
38
|
free_trial?: boolean | undefined;
|
|
@@ -44,12 +44,12 @@ declare const AttachParamsSchema: z.ZodObject<{
|
|
|
44
44
|
reward?: string | undefined;
|
|
45
45
|
}, {
|
|
46
46
|
customer_id: string;
|
|
47
|
-
entity_id?: string | undefined;
|
|
48
47
|
options?: {
|
|
49
48
|
feature_id: string;
|
|
50
49
|
quantity: number;
|
|
51
50
|
}[] | undefined;
|
|
52
51
|
metadata?: Record<string, string> | undefined;
|
|
52
|
+
entity_id?: string | undefined;
|
|
53
53
|
product_id?: string | undefined;
|
|
54
54
|
product_ids?: string[] | undefined;
|
|
55
55
|
free_trial?: boolean | undefined;
|
|
@@ -89,18 +89,18 @@ declare const TrackParamsSchema: z.ZodObject<{
|
|
|
89
89
|
entity_data: z.ZodOptional<z.ZodAny>;
|
|
90
90
|
}, "strip", z.ZodTypeAny, {
|
|
91
91
|
customer_id: string;
|
|
92
|
-
feature_id?: string | undefined;
|
|
93
|
-
entity_id?: string | undefined;
|
|
94
92
|
value?: number | undefined;
|
|
93
|
+
entity_id?: string | undefined;
|
|
94
|
+
feature_id?: string | undefined;
|
|
95
95
|
customer_data?: any;
|
|
96
96
|
entity_data?: any;
|
|
97
97
|
event_name?: string | undefined;
|
|
98
98
|
idempotency_key?: string | undefined;
|
|
99
99
|
}, {
|
|
100
100
|
customer_id: string;
|
|
101
|
-
feature_id?: string | undefined;
|
|
102
|
-
entity_id?: string | undefined;
|
|
103
101
|
value?: number | undefined;
|
|
102
|
+
entity_id?: string | undefined;
|
|
103
|
+
feature_id?: string | undefined;
|
|
104
104
|
customer_data?: any;
|
|
105
105
|
entity_data?: any;
|
|
106
106
|
event_name?: string | undefined;
|
|
@@ -128,8 +128,8 @@ declare const CheckParamsSchema: z.ZodObject<{
|
|
|
128
128
|
}>>;
|
|
129
129
|
}, "strip", z.ZodTypeAny, {
|
|
130
130
|
customer_id: string;
|
|
131
|
-
feature_id?: string | undefined;
|
|
132
131
|
entity_id?: string | undefined;
|
|
132
|
+
feature_id?: string | undefined;
|
|
133
133
|
required_balance?: number | undefined;
|
|
134
134
|
product_id?: string | undefined;
|
|
135
135
|
customer_data?: any;
|
|
@@ -141,8 +141,8 @@ declare const CheckParamsSchema: z.ZodObject<{
|
|
|
141
141
|
with_preview?: boolean | undefined;
|
|
142
142
|
}, {
|
|
143
143
|
customer_id: string;
|
|
144
|
-
feature_id?: string | undefined;
|
|
145
144
|
entity_id?: string | undefined;
|
|
145
|
+
feature_id?: string | undefined;
|
|
146
146
|
required_balance?: number | undefined;
|
|
147
147
|
product_id?: string | undefined;
|
|
148
148
|
customer_data?: any;
|
|
@@ -240,18 +240,18 @@ declare class Autumn {
|
|
|
240
240
|
redeemCode: (params: RedeemReferralCodeParams) => Promise<Result<any, AutumnError>>;
|
|
241
241
|
};
|
|
242
242
|
static attach: (params: AttachParams) => Promise<Result<{
|
|
243
|
-
customer_id: string;
|
|
244
243
|
code: string;
|
|
245
244
|
message: string;
|
|
245
|
+
customer_id: string;
|
|
246
246
|
product_ids: string[];
|
|
247
247
|
customer_data?: any;
|
|
248
248
|
checkout_url?: string | undefined;
|
|
249
249
|
}, AutumnError>>;
|
|
250
250
|
static usage: (params: UsageParams) => Promise<Result<UsageResult, AutumnError>>;
|
|
251
251
|
attach(params: AttachParams): Promise<Result<{
|
|
252
|
-
customer_id: string;
|
|
253
252
|
code: string;
|
|
254
253
|
message: string;
|
|
254
|
+
customer_id: string;
|
|
255
255
|
product_ids: string[];
|
|
256
256
|
customer_data?: any;
|
|
257
257
|
checkout_url?: string | undefined;
|
|
@@ -285,9 +285,9 @@ declare class Autumn {
|
|
|
285
285
|
* Please use the new track() method instead.
|
|
286
286
|
*/
|
|
287
287
|
static event: (params: TrackParams) => Promise<Result<{
|
|
288
|
-
customer_id: string;
|
|
289
|
-
code: string;
|
|
290
288
|
id: string;
|
|
289
|
+
code: string;
|
|
290
|
+
customer_id: string;
|
|
291
291
|
feature_id?: string | undefined;
|
|
292
292
|
event_name?: string | undefined;
|
|
293
293
|
}, AutumnError>>;
|
|
@@ -296,23 +296,23 @@ declare class Autumn {
|
|
|
296
296
|
* Please use the new track() method instead.
|
|
297
297
|
*/
|
|
298
298
|
event(params: TrackParams): Promise<Result<{
|
|
299
|
-
customer_id: string;
|
|
300
|
-
code: string;
|
|
301
299
|
id: string;
|
|
300
|
+
code: string;
|
|
301
|
+
customer_id: string;
|
|
302
302
|
feature_id?: string | undefined;
|
|
303
303
|
event_name?: string | undefined;
|
|
304
304
|
}, AutumnError>>;
|
|
305
305
|
static track: (params: TrackParams) => Promise<Result<{
|
|
306
|
-
customer_id: string;
|
|
307
|
-
code: string;
|
|
308
306
|
id: string;
|
|
307
|
+
code: string;
|
|
308
|
+
customer_id: string;
|
|
309
309
|
feature_id?: string | undefined;
|
|
310
310
|
event_name?: string | undefined;
|
|
311
311
|
}, AutumnError>>;
|
|
312
312
|
track(params: TrackParams): Promise<Result<{
|
|
313
|
-
customer_id: string;
|
|
314
|
-
code: string;
|
|
315
313
|
id: string;
|
|
314
|
+
code: string;
|
|
315
|
+
customer_id: string;
|
|
316
316
|
feature_id?: string | undefined;
|
|
317
317
|
event_name?: string | undefined;
|
|
318
318
|
}, AutumnError>>;
|
|
@@ -362,11 +362,11 @@ declare const RedeemReferralCodeParamsSchema: z.ZodObject<{
|
|
|
362
362
|
code: z.ZodString;
|
|
363
363
|
customer_id: z.ZodString;
|
|
364
364
|
}, "strip", z.ZodTypeAny, {
|
|
365
|
-
customer_id: string;
|
|
366
365
|
code: string;
|
|
367
|
-
}, {
|
|
368
366
|
customer_id: string;
|
|
367
|
+
}, {
|
|
369
368
|
code: string;
|
|
369
|
+
customer_id: string;
|
|
370
370
|
}>;
|
|
371
371
|
type RedeemReferralCodeParams = z.infer<typeof RedeemReferralCodeParamsSchema>;
|
|
372
372
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as CustomerData, a as CheckFeatureResult, b as CheckProductResult, G as GetCustomerParams, c as Customer, d as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, P as Product, e as CreateProductParams, L as ListProductsParams, f as CustomerProduct, g as CustomerFeature, h as CustomerInvoice } from './cusTypes-
|
|
1
|
+
import { C as CustomerData, a as CheckFeatureResult, b as CheckProductResult, G as GetCustomerParams, c as Customer, d as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, P as Product, e as CreateProductParams, L as ListProductsParams, f as CustomerProduct, g as CustomerFeature, h as CustomerInvoice } from './cusTypes-B8u88Vfq.js';
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { R as Result, A as AutumnError } from './response-eH4S4sg0.js';
|
|
4
4
|
|
|
@@ -27,12 +27,12 @@ declare const AttachParamsSchema: z.ZodObject<{
|
|
|
27
27
|
reward: z.ZodOptional<z.ZodString>;
|
|
28
28
|
}, "strip", z.ZodTypeAny, {
|
|
29
29
|
customer_id: string;
|
|
30
|
-
entity_id?: string | undefined;
|
|
31
30
|
options?: {
|
|
32
31
|
feature_id: string;
|
|
33
32
|
quantity: number;
|
|
34
33
|
}[] | undefined;
|
|
35
34
|
metadata?: Record<string, string> | undefined;
|
|
35
|
+
entity_id?: string | undefined;
|
|
36
36
|
product_id?: string | undefined;
|
|
37
37
|
product_ids?: string[] | undefined;
|
|
38
38
|
free_trial?: boolean | undefined;
|
|
@@ -44,12 +44,12 @@ declare const AttachParamsSchema: z.ZodObject<{
|
|
|
44
44
|
reward?: string | undefined;
|
|
45
45
|
}, {
|
|
46
46
|
customer_id: string;
|
|
47
|
-
entity_id?: string | undefined;
|
|
48
47
|
options?: {
|
|
49
48
|
feature_id: string;
|
|
50
49
|
quantity: number;
|
|
51
50
|
}[] | undefined;
|
|
52
51
|
metadata?: Record<string, string> | undefined;
|
|
52
|
+
entity_id?: string | undefined;
|
|
53
53
|
product_id?: string | undefined;
|
|
54
54
|
product_ids?: string[] | undefined;
|
|
55
55
|
free_trial?: boolean | undefined;
|
|
@@ -89,18 +89,18 @@ declare const TrackParamsSchema: z.ZodObject<{
|
|
|
89
89
|
entity_data: z.ZodOptional<z.ZodAny>;
|
|
90
90
|
}, "strip", z.ZodTypeAny, {
|
|
91
91
|
customer_id: string;
|
|
92
|
-
feature_id?: string | undefined;
|
|
93
|
-
entity_id?: string | undefined;
|
|
94
92
|
value?: number | undefined;
|
|
93
|
+
entity_id?: string | undefined;
|
|
94
|
+
feature_id?: string | undefined;
|
|
95
95
|
customer_data?: any;
|
|
96
96
|
entity_data?: any;
|
|
97
97
|
event_name?: string | undefined;
|
|
98
98
|
idempotency_key?: string | undefined;
|
|
99
99
|
}, {
|
|
100
100
|
customer_id: string;
|
|
101
|
-
feature_id?: string | undefined;
|
|
102
|
-
entity_id?: string | undefined;
|
|
103
101
|
value?: number | undefined;
|
|
102
|
+
entity_id?: string | undefined;
|
|
103
|
+
feature_id?: string | undefined;
|
|
104
104
|
customer_data?: any;
|
|
105
105
|
entity_data?: any;
|
|
106
106
|
event_name?: string | undefined;
|
|
@@ -128,8 +128,8 @@ declare const CheckParamsSchema: z.ZodObject<{
|
|
|
128
128
|
}>>;
|
|
129
129
|
}, "strip", z.ZodTypeAny, {
|
|
130
130
|
customer_id: string;
|
|
131
|
-
feature_id?: string | undefined;
|
|
132
131
|
entity_id?: string | undefined;
|
|
132
|
+
feature_id?: string | undefined;
|
|
133
133
|
required_balance?: number | undefined;
|
|
134
134
|
product_id?: string | undefined;
|
|
135
135
|
customer_data?: any;
|
|
@@ -141,8 +141,8 @@ declare const CheckParamsSchema: z.ZodObject<{
|
|
|
141
141
|
with_preview?: boolean | undefined;
|
|
142
142
|
}, {
|
|
143
143
|
customer_id: string;
|
|
144
|
-
feature_id?: string | undefined;
|
|
145
144
|
entity_id?: string | undefined;
|
|
145
|
+
feature_id?: string | undefined;
|
|
146
146
|
required_balance?: number | undefined;
|
|
147
147
|
product_id?: string | undefined;
|
|
148
148
|
customer_data?: any;
|
|
@@ -240,18 +240,18 @@ declare class Autumn {
|
|
|
240
240
|
redeemCode: (params: RedeemReferralCodeParams) => Promise<Result<any, AutumnError>>;
|
|
241
241
|
};
|
|
242
242
|
static attach: (params: AttachParams) => Promise<Result<{
|
|
243
|
-
customer_id: string;
|
|
244
243
|
code: string;
|
|
245
244
|
message: string;
|
|
245
|
+
customer_id: string;
|
|
246
246
|
product_ids: string[];
|
|
247
247
|
customer_data?: any;
|
|
248
248
|
checkout_url?: string | undefined;
|
|
249
249
|
}, AutumnError>>;
|
|
250
250
|
static usage: (params: UsageParams) => Promise<Result<UsageResult, AutumnError>>;
|
|
251
251
|
attach(params: AttachParams): Promise<Result<{
|
|
252
|
-
customer_id: string;
|
|
253
252
|
code: string;
|
|
254
253
|
message: string;
|
|
254
|
+
customer_id: string;
|
|
255
255
|
product_ids: string[];
|
|
256
256
|
customer_data?: any;
|
|
257
257
|
checkout_url?: string | undefined;
|
|
@@ -285,9 +285,9 @@ declare class Autumn {
|
|
|
285
285
|
* Please use the new track() method instead.
|
|
286
286
|
*/
|
|
287
287
|
static event: (params: TrackParams) => Promise<Result<{
|
|
288
|
-
customer_id: string;
|
|
289
|
-
code: string;
|
|
290
288
|
id: string;
|
|
289
|
+
code: string;
|
|
290
|
+
customer_id: string;
|
|
291
291
|
feature_id?: string | undefined;
|
|
292
292
|
event_name?: string | undefined;
|
|
293
293
|
}, AutumnError>>;
|
|
@@ -296,23 +296,23 @@ declare class Autumn {
|
|
|
296
296
|
* Please use the new track() method instead.
|
|
297
297
|
*/
|
|
298
298
|
event(params: TrackParams): Promise<Result<{
|
|
299
|
-
customer_id: string;
|
|
300
|
-
code: string;
|
|
301
299
|
id: string;
|
|
300
|
+
code: string;
|
|
301
|
+
customer_id: string;
|
|
302
302
|
feature_id?: string | undefined;
|
|
303
303
|
event_name?: string | undefined;
|
|
304
304
|
}, AutumnError>>;
|
|
305
305
|
static track: (params: TrackParams) => Promise<Result<{
|
|
306
|
-
customer_id: string;
|
|
307
|
-
code: string;
|
|
308
306
|
id: string;
|
|
307
|
+
code: string;
|
|
308
|
+
customer_id: string;
|
|
309
309
|
feature_id?: string | undefined;
|
|
310
310
|
event_name?: string | undefined;
|
|
311
311
|
}, AutumnError>>;
|
|
312
312
|
track(params: TrackParams): Promise<Result<{
|
|
313
|
-
customer_id: string;
|
|
314
|
-
code: string;
|
|
315
313
|
id: string;
|
|
314
|
+
code: string;
|
|
315
|
+
customer_id: string;
|
|
316
316
|
feature_id?: string | undefined;
|
|
317
317
|
event_name?: string | undefined;
|
|
318
318
|
}, AutumnError>>;
|
|
@@ -362,11 +362,11 @@ declare const RedeemReferralCodeParamsSchema: z.ZodObject<{
|
|
|
362
362
|
code: z.ZodString;
|
|
363
363
|
customer_id: z.ZodString;
|
|
364
364
|
}, "strip", z.ZodTypeAny, {
|
|
365
|
-
customer_id: string;
|
|
366
365
|
code: string;
|
|
367
|
-
}, {
|
|
368
366
|
customer_id: string;
|
|
367
|
+
}, {
|
|
369
368
|
code: string;
|
|
369
|
+
customer_id: string;
|
|
370
370
|
}>;
|
|
371
371
|
type RedeemReferralCodeParams = z.infer<typeof RedeemReferralCodeParamsSchema>;
|
|
372
372
|
|
|
@@ -191,6 +191,7 @@ interface CustomerProduct {
|
|
|
191
191
|
status: ProductStatus;
|
|
192
192
|
started_at: number;
|
|
193
193
|
canceled_at: number | null;
|
|
194
|
+
version: number;
|
|
194
195
|
subscription_ids?: string[] | null;
|
|
195
196
|
current_period_start?: number | null;
|
|
196
197
|
current_period_end?: number | null;
|
|
@@ -230,15 +231,15 @@ declare const CreateCustomerParamsSchema: z.ZodObject<{
|
|
|
230
231
|
expand: z.ZodOptional<z.ZodArray<z.ZodEnum<["invoices", "rewards", "trials_used", "entities", "referrals", "payment_method"]>, "many">>;
|
|
231
232
|
}, "strip", z.ZodTypeAny, {
|
|
232
233
|
id?: string | null | undefined;
|
|
233
|
-
name?: string | null | undefined;
|
|
234
234
|
email?: string | null | undefined;
|
|
235
|
+
name?: string | null | undefined;
|
|
235
236
|
fingerprint?: string | null | undefined;
|
|
236
237
|
metadata?: Record<string, any> | undefined;
|
|
237
238
|
expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
|
|
238
239
|
}, {
|
|
239
240
|
id?: string | null | undefined;
|
|
240
|
-
name?: string | null | undefined;
|
|
241
241
|
email?: string | null | undefined;
|
|
242
|
+
name?: string | null | undefined;
|
|
242
243
|
fingerprint?: string | null | undefined;
|
|
243
244
|
metadata?: Record<string, any> | undefined;
|
|
244
245
|
expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
|
|
@@ -191,6 +191,7 @@ interface CustomerProduct {
|
|
|
191
191
|
status: ProductStatus;
|
|
192
192
|
started_at: number;
|
|
193
193
|
canceled_at: number | null;
|
|
194
|
+
version: number;
|
|
194
195
|
subscription_ids?: string[] | null;
|
|
195
196
|
current_period_start?: number | null;
|
|
196
197
|
current_period_end?: number | null;
|
|
@@ -230,15 +231,15 @@ declare const CreateCustomerParamsSchema: z.ZodObject<{
|
|
|
230
231
|
expand: z.ZodOptional<z.ZodArray<z.ZodEnum<["invoices", "rewards", "trials_used", "entities", "referrals", "payment_method"]>, "many">>;
|
|
231
232
|
}, "strip", z.ZodTypeAny, {
|
|
232
233
|
id?: string | null | undefined;
|
|
233
|
-
name?: string | null | undefined;
|
|
234
234
|
email?: string | null | undefined;
|
|
235
|
+
name?: string | null | undefined;
|
|
235
236
|
fingerprint?: string | null | undefined;
|
|
236
237
|
metadata?: Record<string, any> | undefined;
|
|
237
238
|
expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
|
|
238
239
|
}, {
|
|
239
240
|
id?: string | null | undefined;
|
|
240
|
-
name?: string | null | undefined;
|
|
241
241
|
email?: string | null | undefined;
|
|
242
|
+
name?: string | null | undefined;
|
|
242
243
|
fingerprint?: string | null | undefined;
|
|
243
244
|
metadata?: Record<string, any> | undefined;
|
|
244
245
|
expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
|
-
import { C as CustomerData, B as BillingPortalParams } from './cusTypes-
|
|
2
|
+
import { C as CustomerData, B as BillingPortalParams } from './cusTypes-B8u88Vfq.mjs';
|
|
3
3
|
import 'zod';
|
|
4
4
|
|
|
5
5
|
declare const attachAction: (args: Omit<{
|
package/dist/sdk/index.d.mts
CHANGED
package/dist/sdk/index.d.ts
CHANGED