Parcourir la source

Document /api/health

Document the health check implemented in #3302 (and #935), see  https://github.com/grafana/grafana/issues/3302#issuecomment-297066201
Frank lin Piat il y a 7 ans
Parent
commit
1fc5ea181a
1 fichiers modifiés avec 26 ajouts et 1 suppressions
  1. 26 1
      docs/sources/http_api/other.md

+ 26 - 1
docs/sources/http_api/other.md

@@ -82,4 +82,29 @@ HTTP/1.1 200
 Content-Type: application/json
 
 {"message": "Logged in"}
-```
+```
+
+# Health API
+
+## Returns health information about Grafana
+
+`GET /api/health`
+
+**Example Request**
+
+```http
+GET /api/health
+Accept: application/json
+```
+
+**Example Response**:
+
+```http
+HTTP/1.1 200 OK
+
+{
+  "commit": "087143285",
+  "database": "ok",
+  "version": "5.1.3"
+}
+```