rest

package
v0.0.0-...-49abefd Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2021 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

Package rest and its sub-packages are the application REST entry point.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server interface {
	Use(m ...func(http.Handler) http.Handler) *server
	Start(c *env.RestConfig)
}

Server exposes the services provived by the application via REST

func NewServer

func NewServer(accountSrv *service.Account, transferSrv *service.Transfer) Server

NewServer constructs a server with its required dependencies

Directories

Path Synopsis
Package body includes models that handles request and response data
Package body includes models that handles request and response data
Package jwt contains structs that handles JWT token encoding and parsing
Package jwt contains structs that handles JWT token encoding and parsing
Package middleware contains custom http request middlewares
Package middleware contains custom http request middlewares
Package response holds utility functions related to http response handling
Package response holds utility functions related to http response handling
Package routing contains files that registers the REST endpoints handle by the application
Package routing contains files that registers the REST endpoints handle by the application

Jump to

Keyboard shortcuts

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