apollo-backend/internal/api/health.go
Andre Medeiros fc1065deb5 fix ci
2021-09-25 09:19:42 -04:00

16 lines
307 B
Go

package api
import (
"encoding/json"
"net/http"
)
func (a *api) healthCheckHandler(w http.ResponseWriter, r *http.Request) {
data := map[string]string{
"status": "available",
}
w.WriteHeader(http.StatusOK)
w.Header().Set("Content-Type", "application/json")
_ = json.NewEncoder(w).Encode(data)
}