import * as Schema from "effect/Schema";
import { API } from "../../client.js";
import * as T from "../../traits.js";
import { BadRequest, Forbidden, NotFound } from "../../errors.js";
// Input Schema
export const MembersUpdateInput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    organization_id: Schema.String.pipe(T.PathParam()),
    user__uuid: Schema.String.pipe(T.PathParam()),
    id: Schema.optional(Schema.String),
    user: Schema.optional(Schema.NullOr(Schema.Struct({
        id: Schema.optional(Schema.Number),
        uuid: Schema.optional(Schema.String),
        distinct_id: Schema.optional(Schema.NullOr(Schema.String)),
        first_name: Schema.optional(Schema.String),
        last_name: Schema.optional(Schema.String),
        email: Schema.optional(Schema.String),
        is_email_verified: Schema.optional(Schema.NullOr(Schema.Boolean)),
        hedgehog_config: Schema.optional(Schema.NullOr(Schema.Record(Schema.String, Schema.Unknown))),
        role_at_organization: Schema.optional(Schema.Unknown),
    }))),
    level: Schema.optional(Schema.Literals([1, 8, 15])),
    joined_at: Schema.optional(Schema.String),
    updated_at: Schema.optional(Schema.String),
    is_2fa_enabled: Schema.optional(Schema.Boolean),
    has_social_auth: Schema.optional(Schema.Boolean),
    last_login: Schema.optional(Schema.String),
}).pipe(T.Http({
    method: "PUT",
    path: "/api/organizations/{organization_id}/members/{user__uuid}/",
}));
// Output Schema
export const MembersUpdateOutput = /*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    id: Schema.optional(Schema.String),
    user: Schema.optional(Schema.NullOr(Schema.Struct({
        id: Schema.optional(Schema.Number),
        uuid: Schema.optional(Schema.String),
        distinct_id: Schema.optional(Schema.NullOr(Schema.String)),
        first_name: Schema.optional(Schema.String),
        last_name: Schema.optional(Schema.String),
        email: Schema.optional(Schema.String),
        is_email_verified: Schema.optional(Schema.NullOr(Schema.Boolean)),
        hedgehog_config: Schema.optional(Schema.NullOr(Schema.Record(Schema.String, Schema.Unknown))),
        role_at_organization: Schema.optional(Schema.Unknown),
    }))),
    level: Schema.optional(Schema.Literals([1, 8, 15])),
    joined_at: Schema.optional(Schema.String),
    updated_at: Schema.optional(Schema.String),
    is_2fa_enabled: Schema.optional(Schema.Boolean),
    has_social_auth: Schema.optional(Schema.Boolean),
    last_login: Schema.optional(Schema.String),
});
// The operation
export const membersUpdate = /*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    inputSchema: MembersUpdateInput,
    outputSchema: MembersUpdateOutput,
    errors: [BadRequest, Forbidden, NotFound],
}));
//# sourceMappingURL=membersUpdate.js.map