api

package
v0.0.0-...-53bd342 Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2023 License: GPL-3.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func APIMux

func APIMux(cfg APIConfig) http.Handler

APIMux constructs a http.Handler with all application routes defined.

Types

type APIConfig

type APIConfig struct {
	CorsOrigin         string
	Log                logrus.FieldLogger
	DB                 *sqlx.DB
	Session            *scs.SessionManager
	Mailer             token.Mailer
	TokenTimeout       time.Duration
	Background         *background.Background
	Paypal             *paypal.Client
	Stripe             *stripecl.API
	StripeCfg          config.Stripe
	Providers          map[string]auth.Provider
	LoginRedirectURL   string
	ActivationRequired bool
}

APIConfig contains all the mandatory dependencies required by handlers.

Directories

Path Synopsis
Package weberr allows to add behaviors to errors.
Package weberr allows to add behaviors to errors.

Jump to

Keyboard shortcuts

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