user

package
v1.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 14, 2025 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IdentityInfo

type IdentityInfo struct {
	Provider       string    `json:"provider" doc:"identity provider"`
	VerifiedEmails []string  `json:"verified_emails" doc:"verified emails"`
	CreatedAt      time.Time `json:"created_at" doc:"created at time"`
}

type OrganizationInfo

type OrganizationInfo struct {
	Name      string    `json:"name" doc:"organization name"`
	CreatedAt time.Time `json:"created_at" doc:"organization creation time"`
	Role      string    `json:"membership_role" doc:"user's role in this organization"`
	JoinedAt  time.Time `json:"joined_at" doc:"when the user joined this organization"`
}

type User

type User struct {
	// contains filtered or unexported fields
}

func New

func New(options options.Options, logger types.Logger) *User

func (*User) Register

func (g *User) Register(prefixes []string, group huma.API)

type UserInfoResponse

type UserInfoResponse struct {
	Body UserInfoResponseBody
}

type UserInfoResponseBody

type UserInfoResponseBody struct {
	Name                string             `json:"name" doc:"user's name"`
	Email               string             `json:"email" doc:"user's email address"`
	LastLogin           time.Time          `json:"last_login" doc:"user's last login"`
	CreatedAt           time.Time          `json:"created_at" doc:"user's creation time"`
	DefaultOrganization OrganizationInfo   `json:"default_organization" doc:"user's default organization"`
	Organizations       []OrganizationInfo `json:"organizations" doc:"user's organizations"`
	Identities          []IdentityInfo     `json:"identities" doc:"user's identities"`
}

type UserUpdateRequest

type UserUpdateRequest struct {
	Name  string `query:"name" required:"false" minLength:"1" maxLength:"255" doc:"user's name"`
	Email string `query:"email" required:"false" minLength:"3" maxLength:"255" doc:"user's email"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL