api

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HelloHandler

func HelloHandler(ctx context.Context) http.HandlerFunc

HelloHandler returns function containing a simple hello world example of an api handler

Types

type API

type API struct {
	Mux *http.ServeMux
}

API provides a struct to wrap the api around

func Setup

func Setup(ctx context.Context, m *http.ServeMux) *API

Setup function sets up the api and returns an api

type HelloResponse

type HelloResponse struct {
	Message string `json:"message,omitempty"`
}

Jump to

Keyboard shortcuts

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