autumn-js 1.2.0 → 1.2.2

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 (102) hide show
  1. package/dist/backend/adapters/express.js +4 -0
  2. package/dist/backend/adapters/express.mjs +5 -5
  3. package/dist/backend/adapters/fetch.js +4 -0
  4. package/dist/backend/adapters/fetch.mjs +5 -5
  5. package/dist/backend/adapters/hono.js +4 -0
  6. package/dist/backend/adapters/hono.mjs +5 -5
  7. package/dist/backend/adapters/index.js +4 -0
  8. package/dist/backend/adapters/index.mjs +8 -8
  9. package/dist/backend/adapters/next.js +4 -0
  10. package/dist/backend/adapters/next.mjs +5 -5
  11. package/dist/backend/{chunk-JDL37I7Y.mjs → chunk-3QNAZFQH.mjs} +2 -2
  12. package/dist/backend/{chunk-MJBKNDWD.mjs → chunk-6BVI5XZX.mjs} +2 -0
  13. package/dist/backend/{chunk-6YVVHFAT.mjs → chunk-C5ZDQJPP.mjs} +1 -1
  14. package/dist/backend/{chunk-5TDPAYPN.mjs → chunk-GENKYO6B.mjs} +1 -1
  15. package/dist/backend/{chunk-VR35K2UZ.mjs → chunk-GLPHS5KF.mjs} +2 -2
  16. package/dist/backend/{chunk-RYP3CVST.mjs → chunk-OB47KG2H.mjs} +1 -1
  17. package/dist/backend/{chunk-3YYODLUY.mjs → chunk-SX3CNUF5.mjs} +1 -1
  18. package/dist/backend/{chunk-BSY23UM3.mjs → chunk-XU4OGYDV.mjs} +2 -0
  19. package/dist/backend/core/handlers/coreHandler.d.mts +1 -1
  20. package/dist/backend/core/handlers/coreHandler.d.ts +1 -1
  21. package/dist/backend/core/handlers/coreHandler.js +4 -0
  22. package/dist/backend/core/handlers/coreHandler.mjs +3 -3
  23. package/dist/backend/core/handlers/executeRoute.d.mts +1 -1
  24. package/dist/backend/core/handlers/executeRoute.d.ts +1 -1
  25. package/dist/backend/core/handlers/handleRouteByName.js +4 -0
  26. package/dist/backend/core/handlers/handleRouteByName.mjs +3 -3
  27. package/dist/backend/core/handlers/index.d.mts +1 -1
  28. package/dist/backend/core/handlers/index.d.ts +1 -1
  29. package/dist/backend/core/handlers/index.js +4 -0
  30. package/dist/backend/core/handlers/index.mjs +4 -4
  31. package/dist/backend/core/index.d.mts +1 -1
  32. package/dist/backend/core/index.d.ts +1 -1
  33. package/dist/backend/core/index.js +4 -0
  34. package/dist/backend/core/index.mjs +4 -4
  35. package/dist/backend/core/routes/index.d.mts +1 -1
  36. package/dist/backend/core/routes/index.d.ts +1 -1
  37. package/dist/backend/core/routes/index.js +2 -0
  38. package/dist/backend/core/routes/index.mjs +1 -1
  39. package/dist/backend/core/routes/routeBuilder.d.mts +1 -1
  40. package/dist/backend/core/routes/routeBuilder.d.ts +1 -1
  41. package/dist/backend/core/routes/routeConfigs.d.mts +1 -1
  42. package/dist/backend/core/routes/routeConfigs.d.ts +1 -1
  43. package/dist/backend/core/routes/routeConfigs.js +2 -0
  44. package/dist/backend/core/routes/routeConfigs.mjs +1 -1
  45. package/dist/backend/core/types/handlerTypes.d.mts +1 -1
  46. package/dist/backend/core/types/handlerTypes.d.ts +1 -1
  47. package/dist/backend/core/types/index.d.mts +1 -1
  48. package/dist/backend/core/types/index.d.ts +1 -1
  49. package/dist/backend/core/types/routeTypes.d.mts +1 -1
  50. package/dist/backend/core/types/routeTypes.d.ts +1 -1
  51. package/dist/backend/index.d.mts +2 -2
  52. package/dist/backend/index.d.ts +2 -2
  53. package/dist/backend/index.js +4 -0
  54. package/dist/backend/index.mjs +4 -4
  55. package/dist/backend/{routeTypes-B7YXq83l.d.ts → routeTypes-Che2nkqv.d.ts} +6 -0
  56. package/dist/backend/{routeTypes-BglWygTb.d.mts → routeTypes-RMeyKg5T.d.mts} +6 -0
  57. package/dist/better-auth/{chunk-I4LI2AOX.mjs → chunk-5F3J4ZQQ.mjs} +3 -1
  58. package/dist/better-auth/{chunk-LHA6NFFS.mjs → chunk-6TAYCQUD.mjs} +2 -0
  59. package/dist/better-auth/{chunk-TDX4NREA.mjs → chunk-IODRHT4E.mjs} +1 -1
  60. package/dist/better-auth/index.js +4 -0
  61. package/dist/better-auth/index.mjs +3 -3
  62. package/dist/better-auth/utils/createAutumnEndpoint.js +2 -0
  63. package/dist/better-auth/utils/createAutumnEndpoint.mjs +2 -2
  64. package/dist/better-auth/utils/handleBetterAuthRoute.js +4 -0
  65. package/dist/better-auth/utils/handleBetterAuthRoute.mjs +2 -2
  66. package/dist/better-auth/utils/index.js +4 -0
  67. package/dist/better-auth/utils/index.mjs +3 -3
  68. package/dist/react/AutumnContext.d.mts +1 -1
  69. package/dist/react/AutumnContext.d.ts +1 -1
  70. package/dist/react/client/AutumnClient.d.mts +1 -1
  71. package/dist/react/client/AutumnClient.d.ts +1 -1
  72. package/dist/react/client/IAutumnClient.d.mts +1 -1
  73. package/dist/react/client/IAutumnClient.d.ts +1 -1
  74. package/dist/react/client/index.d.mts +1 -1
  75. package/dist/react/client/index.d.ts +1 -1
  76. package/dist/react/hooks/index.d.mts +1 -1
  77. package/dist/react/hooks/index.d.ts +1 -1
  78. package/dist/react/hooks/internal/getLocalCheckResponse.d.mts +1 -1
  79. package/dist/react/hooks/internal/getLocalCheckResponse.d.ts +1 -1
  80. package/dist/react/hooks/internal/useCustomerActions.d.mts +1 -1
  81. package/dist/react/hooks/internal/useCustomerActions.d.ts +1 -1
  82. package/dist/react/hooks/useAggregateEvents.d.mts +1 -1
  83. package/dist/react/hooks/useAggregateEvents.d.ts +1 -1
  84. package/dist/react/hooks/useCustomer.d.mts +1 -1
  85. package/dist/react/hooks/useCustomer.d.ts +1 -1
  86. package/dist/react/hooks/useEntity.d.mts +1 -1
  87. package/dist/react/hooks/useEntity.d.ts +1 -1
  88. package/dist/react/hooks/useListEvents.d.mts +1 -1
  89. package/dist/react/hooks/useListEvents.d.ts +1 -1
  90. package/dist/react/hooks/useListPlans.d.mts +1 -1
  91. package/dist/react/hooks/useListPlans.d.ts +1 -1
  92. package/dist/react/hooks/useReferrals.d.mts +1 -1
  93. package/dist/react/hooks/useReferrals.d.ts +1 -1
  94. package/dist/react/index.d.mts +1 -1
  95. package/dist/react/index.d.ts +1 -1
  96. package/dist/react/{params-BmtAnULw.d.mts → params-Cdkj83CV.d.mts} +6 -0
  97. package/dist/react/{params-CL0lZNfr.d.ts → params-CnOvYjqJ.d.ts} +6 -0
  98. package/dist/sdk/index.d.mts +9 -0
  99. package/dist/sdk/index.d.ts +9 -0
  100. package/dist/sdk/index.js +2 -0
  101. package/dist/sdk/index.mjs +2 -0
  102. package/package.json +1 -1
@@ -7,6 +7,6 @@ export { UseListPlansParams, useListPlans } from './useListPlans.js';
7
7
  export { UseReferralsParams, UseReferralsResult, useReferrals } from './useReferrals.js';
8
8
  import '@tanstack/react-query';
9
9
  import '../client/AutumnClientError.js';
10
- import '../params-CL0lZNfr.js';
10
+ import '../params-CnOvYjqJ.js';
11
11
  import '../plan-BoMslu_O.js';
12
12
  import '../customer-CMAtwbJl.js';
@@ -1,4 +1,4 @@
1
- import { o as ClientCheckParams, s as CheckResponse } from '../../params-BmtAnULw.mjs';
1
+ import { o as ClientCheckParams, s as CheckResponse } from '../../params-Cdkj83CV.mjs';
2
2
  import { C as Customer } from '../../customer-CNvpHhpS.mjs';
3
3
  import '../../plan-BoMslu_O.mjs';
4
4
 
@@ -1,4 +1,4 @@
1
- import { o as ClientCheckParams, s as CheckResponse } from '../../params-CL0lZNfr.js';
1
+ import { o as ClientCheckParams, s as CheckResponse } from '../../params-CnOvYjqJ.js';
2
2
  import { C as Customer } from '../../customer-CMAtwbJl.js';
3
3
  import '../../plan-BoMslu_O.js';
4
4
 
@@ -1,4 +1,4 @@
1
- import { a as ClientAttachParams, p as AttachResponse, h as ClientPreviewAttachParams, q as PreviewAttachResponse, m as ClientUpdateSubscriptionParams, B as BillingUpdateResponse, j as ClientPreviewUpdateSubscriptionParams, r as PreviewUpdateResponse, f as ClientMultiAttachParams, M as MultiAttachResponse, i as ClientPreviewMultiAttachParams, t as PreviewMultiAttachResponse, o as ClientCheckParams, s as CheckResponse, g as ClientOpenCustomerPortalParams, O as OpenCustomerPortalResponse, l as ClientSetupPaymentParams, S as SetupPaymentResponse } from '../../params-BmtAnULw.mjs';
1
+ import { a as ClientAttachParams, p as AttachResponse, h as ClientPreviewAttachParams, q as PreviewAttachResponse, m as ClientUpdateSubscriptionParams, B as BillingUpdateResponse, j as ClientPreviewUpdateSubscriptionParams, r as PreviewUpdateResponse, f as ClientMultiAttachParams, M as MultiAttachResponse, i as ClientPreviewMultiAttachParams, t as PreviewMultiAttachResponse, o as ClientCheckParams, s as CheckResponse, g as ClientOpenCustomerPortalParams, O as OpenCustomerPortalResponse, l as ClientSetupPaymentParams, S as SetupPaymentResponse } from '../../params-Cdkj83CV.mjs';
2
2
  import { C as Customer } from '../../customer-CNvpHhpS.mjs';
3
3
  import { IAutumnClient } from '../../client/IAutumnClient.mjs';
4
4
  import '../../plan-BoMslu_O.mjs';
@@ -1,4 +1,4 @@
1
- import { a as ClientAttachParams, p as AttachResponse, h as ClientPreviewAttachParams, q as PreviewAttachResponse, m as ClientUpdateSubscriptionParams, B as BillingUpdateResponse, j as ClientPreviewUpdateSubscriptionParams, r as PreviewUpdateResponse, f as ClientMultiAttachParams, M as MultiAttachResponse, i as ClientPreviewMultiAttachParams, t as PreviewMultiAttachResponse, o as ClientCheckParams, s as CheckResponse, g as ClientOpenCustomerPortalParams, O as OpenCustomerPortalResponse, l as ClientSetupPaymentParams, S as SetupPaymentResponse } from '../../params-CL0lZNfr.js';
1
+ import { a as ClientAttachParams, p as AttachResponse, h as ClientPreviewAttachParams, q as PreviewAttachResponse, m as ClientUpdateSubscriptionParams, B as BillingUpdateResponse, j as ClientPreviewUpdateSubscriptionParams, r as PreviewUpdateResponse, f as ClientMultiAttachParams, M as MultiAttachResponse, i as ClientPreviewMultiAttachParams, t as PreviewMultiAttachResponse, o as ClientCheckParams, s as CheckResponse, g as ClientOpenCustomerPortalParams, O as OpenCustomerPortalResponse, l as ClientSetupPaymentParams, S as SetupPaymentResponse } from '../../params-CnOvYjqJ.js';
2
2
  import { C as Customer } from '../../customer-CMAtwbJl.js';
3
3
  import { IAutumnClient } from '../../client/IAutumnClient.js';
4
4
  import '../../plan-BoMslu_O.js';
@@ -1,5 +1,5 @@
1
1
  import * as _tanstack_react_query from '@tanstack/react-query';
2
- import { C as ClientAggregateEventsParams, A as AggregateEventsResponse, n as AggregateEventsList, T as Total } from '../params-BmtAnULw.mjs';
2
+ import { C as ClientAggregateEventsParams, A as AggregateEventsResponse, n as AggregateEventsList, T as Total } from '../params-Cdkj83CV.mjs';
3
3
  import { AutumnClientError } from '../client/AutumnClientError.mjs';
4
4
  import { HookParams } from './types.mjs';
5
5
  import '../plan-BoMslu_O.mjs';
@@ -1,5 +1,5 @@
1
1
  import * as _tanstack_react_query from '@tanstack/react-query';
2
- import { C as ClientAggregateEventsParams, A as AggregateEventsResponse, n as AggregateEventsList, T as Total } from '../params-CL0lZNfr.js';
2
+ import { C as ClientAggregateEventsParams, A as AggregateEventsResponse, n as AggregateEventsList, T as Total } from '../params-CnOvYjqJ.js';
3
3
  import { AutumnClientError } from '../client/AutumnClientError.js';
4
4
  import { HookParams } from './types.js';
5
5
  import '../plan-BoMslu_O.js';
@@ -1,4 +1,4 @@
1
- import { o as ClientCheckParams, d as ClientGetOrCreateCustomerParams, a as ClientAttachParams, p as AttachResponse, h as ClientPreviewAttachParams, q as PreviewAttachResponse, m as ClientUpdateSubscriptionParams, B as BillingUpdateResponse, j as ClientPreviewUpdateSubscriptionParams, r as PreviewUpdateResponse, s as CheckResponse, f as ClientMultiAttachParams, M as MultiAttachResponse, i as ClientPreviewMultiAttachParams, t as PreviewMultiAttachResponse, l as ClientSetupPaymentParams, S as SetupPaymentResponse, g as ClientOpenCustomerPortalParams, O as OpenCustomerPortalResponse } from '../params-BmtAnULw.mjs';
1
+ import { o as ClientCheckParams, d as ClientGetOrCreateCustomerParams, a as ClientAttachParams, p as AttachResponse, h as ClientPreviewAttachParams, q as PreviewAttachResponse, m as ClientUpdateSubscriptionParams, B as BillingUpdateResponse, j as ClientPreviewUpdateSubscriptionParams, r as PreviewUpdateResponse, s as CheckResponse, f as ClientMultiAttachParams, M as MultiAttachResponse, i as ClientPreviewMultiAttachParams, t as PreviewMultiAttachResponse, l as ClientSetupPaymentParams, S as SetupPaymentResponse, g as ClientOpenCustomerPortalParams, O as OpenCustomerPortalResponse } from '../params-Cdkj83CV.mjs';
2
2
  import { C as Customer } from '../customer-CNvpHhpS.mjs';
3
3
  import { HookParams, HookResultWithMethods } from './types.mjs';
4
4
  import '../plan-BoMslu_O.mjs';
@@ -1,4 +1,4 @@
1
- import { o as ClientCheckParams, d as ClientGetOrCreateCustomerParams, a as ClientAttachParams, p as AttachResponse, h as ClientPreviewAttachParams, q as PreviewAttachResponse, m as ClientUpdateSubscriptionParams, B as BillingUpdateResponse, j as ClientPreviewUpdateSubscriptionParams, r as PreviewUpdateResponse, s as CheckResponse, f as ClientMultiAttachParams, M as MultiAttachResponse, i as ClientPreviewMultiAttachParams, t as PreviewMultiAttachResponse, l as ClientSetupPaymentParams, S as SetupPaymentResponse, g as ClientOpenCustomerPortalParams, O as OpenCustomerPortalResponse } from '../params-CL0lZNfr.js';
1
+ import { o as ClientCheckParams, d as ClientGetOrCreateCustomerParams, a as ClientAttachParams, p as AttachResponse, h as ClientPreviewAttachParams, q as PreviewAttachResponse, m as ClientUpdateSubscriptionParams, B as BillingUpdateResponse, j as ClientPreviewUpdateSubscriptionParams, r as PreviewUpdateResponse, s as CheckResponse, f as ClientMultiAttachParams, M as MultiAttachResponse, i as ClientPreviewMultiAttachParams, t as PreviewMultiAttachResponse, l as ClientSetupPaymentParams, S as SetupPaymentResponse, g as ClientOpenCustomerPortalParams, O as OpenCustomerPortalResponse } from '../params-CnOvYjqJ.js';
2
2
  import { C as Customer } from '../customer-CMAtwbJl.js';
3
3
  import { HookParams, HookResultWithMethods } from './types.js';
4
4
  import '../plan-BoMslu_O.js';
@@ -1,4 +1,4 @@
1
- import { c as ClientGetEntityParams, G as GetEntityResponse } from '../params-BmtAnULw.mjs';
1
+ import { c as ClientGetEntityParams, G as GetEntityResponse } from '../params-Cdkj83CV.mjs';
2
2
  import { HookParams, HookResult } from './types.mjs';
3
3
  import '../plan-BoMslu_O.mjs';
4
4
  import '@tanstack/react-query';
@@ -1,4 +1,4 @@
1
- import { c as ClientGetEntityParams, G as GetEntityResponse } from '../params-CL0lZNfr.js';
1
+ import { c as ClientGetEntityParams, G as GetEntityResponse } from '../params-CnOvYjqJ.js';
2
2
  import { HookParams, HookResult } from './types.js';
3
3
  import '../plan-BoMslu_O.js';
4
4
  import '@tanstack/react-query';
@@ -1,5 +1,5 @@
1
1
  import * as _tanstack_react_query from '@tanstack/react-query';
2
- import { e as ClientListEventsParams, L as ListEventsResponse, u as ListEventsList } from '../params-BmtAnULw.mjs';
2
+ import { e as ClientListEventsParams, L as ListEventsResponse, u as ListEventsList } from '../params-Cdkj83CV.mjs';
3
3
  import { AutumnClientError } from '../client/AutumnClientError.mjs';
4
4
  import { HookParams } from './types.mjs';
5
5
  import '../plan-BoMslu_O.mjs';
@@ -1,5 +1,5 @@
1
1
  import * as _tanstack_react_query from '@tanstack/react-query';
2
- import { e as ClientListEventsParams, L as ListEventsResponse, u as ListEventsList } from '../params-CL0lZNfr.js';
2
+ import { e as ClientListEventsParams, L as ListEventsResponse, u as ListEventsList } from '../params-CnOvYjqJ.js';
3
3
  import { AutumnClientError } from '../client/AutumnClientError.js';
4
4
  import { HookParams } from './types.js';
5
5
  import '../plan-BoMslu_O.js';
@@ -1,6 +1,6 @@
1
1
  import * as _tanstack_react_query from '@tanstack/react-query';
2
2
  import { P as Plan } from '../plan-BoMslu_O.mjs';
3
- import { v as ClientListPlansParams } from '../params-BmtAnULw.mjs';
3
+ import { v as ClientListPlansParams } from '../params-Cdkj83CV.mjs';
4
4
  import { AutumnClientError } from '../client/AutumnClientError.mjs';
5
5
  import { HookParams } from './types.mjs';
6
6
 
@@ -1,6 +1,6 @@
1
1
  import * as _tanstack_react_query from '@tanstack/react-query';
2
2
  import { P as Plan } from '../plan-BoMslu_O.js';
3
- import { v as ClientListPlansParams } from '../params-CL0lZNfr.js';
3
+ import { v as ClientListPlansParams } from '../params-CnOvYjqJ.js';
4
4
  import { AutumnClientError } from '../client/AutumnClientError.js';
5
5
  import { HookParams } from './types.js';
6
6
 
@@ -1,4 +1,4 @@
1
- import { b as ClientCreateReferralCodeParams, w as CreateReferralCodeResponse, k as ClientRedeemReferralCodeParams, R as RedeemReferralCodeResponse } from '../params-BmtAnULw.mjs';
1
+ import { b as ClientCreateReferralCodeParams, w as CreateReferralCodeResponse, k as ClientRedeemReferralCodeParams, R as RedeemReferralCodeResponse } from '../params-Cdkj83CV.mjs';
2
2
  import { HookParams, HookResultWithMethods } from './types.mjs';
3
3
  import '../plan-BoMslu_O.mjs';
4
4
  import '@tanstack/react-query';
@@ -1,4 +1,4 @@
1
- import { b as ClientCreateReferralCodeParams, w as CreateReferralCodeResponse, k as ClientRedeemReferralCodeParams, R as RedeemReferralCodeResponse } from '../params-CL0lZNfr.js';
1
+ import { b as ClientCreateReferralCodeParams, w as CreateReferralCodeResponse, k as ClientRedeemReferralCodeParams, R as RedeemReferralCodeResponse } from '../params-CnOvYjqJ.js';
2
2
  import { HookParams, HookResultWithMethods } from './types.js';
3
3
  import '../plan-BoMslu_O.js';
4
4
  import '@tanstack/react-query';
@@ -1,4 +1,4 @@
1
- export { C as ClientAggregateEventsParams, a as ClientAttachParams, b as ClientCreateReferralCodeParams, c as ClientGetEntityParams, d as ClientGetOrCreateCustomerParams, e as ClientListEventsParams, f as ClientMultiAttachParams, g as ClientOpenCustomerPortalParams, h as ClientPreviewAttachParams, i as ClientPreviewMultiAttachParams, j as ClientPreviewUpdateSubscriptionParams, k as ClientRedeemReferralCodeParams, l as ClientSetupPaymentParams, m as ClientUpdateSubscriptionParams, P as ProtectedFields } from './params-BmtAnULw.mjs';
1
+ export { C as ClientAggregateEventsParams, a as ClientAttachParams, b as ClientCreateReferralCodeParams, c as ClientGetEntityParams, d as ClientGetOrCreateCustomerParams, e as ClientListEventsParams, f as ClientMultiAttachParams, g as ClientOpenCustomerPortalParams, h as ClientPreviewAttachParams, i as ClientPreviewMultiAttachParams, j as ClientPreviewUpdateSubscriptionParams, k as ClientRedeemReferralCodeParams, l as ClientSetupPaymentParams, m as ClientUpdateSubscriptionParams, P as ProtectedFields } from './params-Cdkj83CV.mjs';
2
2
  export { useAutumnClient } from './AutumnContext.mjs';
3
3
  export { AutumnProvider, AutumnProviderProps } from './AutumnProvider.mjs';
4
4
  export { AutumnClientConfig, createAutumnClient } from './client/AutumnClient.mjs';
@@ -1,4 +1,4 @@
1
- export { C as ClientAggregateEventsParams, a as ClientAttachParams, b as ClientCreateReferralCodeParams, c as ClientGetEntityParams, d as ClientGetOrCreateCustomerParams, e as ClientListEventsParams, f as ClientMultiAttachParams, g as ClientOpenCustomerPortalParams, h as ClientPreviewAttachParams, i as ClientPreviewMultiAttachParams, j as ClientPreviewUpdateSubscriptionParams, k as ClientRedeemReferralCodeParams, l as ClientSetupPaymentParams, m as ClientUpdateSubscriptionParams, P as ProtectedFields } from './params-CL0lZNfr.js';
1
+ export { C as ClientAggregateEventsParams, a as ClientAttachParams, b as ClientCreateReferralCodeParams, c as ClientGetEntityParams, d as ClientGetOrCreateCustomerParams, e as ClientListEventsParams, f as ClientMultiAttachParams, g as ClientOpenCustomerPortalParams, h as ClientPreviewAttachParams, i as ClientPreviewMultiAttachParams, j as ClientPreviewUpdateSubscriptionParams, k as ClientRedeemReferralCodeParams, l as ClientSetupPaymentParams, m as ClientUpdateSubscriptionParams, P as ProtectedFields } from './params-CnOvYjqJ.js';
2
2
  export { useAutumnClient } from './AutumnContext.js';
3
3
  export { AutumnProvider, AutumnProviderProps } from './AutumnProvider.js';
4
4
  export { AutumnClientConfig, createAutumnClient } from './client/AutumnClient.js';
@@ -64,6 +64,12 @@ type EventsAggregateParams = {
64
64
  * Custom time range to aggregate events for. If provided, range must not be provided
65
65
  */
66
66
  customRange?: AggregateEventsCustomRange | undefined;
67
+ /**
68
+ * Filter events by property values, e.g. {"model": "gpt-4", "region": "us"}. Maximum 5 filters.
69
+ */
70
+ filterBy?: {
71
+ [k: string]: string;
72
+ } | undefined;
67
73
  /**
68
74
  * Maximum number of distinct group values to return per time bin when using group_by. Remaining values are bundled into an 'Other' bucket. Defaults to 9
69
75
  */
@@ -64,6 +64,12 @@ type EventsAggregateParams = {
64
64
  * Custom time range to aggregate events for. If provided, range must not be provided
65
65
  */
66
66
  customRange?: AggregateEventsCustomRange | undefined;
67
+ /**
68
+ * Filter events by property values, e.g. {"model": "gpt-4", "region": "us"}. Maximum 5 filters.
69
+ */
70
+ filterBy?: {
71
+ [k: string]: string;
72
+ } | undefined;
67
73
  /**
68
74
  * Maximum number of distinct group values to return per time bin when using group_by. Remaining values are bundled into an 'Other' bucket. Defaults to 9
69
75
  */
@@ -276,6 +276,12 @@ type EventsAggregateParams = {
276
276
  * Custom time range to aggregate events for. If provided, range must not be provided
277
277
  */
278
278
  customRange?: AggregateEventsCustomRange | undefined;
279
+ /**
280
+ * Filter events by property values, e.g. {"model": "gpt-4", "region": "us"}. Maximum 5 filters.
281
+ */
282
+ filterBy?: {
283
+ [k: string]: string;
284
+ } | undefined;
279
285
  /**
280
286
  * Maximum number of distinct group values to return per time bin when using group_by. Remaining values are bundled into an 'Other' bucket. Defaults to 9
281
287
  */
@@ -352,6 +358,9 @@ type EventsAggregateParams$Outbound = {
352
358
  range?: string | undefined;
353
359
  bin_size: string;
354
360
  custom_range?: AggregateEventsCustomRange$Outbound | undefined;
361
+ filter_by?: {
362
+ [k: string]: string;
363
+ } | undefined;
355
364
  max_groups?: number | undefined;
356
365
  };
357
366
  /** @internal */
@@ -276,6 +276,12 @@ type EventsAggregateParams = {
276
276
  * Custom time range to aggregate events for. If provided, range must not be provided
277
277
  */
278
278
  customRange?: AggregateEventsCustomRange | undefined;
279
+ /**
280
+ * Filter events by property values, e.g. {"model": "gpt-4", "region": "us"}. Maximum 5 filters.
281
+ */
282
+ filterBy?: {
283
+ [k: string]: string;
284
+ } | undefined;
279
285
  /**
280
286
  * Maximum number of distinct group values to return per time bin when using group_by. Remaining values are bundled into an 'Other' bucket. Defaults to 9
281
287
  */
@@ -352,6 +358,9 @@ type EventsAggregateParams$Outbound = {
352
358
  range?: string | undefined;
353
359
  bin_size: string;
354
360
  custom_range?: AggregateEventsCustomRange$Outbound | undefined;
361
+ filter_by?: {
362
+ [k: string]: string;
363
+ } | undefined;
355
364
  max_groups?: number | undefined;
356
365
  };
357
366
  /** @internal */
package/dist/sdk/index.js CHANGED
@@ -1371,6 +1371,7 @@ var EventsAggregateParams$outboundSchema = z39__namespace.pipe(
1371
1371
  customRange: z39__namespace.optional(
1372
1372
  z39__namespace.lazy(() => AggregateEventsCustomRange$outboundSchema)
1373
1373
  ),
1374
+ filterBy: z39__namespace.optional(z39__namespace.record(z39__namespace.string(), z39__namespace.string())),
1374
1375
  maxGroups: z39__namespace.optional(z39__namespace.int())
1375
1376
  }),
1376
1377
  z39__namespace.transform((v) => {
@@ -1381,6 +1382,7 @@ var EventsAggregateParams$outboundSchema = z39__namespace.pipe(
1381
1382
  groupBy: "group_by",
1382
1383
  binSize: "bin_size",
1383
1384
  customRange: "custom_range",
1385
+ filterBy: "filter_by",
1384
1386
  maxGroups: "max_groups"
1385
1387
  });
1386
1388
  })
@@ -1348,6 +1348,7 @@ var EventsAggregateParams$outboundSchema = z39.pipe(
1348
1348
  customRange: z39.optional(
1349
1349
  z39.lazy(() => AggregateEventsCustomRange$outboundSchema)
1350
1350
  ),
1351
+ filterBy: z39.optional(z39.record(z39.string(), z39.string())),
1351
1352
  maxGroups: z39.optional(z39.int())
1352
1353
  }),
1353
1354
  z39.transform((v) => {
@@ -1358,6 +1359,7 @@ var EventsAggregateParams$outboundSchema = z39.pipe(
1358
1359
  groupBy: "group_by",
1359
1360
  binSize: "bin_size",
1360
1361
  customRange: "custom_range",
1362
+ filterBy: "filter_by",
1361
1363
  maxGroups: "max_groups"
1362
1364
  });
1363
1365
  })
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "autumn-js",
3
3
  "description": "Autumn JS Library",
4
- "version": "1.2.0",
4
+ "version": "1.2.2",
5
5
  "repository": "github:useautumn/autumn",
6
6
  "homepage": "https://docs.useautumn.com",
7
7
  "main": "./dist/sdk/index.js",