/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
import * as z from "zod";
import { remap as remap$ } from "../../lib/primitives.js";
import { safeParse } from "../../lib/schemas.js";
import * as components from "../components/index.js";
/**
 * The order to sort the response by
 */
export const GetResultsForClassOrderBy = {
    Asc: "asc",
    Desc: "desc",
};
/** @internal */
export const GetResultsForClassOrderBy$inboundSchema = z.nativeEnum(GetResultsForClassOrderBy);
/** @internal */
export const GetResultsForClassOrderBy$outboundSchema = GetResultsForClassOrderBy$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var GetResultsForClassOrderBy$;
(function (GetResultsForClassOrderBy$) {
    /** @deprecated use `GetResultsForClassOrderBy$inboundSchema` instead. */
    GetResultsForClassOrderBy$.inboundSchema = GetResultsForClassOrderBy$inboundSchema;
    /** @deprecated use `GetResultsForClassOrderBy$outboundSchema` instead. */
    GetResultsForClassOrderBy$.outboundSchema = GetResultsForClassOrderBy$outboundSchema;
})(GetResultsForClassOrderBy$ || (GetResultsForClassOrderBy$ = {}));
/** @internal */
export const GetResultsForClassRequest$inboundSchema = z.object({
    sourcedId: z.string(),
    fields: z.string().optional(),
    limit: z.number().int().default(100),
    offset: z.number().int().default(0),
    sort: z.string().optional(),
    orderBy: GetResultsForClassOrderBy$inboundSchema.optional(),
    filter: z.string().optional(),
    search: z.string().optional(),
});
/** @internal */
export const GetResultsForClassRequest$outboundSchema = z.object({
    sourcedId: z.string(),
    fields: z.string().optional(),
    limit: z.number().int().default(100),
    offset: z.number().int().default(0),
    sort: z.string().optional(),
    orderBy: GetResultsForClassOrderBy$outboundSchema.optional(),
    filter: z.string().optional(),
    search: z.string().optional(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var GetResultsForClassRequest$;
(function (GetResultsForClassRequest$) {
    /** @deprecated use `GetResultsForClassRequest$inboundSchema` instead. */
    GetResultsForClassRequest$.inboundSchema = GetResultsForClassRequest$inboundSchema;
    /** @deprecated use `GetResultsForClassRequest$outboundSchema` instead. */
    GetResultsForClassRequest$.outboundSchema = GetResultsForClassRequest$outboundSchema;
})(GetResultsForClassRequest$ || (GetResultsForClassRequest$ = {}));
export function getResultsForClassRequestToJSON(getResultsForClassRequest) {
    return JSON.stringify(GetResultsForClassRequest$outboundSchema.parse(getResultsForClassRequest));
}
export function getResultsForClassRequestFromJSON(jsonString) {
    return safeParse(jsonString, (x) => GetResultsForClassRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetResultsForClassRequest' from JSON`);
}
/** @internal */
export const GetResultsForClassResponseBody$inboundSchema = z.object({
    results: z.array(components.Result$inboundSchema),
    totalCount: z.number(),
    pageCount: z.number(),
    pageNumber: z.number(),
    offset: z.number(),
    limit: z.number(),
});
/** @internal */
export const GetResultsForClassResponseBody$outboundSchema = z.object({
    results: z.array(components.Result$outboundSchema),
    totalCount: z.number(),
    pageCount: z.number(),
    pageNumber: z.number(),
    offset: z.number(),
    limit: z.number(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var GetResultsForClassResponseBody$;
(function (GetResultsForClassResponseBody$) {
    /** @deprecated use `GetResultsForClassResponseBody$inboundSchema` instead. */
    GetResultsForClassResponseBody$.inboundSchema = GetResultsForClassResponseBody$inboundSchema;
    /** @deprecated use `GetResultsForClassResponseBody$outboundSchema` instead. */
    GetResultsForClassResponseBody$.outboundSchema = GetResultsForClassResponseBody$outboundSchema;
})(GetResultsForClassResponseBody$ || (GetResultsForClassResponseBody$ = {}));
export function getResultsForClassResponseBodyToJSON(getResultsForClassResponseBody) {
    return JSON.stringify(GetResultsForClassResponseBody$outboundSchema.parse(getResultsForClassResponseBody));
}
export function getResultsForClassResponseBodyFromJSON(jsonString) {
    return safeParse(jsonString, (x) => GetResultsForClassResponseBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetResultsForClassResponseBody' from JSON`);
}
/** @internal */
export const GetResultsForClassResponse$inboundSchema = z.object({
    Result: z.lazy(() => GetResultsForClassResponseBody$inboundSchema),
}).transform((v) => {
    return remap$(v, {
        "Result": "result",
    });
});
/** @internal */
export const GetResultsForClassResponse$outboundSchema = z.object({
    result: z.lazy(() => GetResultsForClassResponseBody$outboundSchema),
}).transform((v) => {
    return remap$(v, {
        result: "Result",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var GetResultsForClassResponse$;
(function (GetResultsForClassResponse$) {
    /** @deprecated use `GetResultsForClassResponse$inboundSchema` instead. */
    GetResultsForClassResponse$.inboundSchema = GetResultsForClassResponse$inboundSchema;
    /** @deprecated use `GetResultsForClassResponse$outboundSchema` instead. */
    GetResultsForClassResponse$.outboundSchema = GetResultsForClassResponse$outboundSchema;
})(GetResultsForClassResponse$ || (GetResultsForClassResponse$ = {}));
export function getResultsForClassResponseToJSON(getResultsForClassResponse) {
    return JSON.stringify(GetResultsForClassResponse$outboundSchema.parse(getResultsForClassResponse));
}
export function getResultsForClassResponseFromJSON(jsonString) {
    return safeParse(jsonString, (x) => GetResultsForClassResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetResultsForClassResponse' from JSON`);
}
//# sourceMappingURL=getresultsforclass.js.map