atmn 1.1.17 → 1.1.18
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/cli.js +79 -49
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -46954,7 +46954,7 @@ var hasBillingControls = (value) => Boolean(value && typeof value === "object" &
|
|
|
46954
46954
|
...filter2.feature_id !== undefined ? { featureId: filter2.feature_id } : {},
|
|
46955
46955
|
...filter2.billing_method !== undefined ? { billingMethod: filter2.billing_method } : {},
|
|
46956
46956
|
...filter2.interval !== undefined ? { interval: filter2.interval } : {},
|
|
46957
|
-
...filter2.interval_count !== undefined
|
|
46957
|
+
...filter2.interval_count !== undefined ? { intervalCount: filter2.interval_count } : {}
|
|
46958
46958
|
}), transformApiCustomizePlan = (customize) => {
|
|
46959
46959
|
if (!customize)
|
|
46960
46960
|
return;
|
|
@@ -48433,7 +48433,7 @@ var init_pull = __esm(() => {
|
|
|
48433
48433
|
});
|
|
48434
48434
|
|
|
48435
48435
|
// src/lib/version.ts
|
|
48436
|
-
var APP_VERSION = "1.1.
|
|
48436
|
+
var APP_VERSION = "1.1.18";
|
|
48437
48437
|
|
|
48438
48438
|
// ../../node_modules/.bun/@tanstack+query-core@5.101.1/node_modules/@tanstack/query-core/build/modern/subscribable.js
|
|
48439
48439
|
var Subscribable = class {
|
|
@@ -110661,28 +110661,6 @@ var init_billingControls = __esm(() => {
|
|
|
110661
110661
|
init_usageLimit2();
|
|
110662
110662
|
});
|
|
110663
110663
|
|
|
110664
|
-
// ../../shared/api/errors/base/RecaseError.ts
|
|
110665
|
-
var RecaseError;
|
|
110666
|
-
var init_RecaseError = __esm(() => {
|
|
110667
|
-
RecaseError = class RecaseError extends Error {
|
|
110668
|
-
code;
|
|
110669
|
-
statusCode;
|
|
110670
|
-
data;
|
|
110671
|
-
constructor({
|
|
110672
|
-
message,
|
|
110673
|
-
code,
|
|
110674
|
-
statusCode = 400,
|
|
110675
|
-
data
|
|
110676
|
-
}) {
|
|
110677
|
-
super(message);
|
|
110678
|
-
this.name = "RecaseError";
|
|
110679
|
-
this.code = code || "invalid_request";
|
|
110680
|
-
this.statusCode = statusCode;
|
|
110681
|
-
this.data = data;
|
|
110682
|
-
}
|
|
110683
|
-
};
|
|
110684
|
-
});
|
|
110685
|
-
|
|
110686
110664
|
// ../../shared/enums/ErrCode.ts
|
|
110687
110665
|
var ErrCode;
|
|
110688
110666
|
var init_ErrCode = __esm(() => {
|
|
@@ -110823,6 +110801,28 @@ var init_ErrCode = __esm(() => {
|
|
|
110823
110801
|
};
|
|
110824
110802
|
});
|
|
110825
110803
|
|
|
110804
|
+
// ../../shared/api/errors/base/RecaseError.ts
|
|
110805
|
+
var RecaseError;
|
|
110806
|
+
var init_RecaseError = __esm(() => {
|
|
110807
|
+
RecaseError = class RecaseError extends Error {
|
|
110808
|
+
code;
|
|
110809
|
+
statusCode;
|
|
110810
|
+
data;
|
|
110811
|
+
constructor({
|
|
110812
|
+
message,
|
|
110813
|
+
code,
|
|
110814
|
+
statusCode = 400,
|
|
110815
|
+
data
|
|
110816
|
+
}) {
|
|
110817
|
+
super(message);
|
|
110818
|
+
this.name = "RecaseError";
|
|
110819
|
+
this.code = code || "invalid_request";
|
|
110820
|
+
this.statusCode = statusCode;
|
|
110821
|
+
this.data = data;
|
|
110822
|
+
}
|
|
110823
|
+
};
|
|
110824
|
+
});
|
|
110825
|
+
|
|
110826
110826
|
// ../../shared/api/common/cursorPaginationSchemas.ts
|
|
110827
110827
|
function defineCursor({
|
|
110828
110828
|
fieldsSchema
|
|
@@ -110898,7 +110898,7 @@ function defineCursor({
|
|
|
110898
110898
|
};
|
|
110899
110899
|
return { fieldsSchema, encode, decode, predicate };
|
|
110900
110900
|
}
|
|
110901
|
-
var CURRENT_CURSOR_VERSION = 0, StandardCursorFieldsSchema, StandardCursor, PaginationDefaults, CursorRequestFieldSchema, createCursorLimitSchema = ({
|
|
110901
|
+
var CURRENT_CURSOR_VERSION = 0, StandardCursorFieldsSchema, StandardCursor, SortOrderSchema, PaginationDefaults, CursorRequestFieldSchema, createCursorLimitSchema = ({
|
|
110902
110902
|
defaultLimit = PaginationDefaults.DefaultLimit,
|
|
110903
110903
|
maxLimit = PaginationDefaults.SchemaHardCeiling
|
|
110904
110904
|
} = {}) => exports_external.coerce.number().int().min(1).max(maxLimit).default(defaultLimit).describe(`Number of items to return. Default ${defaultLimit}, hard ceiling ${maxLimit}.`), createCursorPaginatedResponseSchema = (itemSchema) => exports_external.object({
|
|
@@ -110908,8 +110908,8 @@ var CURRENT_CURSOR_VERSION = 0, StandardCursorFieldsSchema, StandardCursor, Pagi
|
|
|
110908
110908
|
var init_cursorPaginationSchemas = __esm(() => {
|
|
110909
110909
|
init_drizzle_orm();
|
|
110910
110910
|
init_v4();
|
|
110911
|
-
init_RecaseError();
|
|
110912
110911
|
init_ErrCode();
|
|
110912
|
+
init_RecaseError();
|
|
110913
110913
|
StandardCursorFieldsSchema = exports_external.object({
|
|
110914
110914
|
v: exports_external.literal(CURRENT_CURSOR_VERSION),
|
|
110915
110915
|
id: exports_external.string().min(1),
|
|
@@ -110918,6 +110918,7 @@ var init_cursorPaginationSchemas = __esm(() => {
|
|
|
110918
110918
|
StandardCursor = defineCursor({
|
|
110919
110919
|
fieldsSchema: StandardCursorFieldsSchema
|
|
110920
110920
|
});
|
|
110921
|
+
SortOrderSchema = exports_external.enum(["asc", "desc"]);
|
|
110921
110922
|
PaginationDefaults = {
|
|
110922
110923
|
DefaultLimit: 50,
|
|
110923
110924
|
MaxLimit: 1000,
|
|
@@ -112071,7 +112072,7 @@ var init_migrationParams = __esm(() => {
|
|
|
112071
112072
|
// ../../shared/utils/planV1Utils/diff/diffPlanV1.ts
|
|
112072
112073
|
var DiffedCustomizePlanV1Schema;
|
|
112073
112074
|
var init_diffPlanV1 = __esm(() => {
|
|
112074
|
-
|
|
112075
|
+
init_customizePlanV1();
|
|
112075
112076
|
init_freeTrialEnums();
|
|
112076
112077
|
init_usagePriceConfig();
|
|
112077
112078
|
DiffedCustomizePlanV1Schema = refineCustomizePlanV1Schema(CustomizePlanV1BaseSchema.omit({
|
|
@@ -112554,6 +112555,9 @@ var init_productItemModels = __esm(() => {
|
|
|
112554
112555
|
}),
|
|
112555
112556
|
price_config: exports_external.any().nullish().meta({
|
|
112556
112557
|
internal: true
|
|
112558
|
+
}),
|
|
112559
|
+
_uid: exports_external.string().nullish().meta({
|
|
112560
|
+
internal: true
|
|
112557
112561
|
})
|
|
112558
112562
|
});
|
|
112559
112563
|
LimitedItemSchema = ProductItemSchema.extend({
|
|
@@ -112912,8 +112916,8 @@ var init_rewardsCreateOpModels = __esm(() => {
|
|
|
112912
112916
|
name: exports_external.string().min(1),
|
|
112913
112917
|
grants: exports_external.array(exports_external.object({
|
|
112914
112918
|
feature_id: exports_external.string().min(1),
|
|
112915
|
-
included: exports_external.number().
|
|
112916
|
-
description: "A
|
|
112919
|
+
included: exports_external.number().nonnegative().nullable().meta({
|
|
112920
|
+
description: "A non-negative amount to grant, or null for boolean features."
|
|
112917
112921
|
}),
|
|
112918
112922
|
expiry: GrantExpirySchema2
|
|
112919
112923
|
}).strict()).min(1).meta({ description: "Feature IDs must be unique." }),
|
|
@@ -113799,6 +113803,9 @@ var init_apiBalance = __esm(() => {
|
|
|
113799
113803
|
})
|
|
113800
113804
|
});
|
|
113801
113805
|
ApiBalanceRolloverSchema = exports_external.object({
|
|
113806
|
+
granted: exports_external.number().meta({
|
|
113807
|
+
description: "Amount originally rolled over from a previous period, before any of it was consumed."
|
|
113808
|
+
}),
|
|
113802
113809
|
balance: exports_external.number().meta({
|
|
113803
113810
|
description: "Amount of balance rolled over from a previous period."
|
|
113804
113811
|
}),
|
|
@@ -114869,11 +114876,31 @@ var init_listCustomersParamsV2 = __esm(() => {
|
|
|
114869
114876
|
});
|
|
114870
114877
|
});
|
|
114871
114878
|
|
|
114879
|
+
// ../../shared/api/customers/customerListFilters.ts
|
|
114880
|
+
var MAX_FILTER_VALUES = 1000, MAX_FILTER_VALUE_LENGTH = 200, FilterValuesSchema, CreatedAtRangeSchema, CustomerListFiltersSchema;
|
|
114881
|
+
var init_customerListFilters = __esm(() => {
|
|
114882
|
+
init_v4();
|
|
114883
|
+
FilterValuesSchema = exports_external.array(exports_external.string().max(MAX_FILTER_VALUE_LENGTH)).max(MAX_FILTER_VALUES);
|
|
114884
|
+
CreatedAtRangeSchema = exports_external.object({
|
|
114885
|
+
start: exports_external.coerce.number().optional().describe("Include customers created at or after this timestamp (epoch milliseconds, inclusive)"),
|
|
114886
|
+
end: exports_external.coerce.number().optional().describe("Include customers created at or before this timestamp (epoch milliseconds, inclusive)")
|
|
114887
|
+
}).refine(({ start, end }) => start === undefined || end === undefined || start <= end, { message: "created_at_range.start must be <= created_at_range.end" });
|
|
114888
|
+
CustomerListFiltersSchema = exports_external.object({
|
|
114889
|
+
status: FilterValuesSchema.optional(),
|
|
114890
|
+
version: FilterValuesSchema.optional(),
|
|
114891
|
+
none: exports_external.boolean().optional(),
|
|
114892
|
+
processor: FilterValuesSchema.optional(),
|
|
114893
|
+
interval: FilterValuesSchema.optional(),
|
|
114894
|
+
created_at_range: CreatedAtRangeSchema.optional()
|
|
114895
|
+
});
|
|
114896
|
+
});
|
|
114897
|
+
|
|
114872
114898
|
// ../../shared/api/customers/crud/listCustomersParamsV2_3.ts
|
|
114873
114899
|
var ListCustomersV2_3ParamsSchema;
|
|
114874
114900
|
var init_listCustomersParamsV2_3 = __esm(() => {
|
|
114875
114901
|
init_v4();
|
|
114876
114902
|
init_cursorPaginationSchemas();
|
|
114903
|
+
init_customerListFilters();
|
|
114877
114904
|
ListCustomersV2_3ParamsSchema = exports_external.object({
|
|
114878
114905
|
start_cursor: CursorRequestFieldSchema,
|
|
114879
114906
|
limit: createCursorLimitSchema({
|
|
@@ -114893,6 +114920,12 @@ var init_listCustomersParamsV2_3 = __esm(() => {
|
|
|
114893
114920
|
}),
|
|
114894
114921
|
processors: exports_external.array(exports_external.enum(["stripe", "revenuecat", "vercel"])).optional().meta({
|
|
114895
114922
|
description: "Filter by customer processor type (stripe, revenuecat, vercel)."
|
|
114923
|
+
}),
|
|
114924
|
+
sort_order: SortOrderSchema.optional().meta({
|
|
114925
|
+
description: "Sort by customer creation time. Defaults to desc (newest first)."
|
|
114926
|
+
}),
|
|
114927
|
+
created_at_range: CreatedAtRangeSchema.optional().meta({
|
|
114928
|
+
description: "Filter by customer creation time (epoch milliseconds, inclusive bounds)."
|
|
114896
114929
|
})
|
|
114897
114930
|
});
|
|
114898
114931
|
});
|
|
@@ -116476,6 +116509,7 @@ var init_productModels = __esm(() => {
|
|
|
116476
116509
|
UpdateProductSchema = exports_external.object({
|
|
116477
116510
|
id: exports_external.string().nullish(),
|
|
116478
116511
|
name: exports_external.string().min(1, "Product name cannot be empty").optional(),
|
|
116512
|
+
description: exports_external.string().nullish(),
|
|
116479
116513
|
is_add_on: exports_external.boolean().optional(),
|
|
116480
116514
|
is_default: exports_external.boolean().optional(),
|
|
116481
116515
|
group: exports_external.string().nullish(),
|
|
@@ -121728,6 +121762,7 @@ var init_cusEntsToReset = __esm(() => {
|
|
|
121728
121762
|
|
|
121729
121763
|
// ../../shared/utils/cusEntUtils/balanceUtils/cusEntsToRollovers.ts
|
|
121730
121764
|
var init_cusEntsToRollovers = __esm(() => {
|
|
121765
|
+
init_decimal();
|
|
121731
121766
|
init_shared2();
|
|
121732
121767
|
});
|
|
121733
121768
|
// ../../shared/utils/cusEntUtils/balanceUtils/grantedBalanceUtils/cusEntsToAllowance.ts
|
|
@@ -122993,20 +123028,6 @@ var init_cusProcessors = __esm(() => {
|
|
|
122993
123028
|
init_apiCusProcessors();
|
|
122994
123029
|
});
|
|
122995
123030
|
|
|
122996
|
-
// ../../shared/api/customers/customerListFilters.ts
|
|
122997
|
-
var MAX_FILTER_VALUES = 1000, MAX_FILTER_VALUE_LENGTH = 200, FilterValuesSchema, CustomerListFiltersSchema;
|
|
122998
|
-
var init_customerListFilters = __esm(() => {
|
|
122999
|
-
init_v4();
|
|
123000
|
-
FilterValuesSchema = exports_external.array(exports_external.string().max(MAX_FILTER_VALUE_LENGTH)).max(MAX_FILTER_VALUES);
|
|
123001
|
-
CustomerListFiltersSchema = exports_external.object({
|
|
123002
|
-
status: FilterValuesSchema.optional(),
|
|
123003
|
-
version: FilterValuesSchema.optional(),
|
|
123004
|
-
none: exports_external.boolean().optional(),
|
|
123005
|
-
processor: FilterValuesSchema.optional(),
|
|
123006
|
-
interval: FilterValuesSchema.optional()
|
|
123007
|
-
});
|
|
123008
|
-
});
|
|
123009
|
-
|
|
123010
123031
|
// ../../shared/models/cusModels/cusExportModels.ts
|
|
123011
123032
|
var CustomerExportStatus, ACTIVE_CUSTOMER_EXPORT_STATUSES, CustomerExportField, CUSTOMER_EXPORT_FIELD_ORDER, CUSTOMER_EXPORT_FIELD_HEADERS, CustomerExportStatusSchema, CustomerExportFieldSchema, CustomerExportFieldsSchema, CustomerExportSnapshotSchema;
|
|
123012
123033
|
var init_cusExportModels = __esm(() => {
|
|
@@ -123936,6 +123957,9 @@ var init_productOpModels = __esm(() => {
|
|
|
123936
123957
|
create_in_stripe: exports_external.boolean().optional().meta({
|
|
123937
123958
|
internal: true
|
|
123938
123959
|
}),
|
|
123960
|
+
archived: exports_external.boolean().optional().meta({
|
|
123961
|
+
internal: true
|
|
123962
|
+
}),
|
|
123939
123963
|
base_internal_product_id: exports_external.string().nullable().optional().meta({
|
|
123940
123964
|
internal: true
|
|
123941
123965
|
})
|
|
@@ -124418,7 +124442,7 @@ var init_rewardsOpModels = __esm(() => {
|
|
|
124418
124442
|
name: exports_external.string().min(1).optional(),
|
|
124419
124443
|
grants: exports_external.array(exports_external.object({
|
|
124420
124444
|
feature_id: exports_external.string().min(1),
|
|
124421
|
-
included: exports_external.number().
|
|
124445
|
+
included: exports_external.number().nonnegative().nullable(),
|
|
124422
124446
|
expiry: ApiGrantV0Schema.shape.expiry
|
|
124423
124447
|
}).strict()).min(1).optional().meta({ description: "Replaces the existing grants when provided." }),
|
|
124424
124448
|
promo_codes: exports_external.array(exports_external.object({
|
|
@@ -126830,7 +126854,12 @@ var init_models = __esm(() => {
|
|
|
126830
126854
|
var LimitType, BALANCES_LIMIT_REACHED_EXAMPLE, BalancesLimitReachedSchema;
|
|
126831
126855
|
var init_balancesLimitReached = __esm(() => {
|
|
126832
126856
|
init_v4();
|
|
126833
|
-
LimitType = exports_external.enum([
|
|
126857
|
+
LimitType = exports_external.enum([
|
|
126858
|
+
"included",
|
|
126859
|
+
"max_purchase",
|
|
126860
|
+
"spend_limit",
|
|
126861
|
+
"usage_limit"
|
|
126862
|
+
]);
|
|
126834
126863
|
BALANCES_LIMIT_REACHED_EXAMPLE = {
|
|
126835
126864
|
customer_id: "org_123",
|
|
126836
126865
|
entity_id: "workspace_abc",
|
|
@@ -126848,7 +126877,7 @@ var init_balancesLimitReached = __esm(() => {
|
|
|
126848
126877
|
description: "The feature ID whose limit was reached."
|
|
126849
126878
|
}),
|
|
126850
126879
|
limit_type: LimitType.meta({
|
|
126851
|
-
description: "Which limit was hit: included allowance, max purchase cap, or
|
|
126880
|
+
description: "Which limit was hit: included allowance, max purchase cap, spend limit, or a usage-limit billing control."
|
|
126852
126881
|
})
|
|
126853
126882
|
}).meta({
|
|
126854
126883
|
examples: [BALANCES_LIMIT_REACHED_EXAMPLE]
|
|
@@ -127196,7 +127225,7 @@ var init_webhookRegistry = __esm(() => {
|
|
|
127196
127225
|
title: "Limit Reached",
|
|
127197
127226
|
schema: BalancesLimitReachedSchema,
|
|
127198
127227
|
group: "Balances",
|
|
127199
|
-
description: "Fired when a customer reaches the limit for a feature (included allowance, max purchase, or
|
|
127228
|
+
description: "Fired when a customer reaches the limit for a feature (included allowance, max purchase, spend limit, or a usage-limit billing control)."
|
|
127200
127229
|
},
|
|
127201
127230
|
{
|
|
127202
127231
|
eventType: "billing.auto_topup_failed" /* BillingAutoTopupFailed */,
|
|
@@ -133168,7 +133197,7 @@ var init_rewardModels = __esm(() => {
|
|
|
133168
133197
|
});
|
|
133169
133198
|
RewardEntitlementSchema = exports_external.object({
|
|
133170
133199
|
internal_feature_id: exports_external.string().min(1),
|
|
133171
|
-
allowance: exports_external.number().
|
|
133200
|
+
allowance: exports_external.number().nonnegative().optional(),
|
|
133172
133201
|
expiry: EntitlementExpirySchema.optional()
|
|
133173
133202
|
});
|
|
133174
133203
|
DiscountConfigSchema = exports_external.object({
|
|
@@ -134044,7 +134073,8 @@ var init_generateItemChanges = __esm(() => {
|
|
|
134044
134073
|
"price_id",
|
|
134045
134074
|
"price_config",
|
|
134046
134075
|
"isPrice",
|
|
134047
|
-
"isVariable"
|
|
134076
|
+
"isVariable",
|
|
134077
|
+
"_uid"
|
|
134048
134078
|
]);
|
|
134049
134079
|
});
|
|
134050
134080
|
|