"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.hrisLocationFromJSON = exports.hrisLocationToJSON = exports.HRISLocation$ = exports.HRISLocation$outboundSchema = exports.HRISLocation$inboundSchema = exports.hrisLocationLocationTypeFromJSON = exports.hrisLocationLocationTypeToJSON = exports.HRISLocationLocationType$ = exports.HRISLocationLocationType$outboundSchema = exports.HRISLocationLocationType$inboundSchema = exports.HRISLocationSchemasValue$ = exports.HRISLocationSchemasValue$outboundSchema = exports.HRISLocationSchemasValue$inboundSchema = exports.hrisLocationSchemasSourceValueFromJSON = exports.hrisLocationSchemasSourceValueToJSON = exports.HRISLocationSchemasSourceValue$ = exports.HRISLocationSchemasSourceValue$outboundSchema = exports.HRISLocationSchemasSourceValue$inboundSchema = exports.hrisLocationSchemas4FromJSON = exports.hrisLocationSchemas4ToJSON = exports.HRISLocationSchemas4$ = exports.HRISLocationSchemas4$outboundSchema = exports.HRISLocationSchemas4$inboundSchema = exports.hrisLocationCountryFromJSON = exports.hrisLocationCountryToJSON = exports.HRISLocationCountry$ = exports.HRISLocationCountry$outboundSchema = exports.HRISLocationCountry$inboundSchema = exports.HRISLocationValue$ = exports.HRISLocationValue$outboundSchema = exports.HRISLocationValue$inboundSchema = exports.hrisLocationSourceValueFromJSON = exports.hrisLocationSourceValueToJSON = exports.HRISLocationSourceValue$ = exports.HRISLocationSourceValue$outboundSchema = exports.HRISLocationSourceValue$inboundSchema = exports.hrisLocation4FromJSON = exports.hrisLocation4ToJSON = exports.HRISLocation4$ = exports.HRISLocation4$outboundSchema = exports.HRISLocation4$inboundSchema = exports.HRISLocationSchemasValue = exports.HRISLocationValue = 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 ISO3166-1 Alpha2 Code of the Country
 */
var HRISLocationValue;
(function (HRISLocationValue) {
    HRISLocationValue["Af"] = "AF";
    HRISLocationValue["Al"] = "AL";
    HRISLocationValue["Dz"] = "DZ";
    HRISLocationValue["As"] = "AS";
    HRISLocationValue["Ad"] = "AD";
    HRISLocationValue["Ao"] = "AO";
    HRISLocationValue["Ai"] = "AI";
    HRISLocationValue["Aq"] = "AQ";
    HRISLocationValue["Ag"] = "AG";
    HRISLocationValue["Ar"] = "AR";
    HRISLocationValue["Am"] = "AM";
    HRISLocationValue["Aw"] = "AW";
    HRISLocationValue["Au"] = "AU";
    HRISLocationValue["At"] = "AT";
    HRISLocationValue["Az"] = "AZ";
    HRISLocationValue["Bs"] = "BS";
    HRISLocationValue["Bh"] = "BH";
    HRISLocationValue["Bd"] = "BD";
    HRISLocationValue["Bb"] = "BB";
    HRISLocationValue["By"] = "BY";
    HRISLocationValue["Be"] = "BE";
    HRISLocationValue["Bz"] = "BZ";
    HRISLocationValue["Bj"] = "BJ";
    HRISLocationValue["Bm"] = "BM";
    HRISLocationValue["Bt"] = "BT";
    HRISLocationValue["Bo"] = "BO";
    HRISLocationValue["Bq"] = "BQ";
    HRISLocationValue["Ba"] = "BA";
    HRISLocationValue["Bw"] = "BW";
    HRISLocationValue["Bv"] = "BV";
    HRISLocationValue["Br"] = "BR";
    HRISLocationValue["Io"] = "IO";
    HRISLocationValue["Bn"] = "BN";
    HRISLocationValue["Bg"] = "BG";
    HRISLocationValue["Bf"] = "BF";
    HRISLocationValue["Bi"] = "BI";
    HRISLocationValue["Kh"] = "KH";
    HRISLocationValue["Cm"] = "CM";
    HRISLocationValue["Ca"] = "CA";
    HRISLocationValue["Cv"] = "CV";
    HRISLocationValue["Ky"] = "KY";
    HRISLocationValue["Cf"] = "CF";
    HRISLocationValue["Td"] = "TD";
    HRISLocationValue["Cl"] = "CL";
    HRISLocationValue["Cn"] = "CN";
    HRISLocationValue["Cx"] = "CX";
    HRISLocationValue["Cc"] = "CC";
    HRISLocationValue["Co"] = "CO";
    HRISLocationValue["Km"] = "KM";
    HRISLocationValue["Cg"] = "CG";
    HRISLocationValue["Cd"] = "CD";
    HRISLocationValue["Ck"] = "CK";
    HRISLocationValue["Cr"] = "CR";
    HRISLocationValue["Hr"] = "HR";
    HRISLocationValue["Cu"] = "CU";
    HRISLocationValue["Cw"] = "CW";
    HRISLocationValue["Cy"] = "CY";
    HRISLocationValue["Cz"] = "CZ";
    HRISLocationValue["Ci"] = "CI";
    HRISLocationValue["Dk"] = "DK";
    HRISLocationValue["Dj"] = "DJ";
    HRISLocationValue["Dm"] = "DM";
    HRISLocationValue["Do"] = "DO";
    HRISLocationValue["Ec"] = "EC";
    HRISLocationValue["Eg"] = "EG";
    HRISLocationValue["Sv"] = "SV";
    HRISLocationValue["Gq"] = "GQ";
    HRISLocationValue["Er"] = "ER";
    HRISLocationValue["Ee"] = "EE";
    HRISLocationValue["Et"] = "ET";
    HRISLocationValue["Fk"] = "FK";
    HRISLocationValue["Fo"] = "FO";
    HRISLocationValue["Fj"] = "FJ";
    HRISLocationValue["Fi"] = "FI";
    HRISLocationValue["Fr"] = "FR";
    HRISLocationValue["Gf"] = "GF";
    HRISLocationValue["Pf"] = "PF";
    HRISLocationValue["Tf"] = "TF";
    HRISLocationValue["Ga"] = "GA";
    HRISLocationValue["Gm"] = "GM";
    HRISLocationValue["Ge"] = "GE";
    HRISLocationValue["De"] = "DE";
    HRISLocationValue["Gh"] = "GH";
    HRISLocationValue["Gi"] = "GI";
    HRISLocationValue["Gr"] = "GR";
    HRISLocationValue["Gl"] = "GL";
    HRISLocationValue["Gd"] = "GD";
    HRISLocationValue["Gp"] = "GP";
    HRISLocationValue["Gu"] = "GU";
    HRISLocationValue["Gt"] = "GT";
    HRISLocationValue["Gg"] = "GG";
    HRISLocationValue["Gn"] = "GN";
    HRISLocationValue["Gw"] = "GW";
    HRISLocationValue["Gy"] = "GY";
    HRISLocationValue["Ht"] = "HT";
    HRISLocationValue["Hm"] = "HM";
    HRISLocationValue["Va"] = "VA";
    HRISLocationValue["Hn"] = "HN";
    HRISLocationValue["Hk"] = "HK";
    HRISLocationValue["Hu"] = "HU";
    HRISLocationValue["Is"] = "IS";
    HRISLocationValue["In"] = "IN";
    HRISLocationValue["Id"] = "ID";
    HRISLocationValue["Ir"] = "IR";
    HRISLocationValue["Iq"] = "IQ";
    HRISLocationValue["Ie"] = "IE";
    HRISLocationValue["Im"] = "IM";
    HRISLocationValue["Il"] = "IL";
    HRISLocationValue["It"] = "IT";
    HRISLocationValue["Jm"] = "JM";
    HRISLocationValue["Jp"] = "JP";
    HRISLocationValue["Je"] = "JE";
    HRISLocationValue["Jo"] = "JO";
    HRISLocationValue["Kz"] = "KZ";
    HRISLocationValue["Ke"] = "KE";
    HRISLocationValue["Ki"] = "KI";
    HRISLocationValue["Kp"] = "KP";
    HRISLocationValue["Kr"] = "KR";
    HRISLocationValue["Kw"] = "KW";
    HRISLocationValue["Kg"] = "KG";
    HRISLocationValue["La"] = "LA";
    HRISLocationValue["Lv"] = "LV";
    HRISLocationValue["Lb"] = "LB";
    HRISLocationValue["Ls"] = "LS";
    HRISLocationValue["Lr"] = "LR";
    HRISLocationValue["Ly"] = "LY";
    HRISLocationValue["Li"] = "LI";
    HRISLocationValue["Lt"] = "LT";
    HRISLocationValue["Lu"] = "LU";
    HRISLocationValue["Mo"] = "MO";
    HRISLocationValue["Mk"] = "MK";
    HRISLocationValue["Mg"] = "MG";
    HRISLocationValue["Mw"] = "MW";
    HRISLocationValue["My"] = "MY";
    HRISLocationValue["Mv"] = "MV";
    HRISLocationValue["Ml"] = "ML";
    HRISLocationValue["Mt"] = "MT";
    HRISLocationValue["Mh"] = "MH";
    HRISLocationValue["Mq"] = "MQ";
    HRISLocationValue["Mr"] = "MR";
    HRISLocationValue["Mu"] = "MU";
    HRISLocationValue["Yt"] = "YT";
    HRISLocationValue["Mx"] = "MX";
    HRISLocationValue["Fm"] = "FM";
    HRISLocationValue["Md"] = "MD";
    HRISLocationValue["Mc"] = "MC";
    HRISLocationValue["Mn"] = "MN";
    HRISLocationValue["Me"] = "ME";
    HRISLocationValue["Ms"] = "MS";
    HRISLocationValue["Ma"] = "MA";
    HRISLocationValue["Mz"] = "MZ";
    HRISLocationValue["Mm"] = "MM";
    HRISLocationValue["Na"] = "NA";
    HRISLocationValue["Nr"] = "NR";
    HRISLocationValue["Np"] = "NP";
    HRISLocationValue["Nl"] = "NL";
    HRISLocationValue["Nc"] = "NC";
    HRISLocationValue["Nz"] = "NZ";
    HRISLocationValue["Ni"] = "NI";
    HRISLocationValue["Ne"] = "NE";
    HRISLocationValue["Ng"] = "NG";
    HRISLocationValue["Nu"] = "NU";
    HRISLocationValue["Nf"] = "NF";
    HRISLocationValue["Mp"] = "MP";
    HRISLocationValue["No"] = "NO";
    HRISLocationValue["Om"] = "OM";
    HRISLocationValue["Pk"] = "PK";
    HRISLocationValue["Pw"] = "PW";
    HRISLocationValue["Ps"] = "PS";
    HRISLocationValue["Pa"] = "PA";
    HRISLocationValue["Pg"] = "PG";
    HRISLocationValue["Py"] = "PY";
    HRISLocationValue["Pe"] = "PE";
    HRISLocationValue["Ph"] = "PH";
    HRISLocationValue["Pn"] = "PN";
    HRISLocationValue["Pl"] = "PL";
    HRISLocationValue["Pt"] = "PT";
    HRISLocationValue["Pr"] = "PR";
    HRISLocationValue["Qa"] = "QA";
    HRISLocationValue["Ro"] = "RO";
    HRISLocationValue["Ru"] = "RU";
    HRISLocationValue["Rw"] = "RW";
    HRISLocationValue["Re"] = "RE";
    HRISLocationValue["Bl"] = "BL";
    HRISLocationValue["Sh"] = "SH";
    HRISLocationValue["Kn"] = "KN";
    HRISLocationValue["Lc"] = "LC";
    HRISLocationValue["Mf"] = "MF";
    HRISLocationValue["Pm"] = "PM";
    HRISLocationValue["Vc"] = "VC";
    HRISLocationValue["Ws"] = "WS";
    HRISLocationValue["Sm"] = "SM";
    HRISLocationValue["St"] = "ST";
    HRISLocationValue["Sa"] = "SA";
    HRISLocationValue["Sn"] = "SN";
    HRISLocationValue["Rs"] = "RS";
    HRISLocationValue["Sc"] = "SC";
    HRISLocationValue["Sl"] = "SL";
    HRISLocationValue["Sg"] = "SG";
    HRISLocationValue["Sx"] = "SX";
    HRISLocationValue["Sk"] = "SK";
    HRISLocationValue["Si"] = "SI";
    HRISLocationValue["Sb"] = "SB";
    HRISLocationValue["So"] = "SO";
    HRISLocationValue["Za"] = "ZA";
    HRISLocationValue["Gs"] = "GS";
    HRISLocationValue["Ss"] = "SS";
    HRISLocationValue["Es"] = "ES";
    HRISLocationValue["Lk"] = "LK";
    HRISLocationValue["Sd"] = "SD";
    HRISLocationValue["Sr"] = "SR";
    HRISLocationValue["Sj"] = "SJ";
    HRISLocationValue["Sz"] = "SZ";
    HRISLocationValue["Se"] = "SE";
    HRISLocationValue["Ch"] = "CH";
    HRISLocationValue["Sy"] = "SY";
    HRISLocationValue["Tw"] = "TW";
    HRISLocationValue["Tj"] = "TJ";
    HRISLocationValue["Tz"] = "TZ";
    HRISLocationValue["Th"] = "TH";
    HRISLocationValue["Tl"] = "TL";
    HRISLocationValue["Tg"] = "TG";
    HRISLocationValue["Tk"] = "TK";
    HRISLocationValue["To"] = "TO";
    HRISLocationValue["Tt"] = "TT";
    HRISLocationValue["Tn"] = "TN";
    HRISLocationValue["Tr"] = "TR";
    HRISLocationValue["Tm"] = "TM";
    HRISLocationValue["Tc"] = "TC";
    HRISLocationValue["Tv"] = "TV";
    HRISLocationValue["Ug"] = "UG";
    HRISLocationValue["Ua"] = "UA";
    HRISLocationValue["Ae"] = "AE";
    HRISLocationValue["Gb"] = "GB";
    HRISLocationValue["Us"] = "US";
    HRISLocationValue["Um"] = "UM";
    HRISLocationValue["Uy"] = "UY";
    HRISLocationValue["Uz"] = "UZ";
    HRISLocationValue["Vu"] = "VU";
    HRISLocationValue["Ve"] = "VE";
    HRISLocationValue["Vn"] = "VN";
    HRISLocationValue["Vg"] = "VG";
    HRISLocationValue["Vi"] = "VI";
    HRISLocationValue["Wf"] = "WF";
    HRISLocationValue["Eh"] = "EH";
    HRISLocationValue["Ye"] = "YE";
    HRISLocationValue["Zm"] = "ZM";
    HRISLocationValue["Zw"] = "ZW";
    HRISLocationValue["UnmappedValue"] = "unmapped_value";
})(HRISLocationValue || (exports.HRISLocationValue = HRISLocationValue = {}));
/**
 * The type of the location.
 */
var HRISLocationSchemasValue;
(function (HRISLocationSchemasValue) {
    HRISLocationSchemasValue["Home"] = "home";
    HRISLocationSchemasValue["Work"] = "work";
    HRISLocationSchemasValue["UnmappedValue"] = "unmapped_value";
})(HRISLocationSchemasValue || (exports.HRISLocationSchemasValue = HRISLocationSchemasValue = {}));
/** @internal */
exports.HRISLocation4$inboundSchema = z.object({});
/** @internal */
exports.HRISLocation4$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 HRISLocation4$;
(function (HRISLocation4$) {
    /** @deprecated use `HRISLocation4$inboundSchema` instead. */
    HRISLocation4$.inboundSchema = exports.HRISLocation4$inboundSchema;
    /** @deprecated use `HRISLocation4$outboundSchema` instead. */
    HRISLocation4$.outboundSchema = exports.HRISLocation4$outboundSchema;
})(HRISLocation4$ || (exports.HRISLocation4$ = HRISLocation4$ = {}));
function hrisLocation4ToJSON(hrisLocation4) {
    return JSON.stringify(exports.HRISLocation4$outboundSchema.parse(hrisLocation4));
}
exports.hrisLocation4ToJSON = hrisLocation4ToJSON;
function hrisLocation4FromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.HRISLocation4$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'HRISLocation4' from JSON`);
}
exports.hrisLocation4FromJSON = hrisLocation4FromJSON;
/** @internal */
exports.HRISLocationSourceValue$inboundSchema = z.union([
    z.lazy(() => exports.HRISLocation4$inboundSchema),
    z.string(),
    z.number(),
    z.boolean(),
    z.array(z.any()),
]);
/** @internal */
exports.HRISLocationSourceValue$outboundSchema = z.union([
    z.lazy(() => exports.HRISLocation4$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 HRISLocationSourceValue$;
(function (HRISLocationSourceValue$) {
    /** @deprecated use `HRISLocationSourceValue$inboundSchema` instead. */
    HRISLocationSourceValue$.inboundSchema = exports.HRISLocationSourceValue$inboundSchema;
    /** @deprecated use `HRISLocationSourceValue$outboundSchema` instead. */
    HRISLocationSourceValue$.outboundSchema = exports.HRISLocationSourceValue$outboundSchema;
})(HRISLocationSourceValue$ || (exports.HRISLocationSourceValue$ = HRISLocationSourceValue$ = {}));
function hrisLocationSourceValueToJSON(hrisLocationSourceValue) {
    return JSON.stringify(exports.HRISLocationSourceValue$outboundSchema.parse(hrisLocationSourceValue));
}
exports.hrisLocationSourceValueToJSON = hrisLocationSourceValueToJSON;
function hrisLocationSourceValueFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.HRISLocationSourceValue$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'HRISLocationSourceValue' from JSON`);
}
exports.hrisLocationSourceValueFromJSON = hrisLocationSourceValueFromJSON;
/** @internal */
exports.HRISLocationValue$inboundSchema = z
    .union([
    z.nativeEnum(HRISLocationValue),
    z.string().transform(enums_js_1.catchUnrecognizedEnum),
]);
/** @internal */
exports.HRISLocationValue$outboundSchema = z.union([
    z.nativeEnum(HRISLocationValue),
    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 HRISLocationValue$;
(function (HRISLocationValue$) {
    /** @deprecated use `HRISLocationValue$inboundSchema` instead. */
    HRISLocationValue$.inboundSchema = exports.HRISLocationValue$inboundSchema;
    /** @deprecated use `HRISLocationValue$outboundSchema` instead. */
    HRISLocationValue$.outboundSchema = exports.HRISLocationValue$outboundSchema;
})(HRISLocationValue$ || (exports.HRISLocationValue$ = HRISLocationValue$ = {}));
/** @internal */
exports.HRISLocationCountry$inboundSchema = z.object({
    source_value: z.nullable(z.union([
        z.lazy(() => exports.HRISLocation4$inboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.HRISLocationValue$inboundSchema).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "source_value": "sourceValue",
    });
});
/** @internal */
exports.HRISLocationCountry$outboundSchema = z.object({
    sourceValue: z.nullable(z.union([
        z.lazy(() => exports.HRISLocation4$outboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.HRISLocationValue$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 HRISLocationCountry$;
(function (HRISLocationCountry$) {
    /** @deprecated use `HRISLocationCountry$inboundSchema` instead. */
    HRISLocationCountry$.inboundSchema = exports.HRISLocationCountry$inboundSchema;
    /** @deprecated use `HRISLocationCountry$outboundSchema` instead. */
    HRISLocationCountry$.outboundSchema = exports.HRISLocationCountry$outboundSchema;
})(HRISLocationCountry$ || (exports.HRISLocationCountry$ = HRISLocationCountry$ = {}));
function hrisLocationCountryToJSON(hrisLocationCountry) {
    return JSON.stringify(exports.HRISLocationCountry$outboundSchema.parse(hrisLocationCountry));
}
exports.hrisLocationCountryToJSON = hrisLocationCountryToJSON;
function hrisLocationCountryFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.HRISLocationCountry$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'HRISLocationCountry' from JSON`);
}
exports.hrisLocationCountryFromJSON = hrisLocationCountryFromJSON;
/** @internal */
exports.HRISLocationSchemas4$inboundSchema = z.object({});
/** @internal */
exports.HRISLocationSchemas4$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 HRISLocationSchemas4$;
(function (HRISLocationSchemas4$) {
    /** @deprecated use `HRISLocationSchemas4$inboundSchema` instead. */
    HRISLocationSchemas4$.inboundSchema = exports.HRISLocationSchemas4$inboundSchema;
    /** @deprecated use `HRISLocationSchemas4$outboundSchema` instead. */
    HRISLocationSchemas4$.outboundSchema = exports.HRISLocationSchemas4$outboundSchema;
})(HRISLocationSchemas4$ || (exports.HRISLocationSchemas4$ = HRISLocationSchemas4$ = {}));
function hrisLocationSchemas4ToJSON(hrisLocationSchemas4) {
    return JSON.stringify(exports.HRISLocationSchemas4$outboundSchema.parse(hrisLocationSchemas4));
}
exports.hrisLocationSchemas4ToJSON = hrisLocationSchemas4ToJSON;
function hrisLocationSchemas4FromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.HRISLocationSchemas4$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'HRISLocationSchemas4' from JSON`);
}
exports.hrisLocationSchemas4FromJSON = hrisLocationSchemas4FromJSON;
/** @internal */
exports.HRISLocationSchemasSourceValue$inboundSchema = z.union([
    z.lazy(() => exports.HRISLocationSchemas4$inboundSchema),
    z.string(),
    z.number(),
    z.boolean(),
    z.array(z.any()),
]);
/** @internal */
exports.HRISLocationSchemasSourceValue$outboundSchema = z.union([
    z.lazy(() => exports.HRISLocationSchemas4$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 HRISLocationSchemasSourceValue$;
(function (HRISLocationSchemasSourceValue$) {
    /** @deprecated use `HRISLocationSchemasSourceValue$inboundSchema` instead. */
    HRISLocationSchemasSourceValue$.inboundSchema = exports.HRISLocationSchemasSourceValue$inboundSchema;
    /** @deprecated use `HRISLocationSchemasSourceValue$outboundSchema` instead. */
    HRISLocationSchemasSourceValue$.outboundSchema = exports.HRISLocationSchemasSourceValue$outboundSchema;
})(HRISLocationSchemasSourceValue$ || (exports.HRISLocationSchemasSourceValue$ = HRISLocationSchemasSourceValue$ = {}));
function hrisLocationSchemasSourceValueToJSON(hrisLocationSchemasSourceValue) {
    return JSON.stringify(exports.HRISLocationSchemasSourceValue$outboundSchema.parse(hrisLocationSchemasSourceValue));
}
exports.hrisLocationSchemasSourceValueToJSON = hrisLocationSchemasSourceValueToJSON;
function hrisLocationSchemasSourceValueFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.HRISLocationSchemasSourceValue$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'HRISLocationSchemasSourceValue' from JSON`);
}
exports.hrisLocationSchemasSourceValueFromJSON = hrisLocationSchemasSourceValueFromJSON;
/** @internal */
exports.HRISLocationSchemasValue$inboundSchema = z
    .union([
    z.nativeEnum(HRISLocationSchemasValue),
    z.string().transform(enums_js_1.catchUnrecognizedEnum),
]);
/** @internal */
exports.HRISLocationSchemasValue$outboundSchema = z.union([
    z.nativeEnum(HRISLocationSchemasValue),
    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 HRISLocationSchemasValue$;
(function (HRISLocationSchemasValue$) {
    /** @deprecated use `HRISLocationSchemasValue$inboundSchema` instead. */
    HRISLocationSchemasValue$.inboundSchema = exports.HRISLocationSchemasValue$inboundSchema;
    /** @deprecated use `HRISLocationSchemasValue$outboundSchema` instead. */
    HRISLocationSchemasValue$.outboundSchema = exports.HRISLocationSchemasValue$outboundSchema;
})(HRISLocationSchemasValue$ || (exports.HRISLocationSchemasValue$ = HRISLocationSchemasValue$ = {}));
/** @internal */
exports.HRISLocationLocationType$inboundSchema = z.object({
    source_value: z.nullable(z.union([
        z.lazy(() => exports.HRISLocationSchemas4$inboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.HRISLocationSchemasValue$inboundSchema).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "source_value": "sourceValue",
    });
});
/** @internal */
exports.HRISLocationLocationType$outboundSchema = z.object({
    sourceValue: z.nullable(z.union([
        z.lazy(() => exports.HRISLocationSchemas4$outboundSchema),
        z.string(),
        z.number(),
        z.boolean(),
        z.array(z.any()),
    ])).optional(),
    value: z.nullable(exports.HRISLocationSchemasValue$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 HRISLocationLocationType$;
(function (HRISLocationLocationType$) {
    /** @deprecated use `HRISLocationLocationType$inboundSchema` instead. */
    HRISLocationLocationType$.inboundSchema = exports.HRISLocationLocationType$inboundSchema;
    /** @deprecated use `HRISLocationLocationType$outboundSchema` instead. */
    HRISLocationLocationType$.outboundSchema = exports.HRISLocationLocationType$outboundSchema;
})(HRISLocationLocationType$ || (exports.HRISLocationLocationType$ = HRISLocationLocationType$ = {}));
function hrisLocationLocationTypeToJSON(hrisLocationLocationType) {
    return JSON.stringify(exports.HRISLocationLocationType$outboundSchema.parse(hrisLocationLocationType));
}
exports.hrisLocationLocationTypeToJSON = hrisLocationLocationTypeToJSON;
function hrisLocationLocationTypeFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.HRISLocationLocationType$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'HRISLocationLocationType' from JSON`);
}
exports.hrisLocationLocationTypeFromJSON = hrisLocationLocationTypeFromJSON;
/** @internal */
exports.HRISLocation$inboundSchema = z.object({
    city: z.nullable(z.string()).optional(),
    country: z.nullable(z.lazy(() => exports.HRISLocationCountry$inboundSchema))
        .optional(),
    created_at: z.nullable(z.string().datetime({ offset: true }).transform(v => new Date(v))).optional(),
    employee_id: z.nullable(z.string()).optional(),
    id: z.nullable(z.string()).optional(),
    location_type: z.nullable(z.lazy(() => exports.HRISLocationLocationType$inboundSchema)).optional(),
    name: z.nullable(z.string()).optional(),
    phone_number: z.nullable(z.string()).optional(),
    remote_employee_id: z.nullable(z.string()).optional(),
    remote_id: z.nullable(z.string()).optional(),
    state: z.nullable(z.string()).optional(),
    street_1: z.nullable(z.string()).optional(),
    street_2: z.nullable(z.string()).optional(),
    unified_custom_fields: z.nullable(z.record(z.any())).optional(),
    updated_at: z.nullable(z.string().datetime({ offset: true }).transform(v => new Date(v))).optional(),
    zip_code: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "created_at": "createdAt",
        "employee_id": "employeeId",
        "location_type": "locationType",
        "phone_number": "phoneNumber",
        "remote_employee_id": "remoteEmployeeId",
        "remote_id": "remoteId",
        "street_1": "street1",
        "street_2": "street2",
        "unified_custom_fields": "unifiedCustomFields",
        "updated_at": "updatedAt",
        "zip_code": "zipCode",
    });
});
/** @internal */
exports.HRISLocation$outboundSchema = z.object({
    city: z.nullable(z.string()).optional(),
    country: z.nullable(z.lazy(() => exports.HRISLocationCountry$outboundSchema))
        .optional(),
    createdAt: z.nullable(z.date().transform(v => v.toISOString())).optional(),
    employeeId: z.nullable(z.string()).optional(),
    id: z.nullable(z.string()).optional(),
    locationType: z.nullable(z.lazy(() => exports.HRISLocationLocationType$outboundSchema)).optional(),
    name: z.nullable(z.string()).optional(),
    phoneNumber: z.nullable(z.string()).optional(),
    remoteEmployeeId: z.nullable(z.string()).optional(),
    remoteId: z.nullable(z.string()).optional(),
    state: z.nullable(z.string()).optional(),
    street1: z.nullable(z.string()).optional(),
    street2: z.nullable(z.string()).optional(),
    unifiedCustomFields: z.nullable(z.record(z.any())).optional(),
    updatedAt: z.nullable(z.date().transform(v => v.toISOString())).optional(),
    zipCode: z.nullable(z.string()).optional(),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        createdAt: "created_at",
        employeeId: "employee_id",
        locationType: "location_type",
        phoneNumber: "phone_number",
        remoteEmployeeId: "remote_employee_id",
        remoteId: "remote_id",
        street1: "street_1",
        street2: "street_2",
        unifiedCustomFields: "unified_custom_fields",
        updatedAt: "updated_at",
        zipCode: "zip_code",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var HRISLocation$;
(function (HRISLocation$) {
    /** @deprecated use `HRISLocation$inboundSchema` instead. */
    HRISLocation$.inboundSchema = exports.HRISLocation$inboundSchema;
    /** @deprecated use `HRISLocation$outboundSchema` instead. */
    HRISLocation$.outboundSchema = exports.HRISLocation$outboundSchema;
})(HRISLocation$ || (exports.HRISLocation$ = HRISLocation$ = {}));
function hrisLocationToJSON(hrisLocation) {
    return JSON.stringify(exports.HRISLocation$outboundSchema.parse(hrisLocation));
}
exports.hrisLocationToJSON = hrisLocationToJSON;
function hrisLocationFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.HRISLocation$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'HRISLocation' from JSON`);
}
exports.hrisLocationFromJSON = hrisLocationFromJSON;
//# sourceMappingURL=hrislocation.js.map