Documentation ¶
Index ¶
Constants ¶
View Source
const ( // AccountTypeAdmin define account type ADMIN AccountTypeAdmin = AccountType("ADMIN") // AccountTypeDevice define account type DEVICE AccountTypeDevice = AccountType("DEVICE") // AccountTypeOrg define account type ORG AccountTypeOrg = AccountType("ORG") // AccountTypeService define account type SERVICE AccountTypeService = AccountType("SERVICE") // AccountTypeUser define account type USER AccountTypeUser = AccountType("USER") // AccountTypeSessionUser define account type SESSION AccountTypeSessionUser = AccountType("SESSION") // AccountTypeClient define account type CLIENT AccountTypeClient = AccountType("CLIENT") )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { ID primitive.ObjectID `json:"-" bson:"_id"` Type AccountType `json:"type" bson:"type"` Email string `json:"email" bson:"email"` Nick string `json:"nick" bson:"nick"` Prn string `json:"prn" bson:"prn"` Password string `json:"password,omitempty" bson:"password"` PasswordBcrypt string `json:"password_bcrypt,omitempty" bson:"password_bcrypt"` PasswordScrypt string `json:"password_scrypt,omitempty" bson:"password_scrypt"` Challenge string `json:"challenge,omitempty" bson:"challenge"` TimeCreated time.Time `json:"time-created" bson:"time-created"` TimeModified time.Time `json:"time-modified" bson:"time-modified"` // Oauth2RedirectURIs is limiting the prefix available for redirecting users with oauth code and accesstoken to Oauth2RedirectURIs []string `json:"redirect_uris,omitempty" bson:"redirect_uris,omitempty"` }
Account account information all the structure
func CreateAnonAccount ¶
func CreateAnonAccount() Account
type AccountPublic ¶
type AccountPublic struct { ID primitive.ObjectID `json:"-" bson:"_id"` Type AccountType `json:"type" bson:"type"` Email string `json:"email" bson:"email"` Nick string `json:"nick" bson:"nick"` Prn string `json:"prn" bson:"prn"` TimeCreated time.Time `json:"time-created" bson:"time-created"` TimeModified time.Time `json:"time-modified" bson:"time-modified"` }
AccountPublic Public information for one account
Click to show internal directories.
Click to hide internal directories.