Documentation ¶
Index ¶
- Variables
- type Algorithm
- type Api
- type Apis
- type Attendance
- type AuthPayload
- type Board
- type Campaign
- type Client
- type Clients
- type Collaborator
- type Comment
- type Company
- type Connection
- type Connections
- type Contact
- type Coupon
- type Credential
- type Expense
- type File
- type Goal
- type Identity
- type Integration
- type Integrations
- type Invitation
- type InvitationStatus
- type Invitations
- type Invoice
- type Key
- type Keys
- type Link
- type List
- type Login
- type Member
- type Membership
- type Model
- type NewAPI
- type NewClient
- type NewConnection
- type NewCredential
- type NewIdentity
- type NewIntegration
- type NewInvitation
- type NewKey
- type NewPermission
- type NewRole
- type NewUser
- type NewWorkspace
- type Order
- type Organization
- type Payload
- type Permission
- type Permissions
- type Portfolio
- type Post
- type Quote
- type Reaction
- type Register
- type ResetPassword
- type Role
- type Roles
- type Share
- type SocialLogin
- type SocialProvider
- type Task
- type Token
- type UpdateAPI
- type UpdateClient
- type UpdateConnection
- type UpdateCredential
- type UpdateIntegration
- type UpdateInvitation
- type UpdatePassword
- type UpdatePermission
- type UpdateRole
- type UpdateUser
- type UpdateWorkspace
- type User
- type UserStatus
- type Users
- type Verify
- type Wishlist
- type Workspace
- type Workspaces
Constants ¶
This section is empty.
Variables ¶
View Source
var AllAlgorithm = []Algorithm{ AlgorithmHs256, AlgorithmHs384, AlgorithmHs512, AlgorithmRs256, AlgorithmRs384, AlgorithmRs512, AlgorithmEs256, AlgorithmEs384, AlgorithmEs512, AlgorithmPs256, AlgorithmPs384, AlgorithmPs512, }
View Source
var AllInvitationStatus = []InvitationStatus{ InvitationStatusPending, InvitationStatusAccepted, InvitationStatusDeclined, }
View Source
var AllSocialProvider = []SocialProvider{ SocialProviderFacebook, SocialProviderGoogle, SocialProviderTwitter, SocialProviderGithub, }
View Source
var AllUserStatus = []UserStatus{ UserStatusActive, UserStatusInactive, UserStatusSuspended, UserStatusPending, }
Functions ¶
This section is empty.
Types ¶
type Algorithm ¶
type Algorithm string
const ( AlgorithmHs256 Algorithm = "HS256" AlgorithmHs384 Algorithm = "HS384" AlgorithmHs512 Algorithm = "HS512" AlgorithmRs256 Algorithm = "RS256" AlgorithmRs384 Algorithm = "RS384" AlgorithmRs512 Algorithm = "RS512" AlgorithmEs256 Algorithm = "ES256" AlgorithmEs384 Algorithm = "ES384" AlgorithmEs512 Algorithm = "ES512" AlgorithmPs256 Algorithm = "PS256" AlgorithmPs384 Algorithm = "PS384" AlgorithmPs512 Algorithm = "PS512" )
func (Algorithm) MarshalGQL ¶
func (*Algorithm) UnmarshalGQL ¶
type Api ¶
type Api struct { Model `bson:",inline"` Name string `json:"name" bson:"name"` Description *string `json:"description,omitempty" bson:"description,omitempty"` Identifier string `json:"identifier" bson:"identifier"` Algorithm string `json:"algorithm" bson:"algorithm"` Expiration int64 `json:"expiration" bson:"expiration"` Status string `json:"status" bson:"status"` }
func (*Api) Collection ¶
func (*Api) Index ¶
func (i *Api) Index() []mongo.IndexModel
func (*Api) MarshalBSON ¶
type Attendance ¶
type Attendance struct {
UID string `json:"uid" bson:"uid"`
}
func (Attendance) IsEntity ¶
func (Attendance) IsEntity()
type AuthPayload ¶
type Client ¶
type Client struct { Model `bson:",inline"` UID *primitive.ObjectID `json:"uid,omitempty" bson:"uid,omitempty"` Type string `json:"type" bson:"type"` Name string `json:"name" bson:"name"` Description *string `json:"description,omitempty" bson:"description,omitempty"` Secret string `json:"secret" bson:"secret"` Domain string `json:"domain" bson:"domain"` Redirect string `json:"redirect,omitempty" bson:"redirect,omitempty"` Provider string `json:"provider,omitempty" bson:"provider,omitempty"` Status string `json:"status" bson:"status"` }
func (*Client) Collection ¶
func (*Client) Index ¶
func (i *Client) Index() []mongo.IndexModel
func (*Client) MarshalBSON ¶
type Collaborator ¶
type Collaborator struct {
UID string `json:"uid" bson:"uid"`
}
func (Collaborator) IsEntity ¶
func (Collaborator) IsEntity()
type Connection ¶
type Connection struct { Model `bson:",inline"` Name string `json:"name" bson:"name"` Description *string `json:"description,omitempty" bson:"description,omitempty"` Type string `json:"type" bson:"type"` Client primitive.ObjectID `json:"client" bson:"client"` Status string `json:"status" bson:"status"` }
func (*Connection) Collection ¶
func (i *Connection) Collection() string
func (*Connection) Index ¶
func (i *Connection) Index() []mongo.IndexModel
func (*Connection) MarshalBSON ¶
func (i *Connection) MarshalBSON() ([]byte, error)
func (*Connection) Santize ¶
func (i *Connection) Santize(s string) string
remove spacing characters
type Connections ¶
type Connections struct { Data []*Connection `json:"data,omitempty"` Count int `json:"count"` }
type Credential ¶
type Credential struct { Model `bson:",inline"` UID primitive.ObjectID `json:"uid" bson:"uid"` Type string `json:"type" bson:"type"` Secret string `json:"secret" bson:"secret"` Expires primitive.Timestamp `json:"expires" bson:"expires"` Revoked bool `json:"revoked" bson:"revoked"` Status string `json:"status" bson:"status"` }
func (*Credential) Collection ¶
func (i *Credential) Collection() string
func (*Credential) Index ¶
func (i *Credential) Index() []mongo.IndexModel
func (*Credential) MarshalBSON ¶
func (i *Credential) MarshalBSON() ([]byte, error)
type Identity ¶
type Identity struct { Model `bson:",inline"` UID primitive.ObjectID `json:"uid" bson:"uid"` Provider string `json:"provider" bson:"provider"` UserID string `json:"user_id" bson:"user_id"` Connection string `json:"connection" bson:"connection"` IsSocial bool `json:"is_social" bson:"is_social"` Status string `json:"status"` }
func (*Identity) Collection ¶
func (*Identity) Index ¶
func (i *Identity) Index() []mongo.IndexModel
func (*Identity) MarshalBSON ¶
type Integration ¶
type Integration struct { Model `bson:",inline"` Type string `json:"type" bson:"type"` Name string `json:"name" bson:"name"` Description *string `json:"description,omitempty" bson:"description,omitempty"` Status string `json:"status" bson:"status"` }
func (*Integration) Collection ¶
func (i *Integration) Collection() string
func (*Integration) Index ¶
func (i *Integration) Index() []mongo.IndexModel
func (*Integration) MarshalBSON ¶
func (i *Integration) MarshalBSON() ([]byte, error)
func (*Integration) Santize ¶
func (i *Integration) Santize(s string) string
remove spacing characters
type Integrations ¶
type Integrations struct { Data []*Integration `json:"data,omitempty"` Count int `json:"count"` }
type Invitation ¶
type Invitation struct { Model `bson:",inline"` UID primitive.ObjectID `json:"uid" bson:"uid"` Email string `json:"email" bson:"email"` Roles []*string `json:"roles,omitempty" bson:"roles,omitempty"` Status string `json:"status" bson:"status"` Expires primitive.Timestamp `json:"expires" bson:"expires"` Metadata primitive.M `json:"metadata,omitempty"` }
func (*Invitation) Collection ¶
func (i *Invitation) Collection() string
func (*Invitation) Index ¶
func (i *Invitation) Index() []mongo.IndexModel
func (*Invitation) MarshalBSON ¶
func (i *Invitation) MarshalBSON() ([]byte, error)
type InvitationStatus ¶
type InvitationStatus string
const ( InvitationStatusPending InvitationStatus = "PENDING" InvitationStatusAccepted InvitationStatus = "ACCEPTED" InvitationStatusDeclined InvitationStatus = "DECLINED" )
func (InvitationStatus) IsValid ¶
func (e InvitationStatus) IsValid() bool
func (InvitationStatus) MarshalGQL ¶
func (e InvitationStatus) MarshalGQL(w io.Writer)
func (InvitationStatus) String ¶
func (e InvitationStatus) String() string
func (*InvitationStatus) UnmarshalGQL ¶
func (e *InvitationStatus) UnmarshalGQL(v interface{}) error
type Invitations ¶
type Invitations struct { Data []*Invitation `json:"data,omitempty"` Count int `json:"count"` }
type Key ¶
type Key struct { Model `bson:",inline"` UID *primitive.ObjectID `json:"uid,omitempty" bson:"uid,omitempty"` Name string `json:"name" bson:"name"` Type string `json:"type" bson:"type"` Provider string `json:"provider" bson:"provider"` Certificate string `json:"certificate" bson:"certificate"` Fingerprint string `json:"fingerprint" bson:"fingerprint"` Thumbprint string `json:"thumbprint" bson:"thumbprint"` Expires *primitive.Timestamp `json:"expires,omitempty" bson:"expires,omitempty"` Status string `json:"status" bson:"status"` }
func (*Key) Collection ¶
func (*Key) Index ¶
func (i *Key) Index() []mongo.IndexModel
func (*Key) MarshalBSON ¶
type Member ¶
type Member struct { Model `bson:",inline"` UID primitive.ObjectID `json:"uid" bson:"uid"` Workspace primitive.ObjectID `json:"workspace" bson:"workspace"` Status string `json:"status" bson:"status"` }
func (*Member) Collection ¶
func (*Member) Index ¶
func (i *Member) Index() []mongo.IndexModel
func (*Member) MarshalBSON ¶
type Membership ¶
func (Membership) IsEntity ¶
func (Membership) IsEntity()
type Model ¶
type Model struct { ID primitive.ObjectID `json:"id,omitempty" bson:"_id,omitempty"` Metadata primitive.M `json:"metadata,omitempty" bson:"metadata,omitempty"` Created primitive.Timestamp `json:"created,omitempty" bson:"created,omitempty"` Updated primitive.Timestamp `json:"updated,omitempty" bson:"updated,omitempty"` Deleted primitive.Timestamp `json:"deleted,omitempty" bson:"deleted,omitempty"` Timestamp primitive.Timestamp `json:"timestamp,omitempty" bson:"timestamp,omitempty"` }
type NewConnection ¶
type NewCredential ¶
type NewIdentity ¶
type NewIntegration ¶
type NewInvitation ¶
type NewPermission ¶
type NewUser ¶
type NewUser struct { Name string `json:"name"` GivenName *string `json:"given_name,omitempty"` FamilyName *string `json:"family_name,omitempty"` Email string `json:"email"` Phone *string `json:"phone,omitempty"` Password string `json:"password"` Roles []*string `json:"roles,omitempty"` Timezone *string `json:"timezone,omitempty"` Locale *string `json:"locale,omitempty"` Picture *string `json:"picture,omitempty"` Status *string `json:"status,omitempty"` }
type NewWorkspace ¶
type Organization ¶
func (Organization) IsEntity ¶
func (Organization) IsEntity()
type Permission ¶
type Permission struct { Model `bson:",inline"` Api primitive.ObjectID `json:"api" bson:"api"` Name string `json:"name" bson:"name"` Description *string `json:"description,omitempty" bson:"description,omitempty"` }
func (*Permission) Collection ¶
func (i *Permission) Collection() string
func (*Permission) Index ¶
func (i *Permission) Index() []mongo.IndexModel
func (*Permission) MarshalBSON ¶
func (i *Permission) MarshalBSON() ([]byte, error)
func (*Permission) Santize ¶
func (i *Permission) Santize(s string) string
remove spacing characters
type Permissions ¶
type Permissions struct { Data []*Permission `json:"data,omitempty"` Count int `json:"count"` }
type ResetPassword ¶
type Role ¶
type Role struct { Model `bson:",inline"` Name string `json:"name" bson:"name"` Description *string `json:"description,omitempty" bson:"description,omitempty"` Permissions []*primitive.ObjectID `json:"permissions" bson:"permissions"` }
func (*Role) Collection ¶
func (*Role) Index ¶
func (i *Role) Index() []mongo.IndexModel
func (*Role) MarshalBSON ¶
type SocialLogin ¶
type SocialProvider ¶
type SocialProvider string
const ( SocialProviderFacebook SocialProvider = "FACEBOOK" SocialProviderGoogle SocialProvider = "GOOGLE" SocialProviderTwitter SocialProvider = "TWITTER" SocialProviderGithub SocialProvider = "GITHUB" )
func (SocialProvider) IsValid ¶
func (e SocialProvider) IsValid() bool
func (SocialProvider) MarshalGQL ¶
func (e SocialProvider) MarshalGQL(w io.Writer)
func (SocialProvider) String ¶
func (e SocialProvider) String() string
func (*SocialProvider) UnmarshalGQL ¶
func (e *SocialProvider) UnmarshalGQL(v interface{}) error
type Task ¶
type Token ¶
type Token struct { Model `bson:",inline"` UID primitive.ObjectID `json:"uid" bson:"uid"` Client primitive.ObjectID `json:"client" bson:"client"` Token string `json:"token" bson:"token"` Expires primitive.Timestamp `json:"expires" bson:"expires"` Revoked bool `json:"revoked" bson:"revoked"` LastUsed primitive.Timestamp `json:"last_used" bson:"last_used"` ClientIP string `json:"client_ip" bson:"client_ip"` UserAgent string `json:"user_agent" bson:"user_agent"` Status string `json:"status" bson:"status"` }
func (*Token) Collection ¶
func (*Token) Index ¶
func (i *Token) Index() []mongo.IndexModel
func (*Token) MarshalBSON ¶
type UpdateAPI ¶
type UpdateAPI struct { Name *string `json:"name,omitempty"` Description *string `json:"description,omitempty"` Identifier *string `json:"identifier,omitempty"` Algorithm *Algorithm `json:"algorithm,omitempty"` Expiration *int `json:"expiration,omitempty"` Metadata map[string]interface{} `json:"metadata,omitempty"` }
type UpdateClient ¶
type UpdateConnection ¶
type UpdateCredential ¶
type UpdateIntegration ¶
type UpdateInvitation ¶
type UpdatePassword ¶
type UpdatePermission ¶
type UpdateRole ¶
type UpdateUser ¶
type UpdateUser struct { Name *string `json:"name,omitempty"` GivenName *string `json:"given_name,omitempty"` FamilyName *string `json:"family_name,omitempty"` Roles []*string `json:"roles,omitempty"` Timezone *string `json:"timezone,omitempty"` Locale *string `json:"locale,omitempty"` Picture *string `json:"picture,omitempty"` Status *string `json:"status,omitempty"` Metadata map[string]interface{} `json:"metadata,omitempty"` }
type UpdateWorkspace ¶
type User ¶
type User struct { Model `bson:",inline"` Name string `json:"name" bson:"name"` GivenName *string `json:"given_name,omitempty" bson:"given_name,omitempty"` FamilyName *string `json:"family_name,omitempty" bson:"family_name,omitempty"` Email string `json:"email" bson:"email"` Phone *string `json:"phone,omitempty" bson:"phone,omitempty"` Roles []*string `json:"roles,omitempty" bson:"roles,omitempty"` Locale *string `json:"locale,omitempty" bson:"locale,omitempty"` Timezone *string `json:"timezone,omitempty" bson:"timezone,omitempty"` Picture *string `json:"picture,omitempty" bson:"picture,omitempty"` LastLogin *primitive.Timestamp `json:"last_login,omitempty" bson:"last_login,omitempty"` LastActivity *primitive.Timestamp `json:"last_activity,omitempty" bson:"last_activity,omitempty"` LastIP *string `json:"last_ip,omitempty" bson:"last_ip,omitempty"` EmailVerified *bool `json:"email_verified,omitempty" bson:"email_verified,omitempty"` PhoneVerified *bool `json:"phone_verified,omitempty" bson:"phone_verified,omitempty"` Status *string `json:"status" bson:"status"` }
func (*User) Collection ¶
func (*User) Index ¶
func (i *User) Index() []mongo.IndexModel
func (*User) MarshalBSON ¶
type UserStatus ¶
type UserStatus string
const ( UserStatusActive UserStatus = "ACTIVE" UserStatusInactive UserStatus = "INACTIVE" UserStatusSuspended UserStatus = "SUSPENDED" UserStatusPending UserStatus = "PENDING" )
func (UserStatus) IsValid ¶
func (e UserStatus) IsValid() bool
func (UserStatus) MarshalGQL ¶
func (e UserStatus) MarshalGQL(w io.Writer)
func (UserStatus) String ¶
func (e UserStatus) String() string
func (*UserStatus) UnmarshalGQL ¶
func (e *UserStatus) UnmarshalGQL(v interface{}) error
type Workspace ¶
type Workspace struct { Model `bson:",inline"` UID *primitive.ObjectID `json:"uid,omitempty" bson:"uid,omitempty"` Name string `json:"name" bson:"name"` Description *string `json:"description,omitempty" bson:"description,omitempty"` Status string `json:"status" bson:"status"` }
func (*Workspace) Collection ¶
func (*Workspace) Index ¶
func (i *Workspace) Index() []mongo.IndexModel
func (*Workspace) MarshalBSON ¶
type Workspaces ¶
Source Files ¶
- api.go
- attendance.go
- board.go
- campaign.go
- client.go
- collaborator.go
- comment.go
- company.go
- connection.go
- contact.go
- coupon.go
- credential.go
- expense.go
- file.go
- goal.go
- identity.go
- integration.go
- invitation.go
- invoice.go
- key.go
- link.go
- list.go
- member.go
- model.go
- models_gen.go
- permission.go
- portfolio.go
- post.go
- reaction.go
- role.go
- share.go
- task.go
- token.go
- user.go
- workspace.go
Click to show internal directories.
Click to hide internal directories.