autumn-js 0.0.92-beta.1 → 0.0.92

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.
Files changed (131) hide show
  1. package/dist/libraries/backend/better-auth.d.mts +33 -33
  2. package/dist/libraries/backend/better-auth.d.ts +33 -33
  3. package/dist/libraries/backend/express.d.mts +1 -1
  4. package/dist/libraries/backend/express.d.ts +1 -1
  5. package/dist/libraries/backend/{referralTypes-ecz_wESO.d.mts → referralTypes-C_LRkLGP.d.mts} +18 -18
  6. package/dist/libraries/backend/{referralTypes-BAYl5TR1.d.ts → referralTypes-KJHGHDgD.d.ts} +18 -18
  7. package/dist/libraries/backend/utils/withAuth.d.mts +1 -1
  8. package/dist/libraries/backend/utils/withAuth.d.ts +1 -1
  9. package/dist/libraries/react/AutumnContext.d.mts +4 -4
  10. package/dist/libraries/react/AutumnContext.d.ts +4 -4
  11. package/dist/libraries/react/AutumnContext.mjs +5 -5
  12. package/dist/libraries/react/BaseAutumnProvider.d.mts +4 -4
  13. package/dist/libraries/react/BaseAutumnProvider.d.ts +4 -4
  14. package/dist/libraries/react/BaseAutumnProvider.mjs +9 -9
  15. package/dist/libraries/react/{ReactAutumnClient-BiipnfQn.d.mts → ReactAutumnClient-BmHGkNH1.d.mts} +5 -5
  16. package/dist/libraries/react/{ReactAutumnClient-BTNcA_3b.d.ts → ReactAutumnClient-PGnPqPkr.d.ts} +5 -5
  17. package/dist/libraries/react/ReactAutumnProvider.d.mts +1 -1
  18. package/dist/libraries/react/ReactAutumnProvider.d.ts +1 -1
  19. package/dist/libraries/react/ReactAutumnProvider.mjs +10 -10
  20. package/dist/libraries/react/{chunk-TINC2IR4.mjs → chunk-6SDVW33H.mjs} +2 -2
  21. package/dist/libraries/react/{chunk-G3XBGOHR.mjs → chunk-DIJJCQ2N.mjs} +3 -3
  22. package/dist/libraries/react/{chunk-ITN754AD.mjs → chunk-HL4JNKWK.mjs} +1 -1
  23. package/dist/libraries/react/{chunk-67Y4DFV2.mjs → chunk-L3IZ2O3T.mjs} +3 -3
  24. package/dist/libraries/react/{chunk-TBKIB6DH.mjs → chunk-LPJSRHPQ.mjs} +1 -1
  25. package/dist/libraries/react/{chunk-SJAAUTL2.mjs → chunk-OGFFPM5T.mjs} +2 -2
  26. package/dist/libraries/react/{chunk-GK75OJJJ.mjs → chunk-PJK6OPCU.mjs} +2 -2
  27. package/dist/libraries/react/{chunk-3WP2MI55.mjs → chunk-RZW3QO6B.mjs} +2 -2
  28. package/dist/libraries/react/{chunk-6JOSRG5Z.mjs → chunk-SDZ5NW6G.mjs} +2 -2
  29. package/dist/libraries/react/{chunk-CHQRTGXF.mjs → chunk-TCCWWPEC.mjs} +2 -2
  30. package/dist/libraries/react/{chunk-4AYEAAQU.mjs → chunk-VH4FTCAC.mjs} +2 -2
  31. package/dist/libraries/react/{chunk-LKBUMRHE.mjs → chunk-Y6RO4AM2.mjs} +279 -279
  32. package/dist/libraries/react/client/ReactAutumnClient.d.mts +4 -4
  33. package/dist/libraries/react/client/ReactAutumnClient.d.ts +4 -4
  34. package/dist/libraries/react/client/ReactAutumnClient.mjs +4 -4
  35. package/dist/libraries/react/client/clientCompMethods.d.mts +4 -4
  36. package/dist/libraries/react/client/clientCompMethods.d.ts +4 -4
  37. package/dist/libraries/react/client/clientCusMethods.d.mts +4 -4
  38. package/dist/libraries/react/client/clientCusMethods.d.ts +4 -4
  39. package/dist/libraries/react/client/clientEntityMethods.d.mts +4 -4
  40. package/dist/libraries/react/client/clientEntityMethods.d.ts +4 -4
  41. package/dist/libraries/react/client/clientGenMethods.d.mts +4 -4
  42. package/dist/libraries/react/client/clientGenMethods.d.ts +4 -4
  43. package/dist/libraries/react/client/clientProdMethods.d.mts +4 -4
  44. package/dist/libraries/react/client/clientProdMethods.d.ts +4 -4
  45. package/dist/libraries/react/client/clientReferralMethods.d.mts +4 -4
  46. package/dist/libraries/react/client/clientReferralMethods.d.ts +4 -4
  47. package/dist/libraries/react/client/types/clientGenTypes.d.mts +4 -4
  48. package/dist/libraries/react/client/types/clientGenTypes.d.ts +4 -4
  49. package/dist/libraries/react/components/attach-dialog/attach-dialog-synced.css +1271 -0
  50. package/dist/libraries/react/components/attach-dialog/attach-dialog-synced.d.mts +1 -1
  51. package/dist/libraries/react/components/attach-dialog/attach-dialog-synced.d.ts +1 -1
  52. package/dist/libraries/react/components/attach-dialog/attach-dialog-synced.mjs +20 -20
  53. package/dist/libraries/react/components/attach-dialog/lib/attach-content.d.mts +1 -1
  54. package/dist/libraries/react/components/attach-dialog/lib/attach-content.d.ts +1 -1
  55. package/dist/libraries/react/components/check-dialog/check-dialog-synced.d.mts +1 -1
  56. package/dist/libraries/react/components/check-dialog/check-dialog-synced.d.ts +1 -1
  57. package/dist/libraries/react/components/check-dialog/lib/check-content.d.mts +1 -1
  58. package/dist/libraries/react/components/check-dialog/lib/check-content.d.ts +1 -1
  59. package/dist/libraries/react/components/pricing-table/pricing-table-synced.css +1271 -0
  60. package/dist/libraries/react/components/pricing-table/pricing-table-synced.d.mts +1 -1
  61. package/dist/libraries/react/components/pricing-table/pricing-table-synced.d.ts +1 -1
  62. package/dist/libraries/react/components/pricing-table/pricing-table-synced.mjs +20 -20
  63. package/dist/libraries/react/{cusTypes-Bf1qr9iE.d.ts → cusTypes-WaPJKeAb.d.mts} +3 -3
  64. package/dist/libraries/react/{cusTypes-Bf1qr9iE.d.mts → cusTypes-WaPJKeAb.d.ts} +3 -3
  65. package/dist/libraries/react/{entTypes-O8YXxhrA.d.ts → entTypes-D01S8gFX.d.ts} +1 -1
  66. package/dist/libraries/react/{entTypes-CscyyE1A.d.mts → entTypes-aIV0QUCW.d.mts} +1 -1
  67. package/dist/libraries/react/hooks/handleAllowed.d.mts +2 -2
  68. package/dist/libraries/react/hooks/handleAllowed.d.ts +2 -2
  69. package/dist/libraries/react/hooks/useAutumn.d.mts +2 -2
  70. package/dist/libraries/react/hooks/useAutumn.d.ts +2 -2
  71. package/dist/libraries/react/hooks/useAutumn.mjs +8 -8
  72. package/dist/libraries/react/hooks/useAutumnBase.d.mts +4 -4
  73. package/dist/libraries/react/hooks/useAutumnBase.d.ts +4 -4
  74. package/dist/libraries/react/hooks/useAutumnBase.mjs +7 -7
  75. package/dist/libraries/react/hooks/useCustomer.d.mts +4 -4
  76. package/dist/libraries/react/hooks/useCustomer.d.ts +4 -4
  77. package/dist/libraries/react/hooks/useCustomer.mjs +9 -9
  78. package/dist/libraries/react/hooks/useCustomerBase.d.mts +4 -4
  79. package/dist/libraries/react/hooks/useCustomerBase.d.ts +4 -4
  80. package/dist/libraries/react/hooks/useCustomerBase.mjs +8 -8
  81. package/dist/libraries/react/hooks/useEntity.d.mts +3 -3
  82. package/dist/libraries/react/hooks/useEntity.d.ts +3 -3
  83. package/dist/libraries/react/hooks/useEntity.mjs +9 -9
  84. package/dist/libraries/react/hooks/useEntityBase.d.mts +4 -4
  85. package/dist/libraries/react/hooks/useEntityBase.d.ts +4 -4
  86. package/dist/libraries/react/hooks/useEntityBase.mjs +8 -8
  87. package/dist/libraries/react/hooks/usePricingTable.d.mts +1 -1
  88. package/dist/libraries/react/hooks/usePricingTable.d.ts +1 -1
  89. package/dist/libraries/react/hooks/usePricingTable.mjs +7 -7
  90. package/dist/libraries/react/hooks/usePricingTableBase.d.mts +4 -4
  91. package/dist/libraries/react/hooks/usePricingTableBase.d.ts +4 -4
  92. package/dist/libraries/react/hooks/usePricingTableBase.mjs +6 -6
  93. package/dist/libraries/react/hooks/useProductsBase.mjs +5 -5
  94. package/dist/libraries/react/index.js +25 -0
  95. package/dist/libraries/react/index.mjs +25 -0
  96. package/dist/libraries/react/{response-CDZ_R5pb.d.mts → response-Bt5OMm4y.d.mts} +1 -1
  97. package/dist/libraries/react/{response-BHqAAnND.d.ts → response-CvPzWrT9.d.ts} +1 -1
  98. package/dist/next/client/NextAutumnClient.d.mts +11 -11
  99. package/dist/next/client/NextAutumnClient.d.ts +11 -11
  100. package/dist/next/client/NextAutumnProvider.d.mts +1 -1
  101. package/dist/next/client/NextAutumnProvider.d.ts +1 -1
  102. package/dist/next/client/{clientGenTypes-B28imYzT.d.mts → clientGenTypes-BPjTbeG-.d.mts} +19 -19
  103. package/dist/next/client/{clientGenTypes-D46edNj5.d.ts → clientGenTypes-Bqecpl58.d.ts} +19 -19
  104. package/dist/next/client/clientUtils.d.mts +2 -2
  105. package/dist/next/client/clientUtils.d.ts +2 -2
  106. package/dist/next/client/{entTypes-CJx3GLTt.d.mts → entTypes-B-2_9hzP.d.mts} +1 -1
  107. package/dist/next/client/{entTypes-qYfQsZ9u.d.ts → entTypes-Dq2mbehl.d.ts} +1 -1
  108. package/dist/next/client/hooks/useAutumn.d.mts +2 -2
  109. package/dist/next/client/hooks/useAutumn.d.ts +2 -2
  110. package/dist/next/client/hooks/useCustomer.d.mts +3 -3
  111. package/dist/next/client/hooks/useCustomer.d.ts +3 -3
  112. package/dist/next/client/hooks/useEntity.d.mts +3 -3
  113. package/dist/next/client/hooks/useEntity.d.ts +3 -3
  114. package/dist/next/client/hooks/usePricingTable.d.mts +1 -1
  115. package/dist/next/client/hooks/usePricingTable.d.ts +1 -1
  116. package/dist/next/client/types.d.mts +2 -2
  117. package/dist/next/client/types.d.ts +2 -2
  118. package/dist/next/server/auth/withNextAuth.d.mts +1 -1
  119. package/dist/next/server/auth/withNextAuth.d.ts +1 -1
  120. package/dist/next/server/componentActions.d.mts +1 -1
  121. package/dist/next/server/componentActions.d.ts +1 -1
  122. package/dist/next/server/cusActions.d.mts +5 -5
  123. package/dist/next/server/cusActions.d.ts +5 -5
  124. package/dist/next/server/genActions.d.mts +1 -1
  125. package/dist/next/server/genActions.d.ts +1 -1
  126. package/package.json +1 -1
  127. package/dist/libraries/react/{chunk-QAHVMSK4.mjs → chunk-NCPXL3J2.mjs} +13 -13
  128. package/dist/next/client/{cusTypes-CGXuXu_Y.d.mts → cusTypes-D8lhXGaX.d.mts} +2 -2
  129. package/dist/next/client/{cusTypes-CGXuXu_Y.d.ts → cusTypes-D8lhXGaX.d.ts} +2 -2
  130. package/dist/next/server/{cusTypes-H4mqijcm.d.mts → cusTypes-C86FOl99.d.mts} +2 -2
  131. package/dist/next/server/{cusTypes-H4mqijcm.d.ts → cusTypes-C86FOl99.d.ts} +2 -2
@@ -1,4 +1,4 @@
1
- import { i as CheckFeatureResult, j as CheckProductResult } from './cusTypes-CGXuXu_Y.js';
1
+ import { i as CheckFeatureResult, j as CheckProductResult } from './cusTypes-D8lhXGaX.js';
2
2
  import { z } from 'zod';
3
3
  import { A as AutumnError } from './error-DHbclCVh.js';
4
4
  import * as react from 'react';
@@ -16,19 +16,19 @@ declare const AttachResultSchema: z.ZodObject<{
16
16
  message: z.ZodString;
17
17
  customer_data: z.ZodOptional<z.ZodAny>;
18
18
  }, "strip", z.ZodTypeAny, {
19
+ customer_id: string;
19
20
  code: string;
20
21
  message: string;
21
- customer_id: string;
22
22
  product_ids: string[];
23
- checkout_url?: string | undefined;
24
23
  customer_data?: any;
24
+ checkout_url?: string | undefined;
25
25
  }, {
26
+ customer_id: string;
26
27
  code: string;
27
28
  message: string;
28
- customer_id: string;
29
29
  product_ids: string[];
30
- checkout_url?: string | undefined;
31
30
  customer_data?: any;
31
+ checkout_url?: string | undefined;
32
32
  }>;
33
33
  type AttachResult = z.infer<typeof AttachResultSchema>;
34
34
  interface TrackResult {
@@ -64,11 +64,11 @@ declare const AttachParamsSchema: z.ZodObject<{
64
64
  featureId: z.ZodString;
65
65
  quantity: z.ZodNumber;
66
66
  }, "strip", z.ZodTypeAny, {
67
- featureId: string;
68
67
  quantity: number;
69
- }, {
70
68
  featureId: string;
69
+ }, {
71
70
  quantity: number;
71
+ featureId: string;
72
72
  }>, "many">>;
73
73
  productIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
74
74
  freeTrial: z.ZodOptional<z.ZodBoolean>;
@@ -82,37 +82,37 @@ declare const AttachParamsSchema: z.ZodObject<{
82
82
  checkoutSessionParams: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
83
83
  }, "strip", z.ZodTypeAny, {
84
84
  options?: {
85
- featureId: string;
86
85
  quantity: number;
86
+ featureId: string;
87
87
  }[] | undefined;
88
88
  metadata?: Record<string, string> | undefined;
89
+ reward?: string | undefined;
89
90
  productId?: string | undefined;
90
91
  entityId?: string | undefined;
91
92
  productIds?: string[] | undefined;
92
93
  freeTrial?: boolean | undefined;
93
94
  successUrl?: string | undefined;
94
95
  forceCheckout?: boolean | undefined;
95
- dialog?: ((args_0: any, ...args: unknown[]) => react.ReactNode | JSX.Element) | undefined;
96
+ dialog?: ((args_0: any, ...args: unknown[]) => JSX.Element | react.ReactNode) | undefined;
96
97
  entityData?: any;
97
98
  openInNewTab?: boolean | undefined;
98
- reward?: string | undefined;
99
99
  checkoutSessionParams?: Record<string, any> | undefined;
100
100
  }, {
101
101
  options?: {
102
- featureId: string;
103
102
  quantity: number;
103
+ featureId: string;
104
104
  }[] | undefined;
105
105
  metadata?: Record<string, string> | undefined;
106
+ reward?: string | undefined;
106
107
  productId?: string | undefined;
107
108
  entityId?: string | undefined;
108
109
  productIds?: string[] | undefined;
109
110
  freeTrial?: boolean | undefined;
110
111
  successUrl?: string | undefined;
111
112
  forceCheckout?: boolean | undefined;
112
- dialog?: ((args_0: any, ...args: unknown[]) => react.ReactNode | JSX.Element) | undefined;
113
+ dialog?: ((args_0: any, ...args: unknown[]) => JSX.Element | react.ReactNode) | undefined;
113
114
  entityData?: any;
114
115
  openInNewTab?: boolean | undefined;
115
- reward?: string | undefined;
116
116
  checkoutSessionParams?: Record<string, any> | undefined;
117
117
  }>;
118
118
  type AttachParams = z.infer<typeof AttachParamsSchema>;
@@ -140,19 +140,19 @@ declare const CheckParamsSchema: z.ZodObject<{
140
140
  dialog: z.ZodOptional<z.ZodFunction<z.ZodTuple<[z.ZodAny], z.ZodUnknown>, z.ZodUnion<[z.ZodType<JSX.Element, z.ZodTypeDef, JSX.Element>, z.ZodType<react.ReactNode, z.ZodTypeDef, react.ReactNode>]>>>;
141
141
  entityData: z.ZodOptional<z.ZodAny>;
142
142
  }, "strip", z.ZodTypeAny, {
143
+ featureId?: string | undefined;
143
144
  productId?: string | undefined;
144
145
  entityId?: string | undefined;
145
- featureId?: string | undefined;
146
- dialog?: ((args_0: any, ...args: unknown[]) => react.ReactNode | JSX.Element) | undefined;
146
+ dialog?: ((args_0: any, ...args: unknown[]) => JSX.Element | react.ReactNode) | undefined;
147
147
  entityData?: any;
148
148
  requiredBalance?: number | undefined;
149
149
  sendEvent?: boolean | undefined;
150
150
  withPreview?: boolean | undefined;
151
151
  }, {
152
+ featureId?: string | undefined;
152
153
  productId?: string | undefined;
153
154
  entityId?: string | undefined;
154
- featureId?: string | undefined;
155
- dialog?: ((args_0: any, ...args: unknown[]) => react.ReactNode | JSX.Element) | undefined;
155
+ dialog?: ((args_0: any, ...args: unknown[]) => JSX.Element | react.ReactNode) | undefined;
156
156
  entityData?: any;
157
157
  requiredBalance?: number | undefined;
158
158
  sendEvent?: boolean | undefined;
@@ -168,15 +168,15 @@ declare const TrackParamsSchema: z.ZodObject<{
168
168
  entityData: z.ZodOptional<z.ZodAny>;
169
169
  }, "strip", z.ZodTypeAny, {
170
170
  value?: number | undefined;
171
- entityId?: string | undefined;
172
171
  featureId?: string | undefined;
172
+ entityId?: string | undefined;
173
173
  entityData?: any;
174
174
  eventName?: string | undefined;
175
175
  idempotencyKey?: string | undefined;
176
176
  }, {
177
177
  value?: number | undefined;
178
- entityId?: string | undefined;
179
178
  featureId?: string | undefined;
179
+ entityId?: string | undefined;
180
180
  entityData?: any;
181
181
  eventName?: string | undefined;
182
182
  idempotencyKey?: string | undefined;
@@ -1,7 +1,7 @@
1
1
  import { AutumnClientError, PricingTableProduct } from './types.mjs';
2
- import './cusTypes-CGXuXu_Y.mjs';
2
+ import './cusTypes-D8lhXGaX.mjs';
3
3
  import 'zod';
4
- import './entTypes-CJx3GLTt.mjs';
4
+ import './entTypes-B-2_9hzP.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-CGXuXu_Y.js';
2
+ import './cusTypes-D8lhXGaX.js';
3
3
  import 'zod';
4
- import './entTypes-qYfQsZ9u.js';
4
+ import './entTypes-Dq2mbehl.js';
5
5
 
6
6
  declare const toClientErrorResponse: (error: any) => {
7
7
  data: null;
@@ -1,4 +1,4 @@
1
- import { b as CustomerProduct, c as CustomerFeature, d as CustomerInvoice } from './cusTypes-CGXuXu_Y.mjs';
1
+ import { b as CustomerProduct, c as CustomerFeature, d as CustomerInvoice } from './cusTypes-D8lhXGaX.mjs';
2
2
 
3
3
  type EntityExpandOption = "invoices";
4
4
 
@@ -1,4 +1,4 @@
1
- import { b as CustomerProduct, c as CustomerFeature, d as CustomerInvoice } from './cusTypes-CGXuXu_Y.js';
1
+ import { b as CustomerProduct, c as CustomerFeature, d as CustomerInvoice } from './cusTypes-D8lhXGaX.js';
2
2
 
3
3
  type EntityExpandOption = "invoices";
4
4
 
@@ -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-B28imYzT.mjs';
2
- import { B as BillingPortalResult } from '../cusTypes-CGXuXu_Y.mjs';
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-BPjTbeG-.mjs';
2
+ import { B as BillingPortalResult } from '../cusTypes-D8lhXGaX.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-D46edNj5.js';
2
- import { B as BillingPortalResult } from '../cusTypes-CGXuXu_Y.js';
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-Bqecpl58.js';
2
+ import { B as BillingPortalResult } from '../cusTypes-D8lhXGaX.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-B28imYzT.mjs';
3
- import { h as CustomerExpandOption, a as Customer, B as BillingPortalResult } from '../cusTypes-CGXuXu_Y.mjs';
4
- import { E as Entity } from '../entTypes-CJx3GLTt.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-BPjTbeG-.mjs';
3
+ import { h as CustomerExpandOption, a as Customer, B as BillingPortalResult } from '../cusTypes-D8lhXGaX.mjs';
4
+ import { E as Entity } from '../entTypes-B-2_9hzP.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-D46edNj5.js';
3
- import { h as CustomerExpandOption, a as Customer, B as BillingPortalResult } from '../cusTypes-CGXuXu_Y.js';
4
- import { E as Entity } from '../entTypes-qYfQsZ9u.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-Bqecpl58.js';
3
+ import { h as CustomerExpandOption, a as Customer, B as BillingPortalResult } from '../cusTypes-D8lhXGaX.js';
4
+ import { E as Entity } from '../entTypes-Dq2mbehl.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, e as CancelResult, T as TrackParams, c as TrackResult } from '../clientGenTypes-B28imYzT.mjs';
2
- import { G as GetEntityParams, E as Entity } from '../entTypes-CJx3GLTt.mjs';
1
+ import { C as CheckParams, a as AutumnPromise, b as CheckResult, A as AttachParams, d as CancelParams, e as CancelResult, T as TrackParams, c as TrackResult } from '../clientGenTypes-BPjTbeG-.mjs';
2
+ import { G as GetEntityParams, E as Entity } from '../entTypes-B-2_9hzP.mjs';
3
3
  import { A as AllowedParams } from '../handleAllowed-B8TBAzfI.mjs';
4
4
  import * as swr from 'swr';
5
- import '../cusTypes-CGXuXu_Y.mjs';
5
+ import '../cusTypes-D8lhXGaX.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, e as CancelResult, T as TrackParams, c as TrackResult } from '../clientGenTypes-D46edNj5.js';
2
- import { G as GetEntityParams, E as Entity } from '../entTypes-qYfQsZ9u.js';
1
+ import { C as CheckParams, a as AutumnPromise, b as CheckResult, A as AttachParams, d as CancelParams, e as CancelResult, T as TrackParams, c as TrackResult } from '../clientGenTypes-Bqecpl58.js';
2
+ import { G as GetEntityParams, E as Entity } from '../entTypes-Dq2mbehl.js';
3
3
  import { A as AllowedParams } from '../handleAllowed-B8TBAzfI.js';
4
4
  import * as swr from 'swr';
5
- import '../cusTypes-CGXuXu_Y.js';
5
+ import '../cusTypes-D8lhXGaX.js';
6
6
  import 'zod';
7
7
  import '../error-DHbclCVh.js';
8
8
  import 'react';
@@ -1,6 +1,6 @@
1
1
  import * as swr from 'swr';
2
2
  import { A as AutumnError } from '../error-DHbclCVh.mjs';
3
- import { P as Product } from '../cusTypes-CGXuXu_Y.mjs';
3
+ import { P as Product } from '../cusTypes-D8lhXGaX.mjs';
4
4
  import 'zod';
5
5
 
6
6
  interface ProductDetails {
@@ -1,6 +1,6 @@
1
1
  import * as swr from 'swr';
2
2
  import { A as AutumnError } from '../error-DHbclCVh.js';
3
- import { P as Product } from '../cusTypes-CGXuXu_Y.js';
3
+ import { P as Product } from '../cusTypes-D8lhXGaX.js';
4
4
  import 'zod';
5
5
 
6
6
  interface ProductDetails {
@@ -1,5 +1,5 @@
1
- import { C as CustomerData, a as Customer } from './cusTypes-CGXuXu_Y.mjs';
2
- import { E as Entity } from './entTypes-CJx3GLTt.mjs';
1
+ import { C as CustomerData, a as Customer } from './cusTypes-D8lhXGaX.mjs';
2
+ import { E as Entity } from './entTypes-B-2_9hzP.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-CGXuXu_Y.js';
2
- import { E as Entity } from './entTypes-qYfQsZ9u.js';
1
+ import { C as CustomerData, a as Customer } from './cusTypes-D8lhXGaX.js';
2
+ import { E as Entity } from './entTypes-Dq2mbehl.js';
3
3
  import 'zod';
4
4
 
5
5
  interface ProductDetails {
@@ -1,4 +1,4 @@
1
- import { C as CustomerData } from '../cusTypes-H4mqijcm.mjs';
1
+ import { C as CustomerData } from '../cusTypes-C86FOl99.mjs';
2
2
  import 'zod';
3
3
 
4
4
  declare const withAuth: <T extends {
@@ -1,4 +1,4 @@
1
- import { C as CustomerData } from '../cusTypes-H4mqijcm.js';
1
+ import { C as CustomerData } from '../cusTypes-C86FOl99.js';
2
2
  import 'zod';
3
3
 
4
4
  declare const withAuth: <T extends {
@@ -1,4 +1,4 @@
1
- import { C as CustomerData } from './cusTypes-H4mqijcm.mjs';
1
+ import { C as CustomerData } from './cusTypes-C86FOl99.mjs';
2
2
  import 'zod';
3
3
 
4
4
  declare const getPricingTableAction: (args: Omit<{
@@ -1,4 +1,4 @@
1
- import { C as CustomerData } from './cusTypes-H4mqijcm.js';
1
+ import { C as CustomerData } from './cusTypes-C86FOl99.js';
2
2
  import 'zod';
3
3
 
4
4
  declare const getPricingTableAction: (args: Omit<{
@@ -1,4 +1,4 @@
1
- import { a as CustomerProduct, b as CustomerFeature, c as CustomerInvoice, C as CustomerData, d as CheckFeatureResult, e as CheckProductResult, G as GetCustomerParams, f as Customer, g as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, P as Product, h as CreateProductParams, L as ListProductsParams } from './cusTypes-H4mqijcm.mjs';
1
+ import { a as CustomerProduct, b as CustomerFeature, c as CustomerInvoice, C as CustomerData, d as CheckFeatureResult, e as CheckProductResult, G as GetCustomerParams, f as Customer, g as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, P as Product, h as CreateProductParams, L as ListProductsParams } from './cusTypes-C86FOl99.mjs';
2
2
  import { z } from 'zod';
3
3
  import { R as Result, A as AutumnError } from './response-eH4S4sg0.mjs';
4
4
 
@@ -59,12 +59,12 @@ declare const AttachParamsSchema: z.ZodObject<{
59
59
  reward: z.ZodOptional<z.ZodString>;
60
60
  }, "strip", z.ZodTypeAny, {
61
61
  customer_id: string;
62
- entity_id?: string | undefined;
63
62
  options?: {
64
63
  feature_id: string;
65
64
  quantity: number;
66
65
  }[] | undefined;
67
66
  metadata?: Record<string, string> | undefined;
67
+ entity_id?: string | undefined;
68
68
  product_id?: string | undefined;
69
69
  product_ids?: string[] | undefined;
70
70
  free_trial?: boolean | undefined;
@@ -76,12 +76,12 @@ declare const AttachParamsSchema: z.ZodObject<{
76
76
  reward?: string | undefined;
77
77
  }, {
78
78
  customer_id: string;
79
- entity_id?: string | undefined;
80
79
  options?: {
81
80
  feature_id: string;
82
81
  quantity: number;
83
82
  }[] | undefined;
84
83
  metadata?: Record<string, string> | undefined;
84
+ entity_id?: string | undefined;
85
85
  product_id?: string | undefined;
86
86
  product_ids?: string[] | undefined;
87
87
  free_trial?: boolean | undefined;
@@ -218,18 +218,18 @@ declare class Autumn {
218
218
  redeemCode: (params: RedeemReferralCodeParams) => Promise<Result<any, AutumnError>>;
219
219
  };
220
220
  static attach: (params: AttachParams) => Promise<Result<{
221
- customer_id: string;
222
221
  code: string;
223
222
  message: string;
223
+ customer_id: string;
224
224
  product_ids: string[];
225
225
  customer_data?: any;
226
226
  checkout_url?: string | undefined;
227
227
  }, AutumnError>>;
228
228
  static usage: (params: UsageParams) => Promise<Result<UsageResult, AutumnError>>;
229
229
  attach(params: AttachParams): Promise<Result<{
230
- customer_id: string;
231
230
  code: string;
232
231
  message: string;
232
+ customer_id: string;
233
233
  product_ids: string[];
234
234
  customer_data?: any;
235
235
  checkout_url?: string | undefined;
@@ -1,4 +1,4 @@
1
- import { a as CustomerProduct, b as CustomerFeature, c as CustomerInvoice, C as CustomerData, d as CheckFeatureResult, e as CheckProductResult, G as GetCustomerParams, f as Customer, g as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, P as Product, h as CreateProductParams, L as ListProductsParams } from './cusTypes-H4mqijcm.js';
1
+ import { a as CustomerProduct, b as CustomerFeature, c as CustomerInvoice, C as CustomerData, d as CheckFeatureResult, e as CheckProductResult, G as GetCustomerParams, f as Customer, g as CreateCustomerParams, U as UpdateCustomerParams, B as BillingPortalParams, P as Product, h as CreateProductParams, L as ListProductsParams } from './cusTypes-C86FOl99.js';
2
2
  import { z } from 'zod';
3
3
  import { R as Result, A as AutumnError } from './response-eH4S4sg0.js';
4
4
 
@@ -59,12 +59,12 @@ declare const AttachParamsSchema: z.ZodObject<{
59
59
  reward: z.ZodOptional<z.ZodString>;
60
60
  }, "strip", z.ZodTypeAny, {
61
61
  customer_id: string;
62
- entity_id?: string | undefined;
63
62
  options?: {
64
63
  feature_id: string;
65
64
  quantity: number;
66
65
  }[] | undefined;
67
66
  metadata?: Record<string, string> | undefined;
67
+ entity_id?: string | undefined;
68
68
  product_id?: string | undefined;
69
69
  product_ids?: string[] | undefined;
70
70
  free_trial?: boolean | undefined;
@@ -76,12 +76,12 @@ declare const AttachParamsSchema: z.ZodObject<{
76
76
  reward?: string | undefined;
77
77
  }, {
78
78
  customer_id: string;
79
- entity_id?: string | undefined;
80
79
  options?: {
81
80
  feature_id: string;
82
81
  quantity: number;
83
82
  }[] | undefined;
84
83
  metadata?: Record<string, string> | undefined;
84
+ entity_id?: string | undefined;
85
85
  product_id?: string | undefined;
86
86
  product_ids?: string[] | undefined;
87
87
  free_trial?: boolean | undefined;
@@ -218,18 +218,18 @@ declare class Autumn {
218
218
  redeemCode: (params: RedeemReferralCodeParams) => Promise<Result<any, AutumnError>>;
219
219
  };
220
220
  static attach: (params: AttachParams) => Promise<Result<{
221
- customer_id: string;
222
221
  code: string;
223
222
  message: string;
223
+ customer_id: string;
224
224
  product_ids: string[];
225
225
  customer_data?: any;
226
226
  checkout_url?: string | undefined;
227
227
  }, AutumnError>>;
228
228
  static usage: (params: UsageParams) => Promise<Result<UsageResult, AutumnError>>;
229
229
  attach(params: AttachParams): Promise<Result<{
230
- customer_id: string;
231
230
  code: string;
232
231
  message: string;
232
+ customer_id: string;
233
233
  product_ids: string[];
234
234
  customer_data?: any;
235
235
  checkout_url?: string | undefined;
@@ -1,5 +1,5 @@
1
1
  import * as react from 'react';
2
- import { C as CustomerData, B as BillingPortalParams } from './cusTypes-H4mqijcm.mjs';
2
+ import { C as CustomerData, B as BillingPortalParams } from './cusTypes-C86FOl99.mjs';
3
3
  import 'zod';
4
4
 
5
5
  declare const attachAction: (args: Omit<{
@@ -1,5 +1,5 @@
1
1
  import * as react from 'react';
2
- import { C as CustomerData, B as BillingPortalParams } from './cusTypes-H4mqijcm.js';
2
+ import { C as CustomerData, B as BillingPortalParams } from './cusTypes-C86FOl99.js';
3
3
  import 'zod';
4
4
 
5
5
  declare const attachAction: (args: Omit<{
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "autumn-js",
3
3
  "description": "Autumn JS Library",
4
- "version": "0.0.92-beta.1",
4
+ "version": "0.0.92",
5
5
  "main": "./dist/index.js",
6
6
  "files": [
7
7
  "dist",
@@ -1,5 +1,18 @@
1
1
  "use client";
2
2
 
3
+ import {
4
+ createEntityMethod,
5
+ deleteEntityMethod,
6
+ getEntityMethod
7
+ } from "./chunk-V5PKOA5A.mjs";
8
+ import {
9
+ attachMethod,
10
+ cancelMethod,
11
+ checkMethod,
12
+ openBillingPortalMethod,
13
+ setupPaymentMethod,
14
+ trackMethod
15
+ } from "./chunk-JNM4BLTM.mjs";
3
16
  import {
4
17
  listProductsMethod
5
18
  } from "./chunk-YUV2Y2RW.mjs";
@@ -19,19 +32,6 @@ import {
19
32
  import {
20
33
  createCustomerMethod
21
34
  } from "./chunk-TGX6UKKS.mjs";
22
- import {
23
- createEntityMethod,
24
- deleteEntityMethod,
25
- getEntityMethod
26
- } from "./chunk-V5PKOA5A.mjs";
27
- import {
28
- attachMethod,
29
- cancelMethod,
30
- checkMethod,
31
- openBillingPortalMethod,
32
- setupPaymentMethod,
33
- trackMethod
34
- } from "./chunk-JNM4BLTM.mjs";
35
35
 
36
36
  // src/sdk/error.ts
37
37
  var AutumnError = class _AutumnError extends Error {
@@ -216,15 +216,15 @@ declare const CreateCustomerParamsSchema: z.ZodObject<{
216
216
  expand: z.ZodOptional<z.ZodArray<z.ZodEnum<["invoices", "rewards", "trials_used", "entities", "referrals", "payment_method"]>, "many">>;
217
217
  }, "strip", z.ZodTypeAny, {
218
218
  id?: string | null | undefined;
219
- email?: string | null | undefined;
220
219
  name?: string | null | undefined;
220
+ email?: string | null | undefined;
221
221
  fingerprint?: string | null | undefined;
222
222
  metadata?: Record<string, any> | undefined;
223
223
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
224
224
  }, {
225
225
  id?: string | null | undefined;
226
- email?: string | null | undefined;
227
226
  name?: string | null | undefined;
227
+ email?: string | null | undefined;
228
228
  fingerprint?: string | null | undefined;
229
229
  metadata?: Record<string, any> | undefined;
230
230
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
@@ -216,15 +216,15 @@ declare const CreateCustomerParamsSchema: z.ZodObject<{
216
216
  expand: z.ZodOptional<z.ZodArray<z.ZodEnum<["invoices", "rewards", "trials_used", "entities", "referrals", "payment_method"]>, "many">>;
217
217
  }, "strip", z.ZodTypeAny, {
218
218
  id?: string | null | undefined;
219
- email?: string | null | undefined;
220
219
  name?: string | null | undefined;
220
+ email?: string | null | undefined;
221
221
  fingerprint?: string | null | undefined;
222
222
  metadata?: Record<string, any> | undefined;
223
223
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
224
224
  }, {
225
225
  id?: string | null | undefined;
226
- email?: string | null | undefined;
227
226
  name?: string | null | undefined;
227
+ email?: string | null | undefined;
228
228
  fingerprint?: string | null | undefined;
229
229
  metadata?: Record<string, any> | undefined;
230
230
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
@@ -230,15 +230,15 @@ declare const CreateCustomerParamsSchema: z.ZodObject<{
230
230
  expand: z.ZodOptional<z.ZodArray<z.ZodEnum<["invoices", "rewards", "trials_used", "entities", "referrals", "payment_method"]>, "many">>;
231
231
  }, "strip", z.ZodTypeAny, {
232
232
  id?: string | null | undefined;
233
- name?: string | null | undefined;
234
233
  email?: string | null | undefined;
234
+ name?: string | null | undefined;
235
235
  fingerprint?: string | null | undefined;
236
236
  metadata?: Record<string, any> | undefined;
237
237
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
238
238
  }, {
239
239
  id?: string | null | undefined;
240
- name?: string | null | undefined;
241
240
  email?: string | null | undefined;
241
+ name?: string | null | undefined;
242
242
  fingerprint?: string | null | undefined;
243
243
  metadata?: Record<string, any> | undefined;
244
244
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
@@ -230,15 +230,15 @@ declare const CreateCustomerParamsSchema: z.ZodObject<{
230
230
  expand: z.ZodOptional<z.ZodArray<z.ZodEnum<["invoices", "rewards", "trials_used", "entities", "referrals", "payment_method"]>, "many">>;
231
231
  }, "strip", z.ZodTypeAny, {
232
232
  id?: string | null | undefined;
233
- name?: string | null | undefined;
234
233
  email?: string | null | undefined;
234
+ name?: string | null | undefined;
235
235
  fingerprint?: string | null | undefined;
236
236
  metadata?: Record<string, any> | undefined;
237
237
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
238
238
  }, {
239
239
  id?: string | null | undefined;
240
- name?: string | null | undefined;
241
240
  email?: string | null | undefined;
241
+ name?: string | null | undefined;
242
242
  fingerprint?: string | null | undefined;
243
243
  metadata?: Record<string, any> | undefined;
244
244
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;