V Sanhealth Check APIs
APIs for managing vSAN health checks
Table of Contents
1. Get vSAN health check status
- Get vSAN health check status API is used to fetch vSAN health check status.
1.1. Prerequisites API
The following data is required:
- ID of a domain
The following data is optional:
- Status of health check [ENABLED / DISABLED]
1.2. Steps API
- Invoke the API.
cURL Request
$ curl 'https://sfo-vcf01.rainpole.io/v1/domains/12fd6423-00db-474f-8b61-be184505e455/health-checks' -i -X GET \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer etYWRta....'
HTTP Request
GET /v1/domains/12fd6423-00db-474f-8b61-be184505e455/health-checks HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....
HTTP Response
HTTP/1.1 202 Accepted
Content-Type: application/json
Content-Length: 102
{
"resultId" : "485fe229-8a69-4be8-b708-6f71842d8bb5",
"status" : "INPROGRESS",
"result" : [ ]
}
- Poll the vSAN health check status with the ID from the response of the previous API.
cURL Request
$ curl 'https://sfo-vcf01.rainpole.io/v1/domains/12fd6423-00db-474f-8b61-be184505e455/health-checks/queries/485fe229-8a69-4be8-b708-6f71842d8bb5' -i -X GET \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer etYWRta....'
HTTP Request
GET /v1/domains/12fd6423-00db-474f-8b61-be184505e455/health-checks/queries/485fe229-8a69-4be8-b708-6f71842d8bb5 HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 434
{
"resultId" : "485fe229-8a69-4be8-b708-6f71842d8bb5",
"status" : "SUCCESS",
"result" : [ {
"id" : "objecthealth",
"name" : "vSAN object health",
"description" : "Checks the health status of all vSAN objects.",
"type" : "VSAN",
"status" : "ENABLED",
"resourceType" : "CLUSTER",
"resourceId" : "b813d959-f89c-40b5-8b96-e63cea36b095",
"resourceName" : "e760dc81-f9f0-4367-a03e-70c2004c930f"
} ]
}
1.3. Related APIs API
[_getvsanhealthcheckbydomain] API [_getvsanhealthcheckbyqueryid] API [_updatevsanhealthcheckbydomain] API [_getvsanhealthcheckbytaskid] API
2. Update vSAN health check status
- Update vSAN health check status API is used to update the vSAN health check status.
2.1. Prerequisites API
The following data is required:
ID of the Domain
List of vSAN health check spec
Tip : Refer to: [HealthCheckSpec](index.html# HealthCheckSpec).
2.2. Steps API
- Invoke the API.
cURL Request
$ curl 'https://sfo-vcf01.rainpole.io/v1/domains/12fd6423-00db-474f-8b61-be184505e455/health-checks' -i -X PATCH \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer etYWRta....' \
-d '[ {
"id" : "objecthealth",
"name" : "vSAN object health",
"status" : "DISABLED",
"resourceType" : "CLUSTER",
"resourceName" : "e760dc81-f9f0-4367-a03e-70c2004c930f"
} ]'
HTTP Request
PATCH /v1/domains/12fd6423-00db-474f-8b61-be184505e455/health-checks HTTP/1.1
Content-Type: application/json
Accept: application/json
Content-Length: 178
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....
[ {
"id" : "objecthealth",
"name" : "vSAN object health",
"status" : "DISABLED",
"resourceType" : "CLUSTER",
"resourceName" : "e760dc81-f9f0-4367-a03e-70c2004c930f"
} ]
HTTP Response
HTTP/1.1 202 Accepted
Content-Type: application/json
Content-Length: 164
{
"id" : "afee8cdd-c4ee-4710-ac44-7f51dc898c92",
"status" : "INPROGRESS",
"resourceStatus" : {
"e760dc81-f9f0-4367-a03e-70c2004c930f" : "INPROGRESS"
}
}
- Poll the status of the vSAN health check update with the ID from the response of the previous API.
cURL Request
$ curl 'https://sfo-vcf01.rainpole.io/v1/domains/12fd6423-00db-474f-8b61-be184505e455/health-checks/tasks/afee8cdd-c4ee-4710-ac44-7f51dc898c92' -i -X GET \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer etYWRta....'
HTTP Request
GET /v1/domains/12fd6423-00db-474f-8b61-be184505e455/health-checks/tasks/afee8cdd-c4ee-4710-ac44-7f51dc898c92 HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: sfo-vcf01.rainpole.io
Authorization: Bearer etYWRta....
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 158
{
"id" : "afee8cdd-c4ee-4710-ac44-7f51dc898c92",
"status" : "SUCCESS",
"resourceStatus" : {
"e760dc81-f9f0-4367-a03e-70c2004c930f" : "SUCCESS"
}
}
2.3. Related APIs API
[_getvsanhealthcheckbydomain] API [_getvsanhealthcheckbyqueryid] API [_updatevsanhealthcheckbydomain] API [_getvsanhealthcheckbytaskid] API
Last updated 2024-06-21 01:22:12 -0700