api

package
v0.1.8 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AuthMiddleware

func AuthMiddleware(next http.Handler) http.Handler

Types

type App

type App struct {
	Router  *mux.Router
	Service service.DiamondService
}

func Initialize

func Initialize(service service.DiamondService) App

func (App) HomeHandler

func (app App) HomeHandler(w http.ResponseWriter, _ *http.Request)

func (App) ReviewHandler

func (app App) ReviewHandler(w http.ResponseWriter, r *http.Request)

ReviewHandler Accepts a new review.

func (App) ReviewsHandler

func (app App) ReviewsHandler(w http.ResponseWriter, r *http.Request)

ReviewsHandler Responds with the reviews given

func (App) Run

func (app App) Run()

type Hello

type Hello struct {
	Message string `json:"Message"`
}

Jump to

Keyboard shortcuts

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