Documentation ¶
Index ¶
- Constants
- Variables
- func GetAuthInfo(r *http.Request) (auth domain.AuthInfo)
- func GetRepository(r *http.Request) (repo db.Repository)
- func New(db *pgxpool.Pool, publicKey rsa.PublicKey) *chi.Mux
- func NewVehiclesRouter() *chi.Mux
- func ParsecontextKey(name string) (contextKey, error)
- type ListVehiclesParams
Constants ¶
View Source
const ( // ContextKeyAuth is a contextKey of type Auth. ContextKeyAuth contextKey = iota // ContextKeyRepository is a contextKey of type Repository. ContextKeyRepository )
View Source
const MAX_RESULTS_LIMIT = 20
Variables ¶
View Source
var ErrInvalidcontextKey = errors.New("not a valid contextKey")
Functions ¶
func GetRepository ¶
func GetRepository(r *http.Request) (repo db.Repository)
func New ¶
FIXME: probably MUCH better to use JWKS here so we don't have to restart the server to change keys.
func NewVehiclesRouter ¶
func NewVehiclesRouter() *chi.Mux
func ParsecontextKey ¶
ParsecontextKey attempts to convert a string to a contextKey.
Types ¶
type ListVehiclesParams ¶
Click to show internal directories.
Click to hide internal directories.