@gigapay-dev/contracts 1.8.6 → 2.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/client.d.ts +934 -0
- package/build/client.d.ts.map +1 -0
- package/build/client.js +184 -0
- package/build/client.js.map +1 -0
- package/build/commands/api-response.d.ts +1 -0
- package/build/commands/api-response.d.ts.map +1 -0
- package/build/commands/api-response.js +1 -0
- package/build/commands/api-response.js.map +1 -0
- package/build/commands/auth/confirm.d.ts +1 -0
- package/build/commands/auth/confirm.d.ts.map +1 -0
- package/build/commands/auth/confirm.js +1 -0
- package/build/commands/auth/confirm.js.map +1 -0
- package/build/commands/auth/endpoints.d.ts +1 -0
- package/build/commands/auth/endpoints.d.ts.map +1 -0
- package/build/commands/auth/endpoints.js +1 -0
- package/build/commands/auth/endpoints.js.map +1 -0
- package/build/commands/auth/index.d.ts +2 -0
- package/build/commands/auth/index.d.ts.map +1 -0
- package/build/commands/auth/index.js +2 -0
- package/build/commands/auth/index.js.map +1 -0
- package/build/commands/auth/login.d.ts +1 -0
- package/build/commands/auth/login.d.ts.map +1 -0
- package/build/commands/auth/login.js +1 -0
- package/build/commands/auth/login.js.map +1 -0
- package/build/commands/auth/profile.d.ts +1 -0
- package/build/commands/auth/profile.d.ts.map +1 -0
- package/build/commands/auth/profile.js +1 -0
- package/build/commands/auth/profile.js.map +1 -0
- package/build/commands/auth/register.d.ts +1 -0
- package/build/commands/auth/register.d.ts.map +1 -0
- package/build/commands/auth/register.js +1 -0
- package/build/commands/auth/register.js.map +1 -0
- package/build/commands/auth/reset.d.ts +1 -0
- package/build/commands/auth/reset.d.ts.map +1 -0
- package/build/commands/auth/reset.js +1 -0
- package/build/commands/auth/reset.js.map +1 -0
- package/build/commands/common.d.ts +65 -0
- package/build/commands/common.d.ts.map +1 -0
- package/build/commands/common.js +29 -0
- package/build/commands/common.js.map +1 -0
- package/build/commands/consts.d.ts +1 -0
- package/build/commands/consts.d.ts.map +1 -0
- package/build/commands/consts.js +1 -0
- package/build/commands/consts.js.map +1 -0
- package/build/commands/endpoints.d.ts +4643 -0
- package/build/commands/endpoints.d.ts.map +1 -0
- package/build/commands/endpoints.js +26 -0
- package/build/commands/endpoints.js.map +1 -0
- package/build/commands/index.d.ts +3 -0
- package/build/commands/index.d.ts.map +1 -0
- package/build/commands/index.js +3 -0
- package/build/commands/index.js.map +1 -0
- package/build/commands/orders/create.d.ts +5 -0
- package/build/commands/orders/create.d.ts.map +1 -0
- package/build/commands/orders/create.js +3 -0
- package/build/commands/orders/create.js.map +1 -0
- package/build/commands/orders/endpoints.d.ts +40 -24
- package/build/commands/orders/endpoints.d.ts.map +1 -0
- package/build/commands/orders/endpoints.js +1 -0
- package/build/commands/orders/endpoints.js.map +1 -0
- package/build/commands/orders/enums.d.ts +1 -0
- package/build/commands/orders/enums.d.ts.map +1 -0
- package/build/commands/orders/enums.js +1 -0
- package/build/commands/orders/enums.js.map +1 -0
- package/build/commands/orders/index.d.ts +1 -0
- package/build/commands/orders/index.d.ts.map +1 -0
- package/build/commands/orders/index.js +1 -0
- package/build/commands/orders/index.js.map +1 -0
- package/build/commands/orders/query.d.ts +7 -6
- package/build/commands/orders/query.d.ts.map +1 -0
- package/build/commands/orders/query.js +1 -0
- package/build/commands/orders/query.js.map +1 -0
- package/build/commands/orders/read.d.ts +8 -3
- package/build/commands/orders/read.d.ts.map +1 -0
- package/build/commands/orders/read.js +4 -1
- package/build/commands/orders/read.js.map +1 -0
- package/build/commands/orders/update.d.ts +1 -0
- package/build/commands/orders/update.d.ts.map +1 -0
- package/build/commands/orders/update.js +1 -0
- package/build/commands/orders/update.js.map +1 -0
- package/build/commands/pagination.d.ts +8 -7
- package/build/commands/pagination.d.ts.map +1 -0
- package/build/commands/pagination.js +5 -7
- package/build/commands/pagination.js.map +1 -0
- package/build/commands/payment-methods/create.d.ts +1 -0
- package/build/commands/payment-methods/create.d.ts.map +1 -0
- package/build/commands/payment-methods/create.js +1 -0
- package/build/commands/payment-methods/create.js.map +1 -0
- package/build/commands/payment-methods/endpoints.d.ts +1 -0
- package/build/commands/payment-methods/endpoints.d.ts.map +1 -0
- package/build/commands/payment-methods/endpoints.js +1 -0
- package/build/commands/payment-methods/endpoints.js.map +1 -0
- package/build/commands/payment-methods/index.d.ts +1 -0
- package/build/commands/payment-methods/index.d.ts.map +1 -0
- package/build/commands/payment-methods/index.js +1 -0
- package/build/commands/payment-methods/index.js.map +1 -0
- package/build/commands/payment-methods/read.d.ts +1 -0
- package/build/commands/payment-methods/read.d.ts.map +1 -0
- package/build/commands/payment-methods/read.js +1 -0
- package/build/commands/payment-methods/read.js.map +1 -0
- package/build/commands/payment-methods/update.d.ts +1 -0
- package/build/commands/payment-methods/update.d.ts.map +1 -0
- package/build/commands/payment-methods/update.js +1 -0
- package/build/commands/payment-methods/update.js.map +1 -0
- package/build/commands/products/create.d.ts +13 -0
- package/build/commands/products/create.d.ts.map +1 -0
- package/build/commands/products/create.js +7 -0
- package/build/commands/products/create.js.map +1 -0
- package/build/commands/products/endpoints.d.ts +99 -0
- package/build/commands/products/endpoints.d.ts.map +1 -0
- package/build/commands/products/endpoints.js +1 -0
- package/build/commands/products/endpoints.js.map +1 -0
- package/build/commands/products/enums.d.ts +1 -0
- package/build/commands/products/enums.d.ts.map +1 -0
- package/build/commands/products/enums.js +1 -0
- package/build/commands/products/enums.js.map +1 -0
- package/build/commands/products/index.d.ts +1 -0
- package/build/commands/products/index.d.ts.map +1 -0
- package/build/commands/products/index.js +1 -0
- package/build/commands/products/index.js.map +1 -0
- package/build/commands/products/query.d.ts +1 -0
- package/build/commands/products/query.d.ts.map +1 -0
- package/build/commands/products/query.js +1 -0
- package/build/commands/products/query.js.map +1 -0
- package/build/commands/products/read.d.ts +55 -0
- package/build/commands/products/read.d.ts.map +1 -0
- package/build/commands/products/read.js +11 -0
- package/build/commands/products/read.js.map +1 -0
- package/build/commands/products/update.d.ts +7 -0
- package/build/commands/products/update.d.ts.map +1 -0
- package/build/commands/products/update.js +1 -0
- package/build/commands/products/update.js.map +1 -0
- package/build/commands/promocode-activations/create.d.ts +1 -0
- package/build/commands/promocode-activations/create.d.ts.map +1 -0
- package/build/commands/promocode-activations/create.js +1 -0
- package/build/commands/promocode-activations/create.js.map +1 -0
- package/build/commands/promocode-activations/endpoints.d.ts +158 -0
- package/build/commands/promocode-activations/endpoints.d.ts.map +1 -0
- package/build/commands/promocode-activations/endpoints.js +39 -0
- package/build/commands/promocode-activations/endpoints.js.map +1 -0
- package/build/commands/promocode-activations/index.d.ts +2 -0
- package/build/commands/promocode-activations/index.d.ts.map +1 -0
- package/build/commands/promocode-activations/index.js +2 -0
- package/build/commands/promocode-activations/index.js.map +1 -0
- package/build/commands/promocode-activations/read.d.ts +1 -0
- package/build/commands/promocode-activations/read.d.ts.map +1 -0
- package/build/commands/promocode-activations/read.js +1 -0
- package/build/commands/promocode-activations/read.js.map +1 -0
- package/build/commands/promocode-activations/update.d.ts +1 -0
- package/build/commands/promocode-activations/update.d.ts.map +1 -0
- package/build/commands/promocode-activations/update.js +1 -0
- package/build/commands/promocode-activations/update.js.map +1 -0
- package/build/commands/promocodes/create.d.ts +1 -0
- package/build/commands/promocodes/create.d.ts.map +1 -0
- package/build/commands/promocodes/create.js +1 -0
- package/build/commands/promocodes/create.js.map +1 -0
- package/build/commands/promocodes/endpoints.d.ts +1 -0
- package/build/commands/promocodes/endpoints.d.ts.map +1 -0
- package/build/commands/promocodes/endpoints.js +1 -0
- package/build/commands/promocodes/endpoints.js.map +1 -0
- package/build/commands/promocodes/enums.d.ts +1 -0
- package/build/commands/promocodes/enums.d.ts.map +1 -0
- package/build/commands/promocodes/enums.js +1 -0
- package/build/commands/promocodes/enums.js.map +1 -0
- package/build/commands/promocodes/index.d.ts +1 -0
- package/build/commands/promocodes/index.d.ts.map +1 -0
- package/build/commands/promocodes/index.js +1 -0
- package/build/commands/promocodes/index.js.map +1 -0
- package/build/commands/promocodes/read.d.ts +1 -0
- package/build/commands/promocodes/read.d.ts.map +1 -0
- package/build/commands/promocodes/read.js +1 -0
- package/build/commands/promocodes/read.js.map +1 -0
- package/build/commands/promocodes/update.d.ts +1 -0
- package/build/commands/promocodes/update.d.ts.map +1 -0
- package/build/commands/promocodes/update.js +1 -0
- package/build/commands/promocodes/update.js.map +1 -0
- package/build/commands/refresh-sessions/create.d.ts +1 -0
- package/build/commands/refresh-sessions/create.d.ts.map +1 -0
- package/build/commands/refresh-sessions/create.js +1 -0
- package/build/commands/refresh-sessions/create.js.map +1 -0
- package/build/commands/refresh-sessions/endpoints.d.ts +216 -0
- package/build/commands/refresh-sessions/endpoints.d.ts.map +1 -0
- package/build/commands/refresh-sessions/endpoints.js +47 -0
- package/build/commands/refresh-sessions/endpoints.js.map +1 -0
- package/build/commands/refresh-sessions/enums.d.ts +1 -0
- package/build/commands/refresh-sessions/enums.d.ts.map +1 -0
- package/build/commands/refresh-sessions/enums.js +1 -0
- package/build/commands/refresh-sessions/enums.js.map +1 -0
- package/build/commands/refresh-sessions/index.d.ts +2 -0
- package/build/commands/refresh-sessions/index.d.ts.map +1 -0
- package/build/commands/refresh-sessions/index.js +2 -0
- package/build/commands/refresh-sessions/index.js.map +1 -0
- package/build/commands/refresh-sessions/read.d.ts +1 -0
- package/build/commands/refresh-sessions/read.d.ts.map +1 -0
- package/build/commands/refresh-sessions/read.js +1 -0
- package/build/commands/refresh-sessions/read.js.map +1 -0
- package/build/commands/refresh-sessions/update.d.ts +1 -0
- package/build/commands/refresh-sessions/update.d.ts.map +1 -0
- package/build/commands/refresh-sessions/update.js +1 -0
- package/build/commands/refresh-sessions/update.js.map +1 -0
- package/build/commands/settings/endpoints.d.ts +1 -0
- package/build/commands/settings/endpoints.d.ts.map +1 -0
- package/build/commands/settings/endpoints.js +1 -0
- package/build/commands/settings/endpoints.js.map +1 -0
- package/build/commands/settings/index.d.ts +1 -0
- package/build/commands/settings/index.d.ts.map +1 -0
- package/build/commands/settings/index.js +1 -0
- package/build/commands/settings/index.js.map +1 -0
- package/build/commands/settings/read.d.ts +1 -0
- package/build/commands/settings/read.d.ts.map +1 -0
- package/build/commands/settings/read.js +1 -0
- package/build/commands/settings/read.js.map +1 -0
- package/build/commands/settings/update.d.ts +1 -0
- package/build/commands/settings/update.d.ts.map +1 -0
- package/build/commands/settings/update.js +1 -0
- package/build/commands/settings/update.js.map +1 -0
- package/build/commands/stats/endpoints.d.ts +1 -0
- package/build/commands/stats/endpoints.d.ts.map +1 -0
- package/build/commands/stats/endpoints.js +1 -0
- package/build/commands/stats/endpoints.js.map +1 -0
- package/build/commands/stats/index.d.ts +1 -0
- package/build/commands/stats/index.d.ts.map +1 -0
- package/build/commands/stats/index.js +1 -0
- package/build/commands/stats/index.js.map +1 -0
- package/build/commands/stats/query.d.ts +1 -0
- package/build/commands/stats/query.d.ts.map +1 -0
- package/build/commands/stats/query.js +1 -0
- package/build/commands/stats/query.js.map +1 -0
- package/build/commands/stats/read.d.ts +1 -0
- package/build/commands/stats/read.d.ts.map +1 -0
- package/build/commands/stats/read.js +1 -0
- package/build/commands/stats/read.js.map +1 -0
- package/build/commands/users/create.d.ts +1 -0
- package/build/commands/users/create.d.ts.map +1 -0
- package/build/commands/users/create.js +1 -0
- package/build/commands/users/create.js.map +1 -0
- package/build/commands/users/endpoints.d.ts +7 -6
- package/build/commands/users/endpoints.d.ts.map +1 -0
- package/build/commands/users/endpoints.js +1 -0
- package/build/commands/users/endpoints.js.map +1 -0
- package/build/commands/users/enums.d.ts +1 -0
- package/build/commands/users/enums.d.ts.map +1 -0
- package/build/commands/users/enums.js +1 -0
- package/build/commands/users/enums.js.map +1 -0
- package/build/commands/users/index.d.ts +1 -0
- package/build/commands/users/index.d.ts.map +1 -0
- package/build/commands/users/index.js +1 -0
- package/build/commands/users/index.js.map +1 -0
- package/build/commands/users/query.d.ts +7 -6
- package/build/commands/users/query.d.ts.map +1 -0
- package/build/commands/users/query.js +1 -0
- package/build/commands/users/query.js.map +1 -0
- package/build/commands/users/read.d.ts +1 -0
- package/build/commands/users/read.d.ts.map +1 -0
- package/build/commands/users/read.js +1 -0
- package/build/commands/users/read.js.map +1 -0
- package/build/commands/users/update.d.ts +1 -0
- package/build/commands/users/update.d.ts.map +1 -0
- package/build/commands/users/update.js +1 -0
- package/build/commands/users/update.js.map +1 -0
- package/build/index.d.ts +1 -0
- package/build/index.d.ts.map +1 -0
- package/build/index.js +1 -0
- package/build/index.js.map +1 -0
- package/build/types.d.ts +1 -0
- package/build/types.d.ts.map +1 -0
- package/build/types.js +1 -0
- package/build/types.js.map +1 -0
- package/package.json +48 -17
- 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
|
@@ -0,0 +1,934 @@
|
|
|
1
|
+
import { GetEndpointRequest } from "./commands/endpoints";
|
|
2
|
+
type Interceptor = (config: RequestInit) => RequestInit | Promise<RequestInit>;
|
|
3
|
+
type ResponseInterceptor = (response: Response) => Response | Promise<Response>;
|
|
4
|
+
interface ApiClientConfig {
|
|
5
|
+
baseUrl: string;
|
|
6
|
+
interceptors?: Interceptor[];
|
|
7
|
+
responseInterceptors?: ResponseInterceptor[];
|
|
8
|
+
}
|
|
9
|
+
export declare class ApiError extends Error {
|
|
10
|
+
status: number;
|
|
11
|
+
body: unknown;
|
|
12
|
+
constructor(status: number, body: unknown);
|
|
13
|
+
}
|
|
14
|
+
export declare class ApiClient {
|
|
15
|
+
private baseUrl;
|
|
16
|
+
private interceptors;
|
|
17
|
+
private responseInterceptors;
|
|
18
|
+
constructor(config: ApiClientConfig);
|
|
19
|
+
addInterceptor(interceptor: Interceptor): void;
|
|
20
|
+
addResponseInterceptor(interceptor: ResponseInterceptor): void;
|
|
21
|
+
private request;
|
|
22
|
+
auth: {
|
|
23
|
+
login: (data: GetEndpointRequest<"auth", "login">) => Promise<{
|
|
24
|
+
accessToken: string;
|
|
25
|
+
}>;
|
|
26
|
+
register: (data: GetEndpointRequest<"auth", "register">) => Promise<{
|
|
27
|
+
accessToken: string;
|
|
28
|
+
}>;
|
|
29
|
+
refresh: () => Promise<{
|
|
30
|
+
accessToken: string;
|
|
31
|
+
}>;
|
|
32
|
+
reset: (data: GetEndpointRequest<"auth", "reset">) => Promise<void>;
|
|
33
|
+
confirm: (params: GetEndpointRequest<"auth", "confirm">) => Promise<{
|
|
34
|
+
accessToken: string;
|
|
35
|
+
}>;
|
|
36
|
+
profile: () => Promise<{
|
|
37
|
+
email: string;
|
|
38
|
+
id: number;
|
|
39
|
+
username: string;
|
|
40
|
+
avatar: string | null;
|
|
41
|
+
}>;
|
|
42
|
+
};
|
|
43
|
+
users: {
|
|
44
|
+
create: (data: GetEndpointRequest<"users", "create">) => Promise<{
|
|
45
|
+
email: string | null;
|
|
46
|
+
password: string | null;
|
|
47
|
+
status: "ACTIVE" | "BLOCKED";
|
|
48
|
+
id: number;
|
|
49
|
+
username: string | null;
|
|
50
|
+
telegramId: string | null;
|
|
51
|
+
picture: string | null;
|
|
52
|
+
steamId: string | null;
|
|
53
|
+
vkId: string | null;
|
|
54
|
+
googleId: string | null;
|
|
55
|
+
isConfirmEmail: boolean;
|
|
56
|
+
role: "USER" | "ADMIN" | "NO_AUTH";
|
|
57
|
+
isOnline: boolean;
|
|
58
|
+
createdAt?: Date | null | undefined;
|
|
59
|
+
updatedAt?: Date | null | undefined;
|
|
60
|
+
blockedAt?: Date | null | undefined;
|
|
61
|
+
ordersCount?: number | undefined;
|
|
62
|
+
ordersAmount?: number | undefined;
|
|
63
|
+
}>;
|
|
64
|
+
list: (params?: GetEndpointRequest<"users", "list">) => Promise<{
|
|
65
|
+
email: string | null;
|
|
66
|
+
password: string | null;
|
|
67
|
+
status: "ACTIVE" | "BLOCKED";
|
|
68
|
+
id: number;
|
|
69
|
+
username: string | null;
|
|
70
|
+
telegramId: string | null;
|
|
71
|
+
picture: string | null;
|
|
72
|
+
steamId: string | null;
|
|
73
|
+
vkId: string | null;
|
|
74
|
+
googleId: string | null;
|
|
75
|
+
isConfirmEmail: boolean;
|
|
76
|
+
role: "USER" | "ADMIN" | "NO_AUTH";
|
|
77
|
+
isOnline: boolean;
|
|
78
|
+
createdAt?: Date | null | undefined;
|
|
79
|
+
updatedAt?: Date | null | undefined;
|
|
80
|
+
blockedAt?: Date | null | undefined;
|
|
81
|
+
ordersCount?: number | undefined;
|
|
82
|
+
ordersAmount?: number | undefined;
|
|
83
|
+
}[]>;
|
|
84
|
+
getById: (params: GetEndpointRequest<"users", "getById">) => Promise<{
|
|
85
|
+
email: string | null;
|
|
86
|
+
password: string | null;
|
|
87
|
+
status: "ACTIVE" | "BLOCKED";
|
|
88
|
+
id: number;
|
|
89
|
+
username: string | null;
|
|
90
|
+
telegramId: string | null;
|
|
91
|
+
picture: string | null;
|
|
92
|
+
steamId: string | null;
|
|
93
|
+
vkId: string | null;
|
|
94
|
+
googleId: string | null;
|
|
95
|
+
isConfirmEmail: boolean;
|
|
96
|
+
role: "USER" | "ADMIN" | "NO_AUTH";
|
|
97
|
+
isOnline: boolean;
|
|
98
|
+
createdAt?: Date | null | undefined;
|
|
99
|
+
updatedAt?: Date | null | undefined;
|
|
100
|
+
blockedAt?: Date | null | undefined;
|
|
101
|
+
ordersCount?: number | undefined;
|
|
102
|
+
ordersAmount?: number | undefined;
|
|
103
|
+
}>;
|
|
104
|
+
update: (params: GetEndpointRequest<"users", "update">) => Promise<{
|
|
105
|
+
email: string | null;
|
|
106
|
+
password: string | null;
|
|
107
|
+
status: "ACTIVE" | "BLOCKED";
|
|
108
|
+
id: number;
|
|
109
|
+
username: string | null;
|
|
110
|
+
telegramId: string | null;
|
|
111
|
+
picture: string | null;
|
|
112
|
+
steamId: string | null;
|
|
113
|
+
vkId: string | null;
|
|
114
|
+
googleId: string | null;
|
|
115
|
+
isConfirmEmail: boolean;
|
|
116
|
+
role: "USER" | "ADMIN" | "NO_AUTH";
|
|
117
|
+
isOnline: boolean;
|
|
118
|
+
createdAt?: Date | null | undefined;
|
|
119
|
+
updatedAt?: Date | null | undefined;
|
|
120
|
+
blockedAt?: Date | null | undefined;
|
|
121
|
+
ordersCount?: number | undefined;
|
|
122
|
+
ordersAmount?: number | undefined;
|
|
123
|
+
}>;
|
|
124
|
+
};
|
|
125
|
+
orders: {
|
|
126
|
+
create: (data: GetEndpointRequest<"orders", "create">) => Promise<{
|
|
127
|
+
redirectUrl: string;
|
|
128
|
+
}>;
|
|
129
|
+
list: (params?: GetEndpointRequest<"orders", "list">) => Promise<{
|
|
130
|
+
email: string;
|
|
131
|
+
type: "MAIN" | "WEBAPP";
|
|
132
|
+
status: "PENDING" | "AWAITING_PAYMENT" | "PAID" | "PROCESSING" | "SUCCESS" | "FAILED" | "REFUNDED" | "CANCELLED";
|
|
133
|
+
id: number;
|
|
134
|
+
designType: string | null;
|
|
135
|
+
subtotal: string;
|
|
136
|
+
discount: string;
|
|
137
|
+
commission: string;
|
|
138
|
+
serviceCommission: string;
|
|
139
|
+
total: string;
|
|
140
|
+
paymentMethodName: string | null;
|
|
141
|
+
promocodeValue: string | null;
|
|
142
|
+
promocodeDiscount: string | null;
|
|
143
|
+
createdAt: Date;
|
|
144
|
+
updatedAt: Date;
|
|
145
|
+
paymentMethodId?: number | null | undefined;
|
|
146
|
+
items?: {
|
|
147
|
+
status: "PENDING" | "PROCESSING" | "FAILED" | "REFUNDED" | "DELIVERED";
|
|
148
|
+
id: number;
|
|
149
|
+
variantId: number;
|
|
150
|
+
quantity: number;
|
|
151
|
+
gameUsername: string | null;
|
|
152
|
+
gameUsernameType: string | null;
|
|
153
|
+
productId: number;
|
|
154
|
+
price: string;
|
|
155
|
+
deliveredKey: string | null;
|
|
156
|
+
deliveredAt: Date | null;
|
|
157
|
+
productTitle?: string | undefined;
|
|
158
|
+
variantName?: string | undefined;
|
|
159
|
+
}[] | undefined;
|
|
160
|
+
promocodeId?: number | null | undefined;
|
|
161
|
+
userId?: number | null | undefined;
|
|
162
|
+
utmSource?: string | null | undefined;
|
|
163
|
+
telegramUsername?: string | null | undefined;
|
|
164
|
+
ipAddress?: string | null | undefined;
|
|
165
|
+
serviceCommissionPercent?: number | undefined;
|
|
166
|
+
acquiringCommissionPercent?: number | undefined;
|
|
167
|
+
}[]>;
|
|
168
|
+
getById: (params: GetEndpointRequest<"orders", "getById">) => Promise<{
|
|
169
|
+
email: string;
|
|
170
|
+
type: "MAIN" | "WEBAPP";
|
|
171
|
+
status: "PENDING" | "AWAITING_PAYMENT" | "PAID" | "PROCESSING" | "SUCCESS" | "FAILED" | "REFUNDED" | "CANCELLED";
|
|
172
|
+
id: number;
|
|
173
|
+
designType: string | null;
|
|
174
|
+
subtotal: string;
|
|
175
|
+
discount: string;
|
|
176
|
+
commission: string;
|
|
177
|
+
serviceCommission: string;
|
|
178
|
+
total: string;
|
|
179
|
+
paymentMethodName: string | null;
|
|
180
|
+
promocodeValue: string | null;
|
|
181
|
+
promocodeDiscount: string | null;
|
|
182
|
+
createdAt: Date;
|
|
183
|
+
updatedAt: Date;
|
|
184
|
+
paymentMethodId?: number | null | undefined;
|
|
185
|
+
items?: {
|
|
186
|
+
status: "PENDING" | "PROCESSING" | "FAILED" | "REFUNDED" | "DELIVERED";
|
|
187
|
+
id: number;
|
|
188
|
+
variantId: number;
|
|
189
|
+
quantity: number;
|
|
190
|
+
gameUsername: string | null;
|
|
191
|
+
gameUsernameType: string | null;
|
|
192
|
+
productId: number;
|
|
193
|
+
price: string;
|
|
194
|
+
deliveredKey: string | null;
|
|
195
|
+
deliveredAt: Date | null;
|
|
196
|
+
productTitle?: string | undefined;
|
|
197
|
+
variantName?: string | undefined;
|
|
198
|
+
}[] | undefined;
|
|
199
|
+
promocodeId?: number | null | undefined;
|
|
200
|
+
userId?: number | null | undefined;
|
|
201
|
+
utmSource?: string | null | undefined;
|
|
202
|
+
telegramUsername?: string | null | undefined;
|
|
203
|
+
ipAddress?: string | null | undefined;
|
|
204
|
+
serviceCommissionPercent?: number | undefined;
|
|
205
|
+
acquiringCommissionPercent?: number | undefined;
|
|
206
|
+
}>;
|
|
207
|
+
getUserOrders: (params?: GetEndpointRequest<"orders", "getUserOrders">) => Promise<{
|
|
208
|
+
email: string;
|
|
209
|
+
type: "MAIN" | "WEBAPP";
|
|
210
|
+
status: "PENDING" | "AWAITING_PAYMENT" | "PAID" | "PROCESSING" | "SUCCESS" | "FAILED" | "REFUNDED" | "CANCELLED";
|
|
211
|
+
id: number;
|
|
212
|
+
designType: string | null;
|
|
213
|
+
subtotal: string;
|
|
214
|
+
discount: string;
|
|
215
|
+
commission: string;
|
|
216
|
+
serviceCommission: string;
|
|
217
|
+
total: string;
|
|
218
|
+
paymentMethodName: string | null;
|
|
219
|
+
promocodeValue: string | null;
|
|
220
|
+
promocodeDiscount: string | null;
|
|
221
|
+
createdAt: Date;
|
|
222
|
+
updatedAt: Date;
|
|
223
|
+
paymentMethodId?: number | null | undefined;
|
|
224
|
+
items?: {
|
|
225
|
+
status: "PENDING" | "PROCESSING" | "FAILED" | "REFUNDED" | "DELIVERED";
|
|
226
|
+
id: number;
|
|
227
|
+
variantId: number;
|
|
228
|
+
quantity: number;
|
|
229
|
+
gameUsername: string | null;
|
|
230
|
+
gameUsernameType: string | null;
|
|
231
|
+
productId: number;
|
|
232
|
+
price: string;
|
|
233
|
+
deliveredKey: string | null;
|
|
234
|
+
deliveredAt: Date | null;
|
|
235
|
+
productTitle?: string | undefined;
|
|
236
|
+
variantName?: string | undefined;
|
|
237
|
+
}[] | undefined;
|
|
238
|
+
promocodeId?: number | null | undefined;
|
|
239
|
+
userId?: number | null | undefined;
|
|
240
|
+
utmSource?: string | null | undefined;
|
|
241
|
+
telegramUsername?: string | null | undefined;
|
|
242
|
+
ipAddress?: string | null | undefined;
|
|
243
|
+
serviceCommissionPercent?: number | undefined;
|
|
244
|
+
acquiringCommissionPercent?: number | undefined;
|
|
245
|
+
}[]>;
|
|
246
|
+
getUserOrderById: (params: GetEndpointRequest<"orders", "getUserOrderById">) => Promise<{
|
|
247
|
+
email: string;
|
|
248
|
+
type: "MAIN" | "WEBAPP";
|
|
249
|
+
status: "PENDING" | "AWAITING_PAYMENT" | "PAID" | "PROCESSING" | "SUCCESS" | "FAILED" | "REFUNDED" | "CANCELLED";
|
|
250
|
+
id: number;
|
|
251
|
+
designType: string | null;
|
|
252
|
+
subtotal: string;
|
|
253
|
+
discount: string;
|
|
254
|
+
commission: string;
|
|
255
|
+
serviceCommission: string;
|
|
256
|
+
total: string;
|
|
257
|
+
paymentMethodName: string | null;
|
|
258
|
+
promocodeValue: string | null;
|
|
259
|
+
promocodeDiscount: string | null;
|
|
260
|
+
createdAt: Date;
|
|
261
|
+
updatedAt: Date;
|
|
262
|
+
paymentMethodId?: number | null | undefined;
|
|
263
|
+
items?: {
|
|
264
|
+
status: "PENDING" | "PROCESSING" | "FAILED" | "REFUNDED" | "DELIVERED";
|
|
265
|
+
id: number;
|
|
266
|
+
variantId: number;
|
|
267
|
+
quantity: number;
|
|
268
|
+
gameUsername: string | null;
|
|
269
|
+
gameUsernameType: string | null;
|
|
270
|
+
productId: number;
|
|
271
|
+
price: string;
|
|
272
|
+
deliveredKey: string | null;
|
|
273
|
+
deliveredAt: Date | null;
|
|
274
|
+
productTitle?: string | undefined;
|
|
275
|
+
variantName?: string | undefined;
|
|
276
|
+
}[] | undefined;
|
|
277
|
+
promocodeId?: number | null | undefined;
|
|
278
|
+
userId?: number | null | undefined;
|
|
279
|
+
utmSource?: string | null | undefined;
|
|
280
|
+
telegramUsername?: string | null | undefined;
|
|
281
|
+
ipAddress?: string | null | undefined;
|
|
282
|
+
serviceCommissionPercent?: number | undefined;
|
|
283
|
+
acquiringCommissionPercent?: number | undefined;
|
|
284
|
+
}>;
|
|
285
|
+
};
|
|
286
|
+
products: {
|
|
287
|
+
catalog: (params?: GetEndpointRequest<"products", "catalog">) => Promise<{
|
|
288
|
+
items: {
|
|
289
|
+
type: string;
|
|
290
|
+
id: number;
|
|
291
|
+
slug: string;
|
|
292
|
+
title: string;
|
|
293
|
+
shortDescription: string | null;
|
|
294
|
+
coverImageUrl: string | null;
|
|
295
|
+
publisher: string | null;
|
|
296
|
+
releaseDate: Date | null;
|
|
297
|
+
hasMultiplayer: boolean;
|
|
298
|
+
hasCoop: boolean;
|
|
299
|
+
variants: {
|
|
300
|
+
id: number;
|
|
301
|
+
price: string;
|
|
302
|
+
name: string;
|
|
303
|
+
originalPrice: string | null;
|
|
304
|
+
platform: string | null;
|
|
305
|
+
regionCode: string | null;
|
|
306
|
+
}[];
|
|
307
|
+
steamRating: number | null;
|
|
308
|
+
salesCount: number;
|
|
309
|
+
category: {
|
|
310
|
+
name: string;
|
|
311
|
+
slug: string;
|
|
312
|
+
};
|
|
313
|
+
genres: {
|
|
314
|
+
name: string;
|
|
315
|
+
slug: string;
|
|
316
|
+
}[];
|
|
317
|
+
regions: {
|
|
318
|
+
code: string;
|
|
319
|
+
name: string;
|
|
320
|
+
}[];
|
|
321
|
+
minPrice: string | null;
|
|
322
|
+
hasDiscount: boolean;
|
|
323
|
+
}[];
|
|
324
|
+
total: number;
|
|
325
|
+
take: number;
|
|
326
|
+
skip: number;
|
|
327
|
+
}>;
|
|
328
|
+
categories: () => Promise<{
|
|
329
|
+
id: number;
|
|
330
|
+
name: string;
|
|
331
|
+
slug: string;
|
|
332
|
+
description: string | null;
|
|
333
|
+
iconUrl: string | null;
|
|
334
|
+
_count: {
|
|
335
|
+
products: number;
|
|
336
|
+
};
|
|
337
|
+
}[]>;
|
|
338
|
+
genres: () => Promise<{
|
|
339
|
+
id: number;
|
|
340
|
+
name: string;
|
|
341
|
+
slug: string;
|
|
342
|
+
_count: {
|
|
343
|
+
products: number;
|
|
344
|
+
};
|
|
345
|
+
}[]>;
|
|
346
|
+
regions: () => Promise<{
|
|
347
|
+
code: string;
|
|
348
|
+
id: number;
|
|
349
|
+
name: string;
|
|
350
|
+
_count: {
|
|
351
|
+
products: number;
|
|
352
|
+
};
|
|
353
|
+
}[]>;
|
|
354
|
+
getBySlug: (params: GetEndpointRequest<"products", "getBySlug">) => Promise<{
|
|
355
|
+
type: string;
|
|
356
|
+
status: string;
|
|
357
|
+
id: number;
|
|
358
|
+
createdAt: Date;
|
|
359
|
+
updatedAt: Date;
|
|
360
|
+
slug: string;
|
|
361
|
+
title: string;
|
|
362
|
+
originalTitle: string | null;
|
|
363
|
+
description: string | null;
|
|
364
|
+
customDescription: string | null;
|
|
365
|
+
shortDescription: string | null;
|
|
366
|
+
coverImageUrl: string | null;
|
|
367
|
+
developer: string | null;
|
|
368
|
+
publisher: string | null;
|
|
369
|
+
releaseDate: Date | null;
|
|
370
|
+
steamAppId: number | null;
|
|
371
|
+
hasMultiplayer: boolean;
|
|
372
|
+
hasCoop: boolean;
|
|
373
|
+
hasSinglePlayer: boolean;
|
|
374
|
+
metaTitle: string | null;
|
|
375
|
+
metaDescription: string | null;
|
|
376
|
+
variants: {
|
|
377
|
+
id: number;
|
|
378
|
+
price: string;
|
|
379
|
+
name: string;
|
|
380
|
+
sku: string;
|
|
381
|
+
originalPrice: string | null;
|
|
382
|
+
topupAmount: string | null;
|
|
383
|
+
currency: string | null;
|
|
384
|
+
durationDays: number | null;
|
|
385
|
+
platform: string | null;
|
|
386
|
+
regionCode: string | null;
|
|
387
|
+
deliveryType: string;
|
|
388
|
+
inStock: boolean;
|
|
389
|
+
}[];
|
|
390
|
+
steamRating: number | null;
|
|
391
|
+
salesCount: number;
|
|
392
|
+
category: {
|
|
393
|
+
id: number;
|
|
394
|
+
name: string;
|
|
395
|
+
slug: string;
|
|
396
|
+
};
|
|
397
|
+
genres: {
|
|
398
|
+
id: number;
|
|
399
|
+
name: string;
|
|
400
|
+
slug: string;
|
|
401
|
+
}[];
|
|
402
|
+
regions: {
|
|
403
|
+
code: string;
|
|
404
|
+
id: number;
|
|
405
|
+
name: string;
|
|
406
|
+
}[];
|
|
407
|
+
viewsCount: number;
|
|
408
|
+
media: {
|
|
409
|
+
type: string;
|
|
410
|
+
id: number;
|
|
411
|
+
url: string;
|
|
412
|
+
alt: string | null;
|
|
413
|
+
}[];
|
|
414
|
+
tags: {
|
|
415
|
+
id: number;
|
|
416
|
+
name: string;
|
|
417
|
+
slug: string;
|
|
418
|
+
}[];
|
|
419
|
+
systemRequirements: {
|
|
420
|
+
type: string;
|
|
421
|
+
os: string | null;
|
|
422
|
+
processor: string | null;
|
|
423
|
+
memory: string | null;
|
|
424
|
+
graphics: string | null;
|
|
425
|
+
storage: string | null;
|
|
426
|
+
directx: string | null;
|
|
427
|
+
network: string | null;
|
|
428
|
+
additional: string | null;
|
|
429
|
+
}[];
|
|
430
|
+
dlcs: {
|
|
431
|
+
id: number;
|
|
432
|
+
slug: string;
|
|
433
|
+
title: string;
|
|
434
|
+
coverImageUrl: string | null;
|
|
435
|
+
variants: {
|
|
436
|
+
price?: any;
|
|
437
|
+
originalPrice?: any;
|
|
438
|
+
}[];
|
|
439
|
+
}[];
|
|
440
|
+
}>;
|
|
441
|
+
create: (data: GetEndpointRequest<"products", "create">) => Promise<{
|
|
442
|
+
type: string;
|
|
443
|
+
status: string;
|
|
444
|
+
id: number;
|
|
445
|
+
createdAt: Date;
|
|
446
|
+
updatedAt: Date;
|
|
447
|
+
slug: string;
|
|
448
|
+
title: string;
|
|
449
|
+
originalTitle: string | null;
|
|
450
|
+
description: string | null;
|
|
451
|
+
customDescription: string | null;
|
|
452
|
+
shortDescription: string | null;
|
|
453
|
+
coverImageUrl: string | null;
|
|
454
|
+
developer: string | null;
|
|
455
|
+
publisher: string | null;
|
|
456
|
+
releaseDate: Date | null;
|
|
457
|
+
steamAppId: number | null;
|
|
458
|
+
hasMultiplayer: boolean;
|
|
459
|
+
hasCoop: boolean;
|
|
460
|
+
hasSinglePlayer: boolean;
|
|
461
|
+
metaTitle: string | null;
|
|
462
|
+
metaDescription: string | null;
|
|
463
|
+
variants: {
|
|
464
|
+
id: number;
|
|
465
|
+
price: string;
|
|
466
|
+
name: string;
|
|
467
|
+
sku: string;
|
|
468
|
+
originalPrice: string | null;
|
|
469
|
+
topupAmount: string | null;
|
|
470
|
+
currency: string | null;
|
|
471
|
+
durationDays: number | null;
|
|
472
|
+
platform: string | null;
|
|
473
|
+
regionCode: string | null;
|
|
474
|
+
deliveryType: string;
|
|
475
|
+
inStock: boolean;
|
|
476
|
+
}[];
|
|
477
|
+
steamRating: number | null;
|
|
478
|
+
salesCount: number;
|
|
479
|
+
category: {
|
|
480
|
+
id: number;
|
|
481
|
+
name: string;
|
|
482
|
+
slug: string;
|
|
483
|
+
};
|
|
484
|
+
genres: {
|
|
485
|
+
id: number;
|
|
486
|
+
name: string;
|
|
487
|
+
slug: string;
|
|
488
|
+
}[];
|
|
489
|
+
regions: {
|
|
490
|
+
code: string;
|
|
491
|
+
id: number;
|
|
492
|
+
name: string;
|
|
493
|
+
}[];
|
|
494
|
+
viewsCount: number;
|
|
495
|
+
media: {
|
|
496
|
+
type: string;
|
|
497
|
+
id: number;
|
|
498
|
+
url: string;
|
|
499
|
+
alt: string | null;
|
|
500
|
+
}[];
|
|
501
|
+
tags: {
|
|
502
|
+
id: number;
|
|
503
|
+
name: string;
|
|
504
|
+
slug: string;
|
|
505
|
+
}[];
|
|
506
|
+
systemRequirements: {
|
|
507
|
+
type: string;
|
|
508
|
+
os: string | null;
|
|
509
|
+
processor: string | null;
|
|
510
|
+
memory: string | null;
|
|
511
|
+
graphics: string | null;
|
|
512
|
+
storage: string | null;
|
|
513
|
+
directx: string | null;
|
|
514
|
+
network: string | null;
|
|
515
|
+
additional: string | null;
|
|
516
|
+
}[];
|
|
517
|
+
dlcs: {
|
|
518
|
+
id: number;
|
|
519
|
+
slug: string;
|
|
520
|
+
title: string;
|
|
521
|
+
coverImageUrl: string | null;
|
|
522
|
+
variants: {
|
|
523
|
+
price?: any;
|
|
524
|
+
originalPrice?: any;
|
|
525
|
+
}[];
|
|
526
|
+
}[];
|
|
527
|
+
}>;
|
|
528
|
+
update: (params: GetEndpointRequest<"products", "update">) => Promise<{
|
|
529
|
+
type: string;
|
|
530
|
+
status: string;
|
|
531
|
+
id: number;
|
|
532
|
+
createdAt: Date;
|
|
533
|
+
updatedAt: Date;
|
|
534
|
+
slug: string;
|
|
535
|
+
title: string;
|
|
536
|
+
originalTitle: string | null;
|
|
537
|
+
description: string | null;
|
|
538
|
+
customDescription: string | null;
|
|
539
|
+
shortDescription: string | null;
|
|
540
|
+
coverImageUrl: string | null;
|
|
541
|
+
developer: string | null;
|
|
542
|
+
publisher: string | null;
|
|
543
|
+
releaseDate: Date | null;
|
|
544
|
+
steamAppId: number | null;
|
|
545
|
+
hasMultiplayer: boolean;
|
|
546
|
+
hasCoop: boolean;
|
|
547
|
+
hasSinglePlayer: boolean;
|
|
548
|
+
metaTitle: string | null;
|
|
549
|
+
metaDescription: string | null;
|
|
550
|
+
variants: {
|
|
551
|
+
id: number;
|
|
552
|
+
price: string;
|
|
553
|
+
name: string;
|
|
554
|
+
sku: string;
|
|
555
|
+
originalPrice: string | null;
|
|
556
|
+
topupAmount: string | null;
|
|
557
|
+
currency: string | null;
|
|
558
|
+
durationDays: number | null;
|
|
559
|
+
platform: string | null;
|
|
560
|
+
regionCode: string | null;
|
|
561
|
+
deliveryType: string;
|
|
562
|
+
inStock: boolean;
|
|
563
|
+
}[];
|
|
564
|
+
steamRating: number | null;
|
|
565
|
+
salesCount: number;
|
|
566
|
+
category: {
|
|
567
|
+
id: number;
|
|
568
|
+
name: string;
|
|
569
|
+
slug: string;
|
|
570
|
+
};
|
|
571
|
+
genres: {
|
|
572
|
+
id: number;
|
|
573
|
+
name: string;
|
|
574
|
+
slug: string;
|
|
575
|
+
}[];
|
|
576
|
+
regions: {
|
|
577
|
+
code: string;
|
|
578
|
+
id: number;
|
|
579
|
+
name: string;
|
|
580
|
+
}[];
|
|
581
|
+
viewsCount: number;
|
|
582
|
+
media: {
|
|
583
|
+
type: string;
|
|
584
|
+
id: number;
|
|
585
|
+
url: string;
|
|
586
|
+
alt: string | null;
|
|
587
|
+
}[];
|
|
588
|
+
tags: {
|
|
589
|
+
id: number;
|
|
590
|
+
name: string;
|
|
591
|
+
slug: string;
|
|
592
|
+
}[];
|
|
593
|
+
systemRequirements: {
|
|
594
|
+
type: string;
|
|
595
|
+
os: string | null;
|
|
596
|
+
processor: string | null;
|
|
597
|
+
memory: string | null;
|
|
598
|
+
graphics: string | null;
|
|
599
|
+
storage: string | null;
|
|
600
|
+
directx: string | null;
|
|
601
|
+
network: string | null;
|
|
602
|
+
additional: string | null;
|
|
603
|
+
}[];
|
|
604
|
+
dlcs: {
|
|
605
|
+
id: number;
|
|
606
|
+
slug: string;
|
|
607
|
+
title: string;
|
|
608
|
+
coverImageUrl: string | null;
|
|
609
|
+
variants: {
|
|
610
|
+
price?: any;
|
|
611
|
+
originalPrice?: any;
|
|
612
|
+
}[];
|
|
613
|
+
}[];
|
|
614
|
+
}>;
|
|
615
|
+
archive: (params: GetEndpointRequest<"products", "archive">) => Promise<{
|
|
616
|
+
status: string;
|
|
617
|
+
}>;
|
|
618
|
+
createVariant: (params: GetEndpointRequest<"products", "createVariant">) => Promise<void>;
|
|
619
|
+
updateVariant: (params: GetEndpointRequest<"products", "updateVariant">) => Promise<void>;
|
|
620
|
+
importKeys: (params: GetEndpointRequest<"products", "importKeys">) => Promise<{
|
|
621
|
+
imported: number;
|
|
622
|
+
}>;
|
|
623
|
+
getKeysCount: (params: GetEndpointRequest<"products", "getKeysCount">) => Promise<{
|
|
624
|
+
total: number;
|
|
625
|
+
available: number;
|
|
626
|
+
sold: number;
|
|
627
|
+
reserved: number;
|
|
628
|
+
}>;
|
|
629
|
+
addMedia: (params: GetEndpointRequest<"products", "addMedia">) => Promise<void>;
|
|
630
|
+
removeMedia: (params: GetEndpointRequest<"products", "removeMedia">) => Promise<void>;
|
|
631
|
+
upsertSystemRequirements: (params: GetEndpointRequest<"products", "upsertSystemRequirements">) => Promise<void>;
|
|
632
|
+
};
|
|
633
|
+
paymentMethods: {
|
|
634
|
+
course: () => Promise<{
|
|
635
|
+
USD_RUB: string;
|
|
636
|
+
RUB_KZT: string;
|
|
637
|
+
USD_KZT: string;
|
|
638
|
+
KZT_RUB: string;
|
|
639
|
+
}>;
|
|
640
|
+
create: (params: GetEndpointRequest<"paymentMethods", "create">) => Promise<{
|
|
641
|
+
type: string;
|
|
642
|
+
id: number;
|
|
643
|
+
createdAt: Date;
|
|
644
|
+
updatedAt: Date;
|
|
645
|
+
name: string;
|
|
646
|
+
image: string;
|
|
647
|
+
key: string;
|
|
648
|
+
uniqueKey: string;
|
|
649
|
+
isActive: boolean;
|
|
650
|
+
maxAmount: number;
|
|
651
|
+
minAmount: number;
|
|
652
|
+
comission: number;
|
|
653
|
+
serviceComission: number;
|
|
654
|
+
cryptoToken: string | null;
|
|
655
|
+
cryptoNetwork: string | null;
|
|
656
|
+
secretComission?: number | undefined;
|
|
657
|
+
}>;
|
|
658
|
+
update: (params: GetEndpointRequest<"paymentMethods", "update">) => Promise<{
|
|
659
|
+
type: string;
|
|
660
|
+
id: number;
|
|
661
|
+
createdAt: Date;
|
|
662
|
+
updatedAt: Date;
|
|
663
|
+
name: string;
|
|
664
|
+
image: string;
|
|
665
|
+
key: string;
|
|
666
|
+
uniqueKey: string;
|
|
667
|
+
isActive: boolean;
|
|
668
|
+
maxAmount: number;
|
|
669
|
+
minAmount: number;
|
|
670
|
+
comission: number;
|
|
671
|
+
serviceComission: number;
|
|
672
|
+
cryptoToken: string | null;
|
|
673
|
+
cryptoNetwork: string | null;
|
|
674
|
+
secretComission?: number | undefined;
|
|
675
|
+
}>;
|
|
676
|
+
list: () => Promise<{
|
|
677
|
+
type: string;
|
|
678
|
+
id: number;
|
|
679
|
+
createdAt: Date;
|
|
680
|
+
updatedAt: Date;
|
|
681
|
+
name: string;
|
|
682
|
+
image: string;
|
|
683
|
+
key: string;
|
|
684
|
+
uniqueKey: string;
|
|
685
|
+
isActive: boolean;
|
|
686
|
+
maxAmount: number;
|
|
687
|
+
minAmount: number;
|
|
688
|
+
comission: number;
|
|
689
|
+
serviceComission: number;
|
|
690
|
+
cryptoToken: string | null;
|
|
691
|
+
cryptoNetwork: string | null;
|
|
692
|
+
secretComission?: number | undefined;
|
|
693
|
+
}[]>;
|
|
694
|
+
listAdmin: () => Promise<{
|
|
695
|
+
type: string;
|
|
696
|
+
id: number;
|
|
697
|
+
createdAt: Date;
|
|
698
|
+
updatedAt: Date;
|
|
699
|
+
name: string;
|
|
700
|
+
image: string;
|
|
701
|
+
key: string;
|
|
702
|
+
uniqueKey: string;
|
|
703
|
+
isActive: boolean;
|
|
704
|
+
maxAmount: number;
|
|
705
|
+
minAmount: number;
|
|
706
|
+
comission: number;
|
|
707
|
+
serviceComission: number;
|
|
708
|
+
cryptoToken: string | null;
|
|
709
|
+
cryptoNetwork: string | null;
|
|
710
|
+
secretComission?: number | undefined;
|
|
711
|
+
}[]>;
|
|
712
|
+
getById: (params: GetEndpointRequest<"paymentMethods", "getById">) => Promise<{
|
|
713
|
+
type: string;
|
|
714
|
+
id: number;
|
|
715
|
+
createdAt: Date;
|
|
716
|
+
updatedAt: Date;
|
|
717
|
+
name: string;
|
|
718
|
+
image: string;
|
|
719
|
+
key: string;
|
|
720
|
+
uniqueKey: string;
|
|
721
|
+
isActive: boolean;
|
|
722
|
+
maxAmount: number;
|
|
723
|
+
minAmount: number;
|
|
724
|
+
comission: number;
|
|
725
|
+
serviceComission: number;
|
|
726
|
+
cryptoToken: string | null;
|
|
727
|
+
cryptoNetwork: string | null;
|
|
728
|
+
secretComission?: number | undefined;
|
|
729
|
+
}>;
|
|
730
|
+
getByIdAdmin: (params: GetEndpointRequest<"paymentMethods", "getByIdAdmin">) => Promise<{
|
|
731
|
+
type: string;
|
|
732
|
+
id: number;
|
|
733
|
+
createdAt: Date;
|
|
734
|
+
updatedAt: Date;
|
|
735
|
+
name: string;
|
|
736
|
+
image: string;
|
|
737
|
+
key: string;
|
|
738
|
+
uniqueKey: string;
|
|
739
|
+
isActive: boolean;
|
|
740
|
+
maxAmount: number;
|
|
741
|
+
minAmount: number;
|
|
742
|
+
comission: number;
|
|
743
|
+
serviceComission: number;
|
|
744
|
+
cryptoToken: string | null;
|
|
745
|
+
cryptoNetwork: string | null;
|
|
746
|
+
secretComission?: number | undefined;
|
|
747
|
+
}>;
|
|
748
|
+
};
|
|
749
|
+
promoCodes: {
|
|
750
|
+
create: (data: GetEndpointRequest<"promoCodes", "create">) => Promise<{
|
|
751
|
+
value: string;
|
|
752
|
+
type: "USER" | "AD" | "SYSTEM";
|
|
753
|
+
status: "ACTIVE" | "INACTIVE" | "LIMITED" | "EXPIRED" | "DELETED";
|
|
754
|
+
id: number;
|
|
755
|
+
discountValue: string;
|
|
756
|
+
activated: number;
|
|
757
|
+
createdAt?: Date | null | undefined;
|
|
758
|
+
updatedAt?: Date | null | undefined;
|
|
759
|
+
expiredAt?: Date | null | undefined;
|
|
760
|
+
startedAt?: Date | null | undefined;
|
|
761
|
+
deletedAt?: Date | null | undefined;
|
|
762
|
+
activationLimit?: number | null | undefined;
|
|
763
|
+
activationPerUserLimit?: number | null | undefined;
|
|
764
|
+
}>;
|
|
765
|
+
list: () => Promise<{
|
|
766
|
+
value: string;
|
|
767
|
+
type: "USER" | "AD" | "SYSTEM";
|
|
768
|
+
status: "ACTIVE" | "INACTIVE" | "LIMITED" | "EXPIRED" | "DELETED";
|
|
769
|
+
id: number;
|
|
770
|
+
discountValue: string;
|
|
771
|
+
activated: number;
|
|
772
|
+
createdAt?: Date | null | undefined;
|
|
773
|
+
updatedAt?: Date | null | undefined;
|
|
774
|
+
expiredAt?: Date | null | undefined;
|
|
775
|
+
startedAt?: Date | null | undefined;
|
|
776
|
+
deletedAt?: Date | null | undefined;
|
|
777
|
+
activationLimit?: number | null | undefined;
|
|
778
|
+
activationPerUserLimit?: number | null | undefined;
|
|
779
|
+
}[]>;
|
|
780
|
+
getById: (params: GetEndpointRequest<"promoCodes", "getById">) => Promise<{
|
|
781
|
+
value: string;
|
|
782
|
+
type: "USER" | "AD" | "SYSTEM";
|
|
783
|
+
status: "ACTIVE" | "INACTIVE" | "LIMITED" | "EXPIRED" | "DELETED";
|
|
784
|
+
id: number;
|
|
785
|
+
discountValue: string;
|
|
786
|
+
activated: number;
|
|
787
|
+
createdAt?: Date | null | undefined;
|
|
788
|
+
updatedAt?: Date | null | undefined;
|
|
789
|
+
expiredAt?: Date | null | undefined;
|
|
790
|
+
startedAt?: Date | null | undefined;
|
|
791
|
+
deletedAt?: Date | null | undefined;
|
|
792
|
+
activationLimit?: number | null | undefined;
|
|
793
|
+
activationPerUserLimit?: number | null | undefined;
|
|
794
|
+
}>;
|
|
795
|
+
getByValue: (params: GetEndpointRequest<"promoCodes", "getByValue">) => Promise<{
|
|
796
|
+
value: string;
|
|
797
|
+
type: "USER" | "AD" | "SYSTEM";
|
|
798
|
+
status: "ACTIVE" | "INACTIVE" | "LIMITED" | "EXPIRED" | "DELETED";
|
|
799
|
+
id: number;
|
|
800
|
+
discountValue: string;
|
|
801
|
+
activated: number;
|
|
802
|
+
createdAt?: Date | null | undefined;
|
|
803
|
+
updatedAt?: Date | null | undefined;
|
|
804
|
+
expiredAt?: Date | null | undefined;
|
|
805
|
+
startedAt?: Date | null | undefined;
|
|
806
|
+
deletedAt?: Date | null | undefined;
|
|
807
|
+
activationLimit?: number | null | undefined;
|
|
808
|
+
activationPerUserLimit?: number | null | undefined;
|
|
809
|
+
}>;
|
|
810
|
+
update: (params: GetEndpointRequest<"promoCodes", "update">) => Promise<{
|
|
811
|
+
value: string;
|
|
812
|
+
type: "USER" | "AD" | "SYSTEM";
|
|
813
|
+
status: "ACTIVE" | "INACTIVE" | "LIMITED" | "EXPIRED" | "DELETED";
|
|
814
|
+
id: number;
|
|
815
|
+
discountValue: string;
|
|
816
|
+
activated: number;
|
|
817
|
+
createdAt?: Date | null | undefined;
|
|
818
|
+
updatedAt?: Date | null | undefined;
|
|
819
|
+
expiredAt?: Date | null | undefined;
|
|
820
|
+
startedAt?: Date | null | undefined;
|
|
821
|
+
deletedAt?: Date | null | undefined;
|
|
822
|
+
activationLimit?: number | null | undefined;
|
|
823
|
+
activationPerUserLimit?: number | null | undefined;
|
|
824
|
+
}>;
|
|
825
|
+
};
|
|
826
|
+
promoCodeActivations: {
|
|
827
|
+
create: (data: GetEndpointRequest<"promoCodeActivations", "create">) => Promise<{
|
|
828
|
+
id: number;
|
|
829
|
+
promocodeId: number;
|
|
830
|
+
discountValue: string;
|
|
831
|
+
refferalId: number;
|
|
832
|
+
activatedAt: Date;
|
|
833
|
+
}>;
|
|
834
|
+
list: () => Promise<{
|
|
835
|
+
id: number;
|
|
836
|
+
promocodeId: number;
|
|
837
|
+
discountValue: string;
|
|
838
|
+
refferalId: number;
|
|
839
|
+
activatedAt: Date;
|
|
840
|
+
}[]>;
|
|
841
|
+
getById: (params: GetEndpointRequest<"promoCodeActivations", "getById">) => Promise<{
|
|
842
|
+
id: number;
|
|
843
|
+
promocodeId: number;
|
|
844
|
+
discountValue: string;
|
|
845
|
+
refferalId: number;
|
|
846
|
+
activatedAt: Date;
|
|
847
|
+
}>;
|
|
848
|
+
update: (params: GetEndpointRequest<"promoCodeActivations", "update">) => Promise<{
|
|
849
|
+
id: number;
|
|
850
|
+
promocodeId: number;
|
|
851
|
+
discountValue: string;
|
|
852
|
+
refferalId: number;
|
|
853
|
+
activatedAt: Date;
|
|
854
|
+
}>;
|
|
855
|
+
};
|
|
856
|
+
refreshSessions: {
|
|
857
|
+
create: (data: GetEndpointRequest<"refreshSessions", "create">) => Promise<{
|
|
858
|
+
status: "ACTIVE" | "EXPIRED" | "BLOCKED" | "TERMINATED";
|
|
859
|
+
id: number;
|
|
860
|
+
userId: number;
|
|
861
|
+
refreshToken: string;
|
|
862
|
+
createdAt?: Date | null | undefined;
|
|
863
|
+
updatedAt?: Date | null | undefined;
|
|
864
|
+
expiredAt?: Date | null | undefined;
|
|
865
|
+
}>;
|
|
866
|
+
list: () => Promise<{
|
|
867
|
+
status: "ACTIVE" | "EXPIRED" | "BLOCKED" | "TERMINATED";
|
|
868
|
+
id: number;
|
|
869
|
+
userId: number;
|
|
870
|
+
refreshToken: string;
|
|
871
|
+
createdAt?: Date | null | undefined;
|
|
872
|
+
updatedAt?: Date | null | undefined;
|
|
873
|
+
expiredAt?: Date | null | undefined;
|
|
874
|
+
}[]>;
|
|
875
|
+
getById: (params: GetEndpointRequest<"refreshSessions", "getById">) => Promise<{
|
|
876
|
+
status: "ACTIVE" | "EXPIRED" | "BLOCKED" | "TERMINATED";
|
|
877
|
+
id: number;
|
|
878
|
+
userId: number;
|
|
879
|
+
refreshToken: string;
|
|
880
|
+
createdAt?: Date | null | undefined;
|
|
881
|
+
updatedAt?: Date | null | undefined;
|
|
882
|
+
expiredAt?: Date | null | undefined;
|
|
883
|
+
}>;
|
|
884
|
+
update: (params: GetEndpointRequest<"refreshSessions", "update">) => Promise<{
|
|
885
|
+
status: "ACTIVE" | "EXPIRED" | "BLOCKED" | "TERMINATED";
|
|
886
|
+
id: number;
|
|
887
|
+
userId: number;
|
|
888
|
+
refreshToken: string;
|
|
889
|
+
createdAt?: Date | null | undefined;
|
|
890
|
+
updatedAt?: Date | null | undefined;
|
|
891
|
+
expiredAt?: Date | null | undefined;
|
|
892
|
+
}>;
|
|
893
|
+
revoke: (params: GetEndpointRequest<"refreshSessions", "revoke">) => Promise<{
|
|
894
|
+
success: boolean;
|
|
895
|
+
}>;
|
|
896
|
+
};
|
|
897
|
+
settings: {
|
|
898
|
+
getAll: () => Promise<{
|
|
899
|
+
desslyDiscount: string;
|
|
900
|
+
serviceEnabled: boolean;
|
|
901
|
+
worksEnabled: boolean;
|
|
902
|
+
paymentsEnabled: boolean;
|
|
903
|
+
}>;
|
|
904
|
+
getOne: (params: GetEndpointRequest<"settings", "getOne">) => Promise<{
|
|
905
|
+
value: string | boolean;
|
|
906
|
+
key: string;
|
|
907
|
+
}>;
|
|
908
|
+
updateAll: (data: GetEndpointRequest<"settings", "updateAll">) => Promise<{
|
|
909
|
+
desslyDiscount: string;
|
|
910
|
+
serviceEnabled: boolean;
|
|
911
|
+
worksEnabled: boolean;
|
|
912
|
+
paymentsEnabled: boolean;
|
|
913
|
+
}>;
|
|
914
|
+
updateOne: (params: GetEndpointRequest<"settings", "updateOne">) => Promise<{
|
|
915
|
+
value: string | boolean;
|
|
916
|
+
key: string;
|
|
917
|
+
}>;
|
|
918
|
+
};
|
|
919
|
+
stats: {
|
|
920
|
+
list: (params?: GetEndpointRequest<"stats", "list">) => Promise<{
|
|
921
|
+
serviceCommission: number;
|
|
922
|
+
ordersCount: number;
|
|
923
|
+
usersCount: number;
|
|
924
|
+
totalAmount: number;
|
|
925
|
+
acquiringCommission: number;
|
|
926
|
+
totalAmountWithCommission: number;
|
|
927
|
+
periodStart?: string | undefined;
|
|
928
|
+
periodEnd?: string | undefined;
|
|
929
|
+
}>;
|
|
930
|
+
};
|
|
931
|
+
}
|
|
932
|
+
export declare function createApiClient(config: ApiClientConfig): ApiClient;
|
|
933
|
+
export {};
|
|
934
|
+
//# sourceMappingURL=client.d.ts.map
|