person

package
v0.0.0-...-732a6c7 Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2018 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Person

type Person struct {
	ID         string    `db:"id" json:"id,omitempty"`
	Source     string    `db:"source" json:"source,omitempty"`
	Name       string    `db:"name" json:"name,omitempty"`
	Email      string    `db:"email" json:"email,omitempty"`
	PictureURL string    `db:"picture_url" json:"picture_url,omitempty"`
	Gender     string    `db:"gender" json:"gender,omitempty"`
	SourceID   string    `db:"source_id" json:"source_id,omitempty"`
	Deleted    bool      `db:"deleted" json:"deleted,omitempty"`
	CreatedAt  time.Time `db:"created_at" json:"created_at,omitempty"`
	UpdatedAt  time.Time `db:"updated_at" json:"updated_at,omitempty"`
}

Person saves details for a user

type Service

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

Service for people

func New

func New(conf *config.Config, db *sqlx.DB, oauth oauth2.OAuth2, tokens *token.Service) *Service

New - create a new service for people

func (*Service) Login

func (s *Service) Login() (string, error)

Login a person

func (*Service) Logout

func (s *Service) Logout(accessToken string) error

Logout an accessToken

func (*Service) Verify

func (s *Service) Verify(code string) (string, error)

Verify or add a person

Jump to

Keyboard shortcuts

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