Hayden Hargreaves b6a434ad2a (FEAT): Authentication service with Google OAuth is working!
Still missing a UI and we do not have session management just yet, but
the workflow of calling the Google API's and creating/finding users is
working with the current structure.
2025-06-14 12:35:08 -07:00

27 lines
745 B
Go

package domain
import "time"
// GoogleUserInfo is a data type which contains a mapping of the Google User Info API call.
type GoogleUserInfo struct {
Id string `json:"id"`
Email string `json:"email"`
Verified bool `json:"verified_email"`
Name string `json:"name"`
GivenName string `json:"given_name"`
FamilyName string `json:"family_name"`
Picture string `json:"picture"`
}
// User is the database model of a user. There is no need to map to a different model so
// this will remain in the domain.
type User struct {
Id int
GoogleId string
Name string
Email string
ImageUrl string
GoogleRefreshToken string
Created time.Time
}