autumn-js 1.2.0 → 1.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/backend/adapters/express.d.mts +1 -1
- package/dist/backend/adapters/express.d.ts +1 -1
- package/dist/backend/adapters/express.js +337 -29
- package/dist/backend/adapters/express.mjs +9 -9
- package/dist/backend/adapters/fetch.d.mts +1 -1
- package/dist/backend/adapters/fetch.d.ts +1 -1
- package/dist/backend/adapters/fetch.js +337 -29
- package/dist/backend/adapters/fetch.mjs +9 -9
- package/dist/backend/adapters/hono.d.mts +1 -1
- package/dist/backend/adapters/hono.d.ts +1 -1
- package/dist/backend/adapters/hono.js +337 -29
- package/dist/backend/adapters/hono.mjs +9 -9
- package/dist/backend/adapters/index.d.mts +1 -1
- package/dist/backend/adapters/index.d.ts +1 -1
- package/dist/backend/adapters/index.js +337 -29
- package/dist/backend/adapters/index.mjs +12 -12
- package/dist/backend/adapters/next.d.mts +1 -1
- package/dist/backend/adapters/next.d.ts +1 -1
- package/dist/backend/adapters/next.js +337 -29
- package/dist/backend/adapters/next.mjs +9 -9
- package/dist/backend/{authTypes-BCoyMOAj.d.mts → authTypes-B5VxPaMo.d.mts} +14 -0
- package/dist/backend/{authTypes-BCoyMOAj.d.ts → authTypes-B5VxPaMo.d.ts} +14 -0
- package/dist/backend/{chunk-6YVVHFAT.mjs → chunk-2YEMC57K.mjs} +1 -1
- package/dist/backend/{chunk-MJBKNDWD.mjs → chunk-CCEZMERA.mjs} +279 -24
- package/dist/backend/{chunk-VR35K2UZ.mjs → chunk-ETHQSA52.mjs} +7 -7
- package/dist/backend/{chunk-RYP3CVST.mjs → chunk-FRKRWJ5S.mjs} +1 -1
- package/dist/backend/{chunk-5TDPAYPN.mjs → chunk-IFFSWLXT.mjs} +1 -1
- package/dist/backend/{chunk-3YYODLUY.mjs → chunk-IUFWKMTJ.mjs} +1 -1
- package/dist/backend/{chunk-BSY23UM3.mjs → chunk-N62MDT7U.mjs} +58 -5
- package/dist/backend/{chunk-JDL37I7Y.mjs → chunk-OLHAIHAX.mjs} +5 -5
- package/dist/backend/core/handlers/coreHandler.d.mts +2 -2
- package/dist/backend/core/handlers/coreHandler.d.ts +2 -2
- package/dist/backend/core/handlers/coreHandler.js +337 -29
- package/dist/backend/core/handlers/coreHandler.mjs +7 -7
- package/dist/backend/core/handlers/executeRoute.d.mts +2 -2
- package/dist/backend/core/handlers/executeRoute.d.ts +2 -2
- package/dist/backend/core/handlers/executeRoute.mjs +4 -4
- package/dist/backend/core/handlers/handleRouteByName.d.mts +1 -1
- package/dist/backend/core/handlers/handleRouteByName.d.ts +1 -1
- package/dist/backend/core/handlers/handleRouteByName.js +337 -29
- package/dist/backend/core/handlers/handleRouteByName.mjs +7 -7
- package/dist/backend/core/handlers/index.d.mts +2 -2
- package/dist/backend/core/handlers/index.d.ts +2 -2
- package/dist/backend/core/handlers/index.js +337 -29
- package/dist/backend/core/handlers/index.mjs +10 -10
- package/dist/backend/core/handlers/resolveIdentity.d.mts +1 -1
- package/dist/backend/core/handlers/resolveIdentity.d.ts +1 -1
- package/dist/backend/core/index.d.mts +2 -2
- package/dist/backend/core/index.d.ts +2 -2
- package/dist/backend/core/index.js +337 -29
- package/dist/backend/core/index.mjs +10 -10
- package/dist/backend/core/routes/index.d.mts +2 -2
- package/dist/backend/core/routes/index.d.ts +2 -2
- package/dist/backend/core/routes/index.js +58 -5
- package/dist/backend/core/routes/index.mjs +2 -2
- package/dist/backend/core/routes/routeBuilder.d.mts +2 -2
- package/dist/backend/core/routes/routeBuilder.d.ts +2 -2
- package/dist/backend/core/routes/routeConfigs.d.mts +2 -2
- package/dist/backend/core/routes/routeConfigs.d.ts +2 -2
- package/dist/backend/core/routes/routeConfigs.js +58 -5
- package/dist/backend/core/routes/routeConfigs.mjs +2 -2
- package/dist/backend/core/types/authTypes.d.mts +1 -1
- package/dist/backend/core/types/authTypes.d.ts +1 -1
- package/dist/backend/core/types/handlerTypes.d.mts +2 -2
- package/dist/backend/core/types/handlerTypes.d.ts +2 -2
- package/dist/backend/core/types/index.d.mts +2 -2
- package/dist/backend/core/types/index.d.ts +2 -2
- package/dist/backend/core/types/routeTypes.d.mts +2 -2
- package/dist/backend/core/types/routeTypes.d.ts +2 -2
- package/dist/backend/core/utils/index.mjs +3 -3
- package/dist/backend/index.d.mts +4 -4
- package/dist/backend/index.d.ts +4 -4
- package/dist/backend/index.js +337 -29
- package/dist/backend/index.mjs +10 -10
- package/dist/backend/{routeTypes-B7YXq83l.d.ts → routeTypes-BkSHRiCI.d.ts} +233 -2
- package/dist/backend/{routeTypes-BglWygTb.d.mts → routeTypes-C1hUtfD8.d.mts} +233 -2
- package/dist/better-auth/{chunk-LHA6NFFS.mjs → chunk-2PRVJULJ.mjs} +58 -5
- package/dist/better-auth/{chunk-I4LI2AOX.mjs → chunk-6J74ZVNY.mjs} +280 -25
- package/dist/better-auth/{chunk-TDX4NREA.mjs → chunk-IY7FPOWF.mjs} +1 -1
- package/dist/better-auth/index.js +337 -29
- package/dist/better-auth/index.mjs +3 -3
- package/dist/better-auth/types.d.mts +14 -0
- package/dist/better-auth/types.d.ts +14 -0
- package/dist/better-auth/utils/createAutumnEndpoint.js +58 -5
- package/dist/better-auth/utils/createAutumnEndpoint.mjs +2 -2
- package/dist/better-auth/utils/handleBetterAuthRoute.js +337 -29
- package/dist/better-auth/utils/handleBetterAuthRoute.mjs +2 -2
- package/dist/better-auth/utils/index.js +337 -29
- package/dist/better-auth/utils/index.mjs +3 -3
- package/dist/react/AutumnContext.d.mts +3 -3
- package/dist/react/AutumnContext.d.ts +3 -3
- package/dist/react/client/AutumnClient.d.mts +3 -3
- package/dist/react/client/AutumnClient.d.ts +3 -3
- package/dist/react/client/IAutumnClient.d.mts +7 -3
- package/dist/react/client/IAutumnClient.d.ts +7 -3
- package/dist/react/client/index.d.mts +3 -3
- package/dist/react/client/index.d.ts +3 -3
- package/dist/react/{customer-CNvpHhpS.d.mts → customer-Bb7J-_p_.d.mts} +15 -1
- package/dist/react/{customer-CMAtwbJl.d.ts → customer-CJSDgQMF.d.ts} +15 -1
- package/dist/react/hooks/index.d.mts +3 -3
- package/dist/react/hooks/index.d.ts +3 -3
- package/dist/react/hooks/internal/check/balanceToAllowed.d.mts +2 -2
- package/dist/react/hooks/internal/check/balanceToAllowed.d.ts +2 -2
- package/dist/react/hooks/internal/check/customerToFeatures.d.mts +2 -2
- package/dist/react/hooks/internal/check/customerToFeatures.d.ts +2 -2
- package/dist/react/hooks/internal/check/findCreditSystemsByFeature.d.mts +2 -2
- package/dist/react/hooks/internal/check/findCreditSystemsByFeature.d.ts +2 -2
- package/dist/react/hooks/internal/check/getCreditCost.d.mts +2 -2
- package/dist/react/hooks/internal/check/getCreditCost.d.ts +2 -2
- package/dist/react/hooks/internal/getLocalCheckResponse.d.mts +3 -3
- package/dist/react/hooks/internal/getLocalCheckResponse.d.ts +3 -3
- package/dist/react/hooks/internal/useCustomerActions.d.mts +3 -3
- package/dist/react/hooks/internal/useCustomerActions.d.ts +3 -3
- package/dist/react/hooks/useAggregateEvents.d.mts +2 -2
- package/dist/react/hooks/useAggregateEvents.d.ts +2 -2
- package/dist/react/hooks/useCustomer.d.mts +3 -3
- package/dist/react/hooks/useCustomer.d.ts +3 -3
- package/dist/react/hooks/useEntity.d.mts +2 -2
- package/dist/react/hooks/useEntity.d.ts +2 -2
- package/dist/react/hooks/useListEvents.d.mts +2 -2
- package/dist/react/hooks/useListEvents.d.ts +2 -2
- package/dist/react/hooks/useListPlans.d.mts +2 -2
- package/dist/react/hooks/useListPlans.d.ts +2 -2
- package/dist/react/hooks/useReferrals.d.mts +2 -2
- package/dist/react/hooks/useReferrals.d.ts +2 -2
- package/dist/react/index.d.mts +3 -3
- package/dist/react/index.d.ts +3 -3
- package/dist/react/{params-BmtAnULw.d.mts → params-CheyAQ0-.d.mts} +93 -2
- package/dist/react/{params-CL0lZNfr.d.ts → params-yCtJ7lOA.d.ts} +93 -2
- package/dist/react/{plan-BoMslu_O.d.mts → plan-CqxFGNk2.d.mts} +4 -0
- package/dist/react/{plan-BoMslu_O.d.ts → plan-CqxFGNk2.d.ts} +4 -0
- package/dist/sdk/index.d.mts +342 -4
- package/dist/sdk/index.d.ts +342 -4
- package/dist/sdk/index.js +384 -24
- package/dist/sdk/index.mjs +359 -25
- package/package.json +1 -1
- package/dist/backend/{chunk-55C2WWXQ.mjs → chunk-S5HPMJ4U.mjs} +3 -3
|
@@ -898,8 +898,8 @@ function applyBearer(state, spec) {
|
|
|
898
898
|
state.headers[spec.fieldName] = value;
|
|
899
899
|
}
|
|
900
900
|
}
|
|
901
|
-
function resolveGlobalSecurity(security) {
|
|
902
|
-
|
|
901
|
+
function resolveGlobalSecurity(security, allowedFields) {
|
|
902
|
+
let inputs = [
|
|
903
903
|
[
|
|
904
904
|
{
|
|
905
905
|
fieldName: "Authorization",
|
|
@@ -907,7 +907,16 @@ function resolveGlobalSecurity(security) {
|
|
|
907
907
|
value: security?.secretKey ?? env().AUTUMN_SECRET_KEY
|
|
908
908
|
}
|
|
909
909
|
]
|
|
910
|
-
|
|
910
|
+
];
|
|
911
|
+
if (allowedFields) {
|
|
912
|
+
inputs = allowedFields.map((i) => {
|
|
913
|
+
if (i < 0 || i >= inputs.length) {
|
|
914
|
+
throw new RangeError(`invalid allowedFields index ${i}`);
|
|
915
|
+
}
|
|
916
|
+
return inputs[i];
|
|
917
|
+
});
|
|
918
|
+
}
|
|
919
|
+
return resolveSecurity(...inputs);
|
|
911
920
|
}
|
|
912
921
|
async function extractSecurity(sec) {
|
|
913
922
|
if (sec == null) {
|
|
@@ -1254,6 +1263,7 @@ var EventsAggregateParams$outboundSchema = z8.pipe(
|
|
|
1254
1263
|
customRange: z8.optional(
|
|
1255
1264
|
z8.lazy(() => AggregateEventsCustomRange$outboundSchema)
|
|
1256
1265
|
),
|
|
1266
|
+
filterBy: z8.optional(z8.record(z8.string(), z8.string())),
|
|
1257
1267
|
maxGroups: z8.optional(z8.int())
|
|
1258
1268
|
}),
|
|
1259
1269
|
z8.transform((v) => {
|
|
@@ -1264,6 +1274,7 @@ var EventsAggregateParams$outboundSchema = z8.pipe(
|
|
|
1264
1274
|
groupBy: "group_by",
|
|
1265
1275
|
binSize: "bin_size",
|
|
1266
1276
|
customRange: "custom_range",
|
|
1277
|
+
filterBy: "filter_by",
|
|
1267
1278
|
maxGroups: "max_groups"
|
|
1268
1279
|
});
|
|
1269
1280
|
})
|
|
@@ -1472,11 +1483,13 @@ var AttachExpiryDurationType$outboundSchema = z10.enum(AttachExpiryDurationType)
|
|
|
1472
1483
|
var AttachRollover$outboundSchema = z10.pipe(
|
|
1473
1484
|
z10.object({
|
|
1474
1485
|
max: z10.optional(z10.number()),
|
|
1486
|
+
maxPercentage: z10.optional(z10.number()),
|
|
1475
1487
|
expiryDurationType: AttachExpiryDurationType$outboundSchema,
|
|
1476
1488
|
expiryDurationLength: z10.optional(z10.number())
|
|
1477
1489
|
}),
|
|
1478
1490
|
z10.transform((v) => {
|
|
1479
1491
|
return remap(v, {
|
|
1492
|
+
maxPercentage: "max_percentage",
|
|
1480
1493
|
expiryDurationType: "expiry_duration_type",
|
|
1481
1494
|
expiryDurationLength: "expiry_duration_length"
|
|
1482
1495
|
});
|
|
@@ -2001,11 +2014,13 @@ var BillingUpdateExpiryDurationType$outboundSchema = z12.enum(BillingUpdateExpir
|
|
|
2001
2014
|
var BillingUpdateRollover$outboundSchema = z12.pipe(
|
|
2002
2015
|
z12.object({
|
|
2003
2016
|
max: z12.optional(z12.number()),
|
|
2017
|
+
maxPercentage: z12.optional(z12.number()),
|
|
2004
2018
|
expiryDurationType: BillingUpdateExpiryDurationType$outboundSchema,
|
|
2005
2019
|
expiryDurationLength: z12.optional(z12.number())
|
|
2006
2020
|
}),
|
|
2007
2021
|
z12.transform((v) => {
|
|
2008
2022
|
return remap(v, {
|
|
2023
|
+
maxPercentage: "max_percentage",
|
|
2009
2024
|
expiryDurationType: "expiry_duration_type",
|
|
2010
2025
|
expiryDurationLength: "expiry_duration_length"
|
|
2011
2026
|
});
|
|
@@ -2347,11 +2362,19 @@ var ProductDisplay$inboundSchema = z13.pipe(
|
|
|
2347
2362
|
})
|
|
2348
2363
|
);
|
|
2349
2364
|
var RolloverDuration$inboundSchema = inboundSchema(RolloverDuration);
|
|
2350
|
-
var CheckRollover$inboundSchema = z13.
|
|
2351
|
-
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
|
|
2365
|
+
var CheckRollover$inboundSchema = z13.pipe(
|
|
2366
|
+
z13.object({
|
|
2367
|
+
max: z13.optional(z13.nullable(number2())),
|
|
2368
|
+
max_percentage: z13.optional(z13.nullable(number2())),
|
|
2369
|
+
duration: z13._default(RolloverDuration$inboundSchema, "month"),
|
|
2370
|
+
length: number2()
|
|
2371
|
+
}),
|
|
2372
|
+
z13.transform((v) => {
|
|
2373
|
+
return remap(v, {
|
|
2374
|
+
"max_percentage": "maxPercentage"
|
|
2375
|
+
});
|
|
2376
|
+
})
|
|
2377
|
+
);
|
|
2355
2378
|
var CheckOnIncrease$inboundSchema = inboundSchema(CheckOnIncrease);
|
|
2356
2379
|
var CheckOnDecrease$inboundSchema = inboundSchema(CheckOnDecrease);
|
|
2357
2380
|
var Config$inboundSchema = z13.pipe(
|
|
@@ -2628,6 +2651,17 @@ var CustomerDataUsageAlert$outboundSchema = z15.pipe(
|
|
|
2628
2651
|
});
|
|
2629
2652
|
})
|
|
2630
2653
|
);
|
|
2654
|
+
var CustomerDataOverageAllowed$outboundSchema = z15.pipe(
|
|
2655
|
+
z15.object({
|
|
2656
|
+
featureId: z15.string(),
|
|
2657
|
+
enabled: z15._default(z15.boolean(), false)
|
|
2658
|
+
}),
|
|
2659
|
+
z15.transform((v) => {
|
|
2660
|
+
return remap(v, {
|
|
2661
|
+
featureId: "feature_id"
|
|
2662
|
+
});
|
|
2663
|
+
})
|
|
2664
|
+
);
|
|
2631
2665
|
var CustomerDataBillingControls$outboundSchema = z15.pipe(
|
|
2632
2666
|
z15.object({
|
|
2633
2667
|
autoTopups: z15.optional(
|
|
@@ -2638,13 +2672,17 @@ var CustomerDataBillingControls$outboundSchema = z15.pipe(
|
|
|
2638
2672
|
),
|
|
2639
2673
|
usageAlerts: z15.optional(
|
|
2640
2674
|
z15.array(z15.lazy(() => CustomerDataUsageAlert$outboundSchema))
|
|
2675
|
+
),
|
|
2676
|
+
overageAllowed: z15.optional(
|
|
2677
|
+
z15.array(z15.lazy(() => CustomerDataOverageAllowed$outboundSchema))
|
|
2641
2678
|
)
|
|
2642
2679
|
}),
|
|
2643
2680
|
z15.transform((v) => {
|
|
2644
2681
|
return remap(v, {
|
|
2645
2682
|
autoTopups: "auto_topups",
|
|
2646
2683
|
spendLimits: "spend_limits",
|
|
2647
|
-
usageAlerts: "usage_alerts"
|
|
2684
|
+
usageAlerts: "usage_alerts",
|
|
2685
|
+
overageAllowed: "overage_allowed"
|
|
2648
2686
|
});
|
|
2649
2687
|
})
|
|
2650
2688
|
);
|
|
@@ -2855,11 +2893,13 @@ var ExpiryDurationType$inboundSchema = inboundSchema(ExpiryDurationType);
|
|
|
2855
2893
|
var PlanRollover$inboundSchema = z16.pipe(
|
|
2856
2894
|
z16.object({
|
|
2857
2895
|
max: nullable(number2()),
|
|
2896
|
+
max_percentage: z16.optional(z16.nullable(number2())),
|
|
2858
2897
|
expiry_duration_type: ExpiryDurationType$inboundSchema,
|
|
2859
2898
|
expiry_duration_length: optional2(number2())
|
|
2860
2899
|
}),
|
|
2861
2900
|
z16.transform((v) => {
|
|
2862
2901
|
return remap(v, {
|
|
2902
|
+
"max_percentage": "maxPercentage",
|
|
2863
2903
|
"expiry_duration_type": "expiryDurationType",
|
|
2864
2904
|
"expiry_duration_length": "expiryDurationLength"
|
|
2865
2905
|
});
|
|
@@ -2998,6 +3038,17 @@ var CreateEntityUsageAlertRequestBody$outboundSchema = z17.pipe(
|
|
|
2998
3038
|
});
|
|
2999
3039
|
})
|
|
3000
3040
|
);
|
|
3041
|
+
var CreateEntityOverageAllowedRequest$outboundSchema = z17.pipe(
|
|
3042
|
+
z17.object({
|
|
3043
|
+
featureId: z17.string(),
|
|
3044
|
+
enabled: z17._default(z17.boolean(), false)
|
|
3045
|
+
}),
|
|
3046
|
+
z17.transform((v) => {
|
|
3047
|
+
return remap(v, {
|
|
3048
|
+
featureId: "feature_id"
|
|
3049
|
+
});
|
|
3050
|
+
})
|
|
3051
|
+
);
|
|
3001
3052
|
var CreateEntityBillingControlsRequest$outboundSchema = z17.pipe(
|
|
3002
3053
|
z17.object({
|
|
3003
3054
|
spendLimits: z17.optional(
|
|
@@ -3005,12 +3056,16 @@ var CreateEntityBillingControlsRequest$outboundSchema = z17.pipe(
|
|
|
3005
3056
|
),
|
|
3006
3057
|
usageAlerts: z17.optional(
|
|
3007
3058
|
z17.array(z17.lazy(() => CreateEntityUsageAlertRequestBody$outboundSchema))
|
|
3059
|
+
),
|
|
3060
|
+
overageAllowed: z17.optional(
|
|
3061
|
+
z17.array(z17.lazy(() => CreateEntityOverageAllowedRequest$outboundSchema))
|
|
3008
3062
|
)
|
|
3009
3063
|
}),
|
|
3010
3064
|
z17.transform((v) => {
|
|
3011
3065
|
return remap(v, {
|
|
3012
3066
|
spendLimits: "spend_limits",
|
|
3013
|
-
usageAlerts: "usage_alerts"
|
|
3067
|
+
usageAlerts: "usage_alerts",
|
|
3068
|
+
overageAllowed: "overage_allowed"
|
|
3014
3069
|
});
|
|
3015
3070
|
})
|
|
3016
3071
|
);
|
|
@@ -3167,6 +3222,17 @@ var CreateEntityUsageAlertResponse$inboundSchema = z17.pipe(
|
|
|
3167
3222
|
});
|
|
3168
3223
|
})
|
|
3169
3224
|
);
|
|
3225
|
+
var CreateEntityOverageAllowedResponse$inboundSchema = z17.pipe(
|
|
3226
|
+
z17.object({
|
|
3227
|
+
feature_id: string4(),
|
|
3228
|
+
enabled: z17._default(boolean2(), false)
|
|
3229
|
+
}),
|
|
3230
|
+
z17.transform((v) => {
|
|
3231
|
+
return remap(v, {
|
|
3232
|
+
"feature_id": "featureId"
|
|
3233
|
+
});
|
|
3234
|
+
})
|
|
3235
|
+
);
|
|
3170
3236
|
var CreateEntityBillingControlsResponse$inboundSchema = z17.pipe(
|
|
3171
3237
|
z17.object({
|
|
3172
3238
|
spend_limits: optional2(
|
|
@@ -3174,12 +3240,16 @@ var CreateEntityBillingControlsResponse$inboundSchema = z17.pipe(
|
|
|
3174
3240
|
),
|
|
3175
3241
|
usage_alerts: optional2(
|
|
3176
3242
|
z17.array(z17.lazy(() => CreateEntityUsageAlertResponse$inboundSchema))
|
|
3243
|
+
),
|
|
3244
|
+
overage_allowed: optional2(
|
|
3245
|
+
z17.array(z17.lazy(() => CreateEntityOverageAllowedResponse$inboundSchema))
|
|
3177
3246
|
)
|
|
3178
3247
|
}),
|
|
3179
3248
|
z17.transform((v) => {
|
|
3180
3249
|
return remap(v, {
|
|
3181
3250
|
"spend_limits": "spendLimits",
|
|
3182
|
-
"usage_alerts": "usageAlerts"
|
|
3251
|
+
"usage_alerts": "usageAlerts",
|
|
3252
|
+
"overage_allowed": "overageAllowed"
|
|
3183
3253
|
});
|
|
3184
3254
|
})
|
|
3185
3255
|
);
|
|
@@ -3529,11 +3599,13 @@ var CreatePlanExpiryDurationTypeRequest$outboundSchema = z19.enum(CreatePlanExpi
|
|
|
3529
3599
|
var CreatePlanRolloverRequest$outboundSchema = z19.pipe(
|
|
3530
3600
|
z19.object({
|
|
3531
3601
|
max: z19.optional(z19.number()),
|
|
3602
|
+
maxPercentage: z19.optional(z19.number()),
|
|
3532
3603
|
expiryDurationType: CreatePlanExpiryDurationTypeRequest$outboundSchema,
|
|
3533
3604
|
expiryDurationLength: z19.optional(z19.number())
|
|
3534
3605
|
}),
|
|
3535
3606
|
z19.transform((v) => {
|
|
3536
3607
|
return remap(v, {
|
|
3608
|
+
maxPercentage: "max_percentage",
|
|
3537
3609
|
expiryDurationType: "expiry_duration_type",
|
|
3538
3610
|
expiryDurationLength: "expiry_duration_length"
|
|
3539
3611
|
});
|
|
@@ -3710,11 +3782,13 @@ var CreatePlanExpiryDurationTypeResponse$inboundSchema = inboundSchema(CreatePla
|
|
|
3710
3782
|
var CreatePlanRolloverResponse$inboundSchema = z19.pipe(
|
|
3711
3783
|
z19.object({
|
|
3712
3784
|
max: nullable(number2()),
|
|
3785
|
+
max_percentage: z19.optional(z19.nullable(number2())),
|
|
3713
3786
|
expiry_duration_type: CreatePlanExpiryDurationTypeResponse$inboundSchema,
|
|
3714
3787
|
expiry_duration_length: optional2(number2())
|
|
3715
3788
|
}),
|
|
3716
3789
|
z19.transform((v) => {
|
|
3717
3790
|
return remap(v, {
|
|
3791
|
+
"max_percentage": "maxPercentage",
|
|
3718
3792
|
"expiry_duration_type": "expiryDurationType",
|
|
3719
3793
|
"expiry_duration_length": "expiryDurationLength"
|
|
3720
3794
|
});
|
|
@@ -3936,6 +4010,17 @@ var CustomerUsageAlert$inboundSchema = z21.pipe(
|
|
|
3936
4010
|
});
|
|
3937
4011
|
})
|
|
3938
4012
|
);
|
|
4013
|
+
var CustomerOverageAllowed$inboundSchema = z21.pipe(
|
|
4014
|
+
z21.object({
|
|
4015
|
+
feature_id: string4(),
|
|
4016
|
+
enabled: z21._default(boolean2(), false)
|
|
4017
|
+
}),
|
|
4018
|
+
z21.transform((v) => {
|
|
4019
|
+
return remap(v, {
|
|
4020
|
+
"feature_id": "featureId"
|
|
4021
|
+
});
|
|
4022
|
+
})
|
|
4023
|
+
);
|
|
3939
4024
|
var CustomerBillingControls$inboundSchema = z21.pipe(
|
|
3940
4025
|
z21.object({
|
|
3941
4026
|
auto_topups: optional2(
|
|
@@ -3946,13 +4031,17 @@ var CustomerBillingControls$inboundSchema = z21.pipe(
|
|
|
3946
4031
|
),
|
|
3947
4032
|
usage_alerts: optional2(
|
|
3948
4033
|
z21.array(z21.lazy(() => CustomerUsageAlert$inboundSchema))
|
|
4034
|
+
),
|
|
4035
|
+
overage_allowed: optional2(
|
|
4036
|
+
z21.array(z21.lazy(() => CustomerOverageAllowed$inboundSchema))
|
|
3949
4037
|
)
|
|
3950
4038
|
}),
|
|
3951
4039
|
z21.transform((v) => {
|
|
3952
4040
|
return remap(v, {
|
|
3953
4041
|
"auto_topups": "autoTopups",
|
|
3954
4042
|
"spend_limits": "spendLimits",
|
|
3955
|
-
"usage_alerts": "usageAlerts"
|
|
4043
|
+
"usage_alerts": "usageAlerts",
|
|
4044
|
+
"overage_allowed": "overageAllowed"
|
|
3956
4045
|
});
|
|
3957
4046
|
})
|
|
3958
4047
|
);
|
|
@@ -4491,6 +4580,17 @@ var GetEntityUsageAlert$inboundSchema = z28.pipe(
|
|
|
4491
4580
|
});
|
|
4492
4581
|
})
|
|
4493
4582
|
);
|
|
4583
|
+
var GetEntityOverageAllowed$inboundSchema = z28.pipe(
|
|
4584
|
+
z28.object({
|
|
4585
|
+
feature_id: string4(),
|
|
4586
|
+
enabled: z28._default(boolean2(), false)
|
|
4587
|
+
}),
|
|
4588
|
+
z28.transform((v) => {
|
|
4589
|
+
return remap(v, {
|
|
4590
|
+
"feature_id": "featureId"
|
|
4591
|
+
});
|
|
4592
|
+
})
|
|
4593
|
+
);
|
|
4494
4594
|
var GetEntityBillingControls$inboundSchema = z28.pipe(
|
|
4495
4595
|
z28.object({
|
|
4496
4596
|
spend_limits: optional2(
|
|
@@ -4498,12 +4598,16 @@ var GetEntityBillingControls$inboundSchema = z28.pipe(
|
|
|
4498
4598
|
),
|
|
4499
4599
|
usage_alerts: optional2(
|
|
4500
4600
|
z28.array(z28.lazy(() => GetEntityUsageAlert$inboundSchema))
|
|
4601
|
+
),
|
|
4602
|
+
overage_allowed: optional2(
|
|
4603
|
+
z28.array(z28.lazy(() => GetEntityOverageAllowed$inboundSchema))
|
|
4501
4604
|
)
|
|
4502
4605
|
}),
|
|
4503
4606
|
z28.transform((v) => {
|
|
4504
4607
|
return remap(v, {
|
|
4505
4608
|
"spend_limits": "spendLimits",
|
|
4506
|
-
"usage_alerts": "usageAlerts"
|
|
4609
|
+
"usage_alerts": "usageAlerts",
|
|
4610
|
+
"overage_allowed": "overageAllowed"
|
|
4507
4611
|
});
|
|
4508
4612
|
})
|
|
4509
4613
|
);
|
|
@@ -4681,6 +4785,17 @@ var GetOrCreateCustomerUsageAlert$outboundSchema = z30.pipe(
|
|
|
4681
4785
|
});
|
|
4682
4786
|
})
|
|
4683
4787
|
);
|
|
4788
|
+
var GetOrCreateCustomerOverageAllowed$outboundSchema = z30.pipe(
|
|
4789
|
+
z30.object({
|
|
4790
|
+
featureId: z30.string(),
|
|
4791
|
+
enabled: z30._default(z30.boolean(), false)
|
|
4792
|
+
}),
|
|
4793
|
+
z30.transform((v) => {
|
|
4794
|
+
return remap(v, {
|
|
4795
|
+
featureId: "feature_id"
|
|
4796
|
+
});
|
|
4797
|
+
})
|
|
4798
|
+
);
|
|
4684
4799
|
var GetOrCreateCustomerBillingControls$outboundSchema = z30.pipe(
|
|
4685
4800
|
z30.object({
|
|
4686
4801
|
autoTopups: z30.optional(
|
|
@@ -4691,13 +4806,17 @@ var GetOrCreateCustomerBillingControls$outboundSchema = z30.pipe(
|
|
|
4691
4806
|
),
|
|
4692
4807
|
usageAlerts: z30.optional(
|
|
4693
4808
|
z30.array(z30.lazy(() => GetOrCreateCustomerUsageAlert$outboundSchema))
|
|
4809
|
+
),
|
|
4810
|
+
overageAllowed: z30.optional(
|
|
4811
|
+
z30.array(z30.lazy(() => GetOrCreateCustomerOverageAllowed$outboundSchema))
|
|
4694
4812
|
)
|
|
4695
4813
|
}),
|
|
4696
4814
|
z30.transform((v) => {
|
|
4697
4815
|
return remap(v, {
|
|
4698
4816
|
autoTopups: "auto_topups",
|
|
4699
4817
|
spendLimits: "spend_limits",
|
|
4700
|
-
usageAlerts: "usage_alerts"
|
|
4818
|
+
usageAlerts: "usage_alerts",
|
|
4819
|
+
overageAllowed: "overage_allowed"
|
|
4701
4820
|
});
|
|
4702
4821
|
})
|
|
4703
4822
|
);
|
|
@@ -4922,11 +5041,13 @@ var GetPlanExpiryDurationType$inboundSchema = inboundSchema(GetPlanExpiryDuratio
|
|
|
4922
5041
|
var GetPlanRollover$inboundSchema = z31.pipe(
|
|
4923
5042
|
z31.object({
|
|
4924
5043
|
max: nullable(number2()),
|
|
5044
|
+
max_percentage: z31.optional(z31.nullable(number2())),
|
|
4925
5045
|
expiry_duration_type: GetPlanExpiryDurationType$inboundSchema,
|
|
4926
5046
|
expiry_duration_length: optional2(number2())
|
|
4927
5047
|
}),
|
|
4928
5048
|
z31.transform((v) => {
|
|
4929
5049
|
return remap(v, {
|
|
5050
|
+
"max_percentage": "maxPercentage",
|
|
4930
5051
|
"expiry_duration_type": "expiryDurationType",
|
|
4931
5052
|
"expiry_duration_length": "expiryDurationLength"
|
|
4932
5053
|
});
|
|
@@ -5154,6 +5275,17 @@ var ListCustomersUsageAlert$inboundSchema = z32.pipe(
|
|
|
5154
5275
|
});
|
|
5155
5276
|
})
|
|
5156
5277
|
);
|
|
5278
|
+
var ListCustomersOverageAllowed$inboundSchema = z32.pipe(
|
|
5279
|
+
z32.object({
|
|
5280
|
+
feature_id: string4(),
|
|
5281
|
+
enabled: z32._default(boolean2(), false)
|
|
5282
|
+
}),
|
|
5283
|
+
z32.transform((v) => {
|
|
5284
|
+
return remap(v, {
|
|
5285
|
+
"feature_id": "featureId"
|
|
5286
|
+
});
|
|
5287
|
+
})
|
|
5288
|
+
);
|
|
5157
5289
|
var ListCustomersBillingControls$inboundSchema = z32.pipe(
|
|
5158
5290
|
z32.object({
|
|
5159
5291
|
auto_topups: optional2(
|
|
@@ -5164,13 +5296,17 @@ var ListCustomersBillingControls$inboundSchema = z32.pipe(
|
|
|
5164
5296
|
),
|
|
5165
5297
|
usage_alerts: optional2(
|
|
5166
5298
|
z32.array(z32.lazy(() => ListCustomersUsageAlert$inboundSchema))
|
|
5299
|
+
),
|
|
5300
|
+
overage_allowed: optional2(
|
|
5301
|
+
z32.array(z32.lazy(() => ListCustomersOverageAllowed$inboundSchema))
|
|
5167
5302
|
)
|
|
5168
5303
|
}),
|
|
5169
5304
|
z32.transform((v) => {
|
|
5170
5305
|
return remap(v, {
|
|
5171
5306
|
"auto_topups": "autoTopups",
|
|
5172
5307
|
"spend_limits": "spendLimits",
|
|
5173
|
-
"usage_alerts": "usageAlerts"
|
|
5308
|
+
"usage_alerts": "usageAlerts",
|
|
5309
|
+
"overage_allowed": "overageAllowed"
|
|
5174
5310
|
});
|
|
5175
5311
|
})
|
|
5176
5312
|
);
|
|
@@ -5625,11 +5761,13 @@ var ListPlansExpiryDurationType$inboundSchema = inboundSchema(ListPlansExpiryDur
|
|
|
5625
5761
|
var ListPlansRollover$inboundSchema = z35.pipe(
|
|
5626
5762
|
z35.object({
|
|
5627
5763
|
max: nullable(number2()),
|
|
5764
|
+
max_percentage: z35.optional(z35.nullable(number2())),
|
|
5628
5765
|
expiry_duration_type: ListPlansExpiryDurationType$inboundSchema,
|
|
5629
5766
|
expiry_duration_length: optional2(number2())
|
|
5630
5767
|
}),
|
|
5631
5768
|
z35.transform((v) => {
|
|
5632
5769
|
return remap(v, {
|
|
5770
|
+
"max_percentage": "maxPercentage",
|
|
5633
5771
|
"expiry_duration_type": "expiryDurationType",
|
|
5634
5772
|
"expiry_duration_length": "expiryDurationLength"
|
|
5635
5773
|
});
|
|
@@ -5873,11 +6011,13 @@ var MultiAttachExpiryDurationType$outboundSchema = z36.enum(MultiAttachExpiryDur
|
|
|
5873
6011
|
var MultiAttachRollover$outboundSchema = z36.pipe(
|
|
5874
6012
|
z36.object({
|
|
5875
6013
|
max: z36.optional(z36.number()),
|
|
6014
|
+
maxPercentage: z36.optional(z36.number()),
|
|
5876
6015
|
expiryDurationType: MultiAttachExpiryDurationType$outboundSchema,
|
|
5877
6016
|
expiryDurationLength: z36.optional(z36.number())
|
|
5878
6017
|
}),
|
|
5879
6018
|
z36.transform((v) => {
|
|
5880
6019
|
return remap(v, {
|
|
6020
|
+
maxPercentage: "max_percentage",
|
|
5881
6021
|
expiryDurationType: "expiry_duration_type",
|
|
5882
6022
|
expiryDurationLength: "expiry_duration_length"
|
|
5883
6023
|
});
|
|
@@ -6004,6 +6144,17 @@ var MultiAttachUsageAlert$outboundSchema = z36.pipe(
|
|
|
6004
6144
|
});
|
|
6005
6145
|
})
|
|
6006
6146
|
);
|
|
6147
|
+
var MultiAttachOverageAllowed$outboundSchema = z36.pipe(
|
|
6148
|
+
z36.object({
|
|
6149
|
+
featureId: z36.string(),
|
|
6150
|
+
enabled: z36._default(z36.boolean(), false)
|
|
6151
|
+
}),
|
|
6152
|
+
z36.transform((v) => {
|
|
6153
|
+
return remap(v, {
|
|
6154
|
+
featureId: "feature_id"
|
|
6155
|
+
});
|
|
6156
|
+
})
|
|
6157
|
+
);
|
|
6007
6158
|
var MultiAttachBillingControls$outboundSchema = z36.pipe(
|
|
6008
6159
|
z36.object({
|
|
6009
6160
|
spendLimits: z36.optional(
|
|
@@ -6011,12 +6162,16 @@ var MultiAttachBillingControls$outboundSchema = z36.pipe(
|
|
|
6011
6162
|
),
|
|
6012
6163
|
usageAlerts: z36.optional(
|
|
6013
6164
|
z36.array(z36.lazy(() => MultiAttachUsageAlert$outboundSchema))
|
|
6165
|
+
),
|
|
6166
|
+
overageAllowed: z36.optional(
|
|
6167
|
+
z36.array(z36.lazy(() => MultiAttachOverageAllowed$outboundSchema))
|
|
6014
6168
|
)
|
|
6015
6169
|
}),
|
|
6016
6170
|
z36.transform((v) => {
|
|
6017
6171
|
return remap(v, {
|
|
6018
6172
|
spendLimits: "spend_limits",
|
|
6019
|
-
usageAlerts: "usage_alerts"
|
|
6173
|
+
usageAlerts: "usage_alerts",
|
|
6174
|
+
overageAllowed: "overage_allowed"
|
|
6020
6175
|
});
|
|
6021
6176
|
})
|
|
6022
6177
|
);
|
|
@@ -6310,11 +6465,13 @@ var PreviewAttachExpiryDurationType$outboundSchema = z38.enum(PreviewAttachExpir
|
|
|
6310
6465
|
var PreviewAttachRollover$outboundSchema = z38.pipe(
|
|
6311
6466
|
z38.object({
|
|
6312
6467
|
max: z38.optional(z38.number()),
|
|
6468
|
+
maxPercentage: z38.optional(z38.number()),
|
|
6313
6469
|
expiryDurationType: PreviewAttachExpiryDurationType$outboundSchema,
|
|
6314
6470
|
expiryDurationLength: z38.optional(z38.number())
|
|
6315
6471
|
}),
|
|
6316
6472
|
z38.transform((v) => {
|
|
6317
6473
|
return remap(v, {
|
|
6474
|
+
maxPercentage: "max_percentage",
|
|
6318
6475
|
expiryDurationType: "expiry_duration_type",
|
|
6319
6476
|
expiryDurationLength: "expiry_duration_length"
|
|
6320
6477
|
});
|
|
@@ -6858,11 +7015,13 @@ var PreviewMultiAttachExpiryDurationType$outboundSchema = z39.enum(PreviewMultiA
|
|
|
6858
7015
|
var PreviewMultiAttachRollover$outboundSchema = z39.pipe(
|
|
6859
7016
|
z39.object({
|
|
6860
7017
|
max: z39.optional(z39.number()),
|
|
7018
|
+
maxPercentage: z39.optional(z39.number()),
|
|
6861
7019
|
expiryDurationType: PreviewMultiAttachExpiryDurationType$outboundSchema,
|
|
6862
7020
|
expiryDurationLength: z39.optional(z39.number())
|
|
6863
7021
|
}),
|
|
6864
7022
|
z39.transform((v) => {
|
|
6865
7023
|
return remap(v, {
|
|
7024
|
+
maxPercentage: "max_percentage",
|
|
6866
7025
|
expiryDurationType: "expiry_duration_type",
|
|
6867
7026
|
expiryDurationLength: "expiry_duration_length"
|
|
6868
7027
|
});
|
|
@@ -7002,6 +7161,17 @@ var PreviewMultiAttachUsageAlert$outboundSchema = z39.pipe(
|
|
|
7002
7161
|
});
|
|
7003
7162
|
})
|
|
7004
7163
|
);
|
|
7164
|
+
var PreviewMultiAttachOverageAllowed$outboundSchema = z39.pipe(
|
|
7165
|
+
z39.object({
|
|
7166
|
+
featureId: z39.string(),
|
|
7167
|
+
enabled: z39._default(z39.boolean(), false)
|
|
7168
|
+
}),
|
|
7169
|
+
z39.transform((v) => {
|
|
7170
|
+
return remap(v, {
|
|
7171
|
+
featureId: "feature_id"
|
|
7172
|
+
});
|
|
7173
|
+
})
|
|
7174
|
+
);
|
|
7005
7175
|
var PreviewMultiAttachBillingControls$outboundSchema = z39.pipe(
|
|
7006
7176
|
z39.object({
|
|
7007
7177
|
spendLimits: z39.optional(
|
|
@@ -7009,12 +7179,16 @@ var PreviewMultiAttachBillingControls$outboundSchema = z39.pipe(
|
|
|
7009
7179
|
),
|
|
7010
7180
|
usageAlerts: z39.optional(
|
|
7011
7181
|
z39.array(z39.lazy(() => PreviewMultiAttachUsageAlert$outboundSchema))
|
|
7182
|
+
),
|
|
7183
|
+
overageAllowed: z39.optional(
|
|
7184
|
+
z39.array(z39.lazy(() => PreviewMultiAttachOverageAllowed$outboundSchema))
|
|
7012
7185
|
)
|
|
7013
7186
|
}),
|
|
7014
7187
|
z39.transform((v) => {
|
|
7015
7188
|
return remap(v, {
|
|
7016
7189
|
spendLimits: "spend_limits",
|
|
7017
|
-
usageAlerts: "usage_alerts"
|
|
7190
|
+
usageAlerts: "usage_alerts",
|
|
7191
|
+
overageAllowed: "overage_allowed"
|
|
7018
7192
|
});
|
|
7019
7193
|
})
|
|
7020
7194
|
);
|
|
@@ -7470,11 +7644,13 @@ var PreviewUpdateExpiryDurationType$outboundSchema = z40.enum(PreviewUpdateExpir
|
|
|
7470
7644
|
var PreviewUpdateRollover$outboundSchema = z40.pipe(
|
|
7471
7645
|
z40.object({
|
|
7472
7646
|
max: z40.optional(z40.number()),
|
|
7647
|
+
maxPercentage: z40.optional(z40.number()),
|
|
7473
7648
|
expiryDurationType: PreviewUpdateExpiryDurationType$outboundSchema,
|
|
7474
7649
|
expiryDurationLength: z40.optional(z40.number())
|
|
7475
7650
|
}),
|
|
7476
7651
|
z40.transform((v) => {
|
|
7477
7652
|
return remap(v, {
|
|
7653
|
+
maxPercentage: "max_percentage",
|
|
7478
7654
|
expiryDurationType: "expiry_duration_type",
|
|
7479
7655
|
expiryDurationLength: "expiry_duration_length"
|
|
7480
7656
|
});
|
|
@@ -7990,11 +8166,13 @@ var SetupPaymentExpiryDurationType$outboundSchema = z42.enum(SetupPaymentExpiryD
|
|
|
7990
8166
|
var SetupPaymentRollover$outboundSchema = z42.pipe(
|
|
7991
8167
|
z42.object({
|
|
7992
8168
|
max: z42.optional(z42.number()),
|
|
8169
|
+
maxPercentage: z42.optional(z42.number()),
|
|
7993
8170
|
expiryDurationType: SetupPaymentExpiryDurationType$outboundSchema,
|
|
7994
8171
|
expiryDurationLength: z42.optional(z42.number())
|
|
7995
8172
|
}),
|
|
7996
8173
|
z42.transform((v) => {
|
|
7997
8174
|
return remap(v, {
|
|
8175
|
+
maxPercentage: "max_percentage",
|
|
7998
8176
|
expiryDurationType: "expiry_duration_type",
|
|
7999
8177
|
expiryDurationLength: "expiry_duration_length"
|
|
8000
8178
|
});
|
|
@@ -8339,6 +8517,17 @@ var UpdateCustomerUsageAlertRequestBody$outboundSchema = z45.pipe(
|
|
|
8339
8517
|
});
|
|
8340
8518
|
})
|
|
8341
8519
|
);
|
|
8520
|
+
var UpdateCustomerOverageAllowedRequest$outboundSchema = z45.pipe(
|
|
8521
|
+
z45.object({
|
|
8522
|
+
featureId: z45.string(),
|
|
8523
|
+
enabled: z45._default(z45.boolean(), false)
|
|
8524
|
+
}),
|
|
8525
|
+
z45.transform((v) => {
|
|
8526
|
+
return remap(v, {
|
|
8527
|
+
featureId: "feature_id"
|
|
8528
|
+
});
|
|
8529
|
+
})
|
|
8530
|
+
);
|
|
8342
8531
|
var UpdateCustomerBillingControlsRequest$outboundSchema = z45.pipe(
|
|
8343
8532
|
z45.object({
|
|
8344
8533
|
autoTopups: z45.optional(
|
|
@@ -8349,13 +8538,17 @@ var UpdateCustomerBillingControlsRequest$outboundSchema = z45.pipe(
|
|
|
8349
8538
|
),
|
|
8350
8539
|
usageAlerts: z45.optional(
|
|
8351
8540
|
z45.array(z45.lazy(() => UpdateCustomerUsageAlertRequestBody$outboundSchema))
|
|
8541
|
+
),
|
|
8542
|
+
overageAllowed: z45.optional(
|
|
8543
|
+
z45.array(z45.lazy(() => UpdateCustomerOverageAllowedRequest$outboundSchema))
|
|
8352
8544
|
)
|
|
8353
8545
|
}),
|
|
8354
8546
|
z45.transform((v) => {
|
|
8355
8547
|
return remap(v, {
|
|
8356
8548
|
autoTopups: "auto_topups",
|
|
8357
8549
|
spendLimits: "spend_limits",
|
|
8358
|
-
usageAlerts: "usage_alerts"
|
|
8550
|
+
usageAlerts: "usage_alerts",
|
|
8551
|
+
overageAllowed: "overage_allowed"
|
|
8359
8552
|
});
|
|
8360
8553
|
})
|
|
8361
8554
|
);
|
|
@@ -8443,6 +8636,17 @@ var UpdateCustomerUsageAlertResponse$inboundSchema = z45.pipe(
|
|
|
8443
8636
|
});
|
|
8444
8637
|
})
|
|
8445
8638
|
);
|
|
8639
|
+
var UpdateCustomerOverageAllowedResponse$inboundSchema = z45.pipe(
|
|
8640
|
+
z45.object({
|
|
8641
|
+
feature_id: string4(),
|
|
8642
|
+
enabled: z45._default(boolean2(), false)
|
|
8643
|
+
}),
|
|
8644
|
+
z45.transform((v) => {
|
|
8645
|
+
return remap(v, {
|
|
8646
|
+
"feature_id": "featureId"
|
|
8647
|
+
});
|
|
8648
|
+
})
|
|
8649
|
+
);
|
|
8446
8650
|
var UpdateCustomerBillingControlsResponse$inboundSchema = z45.pipe(
|
|
8447
8651
|
z45.object({
|
|
8448
8652
|
auto_topups: optional2(
|
|
@@ -8453,13 +8657,17 @@ var UpdateCustomerBillingControlsResponse$inboundSchema = z45.pipe(
|
|
|
8453
8657
|
),
|
|
8454
8658
|
usage_alerts: optional2(
|
|
8455
8659
|
z45.array(z45.lazy(() => UpdateCustomerUsageAlertResponse$inboundSchema))
|
|
8660
|
+
),
|
|
8661
|
+
overage_allowed: optional2(
|
|
8662
|
+
z45.array(z45.lazy(() => UpdateCustomerOverageAllowedResponse$inboundSchema))
|
|
8456
8663
|
)
|
|
8457
8664
|
}),
|
|
8458
8665
|
z45.transform((v) => {
|
|
8459
8666
|
return remap(v, {
|
|
8460
8667
|
"auto_topups": "autoTopups",
|
|
8461
8668
|
"spend_limits": "spendLimits",
|
|
8462
|
-
"usage_alerts": "usageAlerts"
|
|
8669
|
+
"usage_alerts": "usageAlerts",
|
|
8670
|
+
"overage_allowed": "overageAllowed"
|
|
8463
8671
|
});
|
|
8464
8672
|
})
|
|
8465
8673
|
);
|
|
@@ -8651,6 +8859,17 @@ var UpdateEntityUsageAlertRequestBody$outboundSchema = z46.pipe(
|
|
|
8651
8859
|
});
|
|
8652
8860
|
})
|
|
8653
8861
|
);
|
|
8862
|
+
var UpdateEntityOverageAllowedRequest$outboundSchema = z46.pipe(
|
|
8863
|
+
z46.object({
|
|
8864
|
+
featureId: z46.string(),
|
|
8865
|
+
enabled: z46._default(z46.boolean(), false)
|
|
8866
|
+
}),
|
|
8867
|
+
z46.transform((v) => {
|
|
8868
|
+
return remap(v, {
|
|
8869
|
+
featureId: "feature_id"
|
|
8870
|
+
});
|
|
8871
|
+
})
|
|
8872
|
+
);
|
|
8654
8873
|
var UpdateEntityBillingControlsRequest$outboundSchema = z46.pipe(
|
|
8655
8874
|
z46.object({
|
|
8656
8875
|
spendLimits: z46.optional(
|
|
@@ -8658,12 +8877,16 @@ var UpdateEntityBillingControlsRequest$outboundSchema = z46.pipe(
|
|
|
8658
8877
|
),
|
|
8659
8878
|
usageAlerts: z46.optional(
|
|
8660
8879
|
z46.array(z46.lazy(() => UpdateEntityUsageAlertRequestBody$outboundSchema))
|
|
8880
|
+
),
|
|
8881
|
+
overageAllowed: z46.optional(
|
|
8882
|
+
z46.array(z46.lazy(() => UpdateEntityOverageAllowedRequest$outboundSchema))
|
|
8661
8883
|
)
|
|
8662
8884
|
}),
|
|
8663
8885
|
z46.transform((v) => {
|
|
8664
8886
|
return remap(v, {
|
|
8665
8887
|
spendLimits: "spend_limits",
|
|
8666
|
-
usageAlerts: "usage_alerts"
|
|
8888
|
+
usageAlerts: "usage_alerts",
|
|
8889
|
+
overageAllowed: "overage_allowed"
|
|
8667
8890
|
});
|
|
8668
8891
|
})
|
|
8669
8892
|
);
|
|
@@ -8815,6 +9038,17 @@ var UpdateEntityUsageAlertResponse$inboundSchema = z46.pipe(
|
|
|
8815
9038
|
});
|
|
8816
9039
|
})
|
|
8817
9040
|
);
|
|
9041
|
+
var UpdateEntityOverageAllowedResponse$inboundSchema = z46.pipe(
|
|
9042
|
+
z46.object({
|
|
9043
|
+
feature_id: string4(),
|
|
9044
|
+
enabled: z46._default(boolean2(), false)
|
|
9045
|
+
}),
|
|
9046
|
+
z46.transform((v) => {
|
|
9047
|
+
return remap(v, {
|
|
9048
|
+
"feature_id": "featureId"
|
|
9049
|
+
});
|
|
9050
|
+
})
|
|
9051
|
+
);
|
|
8818
9052
|
var UpdateEntityBillingControlsResponse$inboundSchema = z46.pipe(
|
|
8819
9053
|
z46.object({
|
|
8820
9054
|
spend_limits: optional2(
|
|
@@ -8822,12 +9056,16 @@ var UpdateEntityBillingControlsResponse$inboundSchema = z46.pipe(
|
|
|
8822
9056
|
),
|
|
8823
9057
|
usage_alerts: optional2(
|
|
8824
9058
|
z46.array(z46.lazy(() => UpdateEntityUsageAlertResponse$inboundSchema))
|
|
9059
|
+
),
|
|
9060
|
+
overage_allowed: optional2(
|
|
9061
|
+
z46.array(z46.lazy(() => UpdateEntityOverageAllowedResponse$inboundSchema))
|
|
8825
9062
|
)
|
|
8826
9063
|
}),
|
|
8827
9064
|
z46.transform((v) => {
|
|
8828
9065
|
return remap(v, {
|
|
8829
9066
|
"spend_limits": "spendLimits",
|
|
8830
|
-
"usage_alerts": "usageAlerts"
|
|
9067
|
+
"usage_alerts": "usageAlerts",
|
|
9068
|
+
"overage_allowed": "overageAllowed"
|
|
8831
9069
|
});
|
|
8832
9070
|
})
|
|
8833
9071
|
);
|
|
@@ -9180,11 +9418,13 @@ var UpdatePlanExpiryDurationTypeRequest$outboundSchema = z48.enum(UpdatePlanExpi
|
|
|
9180
9418
|
var UpdatePlanRolloverRequest$outboundSchema = z48.pipe(
|
|
9181
9419
|
z48.object({
|
|
9182
9420
|
max: z48.optional(z48.number()),
|
|
9421
|
+
maxPercentage: z48.optional(z48.number()),
|
|
9183
9422
|
expiryDurationType: UpdatePlanExpiryDurationTypeRequest$outboundSchema,
|
|
9184
9423
|
expiryDurationLength: z48.optional(z48.number())
|
|
9185
9424
|
}),
|
|
9186
9425
|
z48.transform((v) => {
|
|
9187
9426
|
return remap(v, {
|
|
9427
|
+
maxPercentage: "max_percentage",
|
|
9188
9428
|
expiryDurationType: "expiry_duration_type",
|
|
9189
9429
|
expiryDurationLength: "expiry_duration_length"
|
|
9190
9430
|
});
|
|
@@ -9369,11 +9609,13 @@ var UpdatePlanExpiryDurationTypeResponse$inboundSchema = inboundSchema(UpdatePla
|
|
|
9369
9609
|
var UpdatePlanRolloverResponse$inboundSchema = z48.pipe(
|
|
9370
9610
|
z48.object({
|
|
9371
9611
|
max: nullable(number2()),
|
|
9612
|
+
max_percentage: z48.optional(z48.nullable(number2())),
|
|
9372
9613
|
expiry_duration_type: UpdatePlanExpiryDurationTypeResponse$inboundSchema,
|
|
9373
9614
|
expiry_duration_length: optional2(number2())
|
|
9374
9615
|
}),
|
|
9375
9616
|
z48.transform((v) => {
|
|
9376
9617
|
return remap(v, {
|
|
9618
|
+
"max_percentage": "maxPercentage",
|
|
9377
9619
|
"expiry_duration_type": "expiryDurationType",
|
|
9378
9620
|
"expiry_duration_length": "expiryDurationLength"
|
|
9379
9621
|
});
|
|
@@ -9650,7 +9892,8 @@ async function $do2(client, request, options) {
|
|
|
9650
9892
|
var FAIL_OPEN_OPERATION_IDS = /* @__PURE__ */ new Set([
|
|
9651
9893
|
"check",
|
|
9652
9894
|
"track",
|
|
9653
|
-
"getOrCreateCustomer"
|
|
9895
|
+
"getOrCreateCustomer",
|
|
9896
|
+
"getEntity"
|
|
9654
9897
|
]);
|
|
9655
9898
|
var FAIL_OPEN_LOG_MESSAGE = "[Autumn] Request failed \u2014 failing open. Learn more: https://docs.useautumn.com/documentation/fail-open";
|
|
9656
9899
|
var FAIL_OPEN_BODIES = {
|
|
@@ -9680,6 +9923,18 @@ var FAIL_OPEN_BODIES = {
|
|
|
9680
9923
|
purchases: [],
|
|
9681
9924
|
balances: {},
|
|
9682
9925
|
flags: {}
|
|
9926
|
+
},
|
|
9927
|
+
getEntity: {
|
|
9928
|
+
id: null,
|
|
9929
|
+
name: null,
|
|
9930
|
+
customer_id: null,
|
|
9931
|
+
feature_id: null,
|
|
9932
|
+
created_at: 0,
|
|
9933
|
+
env: "live",
|
|
9934
|
+
subscriptions: [],
|
|
9935
|
+
purchases: [],
|
|
9936
|
+
balances: {},
|
|
9937
|
+
flags: {}
|
|
9683
9938
|
}
|
|
9684
9939
|
};
|
|
9685
9940
|
var FailOpenHook = class {
|
|
@@ -9860,8 +10115,8 @@ var SDK_METADATA = {
|
|
|
9860
10115
|
language: "typescript",
|
|
9861
10116
|
openapiDocVersion: "2.2.0",
|
|
9862
10117
|
sdkVersion: "0.10.17",
|
|
9863
|
-
genVersion: "2.
|
|
9864
|
-
userAgent: "speakeasy-sdk/typescript 0.10.17 2.
|
|
10118
|
+
genVersion: "2.879.1",
|
|
10119
|
+
userAgent: "speakeasy-sdk/typescript 0.10.17 2.879.1 2.2.0 @useautumn/sdk"
|
|
9865
10120
|
};
|
|
9866
10121
|
|
|
9867
10122
|
// ../sdk/src/lib/retries.ts
|