@gigapay-dev/contracts 1.8.6 → 3.0.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/README.md +1 -0
- package/build/domains/admin/index.d.ts +150 -0
- package/build/domains/admin/index.d.ts.map +1 -0
- package/build/domains/admin/index.js +72 -0
- package/build/domains/admin/index.js.map +1 -0
- package/build/domains/auth/commands.d.ts +294 -0
- package/build/domains/auth/commands.d.ts.map +1 -0
- package/build/domains/auth/commands.js +116 -0
- package/build/domains/auth/commands.js.map +1 -0
- package/build/domains/auth/dtos.d.ts +37 -0
- package/build/domains/auth/dtos.d.ts.map +1 -0
- package/build/domains/auth/dtos.js +26 -0
- package/build/domains/auth/dtos.js.map +1 -0
- package/build/domains/auth/events.d.ts +35 -0
- package/build/domains/auth/events.d.ts.map +1 -0
- package/build/domains/auth/events.js +24 -0
- package/build/domains/auth/events.js.map +1 -0
- package/build/domains/auth/index.d.ts +165 -0
- package/build/domains/auth/index.d.ts.map +1 -0
- package/build/{commands/products → domains/auth}/index.js +12 -6
- package/build/domains/auth/index.js.map +1 -0
- package/build/domains/auth/queries.d.ts +75 -0
- package/build/domains/auth/queries.d.ts.map +1 -0
- package/build/domains/auth/queries.js +25 -0
- package/build/domains/auth/queries.js.map +1 -0
- package/build/domains/catalog/commands.d.ts +255 -0
- package/build/domains/catalog/commands.d.ts.map +1 -0
- package/build/domains/catalog/commands.js +82 -0
- package/build/domains/catalog/commands.js.map +1 -0
- package/build/domains/catalog/dtos.d.ts +89 -0
- package/build/domains/catalog/dtos.d.ts.map +1 -0
- package/build/domains/catalog/dtos.js +43 -0
- package/build/domains/catalog/dtos.js.map +1 -0
- package/build/domains/catalog/index.d.ts +194 -0
- package/build/domains/catalog/index.d.ts.map +1 -0
- package/build/{commands/payment-methods → domains/catalog}/index.js +11 -4
- package/build/domains/catalog/index.js.map +1 -0
- package/build/domains/catalog/queries.d.ts +168 -0
- package/build/domains/catalog/queries.d.ts.map +1 -0
- package/build/domains/catalog/queries.js +29 -0
- package/build/domains/catalog/queries.js.map +1 -0
- package/build/domains/config/index.d.ts +40 -0
- package/build/domains/config/index.d.ts.map +1 -0
- package/build/domains/config/index.js +18 -0
- package/build/domains/config/index.js.map +1 -0
- package/build/domains/orders/commands.d.ts +262 -0
- package/build/domains/orders/commands.d.ts.map +1 -0
- package/build/domains/orders/commands.js +47 -0
- package/build/domains/orders/commands.js.map +1 -0
- package/build/domains/orders/dtos.d.ts +112 -0
- package/build/domains/orders/dtos.d.ts.map +1 -0
- package/build/domains/orders/dtos.js +44 -0
- package/build/domains/orders/dtos.js.map +1 -0
- package/build/domains/orders/events.d.ts +21 -0
- package/build/domains/orders/events.d.ts.map +1 -0
- package/build/domains/orders/events.js +19 -0
- package/build/domains/orders/events.js.map +1 -0
- package/build/domains/orders/index.d.ts +381 -0
- package/build/domains/orders/index.d.ts.map +1 -0
- package/build/domains/orders/index.js +28 -0
- package/build/domains/orders/index.js.map +1 -0
- package/build/domains/orders/queries.d.ts +532 -0
- package/build/domains/orders/queries.d.ts.map +1 -0
- package/build/domains/orders/queries.js +40 -0
- package/build/domains/orders/queries.js.map +1 -0
- package/build/domains/payments/index.d.ts +96 -0
- package/build/domains/payments/index.d.ts.map +1 -0
- package/build/domains/payments/index.js +34 -0
- package/build/domains/payments/index.js.map +1 -0
- package/build/domains/products/commands.d.ts +302 -0
- package/build/domains/products/commands.d.ts.map +1 -0
- package/build/domains/products/commands.js +101 -0
- package/build/domains/products/commands.js.map +1 -0
- package/build/domains/products/dtos.d.ts +122 -0
- package/build/domains/products/dtos.d.ts.map +1 -0
- package/build/domains/products/dtos.js +54 -0
- package/build/domains/products/dtos.js.map +1 -0
- package/build/domains/products/index.d.ts +276 -0
- package/build/domains/products/index.d.ts.map +1 -0
- package/build/{commands/auth → domains/products}/index.js +11 -5
- package/build/domains/products/index.js.map +1 -0
- package/build/domains/products/queries.d.ts +334 -0
- package/build/domains/products/queries.d.ts.map +1 -0
- package/build/domains/products/queries.js +41 -0
- package/build/domains/products/queries.js.map +1 -0
- package/build/domains/promo-codes/index.d.ts +92 -0
- package/build/domains/promo-codes/index.d.ts.map +1 -0
- package/build/domains/promo-codes/index.js +40 -0
- package/build/domains/promo-codes/index.js.map +1 -0
- package/build/domains/stats/index.d.ts +274 -0
- package/build/domains/stats/index.d.ts.map +1 -0
- package/build/domains/stats/index.js +76 -0
- package/build/domains/stats/index.js.map +1 -0
- package/build/domains/users/dtos.d.ts +9 -0
- package/build/domains/users/dtos.d.ts.map +1 -0
- package/build/domains/users/dtos.js +11 -0
- package/build/domains/users/dtos.js.map +1 -0
- package/build/domains/users/index.d.ts +101 -0
- package/build/domains/users/index.d.ts.map +1 -0
- package/build/domains/users/index.js +52 -0
- package/build/domains/users/index.js.map +1 -0
- package/build/index.d.ts +1310 -1
- package/build/index.d.ts.map +1 -0
- package/build/index.js +35 -1
- package/build/index.js.map +1 -0
- package/build/shared/api-response.d.ts +17 -0
- package/build/shared/api-response.d.ts.map +1 -0
- package/build/shared/api-response.js +22 -0
- package/build/shared/api-response.js.map +1 -0
- package/build/shared/common.d.ts +14 -0
- package/build/shared/common.d.ts.map +1 -0
- package/build/shared/common.js +8 -0
- package/build/shared/common.js.map +1 -0
- package/build/shared/errors.d.ts +34 -0
- package/build/shared/errors.d.ts.map +1 -0
- package/build/shared/errors.js +36 -0
- package/build/shared/errors.js.map +1 -0
- package/build/shared/index.d.ts +7 -0
- package/build/shared/index.d.ts.map +1 -0
- package/build/{commands/orders → shared}/index.js +7 -6
- package/build/shared/index.js.map +1 -0
- package/build/shared/money.d.ts +32 -0
- package/build/shared/money.d.ts.map +1 -0
- package/build/shared/money.js +20 -0
- package/build/shared/money.js.map +1 -0
- package/build/shared/pagination.d.ts +27 -0
- package/build/shared/pagination.d.ts.map +1 -0
- package/build/shared/pagination.js +22 -0
- package/build/shared/pagination.js.map +1 -0
- package/build/shared/types.d.ts +20 -0
- package/build/shared/types.d.ts.map +1 -0
- package/build/{types.js → shared/types.js} +1 -0
- package/build/shared/types.js.map +1 -0
- package/package.json +41 -15
- package/build/commands/api-response.d.ts +0 -18
- package/build/commands/api-response.js +0 -13
- package/build/commands/auth/confirm.d.ts +0 -11
- package/build/commands/auth/confirm.js +0 -11
- package/build/commands/auth/endpoints.d.ts +0 -114
- package/build/commands/auth/endpoints.js +0 -50
- package/build/commands/auth/index.d.ts +0 -5
- package/build/commands/auth/login.d.ts +0 -20
- package/build/commands/auth/login.js +0 -11
- package/build/commands/auth/profile.d.ts +0 -18
- package/build/commands/auth/profile.js +0 -10
- package/build/commands/auth/register.d.ts +0 -12
- package/build/commands/auth/register.js +0 -11
- package/build/commands/auth/reset.d.ts +0 -12
- package/build/commands/auth/reset.js +0 -9
- package/build/commands/consts.d.ts +0 -1
- package/build/commands/consts.js +0 -4
- package/build/commands/index.d.ts +0 -13
- package/build/commands/index.js +0 -29
- package/build/commands/orders/create.d.ts +0 -95
- package/build/commands/orders/create.js +0 -40
- package/build/commands/orders/endpoints.d.ts +0 -726
- package/build/commands/orders/endpoints.js +0 -47
- package/build/commands/orders/enums.d.ts +0 -7
- package/build/commands/orders/enums.js +0 -25
- package/build/commands/orders/index.d.ts +0 -6
- package/build/commands/orders/query.d.ts +0 -103
- package/build/commands/orders/query.js +0 -45
- package/build/commands/orders/read.d.ts +0 -230
- package/build/commands/orders/read.js +0 -81
- package/build/commands/orders/update.d.ts +0 -23
- package/build/commands/orders/update.js +0 -16
- package/build/commands/pagination.d.ts +0 -12
- package/build/commands/pagination.js +0 -11
- package/build/commands/payment-methods/create.d.ts +0 -45
- package/build/commands/payment-methods/create.js +0 -22
- package/build/commands/payment-methods/endpoints.d.ts +0 -536
- package/build/commands/payment-methods/endpoints.js +0 -63
- package/build/commands/payment-methods/index.d.ts +0 -4
- package/build/commands/payment-methods/read.d.ts +0 -71
- package/build/commands/payment-methods/read.js +0 -28
- package/build/commands/payment-methods/update.d.ts +0 -45
- package/build/commands/payment-methods/update.js +0 -19
- package/build/commands/products/create.d.ts +0 -229
- package/build/commands/products/create.js +0 -122
- package/build/commands/products/endpoints.d.ts +0 -1881
- package/build/commands/products/endpoints.js +0 -99
- package/build/commands/products/enums.d.ts +0 -19
- package/build/commands/products/enums.js +0 -27
- package/build/commands/products/index.d.ts +0 -6
- package/build/commands/products/query.d.ts +0 -79
- package/build/commands/products/query.js +0 -55
- package/build/commands/products/read.d.ts +0 -1178
- package/build/commands/products/read.js +0 -231
- package/build/commands/products/update.d.ts +0 -78
- package/build/commands/products/update.js +0 -10
- package/build/commands/promocode-activations/create.d.ts +0 -18
- package/build/commands/promocode-activations/create.js +0 -10
- package/build/commands/promocode-activations/index.d.ts +0 -3
- package/build/commands/promocode-activations/index.js +0 -19
- package/build/commands/promocode-activations/read.d.ts +0 -21
- package/build/commands/promocode-activations/read.js +0 -14
- package/build/commands/promocode-activations/update.d.ts +0 -18
- package/build/commands/promocode-activations/update.js +0 -10
- package/build/commands/promocodes/create.d.ts +0 -39
- package/build/commands/promocodes/create.js +0 -18
- package/build/commands/promocodes/endpoints.d.ts +0 -353
- package/build/commands/promocodes/endpoints.js +0 -46
- package/build/commands/promocodes/enums.d.ts +0 -5
- package/build/commands/promocodes/enums.js +0 -9
- package/build/commands/promocodes/index.d.ts +0 -5
- package/build/commands/promocodes/index.js +0 -21
- package/build/commands/promocodes/read.d.ts +0 -45
- package/build/commands/promocodes/read.js +0 -23
- package/build/commands/promocodes/update.d.ts +0 -33
- package/build/commands/promocodes/update.js +0 -16
- package/build/commands/refresh-sessions/create.d.ts +0 -24
- package/build/commands/refresh-sessions/create.js +0 -13
- package/build/commands/refresh-sessions/enums.d.ts +0 -3
- package/build/commands/refresh-sessions/enums.js +0 -8
- package/build/commands/refresh-sessions/index.d.ts +0 -4
- package/build/commands/refresh-sessions/index.js +0 -20
- package/build/commands/refresh-sessions/read.d.ts +0 -27
- package/build/commands/refresh-sessions/read.js +0 -17
- package/build/commands/refresh-sessions/update.d.ts +0 -24
- package/build/commands/refresh-sessions/update.js +0 -16
- package/build/commands/settings/endpoints.d.ts +0 -108
- package/build/commands/settings/endpoints.js +0 -43
- package/build/commands/settings/index.d.ts +0 -3
- package/build/commands/settings/index.js +0 -19
- package/build/commands/settings/read.d.ts +0 -18
- package/build/commands/settings/read.js +0 -10
- package/build/commands/settings/update.d.ts +0 -18
- package/build/commands/settings/update.js +0 -10
- package/build/commands/stats/endpoints.d.ts +0 -67
- package/build/commands/stats/endpoints.js +0 -13
- package/build/commands/stats/index.d.ts +0 -3
- package/build/commands/stats/index.js +0 -19
- package/build/commands/stats/query.d.ts +0 -31
- package/build/commands/stats/query.js +0 -15
- package/build/commands/stats/read.d.ts +0 -30
- package/build/commands/stats/read.js +0 -17
- package/build/commands/users/create.d.ts +0 -42
- package/build/commands/users/create.js +0 -19
- package/build/commands/users/endpoints.d.ts +0 -403
- package/build/commands/users/endpoints.js +0 -39
- package/build/commands/users/enums.d.ts +0 -6
- package/build/commands/users/enums.js +0 -10
- package/build/commands/users/index.d.ts +0 -6
- package/build/commands/users/index.js +0 -22
- package/build/commands/users/query.d.ts +0 -52
- package/build/commands/users/query.js +0 -21
- package/build/commands/users/read.d.ts +0 -60
- package/build/commands/users/read.js +0 -28
- package/build/commands/users/update.d.ts +0 -42
- package/build/commands/users/update.js +0 -19
- package/build/types.d.ts +0 -8
- package/commands/api-response.ts +0 -10
- package/commands/auth/confirm.ts +0 -10
- package/commands/auth/endpoints.ts +0 -51
- package/commands/auth/index.ts +0 -5
- package/commands/auth/login.ts +0 -13
- package/commands/auth/profile.ts +0 -10
- package/commands/auth/register.ts +0 -8
- package/commands/auth/reset.ts +0 -9
- package/commands/consts.ts +0 -1
- package/commands/index.ts +0 -13
- package/commands/orders/create.ts +0 -41
- package/commands/orders/endpoints.ts +0 -51
- package/commands/orders/enums.ts +0 -25
- package/commands/orders/index.ts +0 -6
- package/commands/orders/query.ts +0 -46
- package/commands/orders/read.ts +0 -83
- package/commands/orders/update.ts +0 -16
- package/commands/pagination.ts +0 -8
- package/commands/payment-methods/create.ts +0 -19
- package/commands/payment-methods/endpoints.ts +0 -67
- package/commands/payment-methods/index.ts +0 -4
- package/commands/payment-methods/read.ts +0 -30
- package/commands/payment-methods/update.ts +0 -19
- package/commands/products/create.ts +0 -134
- package/commands/products/endpoints.ts +0 -108
- package/commands/products/enums.ts +0 -33
- package/commands/products/index.ts +0 -6
- package/commands/products/query.ts +0 -52
- package/commands/products/read.ts +0 -268
- package/commands/products/update.ts +0 -11
- package/commands/promocode-activations/create.ts +0 -10
- package/commands/promocode-activations/index.ts +0 -3
- package/commands/promocode-activations/read.ts +0 -11
- package/commands/promocode-activations/update.ts +0 -10
- package/commands/promocodes/create.ts +0 -18
- package/commands/promocodes/endpoints.ts +0 -62
- package/commands/promocodes/enums.ts +0 -9
- package/commands/promocodes/index.ts +0 -5
- package/commands/promocodes/read.ts +0 -20
- package/commands/promocodes/update.ts +0 -16
- package/commands/refresh-sessions/create.ts +0 -13
- package/commands/refresh-sessions/enums.ts +0 -4
- package/commands/refresh-sessions/index.ts +0 -4
- package/commands/refresh-sessions/read.ts +0 -14
- package/commands/refresh-sessions/update.ts +0 -13
- package/commands/settings/endpoints.ts +0 -52
- package/commands/settings/index.ts +0 -3
- package/commands/settings/read.ts +0 -10
- package/commands/settings/update.ts +0 -10
- package/commands/stats/endpoints.ts +0 -23
- package/commands/stats/index.ts +0 -3
- package/commands/stats/query.ts +0 -18
- package/commands/stats/read.ts +0 -14
- package/commands/users/create.ts +0 -19
- package/commands/users/endpoints.ts +0 -47
- package/commands/users/enums.ts +0 -10
- package/commands/users/index.ts +0 -6
- package/commands/users/query.ts +0 -20
- package/commands/users/read.ts +0 -25
- package/commands/users/update.ts +0 -19
- package/index.ts +0 -1
- package/tsconfig.json +0 -111
- package/types.ts +0 -9
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.PaymentMethodReadResponseSchema = exports.CourseReadResponseSchema = void 0;
|
|
4
|
-
const zod_1 = require("zod");
|
|
5
|
-
exports.CourseReadResponseSchema = zod_1.z.object({
|
|
6
|
-
USD_RUB: zod_1.z.string(),
|
|
7
|
-
RUB_KZT: zod_1.z.string(),
|
|
8
|
-
USD_KZT: zod_1.z.string(),
|
|
9
|
-
KZT_RUB: zod_1.z.string(),
|
|
10
|
-
});
|
|
11
|
-
exports.PaymentMethodReadResponseSchema = zod_1.z.object({
|
|
12
|
-
id: zod_1.z.coerce.number().positive(),
|
|
13
|
-
name: zod_1.z.string(),
|
|
14
|
-
image: zod_1.z.string(),
|
|
15
|
-
key: zod_1.z.string(),
|
|
16
|
-
uniqueKey: zod_1.z.string(),
|
|
17
|
-
isActive: zod_1.z.boolean(),
|
|
18
|
-
type: zod_1.z.string(),
|
|
19
|
-
maxAmount: zod_1.z.coerce.number().nonnegative(),
|
|
20
|
-
minAmount: zod_1.z.coerce.number().nonnegative(),
|
|
21
|
-
comission: zod_1.z.coerce.number().nonnegative(),
|
|
22
|
-
secretComission: zod_1.z.coerce.number().nonnegative().optional(),
|
|
23
|
-
serviceComission: zod_1.z.coerce.number().nonnegative(),
|
|
24
|
-
cryptoToken: zod_1.z.string().nullable(),
|
|
25
|
-
cryptoNetwork: zod_1.z.string().nullable(),
|
|
26
|
-
updatedAt: zod_1.z.coerce.date(),
|
|
27
|
-
createdAt: zod_1.z.coerce.date(),
|
|
28
|
-
});
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { z } from "zod";
|
|
2
|
-
export declare const PaymentMethodUpdateRequestSchema: z.ZodObject<{
|
|
3
|
-
name: z.ZodOptional<z.ZodString>;
|
|
4
|
-
image: z.ZodOptional<z.ZodString>;
|
|
5
|
-
key: z.ZodOptional<z.ZodString>;
|
|
6
|
-
uniqueKey: z.ZodOptional<z.ZodString>;
|
|
7
|
-
isActive: z.ZodOptional<z.ZodBoolean>;
|
|
8
|
-
type: z.ZodOptional<z.ZodString>;
|
|
9
|
-
maxAmount: z.ZodOptional<z.ZodNumber>;
|
|
10
|
-
minAmount: z.ZodOptional<z.ZodNumber>;
|
|
11
|
-
comission: z.ZodOptional<z.ZodNumber>;
|
|
12
|
-
secretComission: z.ZodOptional<z.ZodNumber>;
|
|
13
|
-
serviceComission: z.ZodOptional<z.ZodNumber>;
|
|
14
|
-
cryptoToken: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
15
|
-
cryptoTokenSecret: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
16
|
-
}, "strip", z.ZodTypeAny, {
|
|
17
|
-
type?: string | undefined;
|
|
18
|
-
name?: string | undefined;
|
|
19
|
-
image?: string | undefined;
|
|
20
|
-
key?: string | undefined;
|
|
21
|
-
uniqueKey?: string | undefined;
|
|
22
|
-
isActive?: boolean | undefined;
|
|
23
|
-
maxAmount?: number | undefined;
|
|
24
|
-
minAmount?: number | undefined;
|
|
25
|
-
comission?: number | undefined;
|
|
26
|
-
secretComission?: number | undefined;
|
|
27
|
-
serviceComission?: number | undefined;
|
|
28
|
-
cryptoToken?: string | null | undefined;
|
|
29
|
-
cryptoTokenSecret?: string | null | undefined;
|
|
30
|
-
}, {
|
|
31
|
-
type?: string | undefined;
|
|
32
|
-
name?: string | undefined;
|
|
33
|
-
image?: string | undefined;
|
|
34
|
-
key?: string | undefined;
|
|
35
|
-
uniqueKey?: string | undefined;
|
|
36
|
-
isActive?: boolean | undefined;
|
|
37
|
-
maxAmount?: number | undefined;
|
|
38
|
-
minAmount?: number | undefined;
|
|
39
|
-
comission?: number | undefined;
|
|
40
|
-
secretComission?: number | undefined;
|
|
41
|
-
serviceComission?: number | undefined;
|
|
42
|
-
cryptoToken?: string | null | undefined;
|
|
43
|
-
cryptoTokenSecret?: string | null | undefined;
|
|
44
|
-
}>;
|
|
45
|
-
export type PaymentMethodUpdateRequest = z.infer<typeof PaymentMethodUpdateRequestSchema>;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.PaymentMethodUpdateRequestSchema = void 0;
|
|
4
|
-
const zod_1 = require("zod");
|
|
5
|
-
exports.PaymentMethodUpdateRequestSchema = zod_1.z.object({
|
|
6
|
-
name: zod_1.z.string().optional(),
|
|
7
|
-
image: zod_1.z.string().optional(),
|
|
8
|
-
key: zod_1.z.string().optional(),
|
|
9
|
-
uniqueKey: zod_1.z.string().optional(),
|
|
10
|
-
isActive: zod_1.z.boolean().optional(),
|
|
11
|
-
type: zod_1.z.string().optional(),
|
|
12
|
-
maxAmount: zod_1.z.coerce.number().nonnegative().optional(),
|
|
13
|
-
minAmount: zod_1.z.coerce.number().nonnegative().optional(),
|
|
14
|
-
comission: zod_1.z.coerce.number().nonnegative().optional(),
|
|
15
|
-
secretComission: zod_1.z.coerce.number().nonnegative().optional(),
|
|
16
|
-
serviceComission: zod_1.z.coerce.number().nonnegative().optional(),
|
|
17
|
-
cryptoToken: zod_1.z.string().nullable().optional(),
|
|
18
|
-
cryptoTokenSecret: zod_1.z.string().nullable().optional(),
|
|
19
|
-
});
|
|
@@ -1,229 +0,0 @@
|
|
|
1
|
-
import z from "zod";
|
|
2
|
-
/** Запрос на создание продукта */
|
|
3
|
-
export declare const ProductCreateRequestSchema: z.ZodObject<{
|
|
4
|
-
/** URL-friendly идентификатор */
|
|
5
|
-
slug: z.ZodString;
|
|
6
|
-
/** Название продукта */
|
|
7
|
-
title: z.ZodString;
|
|
8
|
-
/** Оригинальное название (на языке оригинала) */
|
|
9
|
-
originalTitle: z.ZodOptional<z.ZodString>;
|
|
10
|
-
/** Тип продукта */
|
|
11
|
-
type: z.ZodEnum<["GAME_KEY", "GAME_GIFT", "TOPUP", "SUBSCRIPTION", "IN_GAME_ITEM", "DLC", "CURRENCY"]>;
|
|
12
|
-
/** ID категории */
|
|
13
|
-
categoryId: z.ZodNumber;
|
|
14
|
-
/** ID родительского продукта (для DLC) */
|
|
15
|
-
parentProductId: z.ZodOptional<z.ZodNumber>;
|
|
16
|
-
/** Полное описание */
|
|
17
|
-
description: z.ZodOptional<z.ZodString>;
|
|
18
|
-
/** Кастомное описание */
|
|
19
|
-
customDescription: z.ZodOptional<z.ZodString>;
|
|
20
|
-
/** Краткое описание */
|
|
21
|
-
shortDescription: z.ZodOptional<z.ZodString>;
|
|
22
|
-
/** URL обложки */
|
|
23
|
-
coverImageUrl: z.ZodOptional<z.ZodString>;
|
|
24
|
-
/** Разработчик */
|
|
25
|
-
developer: z.ZodOptional<z.ZodString>;
|
|
26
|
-
/** Издатель */
|
|
27
|
-
publisher: z.ZodOptional<z.ZodString>;
|
|
28
|
-
/** Дата выхода (ISO datetime) */
|
|
29
|
-
releaseDate: z.ZodOptional<z.ZodString>;
|
|
30
|
-
/** Steam App ID */
|
|
31
|
-
steamAppId: z.ZodOptional<z.ZodNumber>;
|
|
32
|
-
/** Мультиплеер */
|
|
33
|
-
hasMultiplayer: z.ZodDefault<z.ZodBoolean>;
|
|
34
|
-
/** Кооператив */
|
|
35
|
-
hasCoop: z.ZodDefault<z.ZodBoolean>;
|
|
36
|
-
/** Одиночная игра */
|
|
37
|
-
hasSinglePlayer: z.ZodDefault<z.ZodBoolean>;
|
|
38
|
-
/** SEO: заголовок */
|
|
39
|
-
metaTitle: z.ZodOptional<z.ZodString>;
|
|
40
|
-
/** SEO: описание */
|
|
41
|
-
metaDescription: z.ZodOptional<z.ZodString>;
|
|
42
|
-
/** ID жанров для привязки */
|
|
43
|
-
genreIds: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
|
|
44
|
-
/** ID тегов для привязки */
|
|
45
|
-
tagIds: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
|
|
46
|
-
/** ID регионов для привязки */
|
|
47
|
-
regionIds: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
|
|
48
|
-
}, "strip", z.ZodTypeAny, {
|
|
49
|
-
type: "GAME_KEY" | "GAME_GIFT" | "TOPUP" | "SUBSCRIPTION" | "IN_GAME_ITEM" | "DLC" | "CURRENCY";
|
|
50
|
-
slug: string;
|
|
51
|
-
title: string;
|
|
52
|
-
categoryId: number;
|
|
53
|
-
hasMultiplayer: boolean;
|
|
54
|
-
hasCoop: boolean;
|
|
55
|
-
hasSinglePlayer: boolean;
|
|
56
|
-
originalTitle?: string | undefined;
|
|
57
|
-
parentProductId?: number | undefined;
|
|
58
|
-
description?: string | undefined;
|
|
59
|
-
customDescription?: string | undefined;
|
|
60
|
-
shortDescription?: string | undefined;
|
|
61
|
-
coverImageUrl?: string | undefined;
|
|
62
|
-
developer?: string | undefined;
|
|
63
|
-
publisher?: string | undefined;
|
|
64
|
-
releaseDate?: string | undefined;
|
|
65
|
-
steamAppId?: number | undefined;
|
|
66
|
-
metaTitle?: string | undefined;
|
|
67
|
-
metaDescription?: string | undefined;
|
|
68
|
-
genreIds?: number[] | undefined;
|
|
69
|
-
tagIds?: number[] | undefined;
|
|
70
|
-
regionIds?: number[] | undefined;
|
|
71
|
-
}, {
|
|
72
|
-
type: "GAME_KEY" | "GAME_GIFT" | "TOPUP" | "SUBSCRIPTION" | "IN_GAME_ITEM" | "DLC" | "CURRENCY";
|
|
73
|
-
slug: string;
|
|
74
|
-
title: string;
|
|
75
|
-
categoryId: number;
|
|
76
|
-
originalTitle?: string | undefined;
|
|
77
|
-
parentProductId?: number | undefined;
|
|
78
|
-
description?: string | undefined;
|
|
79
|
-
customDescription?: string | undefined;
|
|
80
|
-
shortDescription?: string | undefined;
|
|
81
|
-
coverImageUrl?: string | undefined;
|
|
82
|
-
developer?: string | undefined;
|
|
83
|
-
publisher?: string | undefined;
|
|
84
|
-
releaseDate?: string | undefined;
|
|
85
|
-
steamAppId?: number | undefined;
|
|
86
|
-
hasMultiplayer?: boolean | undefined;
|
|
87
|
-
hasCoop?: boolean | undefined;
|
|
88
|
-
hasSinglePlayer?: boolean | undefined;
|
|
89
|
-
metaTitle?: string | undefined;
|
|
90
|
-
metaDescription?: string | undefined;
|
|
91
|
-
genreIds?: number[] | undefined;
|
|
92
|
-
tagIds?: number[] | undefined;
|
|
93
|
-
regionIds?: number[] | undefined;
|
|
94
|
-
}>;
|
|
95
|
-
export type ProductCreateRequest = z.infer<typeof ProductCreateRequestSchema>;
|
|
96
|
-
/** Запрос на создание варианта продукта */
|
|
97
|
-
export declare const VariantCreateRequestSchema: z.ZodObject<{
|
|
98
|
-
/** Название варианта */
|
|
99
|
-
name: z.ZodString;
|
|
100
|
-
/** Артикул */
|
|
101
|
-
sku: z.ZodString;
|
|
102
|
-
/** Цена */
|
|
103
|
-
price: z.ZodNumber;
|
|
104
|
-
/** Цена до скидки */
|
|
105
|
-
originalPrice: z.ZodOptional<z.ZodNumber>;
|
|
106
|
-
/** Себестоимость */
|
|
107
|
-
costPrice: z.ZodOptional<z.ZodNumber>;
|
|
108
|
-
/** Сумма пополнения (для TOPUP) */
|
|
109
|
-
topupAmount: z.ZodOptional<z.ZodNumber>;
|
|
110
|
-
/** Валюта */
|
|
111
|
-
currency: z.ZodOptional<z.ZodString>;
|
|
112
|
-
/** Длительность подписки (дни) */
|
|
113
|
-
durationDays: z.ZodOptional<z.ZodNumber>;
|
|
114
|
-
/** Платформа (Steam, Epic Games, ...) */
|
|
115
|
-
platform: z.ZodOptional<z.ZodString>;
|
|
116
|
-
/** Код региона */
|
|
117
|
-
regionCode: z.ZodOptional<z.ZodString>;
|
|
118
|
-
/** Тип доставки */
|
|
119
|
-
deliveryType: z.ZodDefault<z.ZodEnum<["AUTOMATIC", "MANUAL", "BOT"]>>;
|
|
120
|
-
}, "strip", z.ZodTypeAny, {
|
|
121
|
-
price: number;
|
|
122
|
-
name: string;
|
|
123
|
-
sku: string;
|
|
124
|
-
deliveryType: "AUTOMATIC" | "MANUAL" | "BOT";
|
|
125
|
-
originalPrice?: number | undefined;
|
|
126
|
-
costPrice?: number | undefined;
|
|
127
|
-
topupAmount?: number | undefined;
|
|
128
|
-
currency?: string | undefined;
|
|
129
|
-
durationDays?: number | undefined;
|
|
130
|
-
platform?: string | undefined;
|
|
131
|
-
regionCode?: string | undefined;
|
|
132
|
-
}, {
|
|
133
|
-
price: number;
|
|
134
|
-
name: string;
|
|
135
|
-
sku: string;
|
|
136
|
-
originalPrice?: number | undefined;
|
|
137
|
-
costPrice?: number | undefined;
|
|
138
|
-
topupAmount?: number | undefined;
|
|
139
|
-
currency?: string | undefined;
|
|
140
|
-
durationDays?: number | undefined;
|
|
141
|
-
platform?: string | undefined;
|
|
142
|
-
regionCode?: string | undefined;
|
|
143
|
-
deliveryType?: "AUTOMATIC" | "MANUAL" | "BOT" | undefined;
|
|
144
|
-
}>;
|
|
145
|
-
export type VariantCreateRequest = z.infer<typeof VariantCreateRequestSchema>;
|
|
146
|
-
/** Запрос на импорт ключей */
|
|
147
|
-
export declare const KeysImportRequestSchema: z.ZodObject<{
|
|
148
|
-
/** Массив ключей для импорта */
|
|
149
|
-
keys: z.ZodArray<z.ZodString, "many">;
|
|
150
|
-
}, "strip", z.ZodTypeAny, {
|
|
151
|
-
keys: string[];
|
|
152
|
-
}, {
|
|
153
|
-
keys: string[];
|
|
154
|
-
}>;
|
|
155
|
-
export type KeysImportRequest = z.infer<typeof KeysImportRequestSchema>;
|
|
156
|
-
/** Ответ на импорт ключей */
|
|
157
|
-
export declare const KeysImportResponseSchema: z.ZodObject<{
|
|
158
|
-
/** Количество импортированных ключей */
|
|
159
|
-
imported: z.ZodNumber;
|
|
160
|
-
}, "strip", z.ZodTypeAny, {
|
|
161
|
-
imported: number;
|
|
162
|
-
}, {
|
|
163
|
-
imported: number;
|
|
164
|
-
}>;
|
|
165
|
-
export type KeysImportResponse = z.infer<typeof KeysImportResponseSchema>;
|
|
166
|
-
/** Запрос на добавление медиа */
|
|
167
|
-
export declare const MediaCreateRequestSchema: z.ZodObject<{
|
|
168
|
-
/** Тип медиа */
|
|
169
|
-
type: z.ZodEnum<["SCREENSHOT", "SLIDER", "VIDEO", "TRAILER"]>;
|
|
170
|
-
/** URL медиа */
|
|
171
|
-
url: z.ZodString;
|
|
172
|
-
/** Alt-текст */
|
|
173
|
-
alt: z.ZodOptional<z.ZodString>;
|
|
174
|
-
/** Порядок сортировки */
|
|
175
|
-
sortOrder: z.ZodDefault<z.ZodNumber>;
|
|
176
|
-
}, "strip", z.ZodTypeAny, {
|
|
177
|
-
type: "SCREENSHOT" | "SLIDER" | "VIDEO" | "TRAILER";
|
|
178
|
-
url: string;
|
|
179
|
-
sortOrder: number;
|
|
180
|
-
alt?: string | undefined;
|
|
181
|
-
}, {
|
|
182
|
-
type: "SCREENSHOT" | "SLIDER" | "VIDEO" | "TRAILER";
|
|
183
|
-
url: string;
|
|
184
|
-
alt?: string | undefined;
|
|
185
|
-
sortOrder?: number | undefined;
|
|
186
|
-
}>;
|
|
187
|
-
export type MediaCreateRequest = z.infer<typeof MediaCreateRequestSchema>;
|
|
188
|
-
/** Запрос на upsert системных требований */
|
|
189
|
-
export declare const SystemRequirementsRequestSchema: z.ZodObject<{
|
|
190
|
-
/** Тип: минимальные / рекомендуемые */
|
|
191
|
-
type: z.ZodEnum<["minimum", "recommended"]>;
|
|
192
|
-
/** Операционная система */
|
|
193
|
-
os: z.ZodOptional<z.ZodString>;
|
|
194
|
-
/** Процессор */
|
|
195
|
-
processor: z.ZodOptional<z.ZodString>;
|
|
196
|
-
/** Оперативная память */
|
|
197
|
-
memory: z.ZodOptional<z.ZodString>;
|
|
198
|
-
/** Видеокарта */
|
|
199
|
-
graphics: z.ZodOptional<z.ZodString>;
|
|
200
|
-
/** Место на диске */
|
|
201
|
-
storage: z.ZodOptional<z.ZodString>;
|
|
202
|
-
/** DirectX */
|
|
203
|
-
directx: z.ZodOptional<z.ZodString>;
|
|
204
|
-
/** Сеть */
|
|
205
|
-
network: z.ZodOptional<z.ZodString>;
|
|
206
|
-
/** Дополнительно */
|
|
207
|
-
additional: z.ZodOptional<z.ZodString>;
|
|
208
|
-
}, "strip", z.ZodTypeAny, {
|
|
209
|
-
type: "minimum" | "recommended";
|
|
210
|
-
os?: string | undefined;
|
|
211
|
-
processor?: string | undefined;
|
|
212
|
-
memory?: string | undefined;
|
|
213
|
-
graphics?: string | undefined;
|
|
214
|
-
storage?: string | undefined;
|
|
215
|
-
directx?: string | undefined;
|
|
216
|
-
network?: string | undefined;
|
|
217
|
-
additional?: string | undefined;
|
|
218
|
-
}, {
|
|
219
|
-
type: "minimum" | "recommended";
|
|
220
|
-
os?: string | undefined;
|
|
221
|
-
processor?: string | undefined;
|
|
222
|
-
memory?: string | undefined;
|
|
223
|
-
graphics?: string | undefined;
|
|
224
|
-
storage?: string | undefined;
|
|
225
|
-
directx?: string | undefined;
|
|
226
|
-
network?: string | undefined;
|
|
227
|
-
additional?: string | undefined;
|
|
228
|
-
}>;
|
|
229
|
-
export type SystemRequirementsRequest = z.infer<typeof SystemRequirementsRequestSchema>;
|
|
@@ -1,122 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.SystemRequirementsRequestSchema = exports.MediaCreateRequestSchema = exports.KeysImportResponseSchema = exports.KeysImportRequestSchema = exports.VariantCreateRequestSchema = exports.ProductCreateRequestSchema = void 0;
|
|
7
|
-
const zod_1 = __importDefault(require("zod"));
|
|
8
|
-
const enums_1 = require("./enums");
|
|
9
|
-
/** Запрос на создание продукта */
|
|
10
|
-
exports.ProductCreateRequestSchema = zod_1.default.object({
|
|
11
|
-
/** URL-friendly идентификатор */
|
|
12
|
-
slug: zod_1.default.string().min(1),
|
|
13
|
-
/** Название продукта */
|
|
14
|
-
title: zod_1.default.string().min(1),
|
|
15
|
-
/** Оригинальное название (на языке оригинала) */
|
|
16
|
-
originalTitle: zod_1.default.string().optional(),
|
|
17
|
-
/** Тип продукта */
|
|
18
|
-
type: enums_1.ProductType,
|
|
19
|
-
/** ID категории */
|
|
20
|
-
categoryId: zod_1.default.number().int().positive(),
|
|
21
|
-
/** ID родительского продукта (для DLC) */
|
|
22
|
-
parentProductId: zod_1.default.number().int().positive().optional(),
|
|
23
|
-
/** Полное описание */
|
|
24
|
-
description: zod_1.default.string().optional(),
|
|
25
|
-
/** Кастомное описание */
|
|
26
|
-
customDescription: zod_1.default.string().optional(),
|
|
27
|
-
/** Краткое описание */
|
|
28
|
-
shortDescription: zod_1.default.string().optional(),
|
|
29
|
-
/** URL обложки */
|
|
30
|
-
coverImageUrl: zod_1.default.string().url().optional(),
|
|
31
|
-
/** Разработчик */
|
|
32
|
-
developer: zod_1.default.string().optional(),
|
|
33
|
-
/** Издатель */
|
|
34
|
-
publisher: zod_1.default.string().optional(),
|
|
35
|
-
/** Дата выхода (ISO datetime) */
|
|
36
|
-
releaseDate: zod_1.default.string().datetime().optional(),
|
|
37
|
-
/** Steam App ID */
|
|
38
|
-
steamAppId: zod_1.default.number().int().optional(),
|
|
39
|
-
/** Мультиплеер */
|
|
40
|
-
hasMultiplayer: zod_1.default.boolean().default(false),
|
|
41
|
-
/** Кооператив */
|
|
42
|
-
hasCoop: zod_1.default.boolean().default(false),
|
|
43
|
-
/** Одиночная игра */
|
|
44
|
-
hasSinglePlayer: zod_1.default.boolean().default(true),
|
|
45
|
-
/** SEO: заголовок */
|
|
46
|
-
metaTitle: zod_1.default.string().optional(),
|
|
47
|
-
/** SEO: описание */
|
|
48
|
-
metaDescription: zod_1.default.string().optional(),
|
|
49
|
-
/** ID жанров для привязки */
|
|
50
|
-
genreIds: zod_1.default.array(zod_1.default.number().int().positive()).optional(),
|
|
51
|
-
/** ID тегов для привязки */
|
|
52
|
-
tagIds: zod_1.default.array(zod_1.default.number().int().positive()).optional(),
|
|
53
|
-
/** ID регионов для привязки */
|
|
54
|
-
regionIds: zod_1.default.array(zod_1.default.number().int().positive()).optional(),
|
|
55
|
-
});
|
|
56
|
-
/** Запрос на создание варианта продукта */
|
|
57
|
-
exports.VariantCreateRequestSchema = zod_1.default.object({
|
|
58
|
-
/** Название варианта */
|
|
59
|
-
name: zod_1.default.string().min(1),
|
|
60
|
-
/** Артикул */
|
|
61
|
-
sku: zod_1.default.string().min(1),
|
|
62
|
-
/** Цена */
|
|
63
|
-
price: zod_1.default.number().positive(),
|
|
64
|
-
/** Цена до скидки */
|
|
65
|
-
originalPrice: zod_1.default.number().positive().optional(),
|
|
66
|
-
/** Себестоимость */
|
|
67
|
-
costPrice: zod_1.default.number().positive().optional(),
|
|
68
|
-
/** Сумма пополнения (для TOPUP) */
|
|
69
|
-
topupAmount: zod_1.default.number().positive().optional(),
|
|
70
|
-
/** Валюта */
|
|
71
|
-
currency: zod_1.default.string().optional(),
|
|
72
|
-
/** Длительность подписки (дни) */
|
|
73
|
-
durationDays: zod_1.default.number().int().positive().optional(),
|
|
74
|
-
/** Платформа (Steam, Epic Games, ...) */
|
|
75
|
-
platform: zod_1.default.string().optional(),
|
|
76
|
-
/** Код региона */
|
|
77
|
-
regionCode: zod_1.default.string().optional(),
|
|
78
|
-
/** Тип доставки */
|
|
79
|
-
deliveryType: enums_1.DeliveryType.default("AUTOMATIC"),
|
|
80
|
-
});
|
|
81
|
-
/** Запрос на импорт ключей */
|
|
82
|
-
exports.KeysImportRequestSchema = zod_1.default.object({
|
|
83
|
-
/** Массив ключей для импорта */
|
|
84
|
-
keys: zod_1.default.array(zod_1.default.string().min(1)).min(1),
|
|
85
|
-
});
|
|
86
|
-
/** Ответ на импорт ключей */
|
|
87
|
-
exports.KeysImportResponseSchema = zod_1.default.object({
|
|
88
|
-
/** Количество импортированных ключей */
|
|
89
|
-
imported: zod_1.default.number(),
|
|
90
|
-
});
|
|
91
|
-
/** Запрос на добавление медиа */
|
|
92
|
-
exports.MediaCreateRequestSchema = zod_1.default.object({
|
|
93
|
-
/** Тип медиа */
|
|
94
|
-
type: enums_1.MediaType,
|
|
95
|
-
/** URL медиа */
|
|
96
|
-
url: zod_1.default.string().url(),
|
|
97
|
-
/** Alt-текст */
|
|
98
|
-
alt: zod_1.default.string().optional(),
|
|
99
|
-
/** Порядок сортировки */
|
|
100
|
-
sortOrder: zod_1.default.number().int().default(0),
|
|
101
|
-
});
|
|
102
|
-
/** Запрос на upsert системных требований */
|
|
103
|
-
exports.SystemRequirementsRequestSchema = zod_1.default.object({
|
|
104
|
-
/** Тип: минимальные / рекомендуемые */
|
|
105
|
-
type: enums_1.SystemRequirementType,
|
|
106
|
-
/** Операционная система */
|
|
107
|
-
os: zod_1.default.string().optional(),
|
|
108
|
-
/** Процессор */
|
|
109
|
-
processor: zod_1.default.string().optional(),
|
|
110
|
-
/** Оперативная память */
|
|
111
|
-
memory: zod_1.default.string().optional(),
|
|
112
|
-
/** Видеокарта */
|
|
113
|
-
graphics: zod_1.default.string().optional(),
|
|
114
|
-
/** Место на диске */
|
|
115
|
-
storage: zod_1.default.string().optional(),
|
|
116
|
-
/** DirectX */
|
|
117
|
-
directx: zod_1.default.string().optional(),
|
|
118
|
-
/** Сеть */
|
|
119
|
-
network: zod_1.default.string().optional(),
|
|
120
|
-
/** Дополнительно */
|
|
121
|
-
additional: zod_1.default.string().optional(),
|
|
122
|
-
});
|