"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.jobPostingContentSectionFromJSON = exports.jobPostingContentSectionToJSON = exports.JobPostingContentSection$ = exports.JobPostingContentSection$outboundSchema = exports.JobPostingContentSection$inboundSchema = exports.jobPostingContentSectionTypeFromJSON = exports.jobPostingContentSectionTypeToJSON = exports.JobPostingContentSectionType$ = exports.JobPostingContentSectionType$outboundSchema = exports.JobPostingContentSectionType$inboundSchema = exports.JobPostingContentSectionValue$ = exports.JobPostingContentSectionValue$outboundSchema = exports.JobPostingContentSectionValue$inboundSchema = exports.jobPostingContentSectionSourceValueFromJSON = exports.jobPostingContentSectionSourceValueToJSON = exports.JobPostingContentSectionSourceValue$ = exports.JobPostingContentSectionSourceValue$outboundSchema = exports.JobPostingContentSectionSourceValue$inboundSchema = exports.jobPostingContentSection4FromJSON = exports.jobPostingContentSection4ToJSON = exports.JobPostingContentSection4$ = exports.JobPostingContentSection4$outboundSchema = exports.JobPostingContentSection4$inboundSchema = exports.JobPostingContentSectionValue = 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");
/**
 * The type of the description.
 */
var JobPostingContentSectionValue;
(function (JobPostingContentSectionValue) {
    JobPostingContentSectionValue["Responsibilities"] = "responsibilities";
    JobPostingContentSectionValue["Skills"] = "skills";
    JobPostingContentSectionValue["Benefits"] = "benefits";
    JobPostingContentSectionValue["CompanyOverview"] = "company_overview";
    JobPostingContentSectionValue["Description"] = "description";
    JobPostingContentSectionValue["Other"] = "other";
    JobPostingContentSectionValue["UnmappedValue"] = "unmapped_value";
})(JobPostingContentSectionValue || (exports.JobPostingContentSectionValue = JobPostingContentSectionValue = {}));
/** @internal */
exports.JobPostingContentSection4$inboundSchema = z.object({});
/** @internal */
exports.JobPostingContentSection4$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 JobPostingContentSection4$;
(function (JobPostingContentSection4$) {
    /** @deprecated use `JobPostingContentSection4$inboundSchema` instead. */
    JobPostingContentSection4$.inboundSchema = exports.JobPostingContentSection4$inboundSchema;
    /** @deprecated use `JobPostingContentSection4$outboundSchema` instead. */
    JobPostingContentSection4$.outboundSchema = exports.JobPostingContentSection4$outboundSchema;
})(JobPostingContentSection4$ || (exports.JobPostingContentSection4$ = JobPostingContentSection4$ = {}));
function jobPostingContentSection4ToJSON(jobPostingContentSection4) {
    return JSON.stringify(exports.JobPostingContentSection4$outboundSchema.parse(jobPostingContentSection4));
}
exports.jobPostingContentSection4ToJSON = jobPostingContentSection4ToJSON;
function jobPostingContentSection4FromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.JobPostingContentSection4$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'JobPostingContentSection4' from JSON`);
}
exports.jobPostingContentSection4FromJSON = jobPostingContentSection4FromJSON;
/** @internal */
exports.JobPostingContentSectionSourceValue$inboundSchema = z.union([
    z.lazy(() => exports.JobPostingContentSection4$inboundSchema),
    z.string(),
    z.number(),
    z.boolean(),
    z.array(z.any()),
]);
/** @internal */
exports.JobPostingContentSectionSourceValue$outboundSchema = z.union([
    z.lazy(() => exports.JobPostingContentSection4$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 JobPostingContentSectionSourceValue$;
(function (JobPostingContentSectionSourceValue$) {
    /** @deprecated use `JobPostingContentSectionSourceValue$inboundSchema` instead. */
    JobPostingContentSectionSourceValue$.inboundSchema = exports.JobPostingContentSectionSourceValue$inboundSchema;
    /** @deprecated use `JobPostingContentSectionSourceValue$outboundSchema` instead. */
    JobPostingContentSectionSourceValue$.outboundSchema = exports.JobPostingContentSectionSourceValue$outboundSchema;
})(JobPostingContentSectionSourceValue$ || (exports.JobPostingContentSectionSourceValue$ = JobPostingContentSectionSourceValue$ = {}));
function jobPostingContentSectionSourceValueToJSON(jobPostingContentSectionSourceValue) {
    return JSON.stringify(exports.JobPostingContentSectionSourceValue$outboundSchema.parse(jobPostingContentSectionSourceValue));
}
exports.jobPostingContentSectionSourceValueToJSON = jobPostingContentSectionSourceValueToJSON;
function jobPostingContentSectionSourceValueFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.JobPostingContentSectionSourceValue$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'JobPostingContentSectionSourceValue' from JSON`);
}
exports.jobPostingContentSectionSourceValueFromJSON = jobPostingContentSectionSourceValueFromJSON;
/** @internal */
exports.JobPostingContentSectionValue$inboundSchema = z
    .union([
    z.nativeEnum(JobPostingContentSectionValue),
    z.string().transform(enums_js_1.catchUnrecognizedEnum),
]);
/** @internal */
exports.JobPostingContentSectionValue$outboundSchema = z.union([
    z.nativeEnum(JobPostingContentSectionValue),
    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 JobPostingContentSectionValue$;
(function (JobPostingContentSectionValue$) {
    /** @deprecated use `JobPostingContentSectionValue$inboundSchema` instead. */
    JobPostingContentSectionValue$.inboundSchema = exports.JobPostingContentSectionValue$inboundSchema;
    /** @deprecated use `JobPostingContentSectionValue$outboundSchema` instead. */
    JobPostingContentSectionValue$.outboundSchema = exports.JobPostingContentSectionValue$outboundSchema;
})(JobPostingContentSectionValue$ || (exports.JobPostingContentSectionValue$ = JobPostingContentSectionValue$ = {}));
/** @internal */
exports.JobPostingContentSectionType$inboundSchema = z.object({
    source_value: z.nullable(z.union([
        z.lazy(() => exports.JobPostingContentSection4$inboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.JobPostingContentSectionValue$inboundSchema).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "source_value": "sourceValue",
    });
});
/** @internal */
exports.JobPostingContentSectionType$outboundSchema = z.object({
    sourceValue: z.nullable(z.union([
        z.lazy(() => exports.JobPostingContentSection4$outboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.JobPostingContentSectionValue$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 JobPostingContentSectionType$;
(function (JobPostingContentSectionType$) {
    /** @deprecated use `JobPostingContentSectionType$inboundSchema` instead. */
    JobPostingContentSectionType$.inboundSchema = exports.JobPostingContentSectionType$inboundSchema;
    /** @deprecated use `JobPostingContentSectionType$outboundSchema` instead. */
    JobPostingContentSectionType$.outboundSchema = exports.JobPostingContentSectionType$outboundSchema;
})(JobPostingContentSectionType$ || (exports.JobPostingContentSectionType$ = JobPostingContentSectionType$ = {}));
function jobPostingContentSectionTypeToJSON(jobPostingContentSectionType) {
    return JSON.stringify(exports.JobPostingContentSectionType$outboundSchema.parse(jobPostingContentSectionType));
}
exports.jobPostingContentSectionTypeToJSON = jobPostingContentSectionTypeToJSON;
function jobPostingContentSectionTypeFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.JobPostingContentSectionType$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'JobPostingContentSectionType' from JSON`);
}
exports.jobPostingContentSectionTypeFromJSON = jobPostingContentSectionTypeFromJSON;
/** @internal */
exports.JobPostingContentSection$inboundSchema = z.object({
    content: z.nullable(z.string()).optional(),
    id: z.nullable(z.string()).optional(),
    label: z.nullable(z.string()).optional(),
    remote_id: z.nullable(z.string()).optional(),
    type: z.nullable(z.lazy(() => exports.JobPostingContentSectionType$inboundSchema))
        .optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "remote_id": "remoteId",
    });
});
/** @internal */
exports.JobPostingContentSection$outboundSchema = z.object({
    content: z.nullable(z.string()).optional(),
    id: z.nullable(z.string()).optional(),
    label: z.nullable(z.string()).optional(),
    remoteId: z.nullable(z.string()).optional(),
    type: z.nullable(z.lazy(() => exports.JobPostingContentSectionType$outboundSchema))
        .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 JobPostingContentSection$;
(function (JobPostingContentSection$) {
    /** @deprecated use `JobPostingContentSection$inboundSchema` instead. */
    JobPostingContentSection$.inboundSchema = exports.JobPostingContentSection$inboundSchema;
    /** @deprecated use `JobPostingContentSection$outboundSchema` instead. */
    JobPostingContentSection$.outboundSchema = exports.JobPostingContentSection$outboundSchema;
})(JobPostingContentSection$ || (exports.JobPostingContentSection$ = JobPostingContentSection$ = {}));
function jobPostingContentSectionToJSON(jobPostingContentSection) {
    return JSON.stringify(exports.JobPostingContentSection$outboundSchema.parse(jobPostingContentSection));
}
exports.jobPostingContentSectionToJSON = jobPostingContentSectionToJSON;
function jobPostingContentSectionFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.JobPostingContentSection$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'JobPostingContentSection' from JSON`);
}
exports.jobPostingContentSectionFromJSON = jobPostingContentSectionFromJSON;
//# sourceMappingURL=jobpostingcontentsection.js.map