github

package
v0.0.0-...-43b2f59 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2021 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GitHubAuthenticator

type GitHubAuthenticator struct {
	T     trace.Tracer
	Cache *redis.Client
}

GitHubAuthenticator authentices with GitHub personal access token in the Authorization header (bearer token format).

func (*GitHubAuthenticator) Authenticate

type GitHubUser

type GitHubUser struct {
	ID       uint64 // github user ID
	Username string // github username (can be changed by the user on GitHub)
}

func VerifyUser

func VerifyUser(token string) (GitHubUser, error)

func (GitHubUser) DBKey

func (g GitHubUser) DBKey() string

func (GitHubUser) DisplayName

func (g GitHubUser) DisplayName() string

func (GitHubUser) ProfileURL

func (g GitHubUser) ProfileURL() string

Jump to

Keyboard shortcuts

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