Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotFound = errors.New("user not found")
ErrNotFound will be returned if a user could not be found in the user store
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store interface { Get(id, provider string) (*User, error) Save(*User) error Update(*User) error }
Store provides an interface for getting, storing and updating Users
type User ¶
type User struct { RawData map[string]interface{} Provider string Email string Name string FirstName string `bson:"first_name"` LastName string `bson:"last_name"` NickName string `bson:"nick_name"` Description string UserID string `bson:"userid"` AvatarURL string `bson:"avatar_url"` Location string AccessToken string `bson:"access_token"` AccessTokenSecret string `bson:"access_token_secret"` RefreshToken string `bson:"refresh_token"` ExpiresAt time.Time `bson:"expires_at"` }
User contains the information common amongst most OAuth and OAuth2 providers. All of the "raw" datafrom the provider can be found in the `RawData` field.
func FromGothic ¶
FromGothic converts a Gothic user to an Athens user
Click to show internal directories.
Click to hide internal directories.