@lokiengineering/loki-common-node 1.2.0 → 1.4.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.
- package/dist/index.d.ts +39 -31
- package/dist/index.js +40 -30
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -158,6 +158,11 @@ declare enum OrderPenaltyType {
|
|
|
158
158
|
LIQUID_DAMAGE = "LIQUID_DAMAGE",// Soda, grease, vape residue
|
|
159
159
|
SEVERE_STRUCTURAL = "SEVERE_STRUCTURAL"
|
|
160
160
|
}
|
|
161
|
+
declare enum OrderChargeStatus {
|
|
162
|
+
NOT_ASSESSED = 0,
|
|
163
|
+
PENDING = 1,
|
|
164
|
+
SETTLED = 2
|
|
165
|
+
}
|
|
161
166
|
|
|
162
167
|
declare enum MaturityRating {
|
|
163
168
|
EVERYONE = "Everyone",
|
|
@@ -217,42 +222,45 @@ declare enum ErrorEntity {
|
|
|
217
222
|
UpcomingRelease = "upcoming_release"
|
|
218
223
|
}
|
|
219
224
|
declare enum ServerErrorEnum {
|
|
220
|
-
CACHE_LOCK_FAILURE =
|
|
221
|
-
PRICING_RECALCULATION_IN_PROGRESS =
|
|
222
|
-
INVALID_PRICING_VARIABLES =
|
|
223
|
-
MISSING_PRICING_VARIABLES =
|
|
224
|
-
GENERAL =
|
|
225
|
+
CACHE_LOCK_FAILURE = 0,
|
|
226
|
+
PRICING_RECALCULATION_IN_PROGRESS = 1,
|
|
227
|
+
INVALID_PRICING_VARIABLES = 2,
|
|
228
|
+
MISSING_PRICING_VARIABLES = 3,
|
|
229
|
+
GENERAL = 4
|
|
225
230
|
}
|
|
226
231
|
declare enum BusinessLogicErrorEnum {
|
|
227
|
-
INSUFFICIENT_BALANCE =
|
|
228
|
-
COPY_HAS_ACTIVE_RESERVATION =
|
|
229
|
-
CART_EMPTY =
|
|
230
|
-
UNFINISHED_ORDER_EXISTS =
|
|
231
|
-
NOT_AVAILABLE_FOR_RENT =
|
|
232
|
-
INVALID_RENTAL_DURATION =
|
|
233
|
-
WALLET_FROZEN =
|
|
234
|
-
CANNOT_DELETE_PRIMARY_ADDRESS =
|
|
235
|
-
MAX_DEPOSIT_EXCEEDED =
|
|
236
|
-
EDITION_HAS_ACTIVE_COPIES =
|
|
237
|
-
INVALID_ORDER_TRANSITION_CONFIG =
|
|
238
|
-
MISMATCH_LATE_INPUT =
|
|
232
|
+
INSUFFICIENT_BALANCE = 0,
|
|
233
|
+
COPY_HAS_ACTIVE_RESERVATION = 1,
|
|
234
|
+
CART_EMPTY = 2,
|
|
235
|
+
UNFINISHED_ORDER_EXISTS = 3,
|
|
236
|
+
NOT_AVAILABLE_FOR_RENT = 4,
|
|
237
|
+
INVALID_RENTAL_DURATION = 5,
|
|
238
|
+
WALLET_FROZEN = 6,
|
|
239
|
+
CANNOT_DELETE_PRIMARY_ADDRESS = 7,
|
|
240
|
+
MAX_DEPOSIT_EXCEEDED = 8,
|
|
241
|
+
EDITION_HAS_ACTIVE_COPIES = 9,
|
|
242
|
+
INVALID_ORDER_TRANSITION_CONFIG = 10,
|
|
243
|
+
MISMATCH_LATE_INPUT = 11
|
|
239
244
|
}
|
|
240
245
|
declare enum GeneralErrorEnum {
|
|
241
|
-
ROUTE_NOT_FOUND =
|
|
242
|
-
INVALID_CREDENTIALS =
|
|
243
|
-
INVALID_REFRESH_TOKEN =
|
|
244
|
-
TOKEN_EXPIRED =
|
|
245
|
-
TOKEN_INVALID =
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
246
|
+
ROUTE_NOT_FOUND = 0,
|
|
247
|
+
INVALID_CREDENTIALS = 1,
|
|
248
|
+
INVALID_REFRESH_TOKEN = 2,
|
|
249
|
+
TOKEN_EXPIRED = 3,
|
|
250
|
+
TOKEN_INVALID = 4,
|
|
251
|
+
OTP_INVALID = 5,
|
|
252
|
+
OTP_EXPIRED = 6,
|
|
253
|
+
FORBIDDEN = 7,
|
|
254
|
+
UNAUTHORIZED = 8,
|
|
255
|
+
INVALID_VERIFICATION_TOKEN = 9,
|
|
256
|
+
RATE_LIMITED = 10,
|
|
257
|
+
EMAIL_ALREADY_VERIFIED = 11,
|
|
258
|
+
PHONE_ALREADY_VERIFIED = 12,
|
|
259
|
+
NOT_FOUND = 13
|
|
252
260
|
}
|
|
253
261
|
declare enum ParseError {
|
|
254
|
-
INVALID_RESPONSE =
|
|
255
|
-
INVALID_INPUT =
|
|
262
|
+
INVALID_RESPONSE = 0,
|
|
263
|
+
INVALID_INPUT = 1
|
|
256
264
|
}
|
|
257
265
|
type ErrorEnum = ServerErrorEnum | BusinessLogicErrorEnum | GeneralErrorEnum | ParseError;
|
|
258
266
|
|
|
@@ -262,4 +270,4 @@ declare enum PayoutKnownBank {
|
|
|
262
270
|
MANDIRI = "mandiri"
|
|
263
271
|
}
|
|
264
272
|
|
|
265
|
-
export { ActorType, AdminRole, ArticleType, AssetType, AssetVisibility, AuthProvider, BusinessLogicErrorEnum, ContentDescriptor, DeliveryDirection, DeliveryStatus, EmailTemplateType, ErrorEntity, type ErrorEnum, GameCopyStatus, GamePlayMode, GameTier, GeneralErrorEnum, Genre, HouseListPlatform, IncidentResolution, MaturityRating, MembershipTier, OrderIncidentType, OrderItemStatus, OrderPenaltyType, OrderStatus, OrderType, ParseError, PayoutKnownBank, PeriodKey, Platform, RefundStatus, ServerErrorEnum, TokenType, VerificationTokenType, VisibilityToTypeMap, WalletTransactionReason, WalletTransactionType };
|
|
273
|
+
export { ActorType, AdminRole, ArticleType, AssetType, AssetVisibility, AuthProvider, BusinessLogicErrorEnum, ContentDescriptor, DeliveryDirection, DeliveryStatus, EmailTemplateType, ErrorEntity, type ErrorEnum, GameCopyStatus, GamePlayMode, GameTier, GeneralErrorEnum, Genre, HouseListPlatform, IncidentResolution, MaturityRating, MembershipTier, OrderChargeStatus, OrderIncidentType, OrderItemStatus, OrderPenaltyType, OrderStatus, OrderType, ParseError, PayoutKnownBank, PeriodKey, Platform, RefundStatus, ServerErrorEnum, TokenType, VerificationTokenType, VisibilityToTypeMap, WalletTransactionReason, WalletTransactionType };
|
package/dist/index.js
CHANGED
|
@@ -185,6 +185,12 @@ var OrderPenaltyType = /* @__PURE__ */ ((OrderPenaltyType2) => {
|
|
|
185
185
|
OrderPenaltyType2["SEVERE_STRUCTURAL"] = "SEVERE_STRUCTURAL";
|
|
186
186
|
return OrderPenaltyType2;
|
|
187
187
|
})(OrderPenaltyType || {});
|
|
188
|
+
var OrderChargeStatus = /* @__PURE__ */ ((OrderChargeStatus2) => {
|
|
189
|
+
OrderChargeStatus2[OrderChargeStatus2["NOT_ASSESSED"] = 0] = "NOT_ASSESSED";
|
|
190
|
+
OrderChargeStatus2[OrderChargeStatus2["PENDING"] = 1] = "PENDING";
|
|
191
|
+
OrderChargeStatus2[OrderChargeStatus2["SETTLED"] = 2] = "SETTLED";
|
|
192
|
+
return OrderChargeStatus2;
|
|
193
|
+
})(OrderChargeStatus || {});
|
|
188
194
|
|
|
189
195
|
// src/enums/rating.enum.ts
|
|
190
196
|
var MaturityRating = /* @__PURE__ */ ((MaturityRating2) => {
|
|
@@ -252,45 +258,48 @@ var ErrorEntity = /* @__PURE__ */ ((ErrorEntity2) => {
|
|
|
252
258
|
return ErrorEntity2;
|
|
253
259
|
})(ErrorEntity || {});
|
|
254
260
|
var ServerErrorEnum = /* @__PURE__ */ ((ServerErrorEnum2) => {
|
|
255
|
-
ServerErrorEnum2["CACHE_LOCK_FAILURE"] = "CACHE_LOCK_FAILURE";
|
|
256
|
-
ServerErrorEnum2["PRICING_RECALCULATION_IN_PROGRESS"] = "PRICING_RECALCULATION_IN_PROGRESS";
|
|
257
|
-
ServerErrorEnum2["INVALID_PRICING_VARIABLES"] = "INVALID_PRICING_VARIABLES";
|
|
258
|
-
ServerErrorEnum2["MISSING_PRICING_VARIABLES"] = "MISSING_PRICING_VARIABLES";
|
|
259
|
-
ServerErrorEnum2["GENERAL"] = "GENERAL";
|
|
261
|
+
ServerErrorEnum2[ServerErrorEnum2["CACHE_LOCK_FAILURE"] = 0] = "CACHE_LOCK_FAILURE";
|
|
262
|
+
ServerErrorEnum2[ServerErrorEnum2["PRICING_RECALCULATION_IN_PROGRESS"] = 1] = "PRICING_RECALCULATION_IN_PROGRESS";
|
|
263
|
+
ServerErrorEnum2[ServerErrorEnum2["INVALID_PRICING_VARIABLES"] = 2] = "INVALID_PRICING_VARIABLES";
|
|
264
|
+
ServerErrorEnum2[ServerErrorEnum2["MISSING_PRICING_VARIABLES"] = 3] = "MISSING_PRICING_VARIABLES";
|
|
265
|
+
ServerErrorEnum2[ServerErrorEnum2["GENERAL"] = 4] = "GENERAL";
|
|
260
266
|
return ServerErrorEnum2;
|
|
261
267
|
})(ServerErrorEnum || {});
|
|
262
268
|
var BusinessLogicErrorEnum = /* @__PURE__ */ ((BusinessLogicErrorEnum2) => {
|
|
263
|
-
BusinessLogicErrorEnum2["INSUFFICIENT_BALANCE"] = "INSUFFICIENT_BALANCE";
|
|
264
|
-
BusinessLogicErrorEnum2["COPY_HAS_ACTIVE_RESERVATION"] = "COPY_HAS_ACTIVE_RESERVATION";
|
|
265
|
-
BusinessLogicErrorEnum2["CART_EMPTY"] = "CART_EMPTY";
|
|
266
|
-
BusinessLogicErrorEnum2["UNFINISHED_ORDER_EXISTS"] = "UNFINISHED_ORDER_EXISTS";
|
|
267
|
-
BusinessLogicErrorEnum2["NOT_AVAILABLE_FOR_RENT"] = "NOT_AVAILABLE_FOR_RENT";
|
|
268
|
-
BusinessLogicErrorEnum2["INVALID_RENTAL_DURATION"] = "INVALID_RENTAL_DURATION";
|
|
269
|
-
BusinessLogicErrorEnum2["WALLET_FROZEN"] = "WALLET_FROZEN";
|
|
270
|
-
BusinessLogicErrorEnum2["CANNOT_DELETE_PRIMARY_ADDRESS"] = "CANNOT_DELETE_PRIMARY_ADDRESS";
|
|
271
|
-
BusinessLogicErrorEnum2["MAX_DEPOSIT_EXCEEDED"] = "MAX_DEPOSIT_EXCEEDED";
|
|
272
|
-
BusinessLogicErrorEnum2["EDITION_HAS_ACTIVE_COPIES"] = "EDITION_HAS_ACTIVE_COPIES";
|
|
273
|
-
BusinessLogicErrorEnum2["INVALID_ORDER_TRANSITION_CONFIG"] = "INVALID_ORDER_TRANSITION_CONFIG";
|
|
274
|
-
BusinessLogicErrorEnum2["MISMATCH_LATE_INPUT"] = "MISMATCH_LATE_INPUT";
|
|
269
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["INSUFFICIENT_BALANCE"] = 0] = "INSUFFICIENT_BALANCE";
|
|
270
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["COPY_HAS_ACTIVE_RESERVATION"] = 1] = "COPY_HAS_ACTIVE_RESERVATION";
|
|
271
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["CART_EMPTY"] = 2] = "CART_EMPTY";
|
|
272
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["UNFINISHED_ORDER_EXISTS"] = 3] = "UNFINISHED_ORDER_EXISTS";
|
|
273
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["NOT_AVAILABLE_FOR_RENT"] = 4] = "NOT_AVAILABLE_FOR_RENT";
|
|
274
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["INVALID_RENTAL_DURATION"] = 5] = "INVALID_RENTAL_DURATION";
|
|
275
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["WALLET_FROZEN"] = 6] = "WALLET_FROZEN";
|
|
276
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["CANNOT_DELETE_PRIMARY_ADDRESS"] = 7] = "CANNOT_DELETE_PRIMARY_ADDRESS";
|
|
277
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["MAX_DEPOSIT_EXCEEDED"] = 8] = "MAX_DEPOSIT_EXCEEDED";
|
|
278
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["EDITION_HAS_ACTIVE_COPIES"] = 9] = "EDITION_HAS_ACTIVE_COPIES";
|
|
279
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["INVALID_ORDER_TRANSITION_CONFIG"] = 10] = "INVALID_ORDER_TRANSITION_CONFIG";
|
|
280
|
+
BusinessLogicErrorEnum2[BusinessLogicErrorEnum2["MISMATCH_LATE_INPUT"] = 11] = "MISMATCH_LATE_INPUT";
|
|
275
281
|
return BusinessLogicErrorEnum2;
|
|
276
282
|
})(BusinessLogicErrorEnum || {});
|
|
277
283
|
var GeneralErrorEnum = /* @__PURE__ */ ((GeneralErrorEnum2) => {
|
|
278
|
-
GeneralErrorEnum2["ROUTE_NOT_FOUND"] = "ROUTE_NOT_FOUND";
|
|
279
|
-
GeneralErrorEnum2["INVALID_CREDENTIALS"] = "INVALID_CREDENTIALS";
|
|
280
|
-
GeneralErrorEnum2["INVALID_REFRESH_TOKEN"] = "INVALID_REFRESH_TOKEN";
|
|
281
|
-
GeneralErrorEnum2["TOKEN_EXPIRED"] = "TOKEN_EXPIRED";
|
|
282
|
-
GeneralErrorEnum2["TOKEN_INVALID"] = "TOKEN_INVALID";
|
|
283
|
-
GeneralErrorEnum2["
|
|
284
|
-
GeneralErrorEnum2["
|
|
285
|
-
GeneralErrorEnum2["
|
|
286
|
-
GeneralErrorEnum2["
|
|
287
|
-
GeneralErrorEnum2["
|
|
288
|
-
GeneralErrorEnum2["
|
|
284
|
+
GeneralErrorEnum2[GeneralErrorEnum2["ROUTE_NOT_FOUND"] = 0] = "ROUTE_NOT_FOUND";
|
|
285
|
+
GeneralErrorEnum2[GeneralErrorEnum2["INVALID_CREDENTIALS"] = 1] = "INVALID_CREDENTIALS";
|
|
286
|
+
GeneralErrorEnum2[GeneralErrorEnum2["INVALID_REFRESH_TOKEN"] = 2] = "INVALID_REFRESH_TOKEN";
|
|
287
|
+
GeneralErrorEnum2[GeneralErrorEnum2["TOKEN_EXPIRED"] = 3] = "TOKEN_EXPIRED";
|
|
288
|
+
GeneralErrorEnum2[GeneralErrorEnum2["TOKEN_INVALID"] = 4] = "TOKEN_INVALID";
|
|
289
|
+
GeneralErrorEnum2[GeneralErrorEnum2["OTP_INVALID"] = 5] = "OTP_INVALID";
|
|
290
|
+
GeneralErrorEnum2[GeneralErrorEnum2["OTP_EXPIRED"] = 6] = "OTP_EXPIRED";
|
|
291
|
+
GeneralErrorEnum2[GeneralErrorEnum2["FORBIDDEN"] = 7] = "FORBIDDEN";
|
|
292
|
+
GeneralErrorEnum2[GeneralErrorEnum2["UNAUTHORIZED"] = 8] = "UNAUTHORIZED";
|
|
293
|
+
GeneralErrorEnum2[GeneralErrorEnum2["INVALID_VERIFICATION_TOKEN"] = 9] = "INVALID_VERIFICATION_TOKEN";
|
|
294
|
+
GeneralErrorEnum2[GeneralErrorEnum2["RATE_LIMITED"] = 10] = "RATE_LIMITED";
|
|
295
|
+
GeneralErrorEnum2[GeneralErrorEnum2["EMAIL_ALREADY_VERIFIED"] = 11] = "EMAIL_ALREADY_VERIFIED";
|
|
296
|
+
GeneralErrorEnum2[GeneralErrorEnum2["PHONE_ALREADY_VERIFIED"] = 12] = "PHONE_ALREADY_VERIFIED";
|
|
297
|
+
GeneralErrorEnum2[GeneralErrorEnum2["NOT_FOUND"] = 13] = "NOT_FOUND";
|
|
289
298
|
return GeneralErrorEnum2;
|
|
290
299
|
})(GeneralErrorEnum || {});
|
|
291
300
|
var ParseError = /* @__PURE__ */ ((ParseError2) => {
|
|
292
|
-
ParseError2["INVALID_RESPONSE"] = "INVALID_RESPONSE";
|
|
293
|
-
ParseError2["INVALID_INPUT"] = "INVALID_INPUT";
|
|
301
|
+
ParseError2[ParseError2["INVALID_RESPONSE"] = 0] = "INVALID_RESPONSE";
|
|
302
|
+
ParseError2[ParseError2["INVALID_INPUT"] = 1] = "INVALID_INPUT";
|
|
294
303
|
return ParseError2;
|
|
295
304
|
})(ParseError || {});
|
|
296
305
|
|
|
@@ -323,6 +332,7 @@ export {
|
|
|
323
332
|
IncidentResolution,
|
|
324
333
|
MaturityRating,
|
|
325
334
|
MembershipTier,
|
|
335
|
+
OrderChargeStatus,
|
|
326
336
|
OrderIncidentType,
|
|
327
337
|
OrderItemStatus,
|
|
328
338
|
OrderPenaltyType,
|