import * as t from 'io-ts' ; import { id , descriptionOrUndefined , Description , platformOrUndefined , query , versionOrUndefined , interval , ecsMappingOrUndefined , } from '../../common/schemas' ; import { RequiredKeepUndefined } from '../../../types' ; export const createSavedQueryRequestSchema = t . type ( { id , description : descriptionOrUndefined , platform : platformOrUndefined , query , version : versionOrUndefined , interval , ecs_mapping : ecsMappingOrUndefined , } ) ; export type CreateSavedQueryRequestSchema = t . OutputOf < typeof createSavedQueryRequestSchema > ; export type CreateSavedQueryRequestSchemaDecoded = Omit < RequiredKeepUndefined < t . TypeOf < typeof createSavedQueryRequestSchema > > , 'description' > & { description : Description ; } ;