@remnawave/backend-contract 0.0.55 → 0.0.57

Sign up to get free protection for your applications and to get access to all the features.
@@ -86,6 +86,24 @@ var CreateUserCommand;
86
86
  .refine(() => new Date(), {
87
87
  message: 'Expiration date cannot be in the past',
88
88
  }),
89
+ createdAt: zod_1.z.coerce
90
+ .date({
91
+ required_error: 'Expiration date is required',
92
+ invalid_type_error: 'Invalid expiration date format',
93
+ })
94
+ .refine(() => new Date(), {
95
+ message: 'Expiration date cannot be in the past',
96
+ })
97
+ .optional(),
98
+ lastTrafficResetAt: zod_1.z.coerce
99
+ .date({
100
+ required_error: 'Expiration date is required',
101
+ invalid_type_error: 'Invalid expiration date format',
102
+ })
103
+ .refine(() => new Date(), {
104
+ message: 'Expiration date cannot be in the past',
105
+ })
106
+ .optional(),
89
107
  });
90
108
  CreateUserCommand.ResponseSchema = zod_1.z.object({
91
109
  response: models_1.UsersSchema,
@@ -87,6 +87,24 @@ export namespace CreateUserCommand {
87
87
  .refine(() => new Date(), {
88
88
  message: 'Expiration date cannot be in the past',
89
89
  }),
90
+ createdAt: z.coerce
91
+ .date({
92
+ required_error: 'Expiration date is required',
93
+ invalid_type_error: 'Invalid expiration date format',
94
+ })
95
+ .refine(() => new Date(), {
96
+ message: 'Expiration date cannot be in the past',
97
+ })
98
+ .optional(),
99
+ lastTrafficResetAt: z.coerce
100
+ .date({
101
+ required_error: 'Expiration date is required',
102
+ invalid_type_error: 'Invalid expiration date format',
103
+ })
104
+ .refine(() => new Date(), {
105
+ message: 'Expiration date cannot be in the past',
106
+ })
107
+ .optional(),
90
108
  });
91
109
 
92
110
  export type Request = z.infer<typeof RequestSchema>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@remnawave/backend-contract",
3
- "version": "0.0.55",
3
+ "version": "0.0.57",
4
4
  "description": "A contract library for Remnawave",
5
5
  "main": "index.js",
6
6
  "scripts": {