import { array , lazy , object , optional , Schema } from '../schema' ; import { Employee , employeeSchema } from './employee' ; import { Error , errorSchema } from './error' ; export interface RetrieveEmployeeResponse { /** An employee object that is used by the external API. */ employee ? : Employee ; /** Any errors that occurred during the request. */ errors ? : Error [ ] ; } export const retrieveEmployeeResponseSchema = object ( { employee : [ 'employee' , optional ( lazy ( ( ) => employeeSchema ) ) ] , errors : [ 'errors' , optional ( array ( lazy ( ( ) => errorSchema ) ) ) ] , } ) ;