"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.skillsFromJSON = exports.skillsToJSON = exports.Skills$ = exports.Skills$outboundSchema = exports.Skills$inboundSchema = exports.skillsLevelFromJSON = exports.skillsLevelToJSON = exports.SkillsLevel$ = exports.SkillsLevel$outboundSchema = exports.SkillsLevel$inboundSchema = exports.SkillsValue$ = exports.SkillsValue$outboundSchema = exports.SkillsValue$inboundSchema = exports.skillsSourceValueFromJSON = exports.skillsSourceValueToJSON = exports.SkillsSourceValue$ = exports.SkillsSourceValue$outboundSchema = exports.SkillsSourceValue$inboundSchema = exports.skills4FromJSON = exports.skills4ToJSON = exports.Skills4$ = exports.Skills4$outboundSchema = exports.Skills4$inboundSchema = exports.SkillsValue = void 0;
const z = __importStar(require("zod"));
const primitives_js_1 = require("../../../lib/primitives.js");
const schemas_js_1 = require("../../../lib/schemas.js");
const enums_js_1 = require("../../types/enums.js");
var SkillsValue;
(function (SkillsValue) {
    SkillsValue["Primary"] = "primary";
    SkillsValue["Secondary"] = "secondary";
    SkillsValue["Tertiary"] = "tertiary";
})(SkillsValue || (exports.SkillsValue = SkillsValue = {}));
/** @internal */
exports.Skills4$inboundSchema = z.object({});
/** @internal */
exports.Skills4$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 Skills4$;
(function (Skills4$) {
    /** @deprecated use `Skills4$inboundSchema` instead. */
    Skills4$.inboundSchema = exports.Skills4$inboundSchema;
    /** @deprecated use `Skills4$outboundSchema` instead. */
    Skills4$.outboundSchema = exports.Skills4$outboundSchema;
})(Skills4$ || (exports.Skills4$ = Skills4$ = {}));
function skills4ToJSON(skills4) {
    return JSON.stringify(exports.Skills4$outboundSchema.parse(skills4));
}
exports.skills4ToJSON = skills4ToJSON;
function skills4FromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.Skills4$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Skills4' from JSON`);
}
exports.skills4FromJSON = skills4FromJSON;
/** @internal */
exports.SkillsSourceValue$inboundSchema = z.union([
    z.lazy(() => exports.Skills4$inboundSchema),
    z.string(),
    z.number(),
    z.boolean(),
    z.array(z.any()),
]);
/** @internal */
exports.SkillsSourceValue$outboundSchema = z.union([
    z.lazy(() => exports.Skills4$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 SkillsSourceValue$;
(function (SkillsSourceValue$) {
    /** @deprecated use `SkillsSourceValue$inboundSchema` instead. */
    SkillsSourceValue$.inboundSchema = exports.SkillsSourceValue$inboundSchema;
    /** @deprecated use `SkillsSourceValue$outboundSchema` instead. */
    SkillsSourceValue$.outboundSchema = exports.SkillsSourceValue$outboundSchema;
})(SkillsSourceValue$ || (exports.SkillsSourceValue$ = SkillsSourceValue$ = {}));
function skillsSourceValueToJSON(skillsSourceValue) {
    return JSON.stringify(exports.SkillsSourceValue$outboundSchema.parse(skillsSourceValue));
}
exports.skillsSourceValueToJSON = skillsSourceValueToJSON;
function skillsSourceValueFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.SkillsSourceValue$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'SkillsSourceValue' from JSON`);
}
exports.skillsSourceValueFromJSON = skillsSourceValueFromJSON;
/** @internal */
exports.SkillsValue$inboundSchema = z
    .union([
    z.nativeEnum(SkillsValue),
    z.string().transform(enums_js_1.catchUnrecognizedEnum),
]);
/** @internal */
exports.SkillsValue$outboundSchema = z.union([
    z.nativeEnum(SkillsValue),
    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 SkillsValue$;
(function (SkillsValue$) {
    /** @deprecated use `SkillsValue$inboundSchema` instead. */
    SkillsValue$.inboundSchema = exports.SkillsValue$inboundSchema;
    /** @deprecated use `SkillsValue$outboundSchema` instead. */
    SkillsValue$.outboundSchema = exports.SkillsValue$outboundSchema;
})(SkillsValue$ || (exports.SkillsValue$ = SkillsValue$ = {}));
/** @internal */
exports.SkillsLevel$inboundSchema = z.object({
    source_value: z.nullable(z.union([
        z.lazy(() => exports.Skills4$inboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.SkillsValue$inboundSchema).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "source_value": "sourceValue",
    });
});
/** @internal */
exports.SkillsLevel$outboundSchema = z.object({
    sourceValue: z.nullable(z.union([
        z.lazy(() => exports.Skills4$outboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.SkillsValue$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 SkillsLevel$;
(function (SkillsLevel$) {
    /** @deprecated use `SkillsLevel$inboundSchema` instead. */
    SkillsLevel$.inboundSchema = exports.SkillsLevel$inboundSchema;
    /** @deprecated use `SkillsLevel$outboundSchema` instead. */
    SkillsLevel$.outboundSchema = exports.SkillsLevel$outboundSchema;
})(SkillsLevel$ || (exports.SkillsLevel$ = SkillsLevel$ = {}));
function skillsLevelToJSON(skillsLevel) {
    return JSON.stringify(exports.SkillsLevel$outboundSchema.parse(skillsLevel));
}
exports.skillsLevelToJSON = skillsLevelToJSON;
function skillsLevelFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.SkillsLevel$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'SkillsLevel' from JSON`);
}
exports.skillsLevelFromJSON = skillsLevelFromJSON;
/** @internal */
exports.Skills$inboundSchema = z
    .object({
    active: z.nullable(z.boolean()).optional(),
    id: z.nullable(z.string()).optional(),
    level: z.nullable(z.lazy(() => exports.SkillsLevel$inboundSchema)).optional(),
    name: z.nullable(z.string()).optional(),
    remote_id: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "remote_id": "remoteId",
    });
});
/** @internal */
exports.Skills$outboundSchema = z.object({
    active: z.nullable(z.boolean()).optional(),
    id: z.nullable(z.string()).optional(),
    level: z.nullable(z.lazy(() => exports.SkillsLevel$outboundSchema)).optional(),
    name: z.nullable(z.string()).optional(),
    remoteId: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        remoteId: "remote_id",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var Skills$;
(function (Skills$) {
    /** @deprecated use `Skills$inboundSchema` instead. */
    Skills$.inboundSchema = exports.Skills$inboundSchema;
    /** @deprecated use `Skills$outboundSchema` instead. */
    Skills$.outboundSchema = exports.Skills$outboundSchema;
})(Skills$ || (exports.Skills$ = Skills$ = {}));
function skillsToJSON(skills) {
    return JSON.stringify(exports.Skills$outboundSchema.parse(skills));
}
exports.skillsToJSON = skillsToJSON;
function skillsFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.Skills$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Skills' from JSON`);
}
exports.skillsFromJSON = skillsFromJSON;
//# sourceMappingURL=skills.js.map