"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.AtsUpdateBackgroundCheckResultRequestDto$ = exports.AtsUpdateBackgroundCheckResultRequestDto$outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDto$inboundSchema = exports.Score$ = exports.Score$outboundSchema = exports.Score$inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoResult$ = exports.AtsUpdateBackgroundCheckResultRequestDtoResult$outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoResult$inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoValue$ = exports.AtsUpdateBackgroundCheckResultRequestDtoValue$outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoValue$inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$ = exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDto4$ = exports.AtsUpdateBackgroundCheckResultRequestDto4$outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDto4$inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$ = exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoValue = void 0;
exports.atsUpdateBackgroundCheckResultRequestDtoCandidateToJSON = atsUpdateBackgroundCheckResultRequestDtoCandidateToJSON;
exports.atsUpdateBackgroundCheckResultRequestDtoCandidateFromJSON = atsUpdateBackgroundCheckResultRequestDtoCandidateFromJSON;
exports.atsUpdateBackgroundCheckResultRequestDto4ToJSON = atsUpdateBackgroundCheckResultRequestDto4ToJSON;
exports.atsUpdateBackgroundCheckResultRequestDto4FromJSON = atsUpdateBackgroundCheckResultRequestDto4FromJSON;
exports.atsUpdateBackgroundCheckResultRequestDtoSourceValueToJSON = atsUpdateBackgroundCheckResultRequestDtoSourceValueToJSON;
exports.atsUpdateBackgroundCheckResultRequestDtoSourceValueFromJSON = atsUpdateBackgroundCheckResultRequestDtoSourceValueFromJSON;
exports.atsUpdateBackgroundCheckResultRequestDtoResultToJSON = atsUpdateBackgroundCheckResultRequestDtoResultToJSON;
exports.atsUpdateBackgroundCheckResultRequestDtoResultFromJSON = atsUpdateBackgroundCheckResultRequestDtoResultFromJSON;
exports.scoreToJSON = scoreToJSON;
exports.scoreFromJSON = scoreFromJSON;
exports.atsUpdateBackgroundCheckResultRequestDtoToJSON = atsUpdateBackgroundCheckResultRequestDtoToJSON;
exports.atsUpdateBackgroundCheckResultRequestDtoFromJSON = atsUpdateBackgroundCheckResultRequestDtoFromJSON;
const z = __importStar(require("zod/v3"));
const primitives_js_1 = require("../../../lib/primitives.js");
const schemas_js_1 = require("../../../lib/schemas.js");
const enums_js_1 = require("../../types/enums.js");
const attachment_js_1 = require("./attachment.js");
/**
 * The result of the test.
 */
var AtsUpdateBackgroundCheckResultRequestDtoValue;
(function (AtsUpdateBackgroundCheckResultRequestDtoValue) {
    AtsUpdateBackgroundCheckResultRequestDtoValue["Initiated"] = "initiated";
    AtsUpdateBackgroundCheckResultRequestDtoValue["InProgress"] = "in_progress";
    AtsUpdateBackgroundCheckResultRequestDtoValue["Cancelled"] = "cancelled";
    AtsUpdateBackgroundCheckResultRequestDtoValue["Completed"] = "completed";
    AtsUpdateBackgroundCheckResultRequestDtoValue["Expired"] = "expired";
    AtsUpdateBackgroundCheckResultRequestDtoValue["Failed"] = "failed";
    AtsUpdateBackgroundCheckResultRequestDtoValue["Passed"] = "passed";
    AtsUpdateBackgroundCheckResultRequestDtoValue["UnmappedValue"] = "unmapped_value";
})(AtsUpdateBackgroundCheckResultRequestDtoValue || (exports.AtsUpdateBackgroundCheckResultRequestDtoValue = AtsUpdateBackgroundCheckResultRequestDtoValue = {}));
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$inboundSchema = z.object({
    id: z.nullable(z.string()).optional(),
    profile_url: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "profile_url": "profileUrl",
    });
});
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$outboundSchema = z.object({
    id: z.nullable(z.string()).optional(),
    profileUrl: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        profileUrl: "profile_url",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var AtsUpdateBackgroundCheckResultRequestDtoCandidate$;
(function (AtsUpdateBackgroundCheckResultRequestDtoCandidate$) {
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDtoCandidate$inboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDtoCandidate$.inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$inboundSchema;
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDtoCandidate$outboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDtoCandidate$.outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$outboundSchema;
})(AtsUpdateBackgroundCheckResultRequestDtoCandidate$ || (exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$ = AtsUpdateBackgroundCheckResultRequestDtoCandidate$ = {}));
function atsUpdateBackgroundCheckResultRequestDtoCandidateToJSON(atsUpdateBackgroundCheckResultRequestDtoCandidate) {
    return JSON.stringify(exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$outboundSchema.parse(atsUpdateBackgroundCheckResultRequestDtoCandidate));
}
function atsUpdateBackgroundCheckResultRequestDtoCandidateFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'AtsUpdateBackgroundCheckResultRequestDtoCandidate' from JSON`);
}
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDto4$inboundSchema = z.object({});
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDto4$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 AtsUpdateBackgroundCheckResultRequestDto4$;
(function (AtsUpdateBackgroundCheckResultRequestDto4$) {
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDto4$inboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDto4$.inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDto4$inboundSchema;
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDto4$outboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDto4$.outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDto4$outboundSchema;
})(AtsUpdateBackgroundCheckResultRequestDto4$ || (exports.AtsUpdateBackgroundCheckResultRequestDto4$ = AtsUpdateBackgroundCheckResultRequestDto4$ = {}));
function atsUpdateBackgroundCheckResultRequestDto4ToJSON(atsUpdateBackgroundCheckResultRequestDto4) {
    return JSON.stringify(exports.AtsUpdateBackgroundCheckResultRequestDto4$outboundSchema.parse(atsUpdateBackgroundCheckResultRequestDto4));
}
function atsUpdateBackgroundCheckResultRequestDto4FromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.AtsUpdateBackgroundCheckResultRequestDto4$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'AtsUpdateBackgroundCheckResultRequestDto4' from JSON`);
}
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$inboundSchema = z.union([
    z.string(),
    z.number(),
    z.boolean(),
    z.lazy(() => exports.AtsUpdateBackgroundCheckResultRequestDto4$inboundSchema),
    z.array(z.any()),
]);
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$outboundSchema = z.union([
    z.string(),
    z.number(),
    z.boolean(),
    z.lazy(() => exports.AtsUpdateBackgroundCheckResultRequestDto4$outboundSchema),
    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 AtsUpdateBackgroundCheckResultRequestDtoSourceValue$;
(function (AtsUpdateBackgroundCheckResultRequestDtoSourceValue$) {
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDtoSourceValue$inboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDtoSourceValue$.inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$inboundSchema;
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDtoSourceValue$outboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDtoSourceValue$.outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$outboundSchema;
})(AtsUpdateBackgroundCheckResultRequestDtoSourceValue$ || (exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$ = AtsUpdateBackgroundCheckResultRequestDtoSourceValue$ = {}));
function atsUpdateBackgroundCheckResultRequestDtoSourceValueToJSON(atsUpdateBackgroundCheckResultRequestDtoSourceValue) {
    return JSON.stringify(exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$outboundSchema.parse(atsUpdateBackgroundCheckResultRequestDtoSourceValue));
}
function atsUpdateBackgroundCheckResultRequestDtoSourceValueFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.AtsUpdateBackgroundCheckResultRequestDtoSourceValue$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'AtsUpdateBackgroundCheckResultRequestDtoSourceValue' from JSON`);
}
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDtoValue$inboundSchema = z
    .union([
    z.nativeEnum(AtsUpdateBackgroundCheckResultRequestDtoValue),
    z.string().transform(enums_js_1.catchUnrecognizedEnum),
]);
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDtoValue$outboundSchema = z.union([
    z.nativeEnum(AtsUpdateBackgroundCheckResultRequestDtoValue),
    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 AtsUpdateBackgroundCheckResultRequestDtoValue$;
(function (AtsUpdateBackgroundCheckResultRequestDtoValue$) {
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDtoValue$inboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDtoValue$.inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoValue$inboundSchema;
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDtoValue$outboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDtoValue$.outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoValue$outboundSchema;
})(AtsUpdateBackgroundCheckResultRequestDtoValue$ || (exports.AtsUpdateBackgroundCheckResultRequestDtoValue$ = AtsUpdateBackgroundCheckResultRequestDtoValue$ = {}));
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDtoResult$inboundSchema = z.object({
    source_value: z.nullable(z.union([
        z.string(),
        z.number(),
        z.boolean(),
        z.lazy(() => exports.AtsUpdateBackgroundCheckResultRequestDto4$inboundSchema),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.AtsUpdateBackgroundCheckResultRequestDtoValue$inboundSchema).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "source_value": "sourceValue",
    });
});
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDtoResult$outboundSchema = z.object({
    sourceValue: z.nullable(z.union([
        z.string(),
        z.number(),
        z.boolean(),
        z.lazy(() => exports.AtsUpdateBackgroundCheckResultRequestDto4$outboundSchema),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.AtsUpdateBackgroundCheckResultRequestDtoValue$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 AtsUpdateBackgroundCheckResultRequestDtoResult$;
(function (AtsUpdateBackgroundCheckResultRequestDtoResult$) {
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDtoResult$inboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDtoResult$.inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoResult$inboundSchema;
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDtoResult$outboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDtoResult$.outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDtoResult$outboundSchema;
})(AtsUpdateBackgroundCheckResultRequestDtoResult$ || (exports.AtsUpdateBackgroundCheckResultRequestDtoResult$ = AtsUpdateBackgroundCheckResultRequestDtoResult$ = {}));
function atsUpdateBackgroundCheckResultRequestDtoResultToJSON(atsUpdateBackgroundCheckResultRequestDtoResult) {
    return JSON.stringify(exports.AtsUpdateBackgroundCheckResultRequestDtoResult$outboundSchema.parse(atsUpdateBackgroundCheckResultRequestDtoResult));
}
function atsUpdateBackgroundCheckResultRequestDtoResultFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.AtsUpdateBackgroundCheckResultRequestDtoResult$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'AtsUpdateBackgroundCheckResultRequestDtoResult' from JSON`);
}
/** @internal */
exports.Score$inboundSchema = z
    .object({
    label: z.nullable(z.string()).optional(),
    max: z.nullable(z.string()).optional(),
    min: z.nullable(z.string()).optional(),
    value: z.nullable(z.string()).optional(),
});
/** @internal */
exports.Score$outboundSchema = z.object({
    label: z.nullable(z.string()).optional(),
    max: z.nullable(z.string()).optional(),
    min: z.nullable(z.string()).optional(),
    value: z.nullable(z.string()).optional(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var Score$;
(function (Score$) {
    /** @deprecated use `Score$inboundSchema` instead. */
    Score$.inboundSchema = exports.Score$inboundSchema;
    /** @deprecated use `Score$outboundSchema` instead. */
    Score$.outboundSchema = exports.Score$outboundSchema;
})(Score$ || (exports.Score$ = Score$ = {}));
function scoreToJSON(score) {
    return JSON.stringify(exports.Score$outboundSchema.parse(score));
}
function scoreFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.Score$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Score' from JSON`);
}
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDto$inboundSchema = z.object({
    attachments: z.nullable(z.array(attachment_js_1.Attachment$inboundSchema)).optional(),
    candidate: z.nullable(z.lazy(() => exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$inboundSchema)).optional(),
    passthrough: z.nullable(z.record(z.any())).optional(),
    result: z.nullable(z.lazy(() => exports.AtsUpdateBackgroundCheckResultRequestDtoResult$inboundSchema)).optional(),
    result_url: z.nullable(z.string()).optional(),
    score: z.nullable(z.lazy(() => exports.Score$inboundSchema)).optional(),
    start_date: z.nullable(z.string().datetime({ offset: true }).transform(v => new Date(v))).optional(),
    submission_date: z.nullable(z.string().datetime({ offset: true }).transform(v => new Date(v))).optional(),
    summary: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "result_url": "resultUrl",
        "start_date": "startDate",
        "submission_date": "submissionDate",
    });
});
/** @internal */
exports.AtsUpdateBackgroundCheckResultRequestDto$outboundSchema = z.object({
    attachments: z.nullable(z.array(attachment_js_1.Attachment$outboundSchema)).optional(),
    candidate: z.nullable(z.lazy(() => exports.AtsUpdateBackgroundCheckResultRequestDtoCandidate$outboundSchema)).optional(),
    passthrough: z.nullable(z.record(z.any())).optional(),
    result: z.nullable(z.lazy(() => exports.AtsUpdateBackgroundCheckResultRequestDtoResult$outboundSchema)).optional(),
    resultUrl: z.nullable(z.string()).optional(),
    score: z.nullable(z.lazy(() => exports.Score$outboundSchema)).optional(),
    startDate: z.nullable(z.date().transform(v => v.toISOString())).optional(),
    submissionDate: z.nullable(z.date().transform(v => v.toISOString()))
        .optional(),
    summary: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        resultUrl: "result_url",
        startDate: "start_date",
        submissionDate: "submission_date",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var AtsUpdateBackgroundCheckResultRequestDto$;
(function (AtsUpdateBackgroundCheckResultRequestDto$) {
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDto$inboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDto$.inboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDto$inboundSchema;
    /** @deprecated use `AtsUpdateBackgroundCheckResultRequestDto$outboundSchema` instead. */
    AtsUpdateBackgroundCheckResultRequestDto$.outboundSchema = exports.AtsUpdateBackgroundCheckResultRequestDto$outboundSchema;
})(AtsUpdateBackgroundCheckResultRequestDto$ || (exports.AtsUpdateBackgroundCheckResultRequestDto$ = AtsUpdateBackgroundCheckResultRequestDto$ = {}));
function atsUpdateBackgroundCheckResultRequestDtoToJSON(atsUpdateBackgroundCheckResultRequestDto) {
    return JSON.stringify(exports.AtsUpdateBackgroundCheckResultRequestDto$outboundSchema.parse(atsUpdateBackgroundCheckResultRequestDto));
}
function atsUpdateBackgroundCheckResultRequestDtoFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.AtsUpdateBackgroundCheckResultRequestDto$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'AtsUpdateBackgroundCheckResultRequestDto' from JSON`);
}
//# sourceMappingURL=atsupdatebackgroundcheckresultrequestdto.js.map