"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.UpdateEnrollmentRequest$ = exports.UpdateEnrollmentRequest$outboundSchema = exports.UpdateEnrollmentRequest$inboundSchema = exports.UpdateEnrollmentRequestBody$ = exports.UpdateEnrollmentRequestBody$outboundSchema = exports.UpdateEnrollmentRequestBody$inboundSchema = exports.UpdateEnrollmentEnrollment$ = exports.UpdateEnrollmentEnrollment$outboundSchema = exports.UpdateEnrollmentEnrollment$inboundSchema = exports.UpdateEnrollmentClass$ = exports.UpdateEnrollmentClass$outboundSchema = exports.UpdateEnrollmentClass$inboundSchema = exports.UpdateEnrollmentUser$ = exports.UpdateEnrollmentUser$outboundSchema = exports.UpdateEnrollmentUser$inboundSchema = exports.UpdateEnrollmentRole$ = exports.UpdateEnrollmentRole$outboundSchema = exports.UpdateEnrollmentRole$inboundSchema = exports.UpdateEnrollmentStatus$ = exports.UpdateEnrollmentStatus$outboundSchema = exports.UpdateEnrollmentStatus$inboundSchema = exports.UpdateEnrollmentRole = exports.UpdateEnrollmentStatus = void 0;
exports.updateEnrollmentUserToJSON = updateEnrollmentUserToJSON;
exports.updateEnrollmentUserFromJSON = updateEnrollmentUserFromJSON;
exports.updateEnrollmentClassToJSON = updateEnrollmentClassToJSON;
exports.updateEnrollmentClassFromJSON = updateEnrollmentClassFromJSON;
exports.updateEnrollmentEnrollmentToJSON = updateEnrollmentEnrollmentToJSON;
exports.updateEnrollmentEnrollmentFromJSON = updateEnrollmentEnrollmentFromJSON;
exports.updateEnrollmentRequestBodyToJSON = updateEnrollmentRequestBodyToJSON;
exports.updateEnrollmentRequestBodyFromJSON = updateEnrollmentRequestBodyFromJSON;
exports.updateEnrollmentRequestToJSON = updateEnrollmentRequestToJSON;
exports.updateEnrollmentRequestFromJSON = updateEnrollmentRequestFromJSON;
const z = __importStar(require("zod"));
const primitives_js_1 = require("../../lib/primitives.js");
const schemas_js_1 = require("../../lib/schemas.js");
exports.UpdateEnrollmentStatus = {
    Active: "active",
    Tobedeleted: "tobedeleted",
};
exports.UpdateEnrollmentRole = {
    Administrator: "administrator",
    Proctor: "proctor",
    Student: "student",
    Teacher: "teacher",
};
/** @internal */
exports.UpdateEnrollmentStatus$inboundSchema = z.nativeEnum(exports.UpdateEnrollmentStatus);
/** @internal */
exports.UpdateEnrollmentStatus$outboundSchema = exports.UpdateEnrollmentStatus$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateEnrollmentStatus$;
(function (UpdateEnrollmentStatus$) {
    /** @deprecated use `UpdateEnrollmentStatus$inboundSchema` instead. */
    UpdateEnrollmentStatus$.inboundSchema = exports.UpdateEnrollmentStatus$inboundSchema;
    /** @deprecated use `UpdateEnrollmentStatus$outboundSchema` instead. */
    UpdateEnrollmentStatus$.outboundSchema = exports.UpdateEnrollmentStatus$outboundSchema;
})(UpdateEnrollmentStatus$ || (exports.UpdateEnrollmentStatus$ = UpdateEnrollmentStatus$ = {}));
/** @internal */
exports.UpdateEnrollmentRole$inboundSchema = z.nativeEnum(exports.UpdateEnrollmentRole);
/** @internal */
exports.UpdateEnrollmentRole$outboundSchema = exports.UpdateEnrollmentRole$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateEnrollmentRole$;
(function (UpdateEnrollmentRole$) {
    /** @deprecated use `UpdateEnrollmentRole$inboundSchema` instead. */
    UpdateEnrollmentRole$.inboundSchema = exports.UpdateEnrollmentRole$inboundSchema;
    /** @deprecated use `UpdateEnrollmentRole$outboundSchema` instead. */
    UpdateEnrollmentRole$.outboundSchema = exports.UpdateEnrollmentRole$outboundSchema;
})(UpdateEnrollmentRole$ || (exports.UpdateEnrollmentRole$ = UpdateEnrollmentRole$ = {}));
/** @internal */
exports.UpdateEnrollmentUser$inboundSchema = z.object({
    sourcedId: z.string(),
});
/** @internal */
exports.UpdateEnrollmentUser$outboundSchema = z.object({
    sourcedId: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateEnrollmentUser$;
(function (UpdateEnrollmentUser$) {
    /** @deprecated use `UpdateEnrollmentUser$inboundSchema` instead. */
    UpdateEnrollmentUser$.inboundSchema = exports.UpdateEnrollmentUser$inboundSchema;
    /** @deprecated use `UpdateEnrollmentUser$outboundSchema` instead. */
    UpdateEnrollmentUser$.outboundSchema = exports.UpdateEnrollmentUser$outboundSchema;
})(UpdateEnrollmentUser$ || (exports.UpdateEnrollmentUser$ = UpdateEnrollmentUser$ = {}));
function updateEnrollmentUserToJSON(updateEnrollmentUser) {
    return JSON.stringify(exports.UpdateEnrollmentUser$outboundSchema.parse(updateEnrollmentUser));
}
function updateEnrollmentUserFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateEnrollmentUser$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateEnrollmentUser' from JSON`);
}
/** @internal */
exports.UpdateEnrollmentClass$inboundSchema = z.object({
    sourcedId: z.string(),
});
/** @internal */
exports.UpdateEnrollmentClass$outboundSchema = z.object({
    sourcedId: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateEnrollmentClass$;
(function (UpdateEnrollmentClass$) {
    /** @deprecated use `UpdateEnrollmentClass$inboundSchema` instead. */
    UpdateEnrollmentClass$.inboundSchema = exports.UpdateEnrollmentClass$inboundSchema;
    /** @deprecated use `UpdateEnrollmentClass$outboundSchema` instead. */
    UpdateEnrollmentClass$.outboundSchema = exports.UpdateEnrollmentClass$outboundSchema;
})(UpdateEnrollmentClass$ || (exports.UpdateEnrollmentClass$ = UpdateEnrollmentClass$ = {}));
function updateEnrollmentClassToJSON(updateEnrollmentClass) {
    return JSON.stringify(exports.UpdateEnrollmentClass$outboundSchema.parse(updateEnrollmentClass));
}
function updateEnrollmentClassFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateEnrollmentClass$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateEnrollmentClass' from JSON`);
}
/** @internal */
exports.UpdateEnrollmentEnrollment$inboundSchema = z.object({
    sourcedId: z.string(),
    status: exports.UpdateEnrollmentStatus$inboundSchema,
    metadata: z.record(z.any()).optional(),
    role: exports.UpdateEnrollmentRole$inboundSchema,
    primary: z.boolean().default(false),
    beginDate: z.string().optional(),
    endDate: z.string().optional(),
    user: z.lazy(() => exports.UpdateEnrollmentUser$inboundSchema),
    class: z.lazy(() => exports.UpdateEnrollmentClass$inboundSchema),
});
/** @internal */
exports.UpdateEnrollmentEnrollment$outboundSchema = z.object({
    sourcedId: z.string(),
    status: exports.UpdateEnrollmentStatus$outboundSchema,
    metadata: z.record(z.any()).optional(),
    role: exports.UpdateEnrollmentRole$outboundSchema,
    primary: z.boolean().default(false),
    beginDate: z.string().optional(),
    endDate: z.string().optional(),
    user: z.lazy(() => exports.UpdateEnrollmentUser$outboundSchema),
    class: z.lazy(() => exports.UpdateEnrollmentClass$outboundSchema),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateEnrollmentEnrollment$;
(function (UpdateEnrollmentEnrollment$) {
    /** @deprecated use `UpdateEnrollmentEnrollment$inboundSchema` instead. */
    UpdateEnrollmentEnrollment$.inboundSchema = exports.UpdateEnrollmentEnrollment$inboundSchema;
    /** @deprecated use `UpdateEnrollmentEnrollment$outboundSchema` instead. */
    UpdateEnrollmentEnrollment$.outboundSchema = exports.UpdateEnrollmentEnrollment$outboundSchema;
})(UpdateEnrollmentEnrollment$ || (exports.UpdateEnrollmentEnrollment$ = UpdateEnrollmentEnrollment$ = {}));
function updateEnrollmentEnrollmentToJSON(updateEnrollmentEnrollment) {
    return JSON.stringify(exports.UpdateEnrollmentEnrollment$outboundSchema.parse(updateEnrollmentEnrollment));
}
function updateEnrollmentEnrollmentFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateEnrollmentEnrollment$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateEnrollmentEnrollment' from JSON`);
}
/** @internal */
exports.UpdateEnrollmentRequestBody$inboundSchema = z.object({
    enrollment: z.lazy(() => exports.UpdateEnrollmentEnrollment$inboundSchema),
});
/** @internal */
exports.UpdateEnrollmentRequestBody$outboundSchema = z.object({
    enrollment: z.lazy(() => exports.UpdateEnrollmentEnrollment$outboundSchema),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateEnrollmentRequestBody$;
(function (UpdateEnrollmentRequestBody$) {
    /** @deprecated use `UpdateEnrollmentRequestBody$inboundSchema` instead. */
    UpdateEnrollmentRequestBody$.inboundSchema = exports.UpdateEnrollmentRequestBody$inboundSchema;
    /** @deprecated use `UpdateEnrollmentRequestBody$outboundSchema` instead. */
    UpdateEnrollmentRequestBody$.outboundSchema = exports.UpdateEnrollmentRequestBody$outboundSchema;
})(UpdateEnrollmentRequestBody$ || (exports.UpdateEnrollmentRequestBody$ = UpdateEnrollmentRequestBody$ = {}));
function updateEnrollmentRequestBodyToJSON(updateEnrollmentRequestBody) {
    return JSON.stringify(exports.UpdateEnrollmentRequestBody$outboundSchema.parse(updateEnrollmentRequestBody));
}
function updateEnrollmentRequestBodyFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateEnrollmentRequestBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateEnrollmentRequestBody' from JSON`);
}
/** @internal */
exports.UpdateEnrollmentRequest$inboundSchema = z.object({
    sourcedId: z.string(),
    RequestBody: z.lazy(() => exports.UpdateEnrollmentRequestBody$inboundSchema)
        .optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "RequestBody": "requestBody",
    });
});
/** @internal */
exports.UpdateEnrollmentRequest$outboundSchema = z.object({
    sourcedId: z.string(),
    requestBody: z.lazy(() => exports.UpdateEnrollmentRequestBody$outboundSchema)
        .optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        requestBody: "RequestBody",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateEnrollmentRequest$;
(function (UpdateEnrollmentRequest$) {
    /** @deprecated use `UpdateEnrollmentRequest$inboundSchema` instead. */
    UpdateEnrollmentRequest$.inboundSchema = exports.UpdateEnrollmentRequest$inboundSchema;
    /** @deprecated use `UpdateEnrollmentRequest$outboundSchema` instead. */
    UpdateEnrollmentRequest$.outboundSchema = exports.UpdateEnrollmentRequest$outboundSchema;
})(UpdateEnrollmentRequest$ || (exports.UpdateEnrollmentRequest$ = UpdateEnrollmentRequest$ = {}));
function updateEnrollmentRequestToJSON(updateEnrollmentRequest) {
    return JSON.stringify(exports.UpdateEnrollmentRequest$outboundSchema.parse(updateEnrollmentRequest));
}
function updateEnrollmentRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateEnrollmentRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateEnrollmentRequest' from JSON`);
}
//# sourceMappingURL=updateenrollment.js.map