MCPcopy Create free account
hub / github.com/evcc-io/evcc / apiKeyStatusHandler

Function apiKeyStatusHandler

server/http_auth.go:217–221  ·  view source on GitHub ↗
(authObject auth.Auth)

Source from the content-addressed store, hash-verified

215}
216
217func apiKeyStatusHandler(authObject auth.Auth) http.HandlerFunc {
218 return func(w http.ResponseWriter, r *http.Request) {
219 jsonWrite(w, map[string]bool{"configured": authObject.IsApiKeyConfigured()})
220 }
221}
222
223// regenerateApiKeyHandler creates or rotates the API key. Requires the admin password (a leaked API key cannot self-rotate)
224func regenerateApiKeyHandler(authObject auth.Auth) http.HandlerFunc {

Callers 1

RegisterSystemHandlerMethod · 0.85

Calls 2

jsonWriteFunction · 0.70
IsApiKeyConfiguredMethod · 0.65

Tested by

no test coverage detected