"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.UpdateUserRoleResponseEnum$inboundSchema = exports.UpdateUserRoleTypeResponse$ = exports.UpdateUserRoleTypeResponse$outboundSchema = exports.UpdateUserRoleTypeResponse$inboundSchema = exports.UpdateUserUserIdResponse$ = exports.UpdateUserUserIdResponse$outboundSchema = exports.UpdateUserUserIdResponse$inboundSchema = exports.UpdateUserStatusResponse$ = exports.UpdateUserStatusResponse$outboundSchema = exports.UpdateUserStatusResponse$inboundSchema = exports.UpdateUserRequest$ = exports.UpdateUserRequest$outboundSchema = exports.UpdateUserRequest$inboundSchema = exports.UpdateUserRequestBody$ = exports.UpdateUserRequestBody$outboundSchema = exports.UpdateUserRequestBody$inboundSchema = exports.UpdateUserUserRequest$ = exports.UpdateUserUserRequest$outboundSchema = exports.UpdateUserUserRequest$inboundSchema = exports.UpdateUserAgentRequest$ = exports.UpdateUserAgentRequest$outboundSchema = exports.UpdateUserAgentRequest$inboundSchema = exports.UpdateUserPrimaryOrgRequest$ = exports.UpdateUserPrimaryOrgRequest$outboundSchema = exports.UpdateUserPrimaryOrgRequest$inboundSchema = exports.UpdateUserRoleRequest$ = exports.UpdateUserRoleRequest$outboundSchema = exports.UpdateUserRoleRequest$inboundSchema = exports.UpdateUserOrgRequest$ = exports.UpdateUserOrgRequest$outboundSchema = exports.UpdateUserOrgRequest$inboundSchema = exports.UpdateUserRoleRequestEnum$ = exports.UpdateUserRoleRequestEnum$outboundSchema = exports.UpdateUserRoleRequestEnum$inboundSchema = exports.UpdateUserRoleTypeRequest$ = exports.UpdateUserRoleTypeRequest$outboundSchema = exports.UpdateUserRoleTypeRequest$inboundSchema = exports.UpdateUserUserIdRequest$ = exports.UpdateUserUserIdRequest$outboundSchema = exports.UpdateUserUserIdRequest$inboundSchema = exports.UpdateUserStatusRequest$ = exports.UpdateUserStatusRequest$outboundSchema = exports.UpdateUserStatusRequest$inboundSchema = exports.UpdateUserType = exports.UpdateUserRoleResponseEnum = exports.UpdateUserRoleTypeResponse = exports.UpdateUserStatusResponse = exports.UpdateUserRoleRequestEnum = exports.UpdateUserRoleTypeRequest = exports.UpdateUserStatusRequest = void 0;
exports.UpdateUserResponse$ = exports.UpdateUserResponse$outboundSchema = exports.UpdateUserResponse$inboundSchema = exports.UpdateUserUserResponse$ = exports.UpdateUserUserResponse$outboundSchema = exports.UpdateUserUserResponse$inboundSchema = exports.UpdateUserPrimaryOrgResponse$ = exports.UpdateUserPrimaryOrgResponse$outboundSchema = exports.UpdateUserPrimaryOrgResponse$inboundSchema = exports.UpdateUserAgentResponse$ = exports.UpdateUserAgentResponse$outboundSchema = exports.UpdateUserAgentResponse$inboundSchema = exports.UpdateUserType$ = exports.UpdateUserType$outboundSchema = exports.UpdateUserType$inboundSchema = exports.UpdateUserRoleResponse$ = exports.UpdateUserRoleResponse$outboundSchema = exports.UpdateUserRoleResponse$inboundSchema = exports.UpdateUserOrgResponse$ = exports.UpdateUserOrgResponse$outboundSchema = exports.UpdateUserOrgResponse$inboundSchema = exports.UpdateUserRoleResponseEnum$ = exports.UpdateUserRoleResponseEnum$outboundSchema = void 0;
exports.updateUserUserIdRequestToJSON = updateUserUserIdRequestToJSON;
exports.updateUserUserIdRequestFromJSON = updateUserUserIdRequestFromJSON;
exports.updateUserOrgRequestToJSON = updateUserOrgRequestToJSON;
exports.updateUserOrgRequestFromJSON = updateUserOrgRequestFromJSON;
exports.updateUserRoleRequestToJSON = updateUserRoleRequestToJSON;
exports.updateUserRoleRequestFromJSON = updateUserRoleRequestFromJSON;
exports.updateUserPrimaryOrgRequestToJSON = updateUserPrimaryOrgRequestToJSON;
exports.updateUserPrimaryOrgRequestFromJSON = updateUserPrimaryOrgRequestFromJSON;
exports.updateUserAgentRequestToJSON = updateUserAgentRequestToJSON;
exports.updateUserAgentRequestFromJSON = updateUserAgentRequestFromJSON;
exports.updateUserUserRequestToJSON = updateUserUserRequestToJSON;
exports.updateUserUserRequestFromJSON = updateUserUserRequestFromJSON;
exports.updateUserRequestBodyToJSON = updateUserRequestBodyToJSON;
exports.updateUserRequestBodyFromJSON = updateUserRequestBodyFromJSON;
exports.updateUserRequestToJSON = updateUserRequestToJSON;
exports.updateUserRequestFromJSON = updateUserRequestFromJSON;
exports.updateUserUserIdResponseToJSON = updateUserUserIdResponseToJSON;
exports.updateUserUserIdResponseFromJSON = updateUserUserIdResponseFromJSON;
exports.updateUserOrgResponseToJSON = updateUserOrgResponseToJSON;
exports.updateUserOrgResponseFromJSON = updateUserOrgResponseFromJSON;
exports.updateUserRoleResponseToJSON = updateUserRoleResponseToJSON;
exports.updateUserRoleResponseFromJSON = updateUserRoleResponseFromJSON;
exports.updateUserAgentResponseToJSON = updateUserAgentResponseToJSON;
exports.updateUserAgentResponseFromJSON = updateUserAgentResponseFromJSON;
exports.updateUserPrimaryOrgResponseToJSON = updateUserPrimaryOrgResponseToJSON;
exports.updateUserPrimaryOrgResponseFromJSON = updateUserPrimaryOrgResponseFromJSON;
exports.updateUserUserResponseToJSON = updateUserUserResponseToJSON;
exports.updateUserUserResponseFromJSON = updateUserUserResponseFromJSON;
exports.updateUserResponseToJSON = updateUserResponseToJSON;
exports.updateUserResponseFromJSON = updateUserResponseFromJSON;
const z = __importStar(require("zod"));
const primitives_js_1 = require("../../lib/primitives.js");
const schemas_js_1 = require("../../lib/schemas.js");
exports.UpdateUserStatusRequest = {
    Active: "active",
    Tobedeleted: "tobedeleted",
};
exports.UpdateUserRoleTypeRequest = {
    Primary: "primary",
    Secondary: "secondary",
};
exports.UpdateUserRoleRequestEnum = {
    Administrator: "administrator",
    Aide: "aide",
    Guardian: "guardian",
    Parent: "parent",
    Proctor: "proctor",
    Relative: "relative",
    Student: "student",
    Teacher: "teacher",
};
exports.UpdateUserStatusResponse = {
    Active: "active",
    Tobedeleted: "tobedeleted",
};
exports.UpdateUserRoleTypeResponse = {
    Primary: "primary",
    Secondary: "secondary",
};
exports.UpdateUserRoleResponseEnum = {
    Administrator: "administrator",
    Aide: "aide",
    Guardian: "guardian",
    Parent: "parent",
    Proctor: "proctor",
    Relative: "relative",
    Student: "student",
    Teacher: "teacher",
};
exports.UpdateUserType = {
    AcademicSession: "academicSession",
    AssessmentLineItem: "assessmentLineItem",
    Category: "category",
    Class: "class",
    Course: "course",
    Demographics: "demographics",
    Enrollment: "enrollment",
    GradingPeriod: "gradingPeriod",
    LineItem: "lineItem",
    Org: "org",
    Resource: "resource",
    Result: "result",
    ScoreScale: "scoreScale",
    Student: "student",
    Teacher: "teacher",
    Term: "term",
    User: "user",
    ComponentResource: "componentResource",
    CourseComponent: "courseComponent",
};
/** @internal */
exports.UpdateUserStatusRequest$inboundSchema = z.nativeEnum(exports.UpdateUserStatusRequest);
/** @internal */
exports.UpdateUserStatusRequest$outboundSchema = exports.UpdateUserStatusRequest$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserStatusRequest$;
(function (UpdateUserStatusRequest$) {
    /** @deprecated use `UpdateUserStatusRequest$inboundSchema` instead. */
    UpdateUserStatusRequest$.inboundSchema = exports.UpdateUserStatusRequest$inboundSchema;
    /** @deprecated use `UpdateUserStatusRequest$outboundSchema` instead. */
    UpdateUserStatusRequest$.outboundSchema = exports.UpdateUserStatusRequest$outboundSchema;
})(UpdateUserStatusRequest$ || (exports.UpdateUserStatusRequest$ = UpdateUserStatusRequest$ = {}));
/** @internal */
exports.UpdateUserUserIdRequest$inboundSchema = z.object({
    type: z.string(),
    identifier: z.string(),
});
/** @internal */
exports.UpdateUserUserIdRequest$outboundSchema = z.object({
    type: z.string(),
    identifier: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserUserIdRequest$;
(function (UpdateUserUserIdRequest$) {
    /** @deprecated use `UpdateUserUserIdRequest$inboundSchema` instead. */
    UpdateUserUserIdRequest$.inboundSchema = exports.UpdateUserUserIdRequest$inboundSchema;
    /** @deprecated use `UpdateUserUserIdRequest$outboundSchema` instead. */
    UpdateUserUserIdRequest$.outboundSchema = exports.UpdateUserUserIdRequest$outboundSchema;
})(UpdateUserUserIdRequest$ || (exports.UpdateUserUserIdRequest$ = UpdateUserUserIdRequest$ = {}));
function updateUserUserIdRequestToJSON(updateUserUserIdRequest) {
    return JSON.stringify(exports.UpdateUserUserIdRequest$outboundSchema.parse(updateUserUserIdRequest));
}
function updateUserUserIdRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserUserIdRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserUserIdRequest' from JSON`);
}
/** @internal */
exports.UpdateUserRoleTypeRequest$inboundSchema = z.nativeEnum(exports.UpdateUserRoleTypeRequest);
/** @internal */
exports.UpdateUserRoleTypeRequest$outboundSchema = exports.UpdateUserRoleTypeRequest$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserRoleTypeRequest$;
(function (UpdateUserRoleTypeRequest$) {
    /** @deprecated use `UpdateUserRoleTypeRequest$inboundSchema` instead. */
    UpdateUserRoleTypeRequest$.inboundSchema = exports.UpdateUserRoleTypeRequest$inboundSchema;
    /** @deprecated use `UpdateUserRoleTypeRequest$outboundSchema` instead. */
    UpdateUserRoleTypeRequest$.outboundSchema = exports.UpdateUserRoleTypeRequest$outboundSchema;
})(UpdateUserRoleTypeRequest$ || (exports.UpdateUserRoleTypeRequest$ = UpdateUserRoleTypeRequest$ = {}));
/** @internal */
exports.UpdateUserRoleRequestEnum$inboundSchema = z.nativeEnum(exports.UpdateUserRoleRequestEnum);
/** @internal */
exports.UpdateUserRoleRequestEnum$outboundSchema = exports.UpdateUserRoleRequestEnum$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserRoleRequestEnum$;
(function (UpdateUserRoleRequestEnum$) {
    /** @deprecated use `UpdateUserRoleRequestEnum$inboundSchema` instead. */
    UpdateUserRoleRequestEnum$.inboundSchema = exports.UpdateUserRoleRequestEnum$inboundSchema;
    /** @deprecated use `UpdateUserRoleRequestEnum$outboundSchema` instead. */
    UpdateUserRoleRequestEnum$.outboundSchema = exports.UpdateUserRoleRequestEnum$outboundSchema;
})(UpdateUserRoleRequestEnum$ || (exports.UpdateUserRoleRequestEnum$ = UpdateUserRoleRequestEnum$ = {}));
/** @internal */
exports.UpdateUserOrgRequest$inboundSchema = z.object({
    sourcedId: z.string(),
});
/** @internal */
exports.UpdateUserOrgRequest$outboundSchema = z.object({
    sourcedId: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserOrgRequest$;
(function (UpdateUserOrgRequest$) {
    /** @deprecated use `UpdateUserOrgRequest$inboundSchema` instead. */
    UpdateUserOrgRequest$.inboundSchema = exports.UpdateUserOrgRequest$inboundSchema;
    /** @deprecated use `UpdateUserOrgRequest$outboundSchema` instead. */
    UpdateUserOrgRequest$.outboundSchema = exports.UpdateUserOrgRequest$outboundSchema;
})(UpdateUserOrgRequest$ || (exports.UpdateUserOrgRequest$ = UpdateUserOrgRequest$ = {}));
function updateUserOrgRequestToJSON(updateUserOrgRequest) {
    return JSON.stringify(exports.UpdateUserOrgRequest$outboundSchema.parse(updateUserOrgRequest));
}
function updateUserOrgRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserOrgRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserOrgRequest' from JSON`);
}
/** @internal */
exports.UpdateUserRoleRequest$inboundSchema = z.object({
    roleType: exports.UpdateUserRoleTypeRequest$inboundSchema,
    role: exports.UpdateUserRoleRequestEnum$inboundSchema,
    org: z.lazy(() => exports.UpdateUserOrgRequest$inboundSchema),
    userProfile: z.string().optional(),
    beginDate: z.string().optional(),
    endDate: z.string().optional(),
});
/** @internal */
exports.UpdateUserRoleRequest$outboundSchema = z.object({
    roleType: exports.UpdateUserRoleTypeRequest$outboundSchema,
    role: exports.UpdateUserRoleRequestEnum$outboundSchema,
    org: z.lazy(() => exports.UpdateUserOrgRequest$outboundSchema),
    userProfile: z.string().optional(),
    beginDate: z.string().optional(),
    endDate: 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 UpdateUserRoleRequest$;
(function (UpdateUserRoleRequest$) {
    /** @deprecated use `UpdateUserRoleRequest$inboundSchema` instead. */
    UpdateUserRoleRequest$.inboundSchema = exports.UpdateUserRoleRequest$inboundSchema;
    /** @deprecated use `UpdateUserRoleRequest$outboundSchema` instead. */
    UpdateUserRoleRequest$.outboundSchema = exports.UpdateUserRoleRequest$outboundSchema;
})(UpdateUserRoleRequest$ || (exports.UpdateUserRoleRequest$ = UpdateUserRoleRequest$ = {}));
function updateUserRoleRequestToJSON(updateUserRoleRequest) {
    return JSON.stringify(exports.UpdateUserRoleRequest$outboundSchema.parse(updateUserRoleRequest));
}
function updateUserRoleRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserRoleRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserRoleRequest' from JSON`);
}
/** @internal */
exports.UpdateUserPrimaryOrgRequest$inboundSchema = z.object({
    sourcedId: z.string(),
});
/** @internal */
exports.UpdateUserPrimaryOrgRequest$outboundSchema = z.object({
    sourcedId: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserPrimaryOrgRequest$;
(function (UpdateUserPrimaryOrgRequest$) {
    /** @deprecated use `UpdateUserPrimaryOrgRequest$inboundSchema` instead. */
    UpdateUserPrimaryOrgRequest$.inboundSchema = exports.UpdateUserPrimaryOrgRequest$inboundSchema;
    /** @deprecated use `UpdateUserPrimaryOrgRequest$outboundSchema` instead. */
    UpdateUserPrimaryOrgRequest$.outboundSchema = exports.UpdateUserPrimaryOrgRequest$outboundSchema;
})(UpdateUserPrimaryOrgRequest$ || (exports.UpdateUserPrimaryOrgRequest$ = UpdateUserPrimaryOrgRequest$ = {}));
function updateUserPrimaryOrgRequestToJSON(updateUserPrimaryOrgRequest) {
    return JSON.stringify(exports.UpdateUserPrimaryOrgRequest$outboundSchema.parse(updateUserPrimaryOrgRequest));
}
function updateUserPrimaryOrgRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserPrimaryOrgRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserPrimaryOrgRequest' from JSON`);
}
/** @internal */
exports.UpdateUserAgentRequest$inboundSchema = z.object({
    sourcedId: z.string(),
});
/** @internal */
exports.UpdateUserAgentRequest$outboundSchema = z.object({
    sourcedId: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserAgentRequest$;
(function (UpdateUserAgentRequest$) {
    /** @deprecated use `UpdateUserAgentRequest$inboundSchema` instead. */
    UpdateUserAgentRequest$.inboundSchema = exports.UpdateUserAgentRequest$inboundSchema;
    /** @deprecated use `UpdateUserAgentRequest$outboundSchema` instead. */
    UpdateUserAgentRequest$.outboundSchema = exports.UpdateUserAgentRequest$outboundSchema;
})(UpdateUserAgentRequest$ || (exports.UpdateUserAgentRequest$ = UpdateUserAgentRequest$ = {}));
function updateUserAgentRequestToJSON(updateUserAgentRequest) {
    return JSON.stringify(exports.UpdateUserAgentRequest$outboundSchema.parse(updateUserAgentRequest));
}
function updateUserAgentRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserAgentRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserAgentRequest' from JSON`);
}
/** @internal */
exports.UpdateUserUserRequest$inboundSchema = z.object({
    sourcedId: z.string().optional(),
    metadata: z.record(z.any()).optional(),
    status: exports.UpdateUserStatusRequest$inboundSchema.default("active"),
    userMasterIdentifier: z.nullable(z.string()).optional(),
    username: z.nullable(z.string()).optional(),
    userIds: z.array(z.lazy(() => exports.UpdateUserUserIdRequest$inboundSchema))
        .optional(),
    enabledUser: z.boolean(),
    givenName: z.string(),
    familyName: z.string(),
    middleName: z.nullable(z.string()).optional(),
    roles: z.array(z.lazy(() => exports.UpdateUserRoleRequest$inboundSchema)),
    primaryOrg: z.lazy(() => exports.UpdateUserPrimaryOrgRequest$inboundSchema)
        .optional(),
    email: z.nullable(z.string()).optional(),
    preferredFirstName: z.nullable(z.string()).optional(),
    preferredMiddleName: z.nullable(z.string()).optional(),
    preferredLastName: z.nullable(z.string()).optional(),
    pronouns: z.nullable(z.string()).optional(),
    grades: z.array(z.string()).optional(),
    password: z.nullable(z.string()).optional(),
    sms: z.nullable(z.string()).optional(),
    phone: z.nullable(z.string()).optional(),
    agents: z.array(z.lazy(() => exports.UpdateUserAgentRequest$inboundSchema))
        .optional(),
});
/** @internal */
exports.UpdateUserUserRequest$outboundSchema = z.object({
    sourcedId: z.string().optional(),
    metadata: z.record(z.any()).optional(),
    status: exports.UpdateUserStatusRequest$outboundSchema.default("active"),
    userMasterIdentifier: z.nullable(z.string()).optional(),
    username: z.nullable(z.string()).optional(),
    userIds: z.array(z.lazy(() => exports.UpdateUserUserIdRequest$outboundSchema))
        .optional(),
    enabledUser: z.boolean(),
    givenName: z.string(),
    familyName: z.string(),
    middleName: z.nullable(z.string()).optional(),
    roles: z.array(z.lazy(() => exports.UpdateUserRoleRequest$outboundSchema)),
    primaryOrg: z.lazy(() => exports.UpdateUserPrimaryOrgRequest$outboundSchema)
        .optional(),
    email: z.nullable(z.string()).optional(),
    preferredFirstName: z.nullable(z.string()).optional(),
    preferredMiddleName: z.nullable(z.string()).optional(),
    preferredLastName: z.nullable(z.string()).optional(),
    pronouns: z.nullable(z.string()).optional(),
    grades: z.array(z.string()).optional(),
    password: z.nullable(z.string()).optional(),
    sms: z.nullable(z.string()).optional(),
    phone: z.nullable(z.string()).optional(),
    agents: z.array(z.lazy(() => exports.UpdateUserAgentRequest$outboundSchema))
        .optional(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserUserRequest$;
(function (UpdateUserUserRequest$) {
    /** @deprecated use `UpdateUserUserRequest$inboundSchema` instead. */
    UpdateUserUserRequest$.inboundSchema = exports.UpdateUserUserRequest$inboundSchema;
    /** @deprecated use `UpdateUserUserRequest$outboundSchema` instead. */
    UpdateUserUserRequest$.outboundSchema = exports.UpdateUserUserRequest$outboundSchema;
})(UpdateUserUserRequest$ || (exports.UpdateUserUserRequest$ = UpdateUserUserRequest$ = {}));
function updateUserUserRequestToJSON(updateUserUserRequest) {
    return JSON.stringify(exports.UpdateUserUserRequest$outboundSchema.parse(updateUserUserRequest));
}
function updateUserUserRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserUserRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserUserRequest' from JSON`);
}
/** @internal */
exports.UpdateUserRequestBody$inboundSchema = z.object({
    user: z.lazy(() => exports.UpdateUserUserRequest$inboundSchema),
});
/** @internal */
exports.UpdateUserRequestBody$outboundSchema = z.object({
    user: z.lazy(() => exports.UpdateUserUserRequest$outboundSchema),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserRequestBody$;
(function (UpdateUserRequestBody$) {
    /** @deprecated use `UpdateUserRequestBody$inboundSchema` instead. */
    UpdateUserRequestBody$.inboundSchema = exports.UpdateUserRequestBody$inboundSchema;
    /** @deprecated use `UpdateUserRequestBody$outboundSchema` instead. */
    UpdateUserRequestBody$.outboundSchema = exports.UpdateUserRequestBody$outboundSchema;
})(UpdateUserRequestBody$ || (exports.UpdateUserRequestBody$ = UpdateUserRequestBody$ = {}));
function updateUserRequestBodyToJSON(updateUserRequestBody) {
    return JSON.stringify(exports.UpdateUserRequestBody$outboundSchema.parse(updateUserRequestBody));
}
function updateUserRequestBodyFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserRequestBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserRequestBody' from JSON`);
}
/** @internal */
exports.UpdateUserRequest$inboundSchema = z.object({
    sourcedId: z.string(),
    RequestBody: z.lazy(() => exports.UpdateUserRequestBody$inboundSchema),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        "RequestBody": "requestBody",
    });
});
/** @internal */
exports.UpdateUserRequest$outboundSchema = z.object({
    sourcedId: z.string(),
    requestBody: z.lazy(() => exports.UpdateUserRequestBody$outboundSchema),
}).transform((v) => {
    return (0, primitives_js_1.remap)(v, {
        requestBody: "RequestBody",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserRequest$;
(function (UpdateUserRequest$) {
    /** @deprecated use `UpdateUserRequest$inboundSchema` instead. */
    UpdateUserRequest$.inboundSchema = exports.UpdateUserRequest$inboundSchema;
    /** @deprecated use `UpdateUserRequest$outboundSchema` instead. */
    UpdateUserRequest$.outboundSchema = exports.UpdateUserRequest$outboundSchema;
})(UpdateUserRequest$ || (exports.UpdateUserRequest$ = UpdateUserRequest$ = {}));
function updateUserRequestToJSON(updateUserRequest) {
    return JSON.stringify(exports.UpdateUserRequest$outboundSchema.parse(updateUserRequest));
}
function updateUserRequestFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserRequest' from JSON`);
}
/** @internal */
exports.UpdateUserStatusResponse$inboundSchema = z.nativeEnum(exports.UpdateUserStatusResponse);
/** @internal */
exports.UpdateUserStatusResponse$outboundSchema = exports.UpdateUserStatusResponse$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserStatusResponse$;
(function (UpdateUserStatusResponse$) {
    /** @deprecated use `UpdateUserStatusResponse$inboundSchema` instead. */
    UpdateUserStatusResponse$.inboundSchema = exports.UpdateUserStatusResponse$inboundSchema;
    /** @deprecated use `UpdateUserStatusResponse$outboundSchema` instead. */
    UpdateUserStatusResponse$.outboundSchema = exports.UpdateUserStatusResponse$outboundSchema;
})(UpdateUserStatusResponse$ || (exports.UpdateUserStatusResponse$ = UpdateUserStatusResponse$ = {}));
/** @internal */
exports.UpdateUserUserIdResponse$inboundSchema = z.object({
    type: z.string(),
    identifier: z.string(),
});
/** @internal */
exports.UpdateUserUserIdResponse$outboundSchema = z.object({
    type: z.string(),
    identifier: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserUserIdResponse$;
(function (UpdateUserUserIdResponse$) {
    /** @deprecated use `UpdateUserUserIdResponse$inboundSchema` instead. */
    UpdateUserUserIdResponse$.inboundSchema = exports.UpdateUserUserIdResponse$inboundSchema;
    /** @deprecated use `UpdateUserUserIdResponse$outboundSchema` instead. */
    UpdateUserUserIdResponse$.outboundSchema = exports.UpdateUserUserIdResponse$outboundSchema;
})(UpdateUserUserIdResponse$ || (exports.UpdateUserUserIdResponse$ = UpdateUserUserIdResponse$ = {}));
function updateUserUserIdResponseToJSON(updateUserUserIdResponse) {
    return JSON.stringify(exports.UpdateUserUserIdResponse$outboundSchema.parse(updateUserUserIdResponse));
}
function updateUserUserIdResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserUserIdResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserUserIdResponse' from JSON`);
}
/** @internal */
exports.UpdateUserRoleTypeResponse$inboundSchema = z.nativeEnum(exports.UpdateUserRoleTypeResponse);
/** @internal */
exports.UpdateUserRoleTypeResponse$outboundSchema = exports.UpdateUserRoleTypeResponse$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserRoleTypeResponse$;
(function (UpdateUserRoleTypeResponse$) {
    /** @deprecated use `UpdateUserRoleTypeResponse$inboundSchema` instead. */
    UpdateUserRoleTypeResponse$.inboundSchema = exports.UpdateUserRoleTypeResponse$inboundSchema;
    /** @deprecated use `UpdateUserRoleTypeResponse$outboundSchema` instead. */
    UpdateUserRoleTypeResponse$.outboundSchema = exports.UpdateUserRoleTypeResponse$outboundSchema;
})(UpdateUserRoleTypeResponse$ || (exports.UpdateUserRoleTypeResponse$ = UpdateUserRoleTypeResponse$ = {}));
/** @internal */
exports.UpdateUserRoleResponseEnum$inboundSchema = z.nativeEnum(exports.UpdateUserRoleResponseEnum);
/** @internal */
exports.UpdateUserRoleResponseEnum$outboundSchema = exports.UpdateUserRoleResponseEnum$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserRoleResponseEnum$;
(function (UpdateUserRoleResponseEnum$) {
    /** @deprecated use `UpdateUserRoleResponseEnum$inboundSchema` instead. */
    UpdateUserRoleResponseEnum$.inboundSchema = exports.UpdateUserRoleResponseEnum$inboundSchema;
    /** @deprecated use `UpdateUserRoleResponseEnum$outboundSchema` instead. */
    UpdateUserRoleResponseEnum$.outboundSchema = exports.UpdateUserRoleResponseEnum$outboundSchema;
})(UpdateUserRoleResponseEnum$ || (exports.UpdateUserRoleResponseEnum$ = UpdateUserRoleResponseEnum$ = {}));
/** @internal */
exports.UpdateUserOrgResponse$inboundSchema = z.object({
    href: z.string(),
    sourcedId: z.string(),
    type: z.string(),
});
/** @internal */
exports.UpdateUserOrgResponse$outboundSchema = z.object({
    href: z.string(),
    sourcedId: z.string(),
    type: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserOrgResponse$;
(function (UpdateUserOrgResponse$) {
    /** @deprecated use `UpdateUserOrgResponse$inboundSchema` instead. */
    UpdateUserOrgResponse$.inboundSchema = exports.UpdateUserOrgResponse$inboundSchema;
    /** @deprecated use `UpdateUserOrgResponse$outboundSchema` instead. */
    UpdateUserOrgResponse$.outboundSchema = exports.UpdateUserOrgResponse$outboundSchema;
})(UpdateUserOrgResponse$ || (exports.UpdateUserOrgResponse$ = UpdateUserOrgResponse$ = {}));
function updateUserOrgResponseToJSON(updateUserOrgResponse) {
    return JSON.stringify(exports.UpdateUserOrgResponse$outboundSchema.parse(updateUserOrgResponse));
}
function updateUserOrgResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserOrgResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserOrgResponse' from JSON`);
}
/** @internal */
exports.UpdateUserRoleResponse$inboundSchema = z.object({
    roleType: exports.UpdateUserRoleTypeResponse$inboundSchema,
    role: exports.UpdateUserRoleResponseEnum$inboundSchema,
    org: z.lazy(() => exports.UpdateUserOrgResponse$inboundSchema),
    userProfile: z.string().optional(),
    beginDate: z.nullable(z.string()),
    endDate: z.nullable(z.string()),
});
/** @internal */
exports.UpdateUserRoleResponse$outboundSchema = z.object({
    roleType: exports.UpdateUserRoleTypeResponse$outboundSchema,
    role: exports.UpdateUserRoleResponseEnum$outboundSchema,
    org: z.lazy(() => exports.UpdateUserOrgResponse$outboundSchema),
    userProfile: z.string().optional(),
    beginDate: z.nullable(z.string()),
    endDate: z.nullable(z.string()),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserRoleResponse$;
(function (UpdateUserRoleResponse$) {
    /** @deprecated use `UpdateUserRoleResponse$inboundSchema` instead. */
    UpdateUserRoleResponse$.inboundSchema = exports.UpdateUserRoleResponse$inboundSchema;
    /** @deprecated use `UpdateUserRoleResponse$outboundSchema` instead. */
    UpdateUserRoleResponse$.outboundSchema = exports.UpdateUserRoleResponse$outboundSchema;
})(UpdateUserRoleResponse$ || (exports.UpdateUserRoleResponse$ = UpdateUserRoleResponse$ = {}));
function updateUserRoleResponseToJSON(updateUserRoleResponse) {
    return JSON.stringify(exports.UpdateUserRoleResponse$outboundSchema.parse(updateUserRoleResponse));
}
function updateUserRoleResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserRoleResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserRoleResponse' from JSON`);
}
/** @internal */
exports.UpdateUserType$inboundSchema = z.nativeEnum(exports.UpdateUserType);
/** @internal */
exports.UpdateUserType$outboundSchema = exports.UpdateUserType$inboundSchema;
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserType$;
(function (UpdateUserType$) {
    /** @deprecated use `UpdateUserType$inboundSchema` instead. */
    UpdateUserType$.inboundSchema = exports.UpdateUserType$inboundSchema;
    /** @deprecated use `UpdateUserType$outboundSchema` instead. */
    UpdateUserType$.outboundSchema = exports.UpdateUserType$outboundSchema;
})(UpdateUserType$ || (exports.UpdateUserType$ = UpdateUserType$ = {}));
/** @internal */
exports.UpdateUserAgentResponse$inboundSchema = z.object({
    href: z.string(),
    sourcedId: z.string(),
    type: exports.UpdateUserType$inboundSchema,
});
/** @internal */
exports.UpdateUserAgentResponse$outboundSchema = z.object({
    href: z.string(),
    sourcedId: z.string(),
    type: exports.UpdateUserType$outboundSchema,
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserAgentResponse$;
(function (UpdateUserAgentResponse$) {
    /** @deprecated use `UpdateUserAgentResponse$inboundSchema` instead. */
    UpdateUserAgentResponse$.inboundSchema = exports.UpdateUserAgentResponse$inboundSchema;
    /** @deprecated use `UpdateUserAgentResponse$outboundSchema` instead. */
    UpdateUserAgentResponse$.outboundSchema = exports.UpdateUserAgentResponse$outboundSchema;
})(UpdateUserAgentResponse$ || (exports.UpdateUserAgentResponse$ = UpdateUserAgentResponse$ = {}));
function updateUserAgentResponseToJSON(updateUserAgentResponse) {
    return JSON.stringify(exports.UpdateUserAgentResponse$outboundSchema.parse(updateUserAgentResponse));
}
function updateUserAgentResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserAgentResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserAgentResponse' from JSON`);
}
/** @internal */
exports.UpdateUserPrimaryOrgResponse$inboundSchema = z.object({
    href: z.string(),
    sourcedId: z.string(),
    type: z.string(),
});
/** @internal */
exports.UpdateUserPrimaryOrgResponse$outboundSchema = z.object({
    href: z.string(),
    sourcedId: z.string(),
    type: z.string(),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserPrimaryOrgResponse$;
(function (UpdateUserPrimaryOrgResponse$) {
    /** @deprecated use `UpdateUserPrimaryOrgResponse$inboundSchema` instead. */
    UpdateUserPrimaryOrgResponse$.inboundSchema = exports.UpdateUserPrimaryOrgResponse$inboundSchema;
    /** @deprecated use `UpdateUserPrimaryOrgResponse$outboundSchema` instead. */
    UpdateUserPrimaryOrgResponse$.outboundSchema = exports.UpdateUserPrimaryOrgResponse$outboundSchema;
})(UpdateUserPrimaryOrgResponse$ || (exports.UpdateUserPrimaryOrgResponse$ = UpdateUserPrimaryOrgResponse$ = {}));
function updateUserPrimaryOrgResponseToJSON(updateUserPrimaryOrgResponse) {
    return JSON.stringify(exports.UpdateUserPrimaryOrgResponse$outboundSchema.parse(updateUserPrimaryOrgResponse));
}
function updateUserPrimaryOrgResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserPrimaryOrgResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserPrimaryOrgResponse' from JSON`);
}
/** @internal */
exports.UpdateUserUserResponse$inboundSchema = z.object({
    sourcedId: z.string(),
    status: exports.UpdateUserStatusResponse$inboundSchema,
    dateLastModified: z.string().datetime({ offset: true }).transform(v => new Date(v)).optional(),
    metadata: z.nullable(z.record(z.any())).optional(),
    userMasterIdentifier: z.nullable(z.string()).optional(),
    username: z.nullable(z.string()).optional(),
    userIds: z.array(z.lazy(() => exports.UpdateUserUserIdResponse$inboundSchema))
        .optional(),
    enabledUser: z.boolean(),
    givenName: z.string(),
    familyName: z.string(),
    middleName: z.nullable(z.string()).optional(),
    roles: z.array(z.lazy(() => exports.UpdateUserRoleResponse$inboundSchema)),
    agents: z.array(z.lazy(() => exports.UpdateUserAgentResponse$inboundSchema)),
    primaryOrg: z.lazy(() => exports.UpdateUserPrimaryOrgResponse$inboundSchema)
        .optional(),
    email: z.nullable(z.string()).optional(),
    preferredFirstName: z.nullable(z.string()).optional(),
    preferredMiddleName: z.nullable(z.string()).optional(),
    preferredLastName: z.nullable(z.string()).optional(),
    pronouns: z.nullable(z.string()).optional(),
    grades: z.array(z.string()).optional(),
    password: z.nullable(z.string()).optional(),
    sms: z.nullable(z.string()).optional(),
    phone: z.nullable(z.string()).optional(),
});
/** @internal */
exports.UpdateUserUserResponse$outboundSchema = z.object({
    sourcedId: z.string(),
    status: exports.UpdateUserStatusResponse$outboundSchema,
    dateLastModified: z.date().transform(v => v.toISOString()).optional(),
    metadata: z.nullable(z.record(z.any())).optional(),
    userMasterIdentifier: z.nullable(z.string()).optional(),
    username: z.nullable(z.string()).optional(),
    userIds: z.array(z.lazy(() => exports.UpdateUserUserIdResponse$outboundSchema))
        .optional(),
    enabledUser: z.boolean(),
    givenName: z.string(),
    familyName: z.string(),
    middleName: z.nullable(z.string()).optional(),
    roles: z.array(z.lazy(() => exports.UpdateUserRoleResponse$outboundSchema)),
    agents: z.array(z.lazy(() => exports.UpdateUserAgentResponse$outboundSchema)),
    primaryOrg: z.lazy(() => exports.UpdateUserPrimaryOrgResponse$outboundSchema)
        .optional(),
    email: z.nullable(z.string()).optional(),
    preferredFirstName: z.nullable(z.string()).optional(),
    preferredMiddleName: z.nullable(z.string()).optional(),
    preferredLastName: z.nullable(z.string()).optional(),
    pronouns: z.nullable(z.string()).optional(),
    grades: z.array(z.string()).optional(),
    password: z.nullable(z.string()).optional(),
    sms: z.nullable(z.string()).optional(),
    phone: 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 UpdateUserUserResponse$;
(function (UpdateUserUserResponse$) {
    /** @deprecated use `UpdateUserUserResponse$inboundSchema` instead. */
    UpdateUserUserResponse$.inboundSchema = exports.UpdateUserUserResponse$inboundSchema;
    /** @deprecated use `UpdateUserUserResponse$outboundSchema` instead. */
    UpdateUserUserResponse$.outboundSchema = exports.UpdateUserUserResponse$outboundSchema;
})(UpdateUserUserResponse$ || (exports.UpdateUserUserResponse$ = UpdateUserUserResponse$ = {}));
function updateUserUserResponseToJSON(updateUserUserResponse) {
    return JSON.stringify(exports.UpdateUserUserResponse$outboundSchema.parse(updateUserUserResponse));
}
function updateUserUserResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserUserResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserUserResponse' from JSON`);
}
/** @internal */
exports.UpdateUserResponse$inboundSchema = z.object({
    user: z.lazy(() => exports.UpdateUserUserResponse$inboundSchema),
});
/** @internal */
exports.UpdateUserResponse$outboundSchema = z.object({
    user: z.lazy(() => exports.UpdateUserUserResponse$outboundSchema),
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
var UpdateUserResponse$;
(function (UpdateUserResponse$) {
    /** @deprecated use `UpdateUserResponse$inboundSchema` instead. */
    UpdateUserResponse$.inboundSchema = exports.UpdateUserResponse$inboundSchema;
    /** @deprecated use `UpdateUserResponse$outboundSchema` instead. */
    UpdateUserResponse$.outboundSchema = exports.UpdateUserResponse$outboundSchema;
})(UpdateUserResponse$ || (exports.UpdateUserResponse$ = UpdateUserResponse$ = {}));
function updateUserResponseToJSON(updateUserResponse) {
    return JSON.stringify(exports.UpdateUserResponse$outboundSchema.parse(updateUserResponse));
}
function updateUserResponseFromJSON(jsonString) {
    return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateUserResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateUserResponse' from JSON`);
}
//# sourceMappingURL=updateuser.js.map