Description

Request URL

Network API v2.0

POST /v2.0/lb/health_monitors

Request Paramters

Parameter Value Style Description
X-Auth-Token User Token header
type type plain <PING or TCP or HTTP>
delay delay plain Allowed only between 5 to 10.
url_path (Optional) url_path plain
expected_codes (Optional) expected_codes plain Expected HTTP codes for a passing HTTP(S) monitor.

Request Json

{
   "health_monitor":{
      "type":"HTTP",
      "delay":10,
      "url_path":"/check",
      "expected_codes":"200-299"
   }
}

Normal response codes

201

Example

curl -i -X POST  \
-H "X-Auth-Token: 0925897a3d4543218ff0dcd2bb378a8e" \
-H "Accept: application/json" \
-d '{"health_monitor":{"type":"HTTP","delay":10,"url_path":"/check","expected_codes":"200-299"}}' \
https://networking.tyo1.cloud.z.com/v2.0/lb/health_monitors
HTTP/1.1 201 Created
Server: openresty/1.7.10.1
Date: Fri, 08 May 2015 11:45:01 GMT
Content-Type: application/json
Content-Length: 264
Connection: keep-alive

{
    "health_monitor": {
        "admin_state_up": true,
        "tenant_id": "22394afc818d471ca2f0308c06ae7460",
        "delay": 10,
        "expected_codes": "200-299",
        "max_retries": 5,
        "http_method": "GET",
        "timeout": 5,
        "pools": [],
        "url_path": "/check",
        "type": "HTTP",
        "id": "1e898fd5-193d-47f7-8b53-10945399a183"
    }
}