forked from GithubBackups/healthchecks
Updated curl example for pausing a check.
This commit is contained in:
parent
638532adf4
commit
7faf53d71f
@ -336,6 +336,12 @@ To create a "cron" check, specify the "schedule" and "tz" parameters.
|
|||||||
|
|
||||||
{% include "front/snippets/pause_check_request.html" %}
|
{% include "front/snippets/pause_check_request.html" %}
|
||||||
|
|
||||||
|
<p>Note: the <code>--data ""</code> argument forces curl to send a
|
||||||
|
<code>Content-Length</code> request header even though the request body
|
||||||
|
is empty. For HTTP POST requests, the <code>Content-Length</code> header
|
||||||
|
is sometimes required by some network proxies and web servers.
|
||||||
|
</p>
|
||||||
|
|
||||||
<h3 class="api-section">Example Response</h3>
|
<h3 class="api-section">Example Response</h3>
|
||||||
{% include "front/snippets/pause_check_response.html" %}
|
{% include "front/snippets/pause_check_response.html" %}
|
||||||
|
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
<div class="highlight"><pre><span></span>curl {{ SITE_ROOT }}/api/v1/checks/0c8983c9-9d73-446f-adb5-0641fdacc9d4/pause <span class="se">\</span>
|
<div class="highlight"><pre><span></span>curl {{ SITE_ROOT }}/api/v1/checks/0c8983c9-9d73-446f-adb5-0641fdacc9d4/pause <span class="se">\</span>
|
||||||
--request POST --header <span class="s2">"X-Api-Key: your-api-key"</span>
|
--request POST --header <span class="s2">"X-Api-Key: your-api-key"</span> --data <span class="s2">""</span>
|
||||||
</pre></div>
|
</pre></div>
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
curl SITE_ROOT/api/v1/checks/0c8983c9-9d73-446f-adb5-0641fdacc9d4/pause \
|
curl SITE_ROOT/api/v1/checks/0c8983c9-9d73-446f-adb5-0641fdacc9d4/pause \
|
||||||
--request POST --header "X-Api-Key: your-api-key"
|
--request POST --header "X-Api-Key: your-api-key" --data ""
|
||||||
|
Loading…
x
Reference in New Issue
Block a user