import { object, string, minLength, optional, number, picklist } from "valibot";

export const AddWatchlistItemSchema = object({
  type: picklist(["email", "phoneNumber", "ssn", "address", "domain"]),
  value: string([minLength(1)]),
});

export const RemoveWatchlistItemSchema = object({
  itemId: string([minLength(1)]),
});

export const ExposureFilterSchema = object({
  severity: optional(picklist(["info", "warning", "critical"])),
  source: optional(picklist(["hibp", "securityTrails", "censys", "darkWebForum", "shodan", "honeypot"])),
  page: optional(number(), 1),
  limit: optional(number(), 20),
});

export const ExposureDetailsSchema = object({
  exposureId: string([minLength(1)]),
});

export const RunScanSchema = object({});

export const ReportFilterSchema = object({
  page: optional(number(), 1),
  limit: optional(number(), 20),
});
