"use strict";
/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    var desc = Object.getOwnPropertyDescriptor(m, k);
    if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
      desc = { enumerable: true, get: function() { return m[k]; } };
    }
    Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || (function () {
    var ownKeys = function(o) {
        ownKeys = Object.getOwnPropertyNames || function (o) {
            var ar = [];
            for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
            return ar;
        };
        return ownKeys(o);
    };
    return function (mod) {
        if (mod && mod.__esModule) return mod;
        var result = {};
        if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
        __setModuleDefault(result, mod);
        return result;
    };
})();
Object.defineProperty(exports, "__esModule", { value: true });
exports.GetResultsForClassResponse$ = exports.GetResultsForClassResponse$outboundSchema = exports.GetResultsForClassResponse$inboundSchema = exports.GetResultsForClassResponseBody$ = exports.GetResultsForClassResponseBody$outboundSchema = exports.GetResultsForClassResponseBody$inboundSchema = exports.GetResultsForClassRequest$ = exports.GetResultsForClassRequest$outboundSchema = exports.GetResultsForClassRequest$inboundSchema = exports.GetResultsForClassOrderBy$ = exports.GetResultsForClassOrderBy$outboundSchema = exports.GetResultsForClassOrderBy$inboundSchema = exports.GetResultsForClassOrderBy = void 0;
exports.getResultsForClassRequestToJSON = getResultsForClassRequestToJSON;
exports.getResultsForClassRequestFromJSON = getResultsForClassRequestFromJSON;
exports.getResultsForClassResponseBodyToJSON = getResultsForClassResponseBodyToJSON;
exports.getResultsForClassResponseBodyFromJSON = getResultsForClassResponseBodyFromJSON;
exports.getResultsForClassResponseToJSON = getResultsForClassResponseToJSON;
exports.getResultsForClassResponseFromJSON = getResultsForClassResponseFromJSON;
const z = __importStar(require("zod"));
const primitives_js_1 = require("../../lib/primitives.js");
const schemas_js_1 = require("../../lib/schemas.js");
const components = __importStar(require("../components/index.js"));
/**
 * The order to sort the response by
 */
exports.GetResultsForClassOrderBy = {
    Asc: "asc",
    Desc: "desc",
};
/** @internal */
exports.GetResultsForClassOrderBy$inboundSchema = z.nativeEnum(exports.GetResultsForClassOrderBy);
/** @internal */
exports.GetResultsForClassOrderBy$outboundSchema = exports.GetResultsForClassOrderBy$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var GetResultsForClassOrderBy$;
(function (GetResultsForClassOrderBy$) {
    /** @deprecated use `GetResultsForClassOrderBy$inboundSchema` instead. */
    GetResultsForClassOrderBy$.inboundSchema = exports.GetResultsForClassOrderBy$inboundSchema;
    /** @deprecated use `GetResultsForClassOrderBy$outboundSchema` instead. */
    GetResultsForClassOrderBy$.outboundSchema = exports.GetResultsForClassOrderBy$outboundSchema;
})(GetResultsForClassOrderBy$ || (exports.GetResultsForClassOrderBy$ = GetResultsForClassOrderBy$ = {}));
/** @internal */
exports.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: exports.GetResultsForClassOrderBy$inboundSchema.optional(),
    filter: z.string().optional(),
    search: z.string().optional(),
});
/** @internal */
exports.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: exports.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.
 */
var GetResultsForClassRequest$;
(function (GetResultsForClassRequest$) {
    /** @deprecated use `GetResultsForClassRequest$inboundSchema` instead. */
    GetResultsForClassRequest$.inboundSchema = exports.GetResultsForClassRequest$inboundSchema;
    /** @deprecated use `GetResultsForClassRequest$outboundSchema` instead. */
    GetResultsForClassRequest$.outboundSchema = exports.GetResultsForClassRequest$outboundSchema;
})(GetResultsForClassRequest$ || (exports.GetResultsForClassRequest$ = GetResultsForClassRequest$ = {}));
function getResultsForClassRequestToJSON(getResultsForClassRequest) {
    return JSON.stringify(exports.GetResultsForClassRequest$outboundSchema.parse(getResultsForClassRequest));
}
function getResultsForClassRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.GetResultsForClassRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetResultsForClassRequest' from JSON`);
}
/** @internal */
exports.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 */
exports.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.
 */
var GetResultsForClassResponseBody$;
(function (GetResultsForClassResponseBody$) {
    /** @deprecated use `GetResultsForClassResponseBody$inboundSchema` instead. */
    GetResultsForClassResponseBody$.inboundSchema = exports.GetResultsForClassResponseBody$inboundSchema;
    /** @deprecated use `GetResultsForClassResponseBody$outboundSchema` instead. */
    GetResultsForClassResponseBody$.outboundSchema = exports.GetResultsForClassResponseBody$outboundSchema;
})(GetResultsForClassResponseBody$ || (exports.GetResultsForClassResponseBody$ = GetResultsForClassResponseBody$ = {}));
function getResultsForClassResponseBodyToJSON(getResultsForClassResponseBody) {
    return JSON.stringify(exports.GetResultsForClassResponseBody$outboundSchema.parse(getResultsForClassResponseBody));
}
function getResultsForClassResponseBodyFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.GetResultsForClassResponseBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetResultsForClassResponseBody' from JSON`);
}
/** @internal */
exports.GetResultsForClassResponse$inboundSchema = z.object({
    Result: z.lazy(() => exports.GetResultsForClassResponseBody$inboundSchema),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "Result": "result",
    });
});
/** @internal */
exports.GetResultsForClassResponse$outboundSchema = z.object({
    result: z.lazy(() => exports.GetResultsForClassResponseBody$outboundSchema),
}).transform((v) => {
    return (0, primitives_js_1.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.
 */
var GetResultsForClassResponse$;
(function (GetResultsForClassResponse$) {
    /** @deprecated use `GetResultsForClassResponse$inboundSchema` instead. */
    GetResultsForClassResponse$.inboundSchema = exports.GetResultsForClassResponse$inboundSchema;
    /** @deprecated use `GetResultsForClassResponse$outboundSchema` instead. */
    GetResultsForClassResponse$.outboundSchema = exports.GetResultsForClassResponse$outboundSchema;
})(GetResultsForClassResponse$ || (exports.GetResultsForClassResponse$ = GetResultsForClassResponse$ = {}));
function getResultsForClassResponseToJSON(getResultsForClassResponse) {
    return JSON.stringify(exports.GetResultsForClassResponse$outboundSchema.parse(getResultsForClassResponse));
}
function getResultsForClassResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.GetResultsForClassResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetResultsForClassResponse' from JSON`);
}
//# sourceMappingURL=getresultsforclass.js.map