Remnawave_Node/libs/contract/commands/stats/get-users-stats.command.ts
kastov 265e05c0ea
chore: bump version to 0.4.7 and update dependencies
- Updated package version from 0.4.6 to 0.4.7 in package.json and package-lock.json.
- Upgraded NestJS dependencies to versions 10.4.15 for common, core, and platform-express.
- Enhanced ESLint configuration by adding 'eslint-plugin-paths' and 'eslint-plugin-perfectionist' for improved code quality.
- Reorganized export statements in contract library files for better clarity and consistency.
- Improved error handling and logging in various modules, including Xray and Stats services.
- Refactored command and DTO structures for better maintainability and readability.
2024-12-23 01:27:22 +03:00

26 lines
669 B
TypeScript

import { z } from 'zod';
import { REST_API } from '../../api';
export namespace GetUsersStatsCommand {
export const url = REST_API.STATS.GET_USERS_STATS;
export const RequestSchema = z.object({
reset: z.boolean(),
});
export type Request = z.infer<typeof RequestSchema>;
export const ResponseSchema = z.object({
response: z.object({
users: z.array(
z.object({
username: z.string(),
downlink: z.number(),
uplink: z.number(),
}),
),
}),
});
export type Response = z.infer<typeof ResponseSchema>;
}