"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.GetGradingPeriodsForTermResponse$ = exports.GetGradingPeriodsForTermResponse$outboundSchema = exports.GetGradingPeriodsForTermResponse$inboundSchema = exports.GetGradingPeriodsForTermResponseBody$ = exports.GetGradingPeriodsForTermResponseBody$outboundSchema = exports.GetGradingPeriodsForTermResponseBody$inboundSchema = exports.GetGradingPeriodsForTermRequest$ = exports.GetGradingPeriodsForTermRequest$outboundSchema = exports.GetGradingPeriodsForTermRequest$inboundSchema = exports.GetGradingPeriodsForTermOrderBy$ = exports.GetGradingPeriodsForTermOrderBy$outboundSchema = exports.GetGradingPeriodsForTermOrderBy$inboundSchema = exports.GetGradingPeriodsForTermOrderBy = void 0;
exports.getGradingPeriodsForTermRequestToJSON = getGradingPeriodsForTermRequestToJSON;
exports.getGradingPeriodsForTermRequestFromJSON = getGradingPeriodsForTermRequestFromJSON;
exports.getGradingPeriodsForTermResponseBodyToJSON = getGradingPeriodsForTermResponseBodyToJSON;
exports.getGradingPeriodsForTermResponseBodyFromJSON = getGradingPeriodsForTermResponseBodyFromJSON;
exports.getGradingPeriodsForTermResponseToJSON = getGradingPeriodsForTermResponseToJSON;
exports.getGradingPeriodsForTermResponseFromJSON = getGradingPeriodsForTermResponseFromJSON;
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.GetGradingPeriodsForTermOrderBy = {
    Asc: "asc",
    Desc: "desc",
};
/** @internal */
exports.GetGradingPeriodsForTermOrderBy$inboundSchema = z.nativeEnum(exports.GetGradingPeriodsForTermOrderBy);
/** @internal */
exports.GetGradingPeriodsForTermOrderBy$outboundSchema = exports.GetGradingPeriodsForTermOrderBy$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var GetGradingPeriodsForTermOrderBy$;
(function (GetGradingPeriodsForTermOrderBy$) {
    /** @deprecated use `GetGradingPeriodsForTermOrderBy$inboundSchema` instead. */
    GetGradingPeriodsForTermOrderBy$.inboundSchema = exports.GetGradingPeriodsForTermOrderBy$inboundSchema;
    /** @deprecated use `GetGradingPeriodsForTermOrderBy$outboundSchema` instead. */
    GetGradingPeriodsForTermOrderBy$.outboundSchema = exports.GetGradingPeriodsForTermOrderBy$outboundSchema;
})(GetGradingPeriodsForTermOrderBy$ || (exports.GetGradingPeriodsForTermOrderBy$ = GetGradingPeriodsForTermOrderBy$ = {}));
/** @internal */
exports.GetGradingPeriodsForTermRequest$inboundSchema = z.object({
    termSourcedId: z.string(),
    fields: z.string().optional(),
    limit: z.number().int().default(100),
    offset: z.number().int().default(0),
    sort: z.string().optional(),
    orderBy: exports.GetGradingPeriodsForTermOrderBy$inboundSchema.optional(),
    filter: z.string().optional(),
    search: z.string().optional(),
});
/** @internal */
exports.GetGradingPeriodsForTermRequest$outboundSchema = z.object({
    termSourcedId: z.string(),
    fields: z.string().optional(),
    limit: z.number().int().default(100),
    offset: z.number().int().default(0),
    sort: z.string().optional(),
    orderBy: exports.GetGradingPeriodsForTermOrderBy$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 GetGradingPeriodsForTermRequest$;
(function (GetGradingPeriodsForTermRequest$) {
    /** @deprecated use `GetGradingPeriodsForTermRequest$inboundSchema` instead. */
    GetGradingPeriodsForTermRequest$.inboundSchema = exports.GetGradingPeriodsForTermRequest$inboundSchema;
    /** @deprecated use `GetGradingPeriodsForTermRequest$outboundSchema` instead. */
    GetGradingPeriodsForTermRequest$.outboundSchema = exports.GetGradingPeriodsForTermRequest$outboundSchema;
})(GetGradingPeriodsForTermRequest$ || (exports.GetGradingPeriodsForTermRequest$ = GetGradingPeriodsForTermRequest$ = {}));
function getGradingPeriodsForTermRequestToJSON(getGradingPeriodsForTermRequest) {
    return JSON.stringify(exports.GetGradingPeriodsForTermRequest$outboundSchema.parse(getGradingPeriodsForTermRequest));
}
function getGradingPeriodsForTermRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.GetGradingPeriodsForTermRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetGradingPeriodsForTermRequest' from JSON`);
}
/** @internal */
exports.GetGradingPeriodsForTermResponseBody$inboundSchema = z.object({
    gradingPeriods: z.array(components.AcademicSession$inboundSchema),
    totalCount: z.number(),
    pageCount: z.number(),
    pageNumber: z.number(),
    offset: z.number(),
    limit: z.number(),
});
/** @internal */
exports.GetGradingPeriodsForTermResponseBody$outboundSchema = z.object({
    gradingPeriods: z.array(components.AcademicSession$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 GetGradingPeriodsForTermResponseBody$;
(function (GetGradingPeriodsForTermResponseBody$) {
    /** @deprecated use `GetGradingPeriodsForTermResponseBody$inboundSchema` instead. */
    GetGradingPeriodsForTermResponseBody$.inboundSchema = exports.GetGradingPeriodsForTermResponseBody$inboundSchema;
    /** @deprecated use `GetGradingPeriodsForTermResponseBody$outboundSchema` instead. */
    GetGradingPeriodsForTermResponseBody$.outboundSchema = exports.GetGradingPeriodsForTermResponseBody$outboundSchema;
})(GetGradingPeriodsForTermResponseBody$ || (exports.GetGradingPeriodsForTermResponseBody$ = GetGradingPeriodsForTermResponseBody$ = {}));
function getGradingPeriodsForTermResponseBodyToJSON(getGradingPeriodsForTermResponseBody) {
    return JSON.stringify(exports.GetGradingPeriodsForTermResponseBody$outboundSchema.parse(getGradingPeriodsForTermResponseBody));
}
function getGradingPeriodsForTermResponseBodyFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.GetGradingPeriodsForTermResponseBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetGradingPeriodsForTermResponseBody' from JSON`);
}
/** @internal */
exports.GetGradingPeriodsForTermResponse$inboundSchema = z.object({
    Result: z.lazy(() => exports.GetGradingPeriodsForTermResponseBody$inboundSchema),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "Result": "result",
    });
});
/** @internal */
exports.GetGradingPeriodsForTermResponse$outboundSchema = z.object({
    result: z.lazy(() => exports.GetGradingPeriodsForTermResponseBody$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 GetGradingPeriodsForTermResponse$;
(function (GetGradingPeriodsForTermResponse$) {
    /** @deprecated use `GetGradingPeriodsForTermResponse$inboundSchema` instead. */
    GetGradingPeriodsForTermResponse$.inboundSchema = exports.GetGradingPeriodsForTermResponse$inboundSchema;
    /** @deprecated use `GetGradingPeriodsForTermResponse$outboundSchema` instead. */
    GetGradingPeriodsForTermResponse$.outboundSchema = exports.GetGradingPeriodsForTermResponse$outboundSchema;
})(GetGradingPeriodsForTermResponse$ || (exports.GetGradingPeriodsForTermResponse$ = GetGradingPeriodsForTermResponse$ = {}));
function getGradingPeriodsForTermResponseToJSON(getGradingPeriodsForTermResponse) {
    return JSON.stringify(exports.GetGradingPeriodsForTermResponse$outboundSchema.parse(getGradingPeriodsForTermResponse));
}
function getGradingPeriodsForTermResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.GetGradingPeriodsForTermResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetGradingPeriodsForTermResponse' from JSON`);
}
//# sourceMappingURL=getgradingperiodsforterm.js.map