mirror of
https://github.com/notherealmarco/WASAPhoto.git
synced 2025-03-14 06:06:15 +01:00
14 lines
545 B
Go
14 lines
545 B
Go
package api
|
|
|
|
import (
|
|
"github.com/notherealmarco/WASAPhoto/service/api/reqcontext"
|
|
"github.com/julienschmidt/httprouter"
|
|
"net/http"
|
|
)
|
|
|
|
// getContextReply is an example of HTTP endpoint that returns "Hello World!" as a plain text. The signature of this
|
|
// handler accepts a reqcontext.RequestContext (see httpRouterHandler).
|
|
func (rt *_router) getContextReply(w http.ResponseWriter, r *http.Request, ps httprouter.Params, ctx reqcontext.RequestContext) {
|
|
w.Header().Set("content-type", "text/plain")
|
|
_, _ = w.Write([]byte("Hello World!"))
|
|
}
|