"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 (mod) {
    if (mod && mod.__esModule) return mod;
    var result = {};
    if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
    __setModuleDefault(result, mod);
    return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.Completion$ = exports.Completion$outboundSchema = exports.Completion$inboundSchema = exports.CompletionSchemasResult$ = exports.CompletionSchemasResult$outboundSchema = exports.CompletionSchemasResult$inboundSchema = exports.CompletionValue$ = exports.CompletionValue$outboundSchema = exports.CompletionValue$inboundSchema = exports.CompletionSourceValue$ = exports.CompletionSourceValue$outboundSchema = exports.CompletionSourceValue$inboundSchema = exports.Completion4$ = exports.Completion4$outboundSchema = exports.Completion4$inboundSchema = exports.CompletionValue = void 0;
const z = __importStar(require("zod"));
const primitives_js_1 = require("../../../lib/primitives.js");
const enums_js_1 = require("../../types/enums.js");
var CompletionValue;
(function (CompletionValue) {
    CompletionValue["Pass"] = "Pass";
    CompletionValue["Fail"] = "Fail";
})(CompletionValue || (exports.CompletionValue = CompletionValue = {}));
/** @internal */
exports.Completion4$inboundSchema = z.object({});
/** @internal */
exports.Completion4$outboundSchema = z.object({});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var Completion4$;
(function (Completion4$) {
    /** @deprecated use `Completion4$inboundSchema` instead. */
    Completion4$.inboundSchema = exports.Completion4$inboundSchema;
    /** @deprecated use `Completion4$outboundSchema` instead. */
    Completion4$.outboundSchema = exports.Completion4$outboundSchema;
})(Completion4$ || (exports.Completion4$ = Completion4$ = {}));
/** @internal */
exports.CompletionSourceValue$inboundSchema = z.union([
    z.lazy(() => exports.Completion4$inboundSchema),
    z.string(),
    z.number(),
    z.boolean(),
    z.array(z.any()),
]);
/** @internal */
exports.CompletionSourceValue$outboundSchema = z.union([
    z.lazy(() => exports.Completion4$outboundSchema),
    z.string(),
    z.number(),
    z.boolean(),
    z.array(z.any()),
]);
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CompletionSourceValue$;
(function (CompletionSourceValue$) {
    /** @deprecated use `CompletionSourceValue$inboundSchema` instead. */
    CompletionSourceValue$.inboundSchema = exports.CompletionSourceValue$inboundSchema;
    /** @deprecated use `CompletionSourceValue$outboundSchema` instead. */
    CompletionSourceValue$.outboundSchema = exports.CompletionSourceValue$outboundSchema;
})(CompletionSourceValue$ || (exports.CompletionSourceValue$ = CompletionSourceValue$ = {}));
/** @internal */
exports.CompletionValue$inboundSchema = z
    .union([
    z.nativeEnum(CompletionValue),
    z.string().transform(enums_js_1.catchUnrecognizedEnum),
]);
/** @internal */
exports.CompletionValue$outboundSchema = z.union([
    z.nativeEnum(CompletionValue),
    z.string().and(z.custom()),
]);
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CompletionValue$;
(function (CompletionValue$) {
    /** @deprecated use `CompletionValue$inboundSchema` instead. */
    CompletionValue$.inboundSchema = exports.CompletionValue$inboundSchema;
    /** @deprecated use `CompletionValue$outboundSchema` instead. */
    CompletionValue$.outboundSchema = exports.CompletionValue$outboundSchema;
})(CompletionValue$ || (exports.CompletionValue$ = CompletionValue$ = {}));
/** @internal */
exports.CompletionSchemasResult$inboundSchema = z.object({
    source_value: z.nullable(z.union([
        z.lazy(() => exports.Completion4$inboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.CompletionValue$inboundSchema).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "source_value": "sourceValue",
    });
});
/** @internal */
exports.CompletionSchemasResult$outboundSchema = z.object({
    sourceValue: z.nullable(z.union([
        z.lazy(() => exports.Completion4$outboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.CompletionValue$outboundSchema).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        sourceValue: "source_value",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var CompletionSchemasResult$;
(function (CompletionSchemasResult$) {
    /** @deprecated use `CompletionSchemasResult$inboundSchema` instead. */
    CompletionSchemasResult$.inboundSchema = exports.CompletionSchemasResult$inboundSchema;
    /** @deprecated use `CompletionSchemasResult$outboundSchema` instead. */
    CompletionSchemasResult$.outboundSchema = exports.CompletionSchemasResult$outboundSchema;
})(CompletionSchemasResult$ || (exports.CompletionSchemasResult$ = CompletionSchemasResult$ = {}));
/** @internal */
exports.Completion$inboundSchema = z.object({
    completed_at: z.nullable(z.string()).optional(),
    content_external_reference: z.nullable(z.string()).optional(),
    content_id: z.nullable(z.string()).optional(),
    course_id: z.nullable(z.string()).optional(),
    created_at: z.nullable(z.string()).optional(),
    external_id: z.nullable(z.string()).optional(),
    id: z.nullable(z.string()).optional(),
    remote_content_id: z.nullable(z.string()).optional(),
    remote_course_id: z.nullable(z.string()).optional(),
    remote_external_id: z.nullable(z.string()).optional(),
    remote_id: z.nullable(z.string()).optional(),
    remote_user_id: z.nullable(z.string()).optional(),
    result: z.nullable(z.lazy(() => exports.CompletionSchemasResult$inboundSchema))
        .optional(),
    unified_custom_fields: z.nullable(z.record(z.any())).optional(),
    updated_at: z.nullable(z.string()).optional(),
    user_id: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "completed_at": "completedAt",
        "content_external_reference": "contentExternalReference",
        "content_id": "contentId",
        "course_id": "courseId",
        "created_at": "createdAt",
        "external_id": "externalId",
        "remote_content_id": "remoteContentId",
        "remote_course_id": "remoteCourseId",
        "remote_external_id": "remoteExternalId",
        "remote_id": "remoteId",
        "remote_user_id": "remoteUserId",
        "unified_custom_fields": "unifiedCustomFields",
        "updated_at": "updatedAt",
        "user_id": "userId",
    });
});
/** @internal */
exports.Completion$outboundSchema = z.object({
    completedAt: z.nullable(z.string()).optional(),
    contentExternalReference: z.nullable(z.string()).optional(),
    contentId: z.nullable(z.string()).optional(),
    courseId: z.nullable(z.string()).optional(),
    createdAt: z.nullable(z.string()).optional(),
    externalId: z.nullable(z.string()).optional(),
    id: z.nullable(z.string()).optional(),
    remoteContentId: z.nullable(z.string()).optional(),
    remoteCourseId: z.nullable(z.string()).optional(),
    remoteExternalId: z.nullable(z.string()).optional(),
    remoteId: z.nullable(z.string()).optional(),
    remoteUserId: z.nullable(z.string()).optional(),
    result: z.nullable(z.lazy(() => exports.CompletionSchemasResult$outboundSchema))
        .optional(),
    unifiedCustomFields: z.nullable(z.record(z.any())).optional(),
    updatedAt: z.nullable(z.string()).optional(),
    userId: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        completedAt: "completed_at",
        contentExternalReference: "content_external_reference",
        contentId: "content_id",
        courseId: "course_id",
        createdAt: "created_at",
        externalId: "external_id",
        remoteContentId: "remote_content_id",
        remoteCourseId: "remote_course_id",
        remoteExternalId: "remote_external_id",
        remoteId: "remote_id",
        remoteUserId: "remote_user_id",
        unifiedCustomFields: "unified_custom_fields",
        updatedAt: "updated_at",
        userId: "user_id",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var Completion$;
(function (Completion$) {
    /** @deprecated use `Completion$inboundSchema` instead. */
    Completion$.inboundSchema = exports.Completion$inboundSchema;
    /** @deprecated use `Completion$outboundSchema` instead. */
    Completion$.outboundSchema = exports.Completion$outboundSchema;
})(Completion$ || (exports.Completion$ = Completion$ = {}));
//# sourceMappingURL=completion.js.map