UserBase (users.py)

openclaw-mission-control · auth

User API schemas for create, update, and read operations.

"""User API schemas for create, update, and read operations."""

from __future__ import annotations

from uuid import UUID

from pydantic import Field
from sqlmodel import SQLModel

RUNTIME_ANNOTATION_TYPES = (UUID,)


class UserBase(SQLModel):
    """Common user profile fields shared across user payload schemas."""

    clerk_user_id: str = Field(
        description="External auth provider user identifier (Clerk).",
        examples=["user_2abcXYZ"],
    )
    email: str | None = Field(
        default=None,
        description="Primary email address for the user.",
        examples=["alex@example.com"],
    )
    name: str | None = Field(
        default=None,
        description="Full display name.",
        examples=["Alex Chen"],
    )
    preferred_name: str | None = Field(
        

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search 40K more like it.

Get a free API key