autumn-js 0.0.116 → 0.1.0

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 (119) hide show
  1. package/dist/libraries/backend/better-auth.d.mts +18 -18
  2. package/dist/libraries/backend/better-auth.d.ts +18 -18
  3. package/dist/libraries/backend/convex.d.mts +1 -0
  4. package/dist/libraries/backend/convex.d.ts +1 -0
  5. package/dist/libraries/backend/convex.js +7 -5
  6. package/dist/libraries/backend/convex.mjs +7 -5
  7. package/dist/libraries/backend/elysia.d.mts +3 -3
  8. package/dist/libraries/backend/elysia.d.ts +3 -3
  9. package/dist/libraries/backend/elysia.js +50 -9
  10. package/dist/libraries/backend/elysia.mjs +51 -8
  11. package/dist/libraries/backend/express.d.mts +1 -1
  12. package/dist/libraries/backend/express.d.ts +1 -1
  13. package/dist/libraries/backend/index.d.mts +1 -1
  14. package/dist/libraries/backend/index.d.ts +1 -1
  15. package/dist/libraries/backend/utils/withAuth.d.mts +1 -1
  16. package/dist/libraries/backend/utils/withAuth.d.ts +1 -1
  17. package/dist/libraries/react/AutumnContext.d.mts +6 -6
  18. package/dist/libraries/react/AutumnContext.d.ts +6 -6
  19. package/dist/libraries/react/BaseAutumnProvider.d.mts +6 -6
  20. package/dist/libraries/react/BaseAutumnProvider.d.ts +6 -6
  21. package/dist/libraries/react/BaseAutumnProvider.js +2 -1
  22. package/dist/libraries/react/BaseAutumnProvider.mjs +2 -2
  23. package/dist/libraries/react/{ReactAutumnClient-DooIpMm0.d.mts → ReactAutumnClient-BK3wjb-u.d.mts} +18 -18
  24. package/dist/libraries/react/{ReactAutumnClient-5mFEwitR.d.ts → ReactAutumnClient-Bh0Sgw6f.d.ts} +18 -18
  25. package/dist/libraries/react/ReactAutumnProvider.d.mts +2 -2
  26. package/dist/libraries/react/ReactAutumnProvider.d.ts +2 -2
  27. package/dist/libraries/react/ReactAutumnProvider.js +2 -1
  28. package/dist/libraries/react/ReactAutumnProvider.mjs +3 -3
  29. package/dist/libraries/react/{attachTypes-CSutLgVn.d.ts → attachTypes-Cy6WgUas.d.ts} +7 -7
  30. package/dist/libraries/react/{attachTypes-By0coJIV.d.mts → attachTypes-DKmoXHQO.d.mts} +7 -7
  31. package/dist/libraries/react/{chunk-AXHU3KAH.mjs → chunk-4NCB2TMQ.mjs} +1 -1
  32. package/dist/libraries/react/{chunk-EXUNRZTP.mjs → chunk-53HYUF2F.mjs} +2 -1
  33. package/dist/libraries/react/{chunk-77DMPCGK.mjs → chunk-BGLWB5O2.mjs} +4 -4
  34. package/dist/libraries/react/{chunk-QJJC6MB3.mjs → chunk-JLJPPCQJ.mjs} +1 -1
  35. package/dist/libraries/react/{chunk-MPA65MFU.mjs → chunk-TM3NBNVM.mjs} +1 -1
  36. package/dist/libraries/react/client/ReactAutumnClient.d.mts +6 -6
  37. package/dist/libraries/react/client/ReactAutumnClient.d.ts +6 -6
  38. package/dist/libraries/react/client/clientCompMethods.d.mts +6 -6
  39. package/dist/libraries/react/client/clientCompMethods.d.ts +6 -6
  40. package/dist/libraries/react/client/clientCusMethods.d.mts +6 -6
  41. package/dist/libraries/react/client/clientCusMethods.d.ts +6 -6
  42. package/dist/libraries/react/client/clientEntityMethods.d.mts +6 -6
  43. package/dist/libraries/react/client/clientEntityMethods.d.ts +6 -6
  44. package/dist/libraries/react/client/clientGenMethods.d.mts +6 -6
  45. package/dist/libraries/react/client/clientGenMethods.d.ts +6 -6
  46. package/dist/libraries/react/client/clientProdMethods.d.mts +6 -6
  47. package/dist/libraries/react/client/clientProdMethods.d.ts +6 -6
  48. package/dist/libraries/react/client/clientReferralMethods.d.mts +6 -6
  49. package/dist/libraries/react/client/clientReferralMethods.d.ts +6 -6
  50. package/dist/libraries/react/client/types/clientAttachTypes.d.mts +20 -20
  51. package/dist/libraries/react/client/types/clientAttachTypes.d.ts +20 -20
  52. package/dist/libraries/react/client/types/clientGenTypes.d.mts +4 -4
  53. package/dist/libraries/react/client/types/clientGenTypes.d.ts +4 -4
  54. package/dist/libraries/react/components/checkout-dialog/checkout-dialog-synced.d.mts +2 -2
  55. package/dist/libraries/react/components/checkout-dialog/checkout-dialog-synced.d.ts +2 -2
  56. package/dist/libraries/react/components/checkout-dialog/checkout-dialog-synced.js +2 -1
  57. package/dist/libraries/react/components/checkout-dialog/checkout-dialog-synced.mjs +6 -6
  58. package/dist/libraries/react/components/checkout-dialog/lib/checkout-content.d.mts +2 -2
  59. package/dist/libraries/react/components/checkout-dialog/lib/checkout-content.d.ts +2 -2
  60. package/dist/libraries/react/components/paywall-dialog/lib/paywall-content.d.mts +1 -1
  61. package/dist/libraries/react/components/paywall-dialog/lib/paywall-content.d.ts +1 -1
  62. package/dist/libraries/react/components/paywall-dialog/paywall-dialog-synced.mjs +6 -6
  63. package/dist/libraries/react/components/pricing-table/lib/pricing-table-content.d.mts +1 -1
  64. package/dist/libraries/react/components/pricing-table/lib/pricing-table-content.d.ts +1 -1
  65. package/dist/libraries/react/components/pricing-table/pricing-table-synced.d.mts +1 -1
  66. package/dist/libraries/react/components/pricing-table/pricing-table-synced.d.ts +1 -1
  67. package/dist/libraries/react/components/pricing-table/pricing-table-synced.js +2 -1
  68. package/dist/libraries/react/components/pricing-table/pricing-table-synced.mjs +6 -6
  69. package/dist/libraries/react/components/ui/button.d.mts +1 -1
  70. package/dist/libraries/react/components/ui/button.d.ts +1 -1
  71. package/dist/libraries/react/{cusTypes-Bbmd8V3j.d.mts → cusTypes-Dlt0fQmq.d.mts} +7 -7
  72. package/dist/libraries/react/{cusTypes-d_DR9uFs.d.ts → cusTypes-eNmWJ2rC.d.ts} +7 -7
  73. package/dist/libraries/react/{entTypes-B2DgO6PV.d.mts → entTypes-BDZUfZE_.d.mts} +1 -1
  74. package/dist/libraries/react/{entTypes-D6eoGCKH.d.ts → entTypes-B_DvaeRL.d.ts} +1 -1
  75. package/dist/libraries/react/{genTypes-C2VFQqmX.d.mts → genTypes-BIPS92_Q.d.mts} +5 -5
  76. package/dist/libraries/react/{genTypes-BNXXZTFn.d.ts → genTypes-Rn-oq2sc.d.ts} +5 -5
  77. package/dist/libraries/react/hooks/helpers/handleCheck.d.mts +6 -6
  78. package/dist/libraries/react/hooks/helpers/handleCheck.d.ts +6 -6
  79. package/dist/libraries/react/hooks/helpers/useAutumnBase.d.mts +7 -7
  80. package/dist/libraries/react/hooks/helpers/useAutumnBase.d.ts +7 -7
  81. package/dist/libraries/react/hooks/useAnalytics.d.mts +2 -2
  82. package/dist/libraries/react/hooks/useAnalytics.d.ts +2 -2
  83. package/dist/libraries/react/hooks/useCustomer.d.mts +6 -6
  84. package/dist/libraries/react/hooks/useCustomer.d.ts +6 -6
  85. package/dist/libraries/react/hooks/useCustomer.js +2 -1
  86. package/dist/libraries/react/hooks/useCustomer.mjs +2 -2
  87. package/dist/libraries/react/hooks/useCustomerBase.d.mts +6 -6
  88. package/dist/libraries/react/hooks/useCustomerBase.d.ts +6 -6
  89. package/dist/libraries/react/hooks/useCustomerBase.js +2 -1
  90. package/dist/libraries/react/hooks/useCustomerBase.mjs +1 -1
  91. package/dist/libraries/react/hooks/useEntity.d.mts +6 -6
  92. package/dist/libraries/react/hooks/useEntity.d.ts +6 -6
  93. package/dist/libraries/react/hooks/useEntityBase.d.mts +8 -8
  94. package/dist/libraries/react/hooks/useEntityBase.d.ts +8 -8
  95. package/dist/libraries/react/hooks/usePaywall.d.mts +1 -1
  96. package/dist/libraries/react/hooks/usePaywall.d.ts +1 -1
  97. package/dist/libraries/react/hooks/usePricingTable.d.mts +1 -1
  98. package/dist/libraries/react/hooks/usePricingTable.d.ts +1 -1
  99. package/dist/libraries/react/hooks/usePricingTableBase.d.mts +6 -6
  100. package/dist/libraries/react/hooks/usePricingTableBase.d.ts +6 -6
  101. package/dist/libraries/react/hooks/useProductsBase.d.mts +6 -6
  102. package/dist/libraries/react/hooks/useProductsBase.d.ts +6 -6
  103. package/dist/libraries/react/index.js +2 -1
  104. package/dist/libraries/react/index.mjs +2 -1
  105. package/dist/next/server/auth/withNextAuth.d.mts +1 -1
  106. package/dist/next/server/auth/withNextAuth.d.ts +1 -1
  107. package/dist/next/server/componentActions.d.mts +1 -1
  108. package/dist/next/server/componentActions.d.ts +1 -1
  109. package/dist/next/server/cusActions.d.mts +15 -15
  110. package/dist/next/server/cusActions.d.ts +15 -15
  111. package/dist/next/server/genActions.d.mts +1 -1
  112. package/dist/next/server/genActions.d.ts +1 -1
  113. package/package.json +7 -4
  114. package/dist/libraries/backend/{referralTypes-DXhjwazw.d.ts → referralTypes-DHs1hY4_.d.ts} +35 -35
  115. package/dist/libraries/backend/{referralTypes-Dxn4bOpT.d.mts → referralTypes-DRsv8not.d.mts} +35 -35
  116. package/dist/libraries/react/{prodTypes-B3iWy6kz.d.mts → prodTypes-DuLXGCiA.d.mts} +2 -2
  117. package/dist/libraries/react/{prodTypes-B3iWy6kz.d.ts → prodTypes-DuLXGCiA.d.ts} +2 -2
  118. package/dist/next/server/{cusTypes-MnneoF1F.d.ts → cusTypes-B0zde-Pl.d.mts} +4 -4
  119. package/dist/next/server/{cusTypes-MnneoF1F.d.mts → cusTypes-B0zde-Pl.d.ts} +4 -4
@@ -1,4 +1,4 @@
1
- import { A as AppEnv, a as ProductItem, d as ProductItemInterval } from './prodTypes-B3iWy6kz.mjs';
1
+ import { A as AppEnv, a as ProductItem, d as ProductItemInterval } from './prodTypes-DuLXGCiA.mjs';
2
2
  import { z } from 'zod';
3
3
 
4
4
  declare enum ProductStatus {
@@ -59,7 +59,6 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
59
59
  credit_amount: number;
60
60
  }>, "many">>;
61
61
  }, "strip", z.ZodTypeAny, {
62
- usage_limit?: number | undefined;
63
62
  unlimited?: boolean | undefined;
64
63
  interval?: ProductItemInterval | undefined;
65
64
  balance?: number | null | undefined;
@@ -67,6 +66,7 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
67
66
  included_usage?: number | undefined;
68
67
  next_reset_at?: number | null | undefined;
69
68
  overage_allowed?: boolean | undefined;
69
+ usage_limit?: number | undefined;
70
70
  rollovers?: {
71
71
  balance: number;
72
72
  expires_at: number;
@@ -83,7 +83,6 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
83
83
  credit_amount: number;
84
84
  }[] | undefined;
85
85
  }, {
86
- usage_limit?: number | undefined;
87
86
  unlimited?: boolean | undefined;
88
87
  interval?: ProductItemInterval | undefined;
89
88
  balance?: number | null | undefined;
@@ -91,6 +90,7 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
91
90
  included_usage?: number | undefined;
92
91
  next_reset_at?: number | null | undefined;
93
92
  overage_allowed?: boolean | undefined;
93
+ usage_limit?: number | undefined;
94
94
  rollovers?: {
95
95
  balance: number;
96
96
  expires_at: number;
@@ -148,12 +148,12 @@ declare const CustomerDataSchema: z.ZodObject<{
148
148
  email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
149
149
  fingerprint: z.ZodOptional<z.ZodNullable<z.ZodString>>;
150
150
  }, "strip", z.ZodTypeAny, {
151
- email?: string | null | undefined;
152
151
  name?: string | null | undefined;
152
+ email?: string | null | undefined;
153
153
  fingerprint?: string | null | undefined;
154
154
  }, {
155
- email?: string | null | undefined;
156
155
  name?: string | null | undefined;
156
+ email?: string | null | undefined;
157
157
  fingerprint?: string | null | undefined;
158
158
  }>;
159
159
  type CustomerData = z.infer<typeof CustomerDataSchema>;
@@ -166,15 +166,15 @@ declare const CreateCustomerParamsSchema: z.ZodObject<{
166
166
  expand: z.ZodOptional<z.ZodArray<z.ZodEnum<["invoices", "rewards", "trials_used", "entities", "referrals", "payment_method"]>, "many">>;
167
167
  }, "strip", z.ZodTypeAny, {
168
168
  id?: string | null | undefined;
169
- email?: string | null | undefined;
170
169
  name?: string | null | undefined;
170
+ email?: string | null | undefined;
171
171
  fingerprint?: string | null | undefined;
172
172
  metadata?: Record<string, any> | undefined;
173
173
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
174
174
  }, {
175
175
  id?: string | null | undefined;
176
- email?: string | null | undefined;
177
176
  name?: string | null | undefined;
177
+ email?: string | null | undefined;
178
178
  fingerprint?: string | null | undefined;
179
179
  metadata?: Record<string, any> | undefined;
180
180
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
@@ -1,4 +1,4 @@
1
- import { A as AppEnv, a as ProductItem, d as ProductItemInterval } from './prodTypes-B3iWy6kz.js';
1
+ import { A as AppEnv, a as ProductItem, d as ProductItemInterval } from './prodTypes-DuLXGCiA.js';
2
2
  import { z } from 'zod';
3
3
 
4
4
  declare enum ProductStatus {
@@ -59,7 +59,6 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
59
59
  credit_amount: number;
60
60
  }>, "many">>;
61
61
  }, "strip", z.ZodTypeAny, {
62
- usage_limit?: number | undefined;
63
62
  unlimited?: boolean | undefined;
64
63
  interval?: ProductItemInterval | undefined;
65
64
  balance?: number | null | undefined;
@@ -67,6 +66,7 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
67
66
  included_usage?: number | undefined;
68
67
  next_reset_at?: number | null | undefined;
69
68
  overage_allowed?: boolean | undefined;
69
+ usage_limit?: number | undefined;
70
70
  rollovers?: {
71
71
  balance: number;
72
72
  expires_at: number;
@@ -83,7 +83,6 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
83
83
  credit_amount: number;
84
84
  }[] | undefined;
85
85
  }, {
86
- usage_limit?: number | undefined;
87
86
  unlimited?: boolean | undefined;
88
87
  interval?: ProductItemInterval | undefined;
89
88
  balance?: number | null | undefined;
@@ -91,6 +90,7 @@ declare const CoreCusFeatureSchema: z.ZodObject<{
91
90
  included_usage?: number | undefined;
92
91
  next_reset_at?: number | null | undefined;
93
92
  overage_allowed?: boolean | undefined;
93
+ usage_limit?: number | undefined;
94
94
  rollovers?: {
95
95
  balance: number;
96
96
  expires_at: number;
@@ -148,12 +148,12 @@ declare const CustomerDataSchema: z.ZodObject<{
148
148
  email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
149
149
  fingerprint: z.ZodOptional<z.ZodNullable<z.ZodString>>;
150
150
  }, "strip", z.ZodTypeAny, {
151
- email?: string | null | undefined;
152
151
  name?: string | null | undefined;
152
+ email?: string | null | undefined;
153
153
  fingerprint?: string | null | undefined;
154
154
  }, {
155
- email?: string | null | undefined;
156
155
  name?: string | null | undefined;
156
+ email?: string | null | undefined;
157
157
  fingerprint?: string | null | undefined;
158
158
  }>;
159
159
  type CustomerData = z.infer<typeof CustomerDataSchema>;
@@ -166,15 +166,15 @@ declare const CreateCustomerParamsSchema: z.ZodObject<{
166
166
  expand: z.ZodOptional<z.ZodArray<z.ZodEnum<["invoices", "rewards", "trials_used", "entities", "referrals", "payment_method"]>, "many">>;
167
167
  }, "strip", z.ZodTypeAny, {
168
168
  id?: string | null | undefined;
169
- email?: string | null | undefined;
170
169
  name?: string | null | undefined;
170
+ email?: string | null | undefined;
171
171
  fingerprint?: string | null | undefined;
172
172
  metadata?: Record<string, any> | undefined;
173
173
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
174
174
  }, {
175
175
  id?: string | null | undefined;
176
- email?: string | null | undefined;
177
176
  name?: string | null | undefined;
177
+ email?: string | null | undefined;
178
178
  fingerprint?: string | null | undefined;
179
179
  metadata?: Record<string, any> | undefined;
180
180
  expand?: ("invoices" | "rewards" | "trials_used" | "entities" | "referrals" | "payment_method")[] | undefined;
@@ -1,5 +1,5 @@
1
1
  import { A as AutumnError } from './error-DHbclCVh.mjs';
2
- import { d as CustomerProduct, e as CustomerFeature, f as CustomerInvoice } from './cusTypes-Bbmd8V3j.mjs';
2
+ import { d as CustomerProduct, e as CustomerFeature, f as CustomerInvoice } from './cusTypes-Dlt0fQmq.mjs';
3
3
 
4
4
  type Success<T> = {
5
5
  data: T;
@@ -1,5 +1,5 @@
1
1
  import { A as AutumnError } from './error-DHbclCVh.js';
2
- import { d as CustomerProduct, e as CustomerFeature, f as CustomerInvoice } from './cusTypes-d_DR9uFs.js';
2
+ import { d as CustomerProduct, e as CustomerFeature, f as CustomerInvoice } from './cusTypes-eNmWJ2rC.js';
3
3
 
4
4
  type Success<T> = {
5
5
  data: T;
@@ -1,4 +1,4 @@
1
- import { b as CheckFeatureResult, c as CheckProductResult } from './prodTypes-B3iWy6kz.mjs';
1
+ import { b as CheckFeatureResult, c as CheckProductResult } from './prodTypes-DuLXGCiA.mjs';
2
2
  import { z } from 'zod';
3
3
 
4
4
  declare const CancelResultSchema: z.ZodObject<{
@@ -7,12 +7,12 @@ declare const CancelResultSchema: z.ZodObject<{
7
7
  product_id: z.ZodString;
8
8
  }, "strip", z.ZodTypeAny, {
9
9
  customer_id: string;
10
- product_id: string;
11
10
  success: boolean;
11
+ product_id: string;
12
12
  }, {
13
13
  customer_id: string;
14
- product_id: string;
15
14
  success: boolean;
15
+ product_id: string;
16
16
  }>;
17
17
  type CancelResult = z.infer<typeof CancelResultSchema>;
18
18
  declare const TrackResultSchema: z.ZodObject<{
@@ -23,14 +23,14 @@ declare const TrackResultSchema: z.ZodObject<{
23
23
  event_name: z.ZodOptional<z.ZodString>;
24
24
  }, "strip", z.ZodTypeAny, {
25
25
  id: string;
26
- code: string;
27
26
  customer_id: string;
27
+ code: string;
28
28
  feature_id?: string | undefined;
29
29
  event_name?: string | undefined;
30
30
  }, {
31
31
  id: string;
32
- code: string;
33
32
  customer_id: string;
33
+ code: string;
34
34
  feature_id?: string | undefined;
35
35
  event_name?: string | undefined;
36
36
  }>;
@@ -1,4 +1,4 @@
1
- import { b as CheckFeatureResult, c as CheckProductResult } from './prodTypes-B3iWy6kz.js';
1
+ import { b as CheckFeatureResult, c as CheckProductResult } from './prodTypes-DuLXGCiA.js';
2
2
  import { z } from 'zod';
3
3
 
4
4
  declare const CancelResultSchema: z.ZodObject<{
@@ -7,12 +7,12 @@ declare const CancelResultSchema: z.ZodObject<{
7
7
  product_id: z.ZodString;
8
8
  }, "strip", z.ZodTypeAny, {
9
9
  customer_id: string;
10
- product_id: string;
11
10
  success: boolean;
11
+ product_id: string;
12
12
  }, {
13
13
  customer_id: string;
14
- product_id: string;
15
14
  success: boolean;
15
+ product_id: string;
16
16
  }>;
17
17
  type CancelResult = z.infer<typeof CancelResultSchema>;
18
18
  declare const TrackResultSchema: z.ZodObject<{
@@ -23,14 +23,14 @@ declare const TrackResultSchema: z.ZodObject<{
23
23
  event_name: z.ZodOptional<z.ZodString>;
24
24
  }, "strip", z.ZodTypeAny, {
25
25
  id: string;
26
- code: string;
27
26
  customer_id: string;
27
+ code: string;
28
28
  feature_id?: string | undefined;
29
29
  event_name?: string | undefined;
30
30
  }, {
31
31
  id: string;
32
- code: string;
33
32
  customer_id: string;
33
+ code: string;
34
34
  feature_id?: string | undefined;
35
35
  event_name?: string | undefined;
36
36
  }>;
@@ -1,14 +1,14 @@
1
1
  import { AutumnContextParams } from '../../AutumnContext.mjs';
2
2
  import { CheckParams } from '../../client/types/clientGenTypes.mjs';
3
- import { a as CheckResult } from '../../genTypes-C2VFQqmX.mjs';
4
- import { b as Customer } from '../../cusTypes-Bbmd8V3j.mjs';
5
- import { E as Entity } from '../../entTypes-B2DgO6PV.mjs';
3
+ import { a as CheckResult } from '../../genTypes-BIPS92_Q.mjs';
4
+ import { b as Customer } from '../../cusTypes-Dlt0fQmq.mjs';
5
+ import { E as Entity } from '../../entTypes-BDZUfZE_.mjs';
6
6
  import 'react';
7
- import '../../ReactAutumnClient-DooIpMm0.mjs';
7
+ import '../../ReactAutumnClient-BK3wjb-u.mjs';
8
8
  import '../../client/types/clientEntTypes.mjs';
9
9
  import '../../error-DHbclCVh.mjs';
10
- import '../../attachTypes-By0coJIV.mjs';
11
- import '../../prodTypes-B3iWy6kz.mjs';
10
+ import '../../attachTypes-DKmoXHQO.mjs';
11
+ import '../../prodTypes-DuLXGCiA.mjs';
12
12
  import 'zod';
13
13
 
14
14
  interface AllowedParams {
@@ -1,14 +1,14 @@
1
1
  import { AutumnContextParams } from '../../AutumnContext.js';
2
2
  import { CheckParams } from '../../client/types/clientGenTypes.js';
3
- import { a as CheckResult } from '../../genTypes-BNXXZTFn.js';
4
- import { b as Customer } from '../../cusTypes-d_DR9uFs.js';
5
- import { E as Entity } from '../../entTypes-D6eoGCKH.js';
3
+ import { a as CheckResult } from '../../genTypes-Rn-oq2sc.js';
4
+ import { b as Customer } from '../../cusTypes-eNmWJ2rC.js';
5
+ import { E as Entity } from '../../entTypes-B_DvaeRL.js';
6
6
  import 'react';
7
- import '../../ReactAutumnClient-5mFEwitR.js';
7
+ import '../../ReactAutumnClient-Bh0Sgw6f.js';
8
8
  import '../../client/types/clientEntTypes.js';
9
9
  import '../../error-DHbclCVh.js';
10
- import '../../attachTypes-CSutLgVn.js';
11
- import '../../prodTypes-B3iWy6kz.js';
10
+ import '../../attachTypes-Cy6WgUas.js';
11
+ import '../../prodTypes-DuLXGCiA.js';
12
12
  import 'zod';
13
13
 
14
14
  interface AllowedParams {
@@ -1,13 +1,13 @@
1
- import { R as Result, A as AutumnPromise } from '../../entTypes-B2DgO6PV.mjs';
1
+ import { R as Result, A as AutumnPromise } from '../../entTypes-BDZUfZE_.mjs';
2
2
  import { A as AutumnError } from '../../error-DHbclCVh.mjs';
3
- import { a as CheckResult, T as TrackResult, C as CancelResult, S as SetupPaymentResult } from '../../genTypes-C2VFQqmX.mjs';
4
- import { C as CheckoutResult } from '../../attachTypes-By0coJIV.mjs';
5
- import { B as BillingPortalResult } from '../../cusTypes-Bbmd8V3j.mjs';
3
+ import { a as CheckResult, T as TrackResult, C as CancelResult, S as SetupPaymentResult } from '../../genTypes-BIPS92_Q.mjs';
4
+ import { C as CheckoutResult } from '../../attachTypes-DKmoXHQO.mjs';
5
+ import { B as BillingPortalResult } from '../../cusTypes-Dlt0fQmq.mjs';
6
6
  import { AutumnContextParams } from '../../AutumnContext.mjs';
7
7
  import { TrackParams, CancelParams, OpenBillingPortalParams, SetupPaymentParams } from '../../client/types/clientGenTypes.mjs';
8
8
  import { AttachParams, CheckoutParams } from '../../client/types/clientAttachTypes.mjs';
9
- import { A as AutumnClient } from '../../ReactAutumnClient-DooIpMm0.mjs';
10
- import '../../prodTypes-B3iWy6kz.mjs';
9
+ import { A as AutumnClient } from '../../ReactAutumnClient-BK3wjb-u.mjs';
10
+ import '../../prodTypes-DuLXGCiA.mjs';
11
11
  import 'zod';
12
12
  import 'react';
13
13
  import '../../client/types/clientEntTypes.mjs';
@@ -18,9 +18,9 @@ declare const useAutumnBase: ({ context, client, refetchCustomer, }: {
18
18
  refetchCustomer?: () => Promise<any>;
19
19
  }) => {
20
20
  attach: (params: AttachParams) => Promise<Result<{
21
- customer_id: string;
22
21
  code: string;
23
22
  message: string;
23
+ customer_id: string;
24
24
  product_ids: string[];
25
25
  customer_data?: any;
26
26
  checkout_url?: string | undefined;
@@ -1,13 +1,13 @@
1
- import { R as Result, A as AutumnPromise } from '../../entTypes-D6eoGCKH.js';
1
+ import { R as Result, A as AutumnPromise } from '../../entTypes-B_DvaeRL.js';
2
2
  import { A as AutumnError } from '../../error-DHbclCVh.js';
3
- import { a as CheckResult, T as TrackResult, C as CancelResult, S as SetupPaymentResult } from '../../genTypes-BNXXZTFn.js';
4
- import { C as CheckoutResult } from '../../attachTypes-CSutLgVn.js';
5
- import { B as BillingPortalResult } from '../../cusTypes-d_DR9uFs.js';
3
+ import { a as CheckResult, T as TrackResult, C as CancelResult, S as SetupPaymentResult } from '../../genTypes-Rn-oq2sc.js';
4
+ import { C as CheckoutResult } from '../../attachTypes-Cy6WgUas.js';
5
+ import { B as BillingPortalResult } from '../../cusTypes-eNmWJ2rC.js';
6
6
  import { AutumnContextParams } from '../../AutumnContext.js';
7
7
  import { TrackParams, CancelParams, OpenBillingPortalParams, SetupPaymentParams } from '../../client/types/clientGenTypes.js';
8
8
  import { AttachParams, CheckoutParams } from '../../client/types/clientAttachTypes.js';
9
- import { A as AutumnClient } from '../../ReactAutumnClient-5mFEwitR.js';
10
- import '../../prodTypes-B3iWy6kz.js';
9
+ import { A as AutumnClient } from '../../ReactAutumnClient-Bh0Sgw6f.js';
10
+ import '../../prodTypes-DuLXGCiA.js';
11
11
  import 'zod';
12
12
  import 'react';
13
13
  import '../../client/types/clientEntTypes.js';
@@ -18,9 +18,9 @@ declare const useAutumnBase: ({ context, client, refetchCustomer, }: {
18
18
  refetchCustomer?: () => Promise<any>;
19
19
  }) => {
20
20
  attach: (params: AttachParams) => Promise<Result<{
21
- customer_id: string;
22
21
  code: string;
23
22
  message: string;
23
+ customer_id: string;
24
24
  product_ids: string[];
25
25
  customer_data?: any;
26
26
  checkout_url?: string | undefined;
@@ -1,9 +1,9 @@
1
1
  import * as swr from 'swr';
2
2
  import { QueryParams } from '../client/types/clientGenTypes.mjs';
3
3
  import { A as AutumnError } from '../error-DHbclCVh.mjs';
4
- import { Q as QueryResult } from '../genTypes-C2VFQqmX.mjs';
4
+ import { Q as QueryResult } from '../genTypes-BIPS92_Q.mjs';
5
5
  import 'zod';
6
- import '../prodTypes-B3iWy6kz.mjs';
6
+ import '../prodTypes-DuLXGCiA.mjs';
7
7
 
8
8
  declare const useAnalytics: (params: QueryParams) => {
9
9
  data: ({
@@ -1,9 +1,9 @@
1
1
  import * as swr from 'swr';
2
2
  import { QueryParams } from '../client/types/clientGenTypes.js';
3
3
  import { A as AutumnError } from '../error-DHbclCVh.js';
4
- import { Q as QueryResult } from '../genTypes-BNXXZTFn.js';
4
+ import { Q as QueryResult } from '../genTypes-Rn-oq2sc.js';
5
5
  import 'zod';
6
- import '../prodTypes-B3iWy6kz.js';
6
+ import '../prodTypes-DuLXGCiA.js';
7
7
 
8
8
  declare const useAnalytics: (params: QueryParams) => {
9
9
  data: ({
@@ -1,12 +1,12 @@
1
1
  import { UseCustomerParams, UseCustomerResult } from './useCustomerBase.mjs';
2
2
  import '../error-DHbclCVh.mjs';
3
- import '../genTypes-C2VFQqmX.mjs';
4
- import '../prodTypes-B3iWy6kz.mjs';
3
+ import '../genTypes-BIPS92_Q.mjs';
4
+ import '../prodTypes-DuLXGCiA.mjs';
5
5
  import 'zod';
6
- import '../attachTypes-By0coJIV.mjs';
7
- import '../entTypes-B2DgO6PV.mjs';
8
- import '../cusTypes-Bbmd8V3j.mjs';
9
- import '../ReactAutumnClient-DooIpMm0.mjs';
6
+ import '../attachTypes-DKmoXHQO.mjs';
7
+ import '../entTypes-BDZUfZE_.mjs';
8
+ import '../cusTypes-Dlt0fQmq.mjs';
9
+ import '../ReactAutumnClient-BK3wjb-u.mjs';
10
10
  import '../client/types/clientEntTypes.mjs';
11
11
  import '../client/types/clientGenTypes.mjs';
12
12
  import '../client/types/clientReferralTypes.mjs';
@@ -1,12 +1,12 @@
1
1
  import { UseCustomerParams, UseCustomerResult } from './useCustomerBase.js';
2
2
  import '../error-DHbclCVh.js';
3
- import '../genTypes-BNXXZTFn.js';
4
- import '../prodTypes-B3iWy6kz.js';
3
+ import '../genTypes-Rn-oq2sc.js';
4
+ import '../prodTypes-DuLXGCiA.js';
5
5
  import 'zod';
6
- import '../attachTypes-CSutLgVn.js';
7
- import '../entTypes-D6eoGCKH.js';
8
- import '../cusTypes-d_DR9uFs.js';
9
- import '../ReactAutumnClient-5mFEwitR.js';
6
+ import '../attachTypes-Cy6WgUas.js';
7
+ import '../entTypes-B_DvaeRL.js';
8
+ import '../cusTypes-eNmWJ2rC.js';
9
+ import '../ReactAutumnClient-Bh0Sgw6f.js';
10
10
  import '../client/types/clientEntTypes.js';
11
11
  import '../client/types/clientGenTypes.js';
12
12
  import '../client/types/clientReferralTypes.js';
@@ -1584,7 +1584,8 @@ var useCustomerBase = ({
1584
1584
  mutate
1585
1585
  } = (0, import_swr2.default)(queryKey, fetchCustomer, {
1586
1586
  fallbackData: null,
1587
- ...params?.swrConfig
1587
+ // Default to 5 minutes
1588
+ swrConfig: { refreshInterval: 1e3 * 60 * 5, ...params?.swrConfig }
1588
1589
  });
1589
1590
  const autumnFunctions = useAutumnBase({
1590
1591
  context,
@@ -2,8 +2,8 @@
2
2
 
3
3
  import {
4
4
  useCustomer
5
- } from "../chunk-QJJC6MB3.mjs";
6
- import "../chunk-EXUNRZTP.mjs";
5
+ } from "../chunk-JLJPPCQJ.mjs";
6
+ import "../chunk-53HYUF2F.mjs";
7
7
  import "../chunk-LFLX6NJU.mjs";
8
8
  import "../chunk-UAK4XMNC.mjs";
9
9
  import "../chunk-UCUAGLCJ.mjs";
@@ -1,9 +1,9 @@
1
1
  import { A as AutumnError } from '../error-DHbclCVh.mjs';
2
- import { a as CheckResult, T as TrackResult, C as CancelResult, S as SetupPaymentResult } from '../genTypes-C2VFQqmX.mjs';
3
- import { A as AttachResult, C as CheckoutResult } from '../attachTypes-By0coJIV.mjs';
4
- import { A as AutumnPromise, E as Entity, S as Success } from '../entTypes-B2DgO6PV.mjs';
5
- import { c as CustomerExpandOption, b as Customer, B as BillingPortalResult } from '../cusTypes-Bbmd8V3j.mjs';
6
- import { C as CreateReferralCodeResult, R as RedeemReferralCodeResult, A as AutumnClient } from '../ReactAutumnClient-DooIpMm0.mjs';
2
+ import { a as CheckResult, T as TrackResult, C as CancelResult, S as SetupPaymentResult } from '../genTypes-BIPS92_Q.mjs';
3
+ import { A as AttachResult, C as CheckoutResult } from '../attachTypes-DKmoXHQO.mjs';
4
+ import { A as AutumnPromise, E as Entity, S as Success } from '../entTypes-BDZUfZE_.mjs';
5
+ import { c as CustomerExpandOption, b as Customer, B as BillingPortalResult } from '../cusTypes-Dlt0fQmq.mjs';
6
+ import { C as CreateReferralCodeResult, R as RedeemReferralCodeResult, A as AutumnClient } from '../ReactAutumnClient-BK3wjb-u.mjs';
7
7
  import { CreateEntityParams } from '../client/types/clientEntTypes.mjs';
8
8
  import { CreateReferralCodeParams, RedeemReferralCodeParams } from '../client/types/clientReferralTypes.mjs';
9
9
  import { SWRConfiguration } from 'swr';
@@ -11,7 +11,7 @@ import React__default from 'react';
11
11
  import { TrackParams, CancelParams, SetupPaymentParams, OpenBillingPortalParams, CheckParams } from '../client/types/clientGenTypes.mjs';
12
12
  import { AllowedParams } from './helpers/handleCheck.mjs';
13
13
  import { AttachParams, CheckoutParams } from '../client/types/clientAttachTypes.mjs';
14
- import '../prodTypes-B3iWy6kz.mjs';
14
+ import '../prodTypes-DuLXGCiA.mjs';
15
15
  import 'zod';
16
16
  import '../AutumnContext.mjs';
17
17
 
@@ -1,9 +1,9 @@
1
1
  import { A as AutumnError } from '../error-DHbclCVh.js';
2
- import { a as CheckResult, T as TrackResult, C as CancelResult, S as SetupPaymentResult } from '../genTypes-BNXXZTFn.js';
3
- import { A as AttachResult, C as CheckoutResult } from '../attachTypes-CSutLgVn.js';
4
- import { A as AutumnPromise, E as Entity, S as Success } from '../entTypes-D6eoGCKH.js';
5
- import { c as CustomerExpandOption, b as Customer, B as BillingPortalResult } from '../cusTypes-d_DR9uFs.js';
6
- import { C as CreateReferralCodeResult, R as RedeemReferralCodeResult, A as AutumnClient } from '../ReactAutumnClient-5mFEwitR.js';
2
+ import { a as CheckResult, T as TrackResult, C as CancelResult, S as SetupPaymentResult } from '../genTypes-Rn-oq2sc.js';
3
+ import { A as AttachResult, C as CheckoutResult } from '../attachTypes-Cy6WgUas.js';
4
+ import { A as AutumnPromise, E as Entity, S as Success } from '../entTypes-B_DvaeRL.js';
5
+ import { c as CustomerExpandOption, b as Customer, B as BillingPortalResult } from '../cusTypes-eNmWJ2rC.js';
6
+ import { C as CreateReferralCodeResult, R as RedeemReferralCodeResult, A as AutumnClient } from '../ReactAutumnClient-Bh0Sgw6f.js';
7
7
  import { CreateEntityParams } from '../client/types/clientEntTypes.js';
8
8
  import { CreateReferralCodeParams, RedeemReferralCodeParams } from '../client/types/clientReferralTypes.js';
9
9
  import { SWRConfiguration } from 'swr';
@@ -11,7 +11,7 @@ import React__default from 'react';
11
11
  import { TrackParams, CancelParams, SetupPaymentParams, OpenBillingPortalParams, CheckParams } from '../client/types/clientGenTypes.js';
12
12
  import { AllowedParams } from './helpers/handleCheck.js';
13
13
  import { AttachParams, CheckoutParams } from '../client/types/clientAttachTypes.js';
14
- import '../prodTypes-B3iWy6kz.js';
14
+ import '../prodTypes-DuLXGCiA.js';
15
15
  import 'zod';
16
16
  import '../AutumnContext.js';
17
17
 
@@ -1582,7 +1582,8 @@ var useCustomerBase = ({
1582
1582
  mutate
1583
1583
  } = (0, import_swr2.default)(queryKey, fetchCustomer, {
1584
1584
  fallbackData: null,
1585
- ...params?.swrConfig
1585
+ // Default to 5 minutes
1586
+ swrConfig: { refreshInterval: 1e3 * 60 * 5, ...params?.swrConfig }
1586
1587
  });
1587
1588
  const autumnFunctions = useAutumnBase({
1588
1589
  context,
@@ -2,7 +2,7 @@
2
2
 
3
3
  import {
4
4
  useCustomerBase
5
- } from "../chunk-EXUNRZTP.mjs";
5
+ } from "../chunk-53HYUF2F.mjs";
6
6
  import "../chunk-LFLX6NJU.mjs";
7
7
  import "../chunk-UAK4XMNC.mjs";
8
8
  import "../chunk-UCUAGLCJ.mjs";
@@ -1,12 +1,12 @@
1
- import { E as Entity, R as Result, A as AutumnPromise } from '../entTypes-B2DgO6PV.mjs';
1
+ import { E as Entity, R as Result, A as AutumnPromise } from '../entTypes-BDZUfZE_.mjs';
2
2
  import { AttachParams } from '../client/types/clientAttachTypes.mjs';
3
3
  import { CheckParams, CancelParams, TrackParams } from '../client/types/clientGenTypes.mjs';
4
4
  import * as swr from 'swr';
5
5
  import { A as AutumnError } from '../error-DHbclCVh.mjs';
6
- import { a as CheckResult } from '../genTypes-C2VFQqmX.mjs';
6
+ import { a as CheckResult } from '../genTypes-BIPS92_Q.mjs';
7
7
  import { GetEntityParams } from '../client/types/clientEntTypes.mjs';
8
- import '../cusTypes-Bbmd8V3j.mjs';
9
- import '../prodTypes-B3iWy6kz.mjs';
8
+ import '../cusTypes-Dlt0fQmq.mjs';
9
+ import '../prodTypes-DuLXGCiA.mjs';
10
10
  import 'zod';
11
11
 
12
12
  declare const useEntity: (entityId: string | null, params?: GetEntityParams) => {
@@ -19,9 +19,9 @@ declare const useEntity: (entityId: string | null, params?: GetEntityParams) =>
19
19
  error: null;
20
20
  };
21
21
  attach: (params: AttachParams) => Promise<Result<{
22
- customer_id: string;
23
22
  code: string;
24
23
  message: string;
24
+ customer_id: string;
25
25
  product_ids: string[];
26
26
  customer_data?: any;
27
27
  checkout_url?: string | undefined;
@@ -32,8 +32,8 @@ declare const useEntity: (entityId: string | null, params?: GetEntityParams) =>
32
32
  success: boolean;
33
33
  }>;
34
34
  track: (params: TrackParams) => AutumnPromise<{
35
- customer_id: string;
36
35
  code: string;
36
+ customer_id: string;
37
37
  id: string;
38
38
  feature_id?: string | undefined;
39
39
  event_name?: string | undefined;
@@ -1,12 +1,12 @@
1
- import { E as Entity, R as Result, A as AutumnPromise } from '../entTypes-D6eoGCKH.js';
1
+ import { E as Entity, R as Result, A as AutumnPromise } from '../entTypes-B_DvaeRL.js';
2
2
  import { AttachParams } from '../client/types/clientAttachTypes.js';
3
3
  import { CheckParams, CancelParams, TrackParams } from '../client/types/clientGenTypes.js';
4
4
  import * as swr from 'swr';
5
5
  import { A as AutumnError } from '../error-DHbclCVh.js';
6
- import { a as CheckResult } from '../genTypes-BNXXZTFn.js';
6
+ import { a as CheckResult } from '../genTypes-Rn-oq2sc.js';
7
7
  import { GetEntityParams } from '../client/types/clientEntTypes.js';
8
- import '../cusTypes-d_DR9uFs.js';
9
- import '../prodTypes-B3iWy6kz.js';
8
+ import '../cusTypes-eNmWJ2rC.js';
9
+ import '../prodTypes-DuLXGCiA.js';
10
10
  import 'zod';
11
11
 
12
12
  declare const useEntity: (entityId: string | null, params?: GetEntityParams) => {
@@ -19,9 +19,9 @@ declare const useEntity: (entityId: string | null, params?: GetEntityParams) =>
19
19
  error: null;
20
20
  };
21
21
  attach: (params: AttachParams) => Promise<Result<{
22
- customer_id: string;
23
22
  code: string;
24
23
  message: string;
24
+ customer_id: string;
25
25
  product_ids: string[];
26
26
  customer_data?: any;
27
27
  checkout_url?: string | undefined;
@@ -32,8 +32,8 @@ declare const useEntity: (entityId: string | null, params?: GetEntityParams) =>
32
32
  success: boolean;
33
33
  }>;
34
34
  track: (params: TrackParams) => AutumnPromise<{
35
- customer_id: string;
36
35
  code: string;
36
+ customer_id: string;
37
37
  id: string;
38
38
  feature_id?: string | undefined;
39
39
  event_name?: string | undefined;
@@ -1,17 +1,17 @@
1
- import { E as Entity, R as Result, A as AutumnPromise } from '../entTypes-B2DgO6PV.mjs';
1
+ import { E as Entity, R as Result, A as AutumnPromise } from '../entTypes-BDZUfZE_.mjs';
2
2
  import * as swr from 'swr';
3
3
  import { A as AutumnError } from '../error-DHbclCVh.mjs';
4
- import { a as CheckResult } from '../genTypes-C2VFQqmX.mjs';
4
+ import { a as CheckResult } from '../genTypes-BIPS92_Q.mjs';
5
5
  import { GetEntityParams } from '../client/types/clientEntTypes.mjs';
6
6
  import { AutumnContextParams } from '../AutumnContext.mjs';
7
7
  import { CheckParams, CancelParams, TrackParams } from '../client/types/clientGenTypes.mjs';
8
8
  import { AttachParams } from '../client/types/clientAttachTypes.mjs';
9
- import '../cusTypes-Bbmd8V3j.mjs';
10
- import '../prodTypes-B3iWy6kz.mjs';
9
+ import '../cusTypes-Dlt0fQmq.mjs';
10
+ import '../prodTypes-DuLXGCiA.mjs';
11
11
  import 'zod';
12
12
  import 'react';
13
- import '../ReactAutumnClient-DooIpMm0.mjs';
14
- import '../attachTypes-By0coJIV.mjs';
13
+ import '../ReactAutumnClient-BK3wjb-u.mjs';
14
+ import '../attachTypes-DKmoXHQO.mjs';
15
15
 
16
16
  declare const useEntityBase: ({ entityId, params, AutumnContext, }: {
17
17
  entityId: string | null;
@@ -27,9 +27,9 @@ declare const useEntityBase: ({ entityId, params, AutumnContext, }: {
27
27
  error: null;
28
28
  };
29
29
  attach: (params: AttachParams) => Promise<Result<{
30
- customer_id: string;
31
30
  code: string;
32
31
  message: string;
32
+ customer_id: string;
33
33
  product_ids: string[];
34
34
  customer_data?: any;
35
35
  checkout_url?: string | undefined;
@@ -40,8 +40,8 @@ declare const useEntityBase: ({ entityId, params, AutumnContext, }: {
40
40
  success: boolean;
41
41
  }>;
42
42
  track: (params: TrackParams) => AutumnPromise<{
43
- customer_id: string;
44
43
  code: string;
44
+ customer_id: string;
45
45
  id: string;
46
46
  feature_id?: string | undefined;
47
47
  event_name?: string | undefined;