2015-04-23 18:58:10 +00:00
|
|
|
---
|
|
|
|
layout: "http"
|
|
|
|
page_title: "HTTP API: /sys/health"
|
|
|
|
sidebar_current: "docs-http-debug-health"
|
|
|
|
description: |-
|
|
|
|
The '/sys/health' endpoint is used to check the health status of Vault.
|
|
|
|
---
|
|
|
|
|
|
|
|
# /sys/health
|
|
|
|
|
|
|
|
<dl>
|
2016-06-09 16:30:23 +00:00
|
|
|
<dt>Description</dt>
|
|
|
|
<dd>
|
2016-03-11 05:41:25 +00:00
|
|
|
Returns the health status of Vault. This matches the semantics of a
|
|
|
|
Consul HTTP health check and provides a simple way to monitor the
|
|
|
|
health of a Vault instance.
|
2016-06-09 16:30:23 +00:00
|
|
|
</dd>
|
2015-04-23 18:58:10 +00:00
|
|
|
|
2016-06-09 16:30:23 +00:00
|
|
|
<dt>Method</dt>
|
|
|
|
<dd>GET/HEAD</dd>
|
2015-04-23 18:58:10 +00:00
|
|
|
|
2016-06-09 16:30:23 +00:00
|
|
|
<dt>Parameters</dt>
|
|
|
|
<dd>
|
2015-07-03 00:49:35 +00:00
|
|
|
<ul>
|
|
|
|
<li>
|
|
|
|
<span class="param">standbyok</span>
|
|
|
|
<span class="param-flags">optional</span>
|
|
|
|
A query parameter provided to indicate that being a standby should
|
2016-03-11 05:41:25 +00:00
|
|
|
still return the active status code instead of the standby code
|
|
|
|
</li>
|
|
|
|
<li>
|
|
|
|
<span class="param">activecode</span>
|
|
|
|
<span class="param-flags">optional</span>
|
|
|
|
A query parameter provided to indicate the status code that should
|
|
|
|
be returned for an active node instead of the default of `200`
|
|
|
|
</li>
|
|
|
|
<li>
|
|
|
|
<span class="param">standbycode</span>
|
|
|
|
<span class="param-flags">optional</span>
|
|
|
|
A query parameter provided to indicate the status code that should
|
|
|
|
be returned for a standby node instead of the default of `429`
|
|
|
|
</li>
|
|
|
|
<li>
|
|
|
|
<span class="param">sealedcode</span>
|
|
|
|
<span class="param-flags">optional</span>
|
|
|
|
A query parameter provided to indicate the status code that should
|
2016-08-18 16:10:23 +00:00
|
|
|
be returned for a sealed node instead of the default of `503`
|
|
|
|
</li>
|
|
|
|
<li>
|
|
|
|
<span class="param">uninitcode</span>
|
|
|
|
<span class="param-flags">optional</span>
|
|
|
|
A query parameter provided to indicate the status code that should
|
|
|
|
be returned for an uninitialized Vault instead of the default of
|
|
|
|
`501`
|
2015-07-03 00:49:35 +00:00
|
|
|
</li>
|
|
|
|
</ul>
|
2016-06-09 16:30:23 +00:00
|
|
|
</dd>
|
2015-04-23 18:58:10 +00:00
|
|
|
|
2016-06-09 16:30:23 +00:00
|
|
|
<dt>Returns (only with GET)</dt>
|
|
|
|
<dd>
|
2015-04-23 18:58:10 +00:00
|
|
|
|
2015-10-12 16:10:22 +00:00
|
|
|
```javascript
|
2016-07-22 22:33:29 +00:00
|
|
|
{
|
2016-07-26 18:05:27 +00:00
|
|
|
"cluster_id": "c9abceea-4f46-4dab-a688-5ce55f89e228",
|
|
|
|
"cluster_name": "vault-cluster-5515c810",
|
2016-09-01 21:18:03 +00:00
|
|
|
"version": "0.6.1-dev"
|
2016-07-26 18:05:27 +00:00
|
|
|
"server_time_utc": 1469555798,
|
2016-07-22 22:33:29 +00:00
|
|
|
"standby": false,
|
|
|
|
"sealed": false,
|
|
|
|
"initialized": true
|
|
|
|
}
|
2015-10-12 16:10:22 +00:00
|
|
|
```
|
2015-04-23 18:58:10 +00:00
|
|
|
|
2016-06-09 16:30:23 +00:00
|
|
|
Default Status Codes (GET/HEAD):
|
2015-04-23 18:58:10 +00:00
|
|
|
|
2016-03-11 05:41:25 +00:00
|
|
|
* `200` if initialized, unsealed, and active.
|
2015-04-23 18:58:10 +00:00
|
|
|
* `429` if unsealed and standby.
|
2016-03-11 05:41:25 +00:00
|
|
|
* `500` if sealed, or if not initialized.
|
2015-04-23 18:58:10 +00:00
|
|
|
</dd>
|
|
|
|
</dl>
|