@remnawave/backend-contract 0.7.11 → 0.7.13
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/build/backend/commands/users/create-user.command.d.ts +12 -12
- package/build/backend/commands/users/create-user.command.d.ts.map +1 -1
- package/build/backend/commands/users/create-user.command.js +5 -4
- package/build/frontend/commands/users/create-user.command.js +5 -4
- package/package.json +1 -1
@@ -16,17 +16,17 @@ export declare namespace CreateUserCommand {
|
|
16
16
|
trojanPassword: z.ZodOptional<z.ZodString>;
|
17
17
|
vlessUuid: z.ZodOptional<z.ZodString>;
|
18
18
|
ssPassword: z.ZodOptional<z.ZodString>;
|
19
|
-
trafficLimitBytes: z.ZodNumber
|
20
|
-
trafficLimitStrategy: z.
|
19
|
+
trafficLimitBytes: z.ZodOptional<z.ZodNumber>;
|
20
|
+
trafficLimitStrategy: z.ZodOptional<z.ZodEffects<z.ZodDefault<z.ZodDefault<z.ZodNativeEnum<{
|
21
21
|
readonly NO_RESET: "NO_RESET";
|
22
22
|
readonly DAY: "DAY";
|
23
23
|
readonly WEEK: "WEEK";
|
24
24
|
readonly MONTH: "MONTH";
|
25
|
-
}
|
25
|
+
}>>>, "MONTH" | "NO_RESET" | "DAY" | "WEEK", "MONTH" | "NO_RESET" | "DAY" | "WEEK" | undefined>>;
|
26
26
|
activeUserInbounds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
27
27
|
expireAt: z.ZodEffects<z.ZodString, Date, string>;
|
28
|
-
createdAt: z.ZodEffects<z.ZodString, Date, string
|
29
|
-
lastTrafficResetAt: z.ZodEffects<z.ZodString, Date, string
|
28
|
+
createdAt: z.ZodOptional<z.ZodEffects<z.ZodString, Date, string>>;
|
29
|
+
lastTrafficResetAt: z.ZodOptional<z.ZodEffects<z.ZodString, Date, string>>;
|
30
30
|
description: z.ZodOptional<z.ZodString>;
|
31
31
|
tag: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
32
32
|
telegramId: z.ZodOptional<z.ZodNumber>;
|
@@ -35,16 +35,16 @@ export declare namespace CreateUserCommand {
|
|
35
35
|
activateAllInbounds: z.ZodOptional<z.ZodBoolean>;
|
36
36
|
}, "strip", z.ZodTypeAny, {
|
37
37
|
status: "DISABLED" | "LIMITED" | "EXPIRED" | "ACTIVE";
|
38
|
-
createdAt: Date;
|
39
38
|
username: string;
|
40
|
-
trafficLimitBytes: number;
|
41
|
-
trafficLimitStrategy: "MONTH" | "NO_RESET" | "DAY" | "WEEK";
|
42
39
|
expireAt: Date;
|
43
|
-
|
40
|
+
createdAt?: Date | undefined;
|
44
41
|
tag?: string | null | undefined;
|
45
42
|
subscriptionUuid?: string | undefined;
|
46
43
|
shortUuid?: string | undefined;
|
44
|
+
trafficLimitBytes?: number | undefined;
|
47
45
|
description?: string | undefined;
|
46
|
+
trafficLimitStrategy?: "MONTH" | "NO_RESET" | "DAY" | "WEEK" | undefined;
|
47
|
+
lastTrafficResetAt?: Date | undefined;
|
48
48
|
trojanPassword?: string | undefined;
|
49
49
|
vlessUuid?: string | undefined;
|
50
50
|
ssPassword?: string | undefined;
|
@@ -54,17 +54,17 @@ export declare namespace CreateUserCommand {
|
|
54
54
|
activeUserInbounds?: string[] | undefined;
|
55
55
|
activateAllInbounds?: boolean | undefined;
|
56
56
|
}, {
|
57
|
-
createdAt: string;
|
58
57
|
username: string;
|
59
|
-
trafficLimitBytes: number;
|
60
58
|
expireAt: string;
|
61
|
-
lastTrafficResetAt: string;
|
62
59
|
status?: "DISABLED" | "LIMITED" | "EXPIRED" | "ACTIVE" | undefined;
|
60
|
+
createdAt?: string | undefined;
|
63
61
|
tag?: string | null | undefined;
|
64
62
|
subscriptionUuid?: string | undefined;
|
65
63
|
shortUuid?: string | undefined;
|
64
|
+
trafficLimitBytes?: number | undefined;
|
66
65
|
description?: string | undefined;
|
67
66
|
trafficLimitStrategy?: "MONTH" | "NO_RESET" | "DAY" | "WEEK" | undefined;
|
67
|
+
lastTrafficResetAt?: string | undefined;
|
68
68
|
trojanPassword?: string | undefined;
|
69
69
|
vlessUuid?: string | undefined;
|
70
70
|
ssPassword?: string | undefined;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"create-user.command.d.ts","sourceRoot":"","sources":["../../../../commands/users/create-user.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,yBAAiB,iBAAiB,CAAC;IACxB,MAAM,GAAG,eAAwB,CAAC;IAClC,MAAM,OAAO,eAAM,CAAC;IAEpB,MAAM,eAAe,2CAI3B,CAAC;IAEK,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
1
|
+
{"version":3,"file":"create-user.command.d.ts","sourceRoot":"","sources":["../../../../commands/users/create-user.command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,yBAAiB,iBAAiB,CAAC;IACxB,MAAM,GAAG,eAAwB,CAAC;IAClC,MAAM,OAAO,eAAM,CAAC;IAEpB,MAAM,eAAe,2CAI3B,CAAC;IAEK,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAsJxB,CAAC;IAEH,KAAY,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;IAE7C,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAEzB,CAAC;IAEH,KAAY,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;CACzD"}
|
@@ -66,10 +66,9 @@ var CreateUserCommand;
|
|
66
66
|
})
|
67
67
|
.int('Traffic limit must be an integer')
|
68
68
|
.min(0, 'Traffic limit must be greater than 0')
|
69
|
-
.describe('Optional. Traffic limit in bytes. Set to 0 for unlimited traffic.'),
|
70
|
-
trafficLimitStrategy: models_1.UsersSchema.shape.trafficLimitStrategy
|
71
|
-
.describe('Optional. Strategy for resetting traffic limits. Defaults to NO_RESET. Must be a valid reset period.')
|
72
69
|
.optional()
|
70
|
+
.describe('Optional. Traffic limit in bytes. Set to 0 for unlimited traffic.'),
|
71
|
+
trafficLimitStrategy: zod_1.z.optional(models_1.UsersSchema.shape.trafficLimitStrategy
|
73
72
|
.default(constants_1.RESET_PERIODS.NO_RESET)
|
74
73
|
.superRefine((val, ctx) => {
|
75
74
|
if (val && !Object.values(constants_1.RESET_PERIODS).includes(val)) {
|
@@ -81,7 +80,7 @@ var CreateUserCommand;
|
|
81
80
|
options: Object.values(constants_1.RESET_PERIODS),
|
82
81
|
});
|
83
82
|
}
|
84
|
-
}),
|
83
|
+
})),
|
85
84
|
activeUserInbounds: zod_1.z
|
86
85
|
.array(zod_1.z.string().uuid(), {
|
87
86
|
invalid_type_error: 'Enabled inbounds must be an array',
|
@@ -102,6 +101,7 @@ var CreateUserCommand;
|
|
102
101
|
})
|
103
102
|
.datetime({ message: 'Invalid date format', offset: true, local: true })
|
104
103
|
.transform((str) => new Date(str))
|
104
|
+
.optional()
|
105
105
|
.describe('Optional. Account creation date. Format: 2025-01-17T15:38:45.065Z'),
|
106
106
|
lastTrafficResetAt: zod_1.z
|
107
107
|
.string({
|
@@ -109,6 +109,7 @@ var CreateUserCommand;
|
|
109
109
|
})
|
110
110
|
.datetime({ message: 'Invalid date format', offset: true, local: true })
|
111
111
|
.transform((str) => new Date(str))
|
112
|
+
.optional()
|
112
113
|
.describe('Optional. Date of last traffic reset. Format: 2025-01-17T15:38:45.065Z'),
|
113
114
|
description: zod_1.z
|
114
115
|
.string()
|
@@ -66,10 +66,9 @@ var CreateUserCommand;
|
|
66
66
|
})
|
67
67
|
.int('Traffic limit must be an integer')
|
68
68
|
.min(0, 'Traffic limit must be greater than 0')
|
69
|
-
.describe('Optional. Traffic limit in bytes. Set to 0 for unlimited traffic.'),
|
70
|
-
trafficLimitStrategy: models_1.UsersSchema.shape.trafficLimitStrategy
|
71
|
-
.describe('Optional. Strategy for resetting traffic limits. Defaults to NO_RESET. Must be a valid reset period.')
|
72
69
|
.optional()
|
70
|
+
.describe('Optional. Traffic limit in bytes. Set to 0 for unlimited traffic.'),
|
71
|
+
trafficLimitStrategy: zod_1.z.optional(models_1.UsersSchema.shape.trafficLimitStrategy
|
73
72
|
.default(constants_1.RESET_PERIODS.NO_RESET)
|
74
73
|
.superRefine((val, ctx) => {
|
75
74
|
if (val && !Object.values(constants_1.RESET_PERIODS).includes(val)) {
|
@@ -81,7 +80,7 @@ var CreateUserCommand;
|
|
81
80
|
options: Object.values(constants_1.RESET_PERIODS),
|
82
81
|
});
|
83
82
|
}
|
84
|
-
}),
|
83
|
+
})),
|
85
84
|
activeUserInbounds: zod_1.z
|
86
85
|
.array(zod_1.z.string().uuid(), {
|
87
86
|
invalid_type_error: 'Enabled inbounds must be an array',
|
@@ -102,6 +101,7 @@ var CreateUserCommand;
|
|
102
101
|
})
|
103
102
|
.datetime({ message: 'Invalid date format', offset: true, local: true })
|
104
103
|
.transform((str) => new Date(str))
|
104
|
+
.optional()
|
105
105
|
.describe('Optional. Account creation date. Format: 2025-01-17T15:38:45.065Z'),
|
106
106
|
lastTrafficResetAt: zod_1.z
|
107
107
|
.string({
|
@@ -109,6 +109,7 @@ var CreateUserCommand;
|
|
109
109
|
})
|
110
110
|
.datetime({ message: 'Invalid date format', offset: true, local: true })
|
111
111
|
.transform((str) => new Date(str))
|
112
|
+
.optional()
|
112
113
|
.describe('Optional. Date of last traffic reset. Format: 2025-01-17T15:38:45.065Z'),
|
113
114
|
description: zod_1.z
|
114
115
|
.string()
|