endpoints

package
v0.0.0-...-63ea78d Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrWrongRequestType = errors.New("wrong request type")
)

Functions

func GetStateEndpoint

func GetStateEndpoint(svc services.StateService) endpoint.Endpoint

func GetStatesEndpoint

func GetStatesEndpoint(svc services.StateService) endpoint.Endpoint

Types

type GetStateRequest

type GetStateRequest struct {
	Abbreviation string `json:"abbreviation"`
}

type StateResponse

type StateResponse struct {
	Abbreviation string `json:"abbreviation"`
	Name         string `json:"name"`
	Population   int    `json:"population"`
}

Jump to

Keyboard shortcuts

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