Documentation ¶
Index ¶
- Variables
- func AuthorizationMiddleware(next http.Handler) http.Handler
- func GetTokenFromCookie(r *http.Request, ctx context.Context) (*jwt.Token, error)
- func GetTokenFromRequest(r *http.Request, ctx context.Context) (*jwt.Token, error)
- func GithubCallback(w http.ResponseWriter, r *http.Request)
- func Webhook(w http.ResponseWriter, r *http.Request)
- type App
- func (a *App) CreateUser(w http.ResponseWriter, r *http.Request) error
- func (a *App) Handler() chi.Router
- func (a *App) InstallationCallback(w http.ResponseWriter, r *http.Request) error
- func (a *App) ListSlackAPIUser(w http.ResponseWriter, r *http.Request) error
- func (a *App) ListUser(w http.ResponseWriter, r *http.Request) error
- func (a *App) UpdateUser(w http.ResponseWriter, r *http.Request) error
- type ContextKey
- type InstallationResponse
- type Server
- type User
Constants ¶
This section is empty.
Variables ¶
View Source
var ( UserScopes = []string{"identity.basic"} //"incoming-webhook" TeamScopes = []string{"chat:write", "users.profile:read", "users:read"} )
Functions ¶
func GetTokenFromCookie ¶
func GetTokenFromRequest ¶
func GithubCallback ¶
func GithubCallback(w http.ResponseWriter, r *http.Request)
Types ¶
type App ¶
type App struct {
// contains filtered or unexported fields
}
func (*App) CreateUser ¶
func (*App) InstallationCallback ¶
func (*App) ListSlackAPIUser ¶
func (*App) UpdateUser ¶
type ContextKey ¶
type ContextKey string
ContextKey represents a context key
const ( // UserIDKey is the key for the user id of the authenticated user UserIDKey ContextKey = "userID" ReqIDKey ContextKey = "reqID" )
type InstallationResponse ¶
type InstallationResponse struct {
// contains filtered or unexported fields
}
type Server ¶
Server interface
func NewApp ¶
func NewApp( config config.Config, ghSvc ghSvc.Github, userRepo repository.UserRepository, teamRepo repository.TeamRepository, repoRepo repository.RepoRepository, taskRepo repository.TaskRepository, installationRepo repository.InstallationRepository, ghAppSvc ghSvc.Github, ) Server
Click to show internal directories.
Click to hide internal directories.