Remnawave_Node/libs/contract/commands/plugin/nftables/block-ips.schema.ts
kastov 9cd01fce62
Some checks failed
Build & Push Docker Image / Send TG message (push) Has been cancelled
Build & Push Docker Image / Build linux/amd64 (push) Has been cancelled
Build & Push Docker Image / Build linux/arm64 (push) Has been cancelled
Deploy lib / Send Telegram message (push) Has been cancelled
Deploy lib / build (push) Has been cancelled
Build & Push Docker Image / Merge & push manifest (push) Has been cancelled
Build & Push Docker Image / Send TG message-1 (push) Has been cancelled
Build & Push Docker Image / notify-on-error (push) Has been cancelled
Deploy lib / Send Telegram message-1 (push) Has been cancelled
Deploy lib / notify-on-error (push) Has been cancelled
chore: upgrade zod
2026-07-04 17:38:39 +03:00

26 lines
625 B
TypeScript

import { z } from 'zod';
import { REST_API } from '../../../api';
export namespace BlockIpsCommand {
export const url = REST_API.PLUGIN.NFTABLES.BLOCK_IPS;
export const RequestSchema = z.object({
ips: z.array(
z.object({
ip: z.union([z.ipv4(), z.ipv6()]),
timeout: z.number(),
}),
),
});
export type Request = z.infer<typeof RequestSchema>;
export const ResponseSchema = z.object({
response: z.object({
accepted: z.boolean(),
}),
});
export type Response = z.infer<typeof ResponseSchema>;
}