"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.CreateComponentResourceResponse$ = exports.CreateComponentResourceResponse$outboundSchema = exports.CreateComponentResourceResponse$inboundSchema = exports.CreateComponentResourceSourcedIdPairs$ = exports.CreateComponentResourceSourcedIdPairs$outboundSchema = exports.CreateComponentResourceSourcedIdPairs$inboundSchema = exports.CreateComponentResourceRequest$ = exports.CreateComponentResourceRequest$outboundSchema = exports.CreateComponentResourceRequest$inboundSchema = exports.CreateComponentResourceComponentResource$ = exports.CreateComponentResourceComponentResource$outboundSchema = exports.CreateComponentResourceComponentResource$inboundSchema = exports.CreateComponentResourceResource$ = exports.CreateComponentResourceResource$outboundSchema = exports.CreateComponentResourceResource$inboundSchema = exports.CreateComponentResourceCourseComponent$ = exports.CreateComponentResourceCourseComponent$outboundSchema = exports.CreateComponentResourceCourseComponent$inboundSchema = exports.CreateComponentResourceStatus$ = exports.CreateComponentResourceStatus$outboundSchema = exports.CreateComponentResourceStatus$inboundSchema = exports.CreateComponentResourceStatus = void 0;
exports.createComponentResourceCourseComponentToJSON = createComponentResourceCourseComponentToJSON;
exports.createComponentResourceCourseComponentFromJSON = createComponentResourceCourseComponentFromJSON;
exports.createComponentResourceResourceToJSON = createComponentResourceResourceToJSON;
exports.createComponentResourceResourceFromJSON = createComponentResourceResourceFromJSON;
exports.createComponentResourceComponentResourceToJSON = createComponentResourceComponentResourceToJSON;
exports.createComponentResourceComponentResourceFromJSON = createComponentResourceComponentResourceFromJSON;
exports.createComponentResourceRequestToJSON = createComponentResourceRequestToJSON;
exports.createComponentResourceRequestFromJSON = createComponentResourceRequestFromJSON;
exports.createComponentResourceSourcedIdPairsToJSON = createComponentResourceSourcedIdPairsToJSON;
exports.createComponentResourceSourcedIdPairsFromJSON = createComponentResourceSourcedIdPairsFromJSON;
exports.createComponentResourceResponseToJSON = createComponentResourceResponseToJSON;
exports.createComponentResourceResponseFromJSON = createComponentResourceResponseFromJSON;
const z = __importStar(require("zod"));
const schemas_js_1 = require("../../lib/schemas.js");
exports.CreateComponentResourceStatus = {
    Active: "active",
    Tobedeleted: "tobedeleted",
};
/** @internal */
exports.CreateComponentResourceStatus$inboundSchema = z.nativeEnum(exports.CreateComponentResourceStatus);
/** @internal */
exports.CreateComponentResourceStatus$outboundSchema = exports.CreateComponentResourceStatus$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CreateComponentResourceStatus$;
(function (CreateComponentResourceStatus$) {
    /** @deprecated use `CreateComponentResourceStatus$inboundSchema` instead. */
    CreateComponentResourceStatus$.inboundSchema = exports.CreateComponentResourceStatus$inboundSchema;
    /** @deprecated use `CreateComponentResourceStatus$outboundSchema` instead. */
    CreateComponentResourceStatus$.outboundSchema = exports.CreateComponentResourceStatus$outboundSchema;
})(CreateComponentResourceStatus$ || (exports.CreateComponentResourceStatus$ = CreateComponentResourceStatus$ = {}));
/** @internal */
exports.CreateComponentResourceCourseComponent$inboundSchema = z.object({
    sourcedId: z.string(),
});
/** @internal */
exports.CreateComponentResourceCourseComponent$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 CreateComponentResourceCourseComponent$;
(function (CreateComponentResourceCourseComponent$) {
    /** @deprecated use `CreateComponentResourceCourseComponent$inboundSchema` instead. */
    CreateComponentResourceCourseComponent$.inboundSchema = exports.CreateComponentResourceCourseComponent$inboundSchema;
    /** @deprecated use `CreateComponentResourceCourseComponent$outboundSchema` instead. */
    CreateComponentResourceCourseComponent$.outboundSchema = exports.CreateComponentResourceCourseComponent$outboundSchema;
})(CreateComponentResourceCourseComponent$ || (exports.CreateComponentResourceCourseComponent$ = CreateComponentResourceCourseComponent$ = {}));
function createComponentResourceCourseComponentToJSON(createComponentResourceCourseComponent) {
    return JSON.stringify(exports.CreateComponentResourceCourseComponent$outboundSchema.parse(createComponentResourceCourseComponent));
}
function createComponentResourceCourseComponentFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateComponentResourceCourseComponent$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateComponentResourceCourseComponent' from JSON`);
}
/** @internal */
exports.CreateComponentResourceResource$inboundSchema = z.object({
    sourcedId: z.string(),
});
/** @internal */
exports.CreateComponentResourceResource$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 CreateComponentResourceResource$;
(function (CreateComponentResourceResource$) {
    /** @deprecated use `CreateComponentResourceResource$inboundSchema` instead. */
    CreateComponentResourceResource$.inboundSchema = exports.CreateComponentResourceResource$inboundSchema;
    /** @deprecated use `CreateComponentResourceResource$outboundSchema` instead. */
    CreateComponentResourceResource$.outboundSchema = exports.CreateComponentResourceResource$outboundSchema;
})(CreateComponentResourceResource$ || (exports.CreateComponentResourceResource$ = CreateComponentResourceResource$ = {}));
function createComponentResourceResourceToJSON(createComponentResourceResource) {
    return JSON.stringify(exports.CreateComponentResourceResource$outboundSchema.parse(createComponentResourceResource));
}
function createComponentResourceResourceFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateComponentResourceResource$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateComponentResourceResource' from JSON`);
}
/** @internal */
exports.CreateComponentResourceComponentResource$inboundSchema = z.object({
    sourcedId: z.string(),
    status: exports.CreateComponentResourceStatus$inboundSchema,
    dateLastModified: z.string().datetime({ offset: true }).transform(v => new Date(v)).optional(),
    metadata: z.nullable(z.record(z.any())).optional(),
    courseComponent: z.lazy(() => exports.CreateComponentResourceCourseComponent$inboundSchema),
    resource: z.lazy(() => exports.CreateComponentResourceResource$inboundSchema),
    title: z.string(),
    sortOrder: z.number().default(0),
});
/** @internal */
exports.CreateComponentResourceComponentResource$outboundSchema = z.object({
    sourcedId: z.string(),
    status: exports.CreateComponentResourceStatus$outboundSchema,
    dateLastModified: z.date().transform(v => v.toISOString()).optional(),
    metadata: z.nullable(z.record(z.any())).optional(),
    courseComponent: z.lazy(() => exports.CreateComponentResourceCourseComponent$outboundSchema),
    resource: z.lazy(() => exports.CreateComponentResourceResource$outboundSchema),
    title: z.string(),
    sortOrder: z.number().default(0),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CreateComponentResourceComponentResource$;
(function (CreateComponentResourceComponentResource$) {
    /** @deprecated use `CreateComponentResourceComponentResource$inboundSchema` instead. */
    CreateComponentResourceComponentResource$.inboundSchema = exports.CreateComponentResourceComponentResource$inboundSchema;
    /** @deprecated use `CreateComponentResourceComponentResource$outboundSchema` instead. */
    CreateComponentResourceComponentResource$.outboundSchema = exports.CreateComponentResourceComponentResource$outboundSchema;
})(CreateComponentResourceComponentResource$ || (exports.CreateComponentResourceComponentResource$ = CreateComponentResourceComponentResource$ = {}));
function createComponentResourceComponentResourceToJSON(createComponentResourceComponentResource) {
    return JSON.stringify(exports.CreateComponentResourceComponentResource$outboundSchema.parse(createComponentResourceComponentResource));
}
function createComponentResourceComponentResourceFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateComponentResourceComponentResource$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateComponentResourceComponentResource' from JSON`);
}
/** @internal */
exports.CreateComponentResourceRequest$inboundSchema = z.object({
    componentResource: z.lazy(() => exports.CreateComponentResourceComponentResource$inboundSchema),
});
/** @internal */
exports.CreateComponentResourceRequest$outboundSchema = z.object({
    componentResource: z.lazy(() => exports.CreateComponentResourceComponentResource$outboundSchema),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CreateComponentResourceRequest$;
(function (CreateComponentResourceRequest$) {
    /** @deprecated use `CreateComponentResourceRequest$inboundSchema` instead. */
    CreateComponentResourceRequest$.inboundSchema = exports.CreateComponentResourceRequest$inboundSchema;
    /** @deprecated use `CreateComponentResourceRequest$outboundSchema` instead. */
    CreateComponentResourceRequest$.outboundSchema = exports.CreateComponentResourceRequest$outboundSchema;
})(CreateComponentResourceRequest$ || (exports.CreateComponentResourceRequest$ = CreateComponentResourceRequest$ = {}));
function createComponentResourceRequestToJSON(createComponentResourceRequest) {
    return JSON.stringify(exports.CreateComponentResourceRequest$outboundSchema.parse(createComponentResourceRequest));
}
function createComponentResourceRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateComponentResourceRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateComponentResourceRequest' from JSON`);
}
/** @internal */
exports.CreateComponentResourceSourcedIdPairs$inboundSchema = z.object({
    suppliedSourcedId: z.string(),
    allocatedSourcedId: z.string(),
});
/** @internal */
exports.CreateComponentResourceSourcedIdPairs$outboundSchema = z.object({
    suppliedSourcedId: z.string(),
    allocatedSourcedId: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CreateComponentResourceSourcedIdPairs$;
(function (CreateComponentResourceSourcedIdPairs$) {
    /** @deprecated use `CreateComponentResourceSourcedIdPairs$inboundSchema` instead. */
    CreateComponentResourceSourcedIdPairs$.inboundSchema = exports.CreateComponentResourceSourcedIdPairs$inboundSchema;
    /** @deprecated use `CreateComponentResourceSourcedIdPairs$outboundSchema` instead. */
    CreateComponentResourceSourcedIdPairs$.outboundSchema = exports.CreateComponentResourceSourcedIdPairs$outboundSchema;
})(CreateComponentResourceSourcedIdPairs$ || (exports.CreateComponentResourceSourcedIdPairs$ = CreateComponentResourceSourcedIdPairs$ = {}));
function createComponentResourceSourcedIdPairsToJSON(createComponentResourceSourcedIdPairs) {
    return JSON.stringify(exports.CreateComponentResourceSourcedIdPairs$outboundSchema.parse(createComponentResourceSourcedIdPairs));
}
function createComponentResourceSourcedIdPairsFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateComponentResourceSourcedIdPairs$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateComponentResourceSourcedIdPairs' from JSON`);
}
/** @internal */
exports.CreateComponentResourceResponse$inboundSchema = z.object({
    sourcedIdPairs: z.lazy(() => exports.CreateComponentResourceSourcedIdPairs$inboundSchema),
});
/** @internal */
exports.CreateComponentResourceResponse$outboundSchema = z.object({
    sourcedIdPairs: z.lazy(() => exports.CreateComponentResourceSourcedIdPairs$outboundSchema),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CreateComponentResourceResponse$;
(function (CreateComponentResourceResponse$) {
    /** @deprecated use `CreateComponentResourceResponse$inboundSchema` instead. */
    CreateComponentResourceResponse$.inboundSchema = exports.CreateComponentResourceResponse$inboundSchema;
    /** @deprecated use `CreateComponentResourceResponse$outboundSchema` instead. */
    CreateComponentResourceResponse$.outboundSchema = exports.CreateComponentResourceResponse$outboundSchema;
})(CreateComponentResourceResponse$ || (exports.CreateComponentResourceResponse$ = CreateComponentResourceResponse$ = {}));
function createComponentResourceResponseToJSON(createComponentResourceResponse) {
    return JSON.stringify(exports.CreateComponentResourceResponse$outboundSchema.parse(createComponentResourceResponse));
}
function createComponentResourceResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.CreateComponentResourceResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateComponentResourceResponse' from JSON`);
}
//# sourceMappingURL=createcomponentresource.js.map