import * as t from 'io-ts';

export const SamplePostRequest = {
    path1: t.string,
    path2: t.number,
    path3: t.boolean,
    path4: t.literal('literal'),
};

export const SampleGetResponse = t.type({
    response1: t.string,
    response2: t.type({
        nested1: t.number,
        nested2: t.boolean,
    })
});

export enum SampleEnum {
    Value1 = 'value1',
    Value2 = 'value2',
}

export const SampleEnumType = t.keyof(SampleEnum, "SampleEnum");
export type SampleEnumType = t.TypeOf<typeof SampleEnumType>;

export const SampleUnion = t.union([t.string, t.number]);
