Hypervisors Api Reset Enrollment
Unenrolls the host and returns it to NOT_ENROLLED. The path /api/v1/hypervisors/{id}/unenroll is an alias of this operation. Requires the ADMIN role.
Hypervisor key
102
Proceed when the remote agent identity cannot be confirmed removed
200 OK successful response envelope. The enrollment status of the host after the reset
{
"hypervisorPk": 102,
"agentId": null,
"enrollmentStatus": "NOT_ENROLLED",
"enrolledAt": null,
"enrollmentError": null,
"enrollmentStage": "NONE",
"offboardOutcome": "REMOTE_CONFIRMED"
}
Identifier of the hypervisor the status belongs to
Identifier of the Agent bound to the host, as a decimal string (a 64-bit value, sent as a string because browsers cannot hold it exactly as a number); null after a reset or unenroll, which unbinds the Agent
Agent enrollment status of a hypervisor host.
NOT_ENROLLED: No enrollment: the initial value of every host and the value after an enrollment reset or unenrollENROLLING: An Agent identity was allocated and the enrollment commands were sent; the host awaits the Agent's first heartbeatENROLLED: The Agent's first heartbeat after enrollment promoted the host from ENROLLINGFAILED: An enrollment step failed, the enrollment deadline passed while ENROLLING, or an unenroll could not be completed remotely (stage RECOVERY_REQUIRED)UNENROLLED: No behaviour is documented for this value. No producing site in the current server code
Time the host became ENROLLED; null while it is not enrolled
Error text of the last enrollment failure or forced reset; null when there is none
Stage of the agent enrollment of a hypervisor host.
NONE: No enrollment step has run; the initial value and the value after an enrollment resetAUTHORIZING: The Console is authenticating to the ESXi host to obtain a bearer tokenCSR_REQUESTED: The Console asked the host's Agent to start enrollment and awaits its certificate signing request (CSR)CSR_RECEIVED: The Agent returned a certificate signing requestCERT_SIGNED: The Console signed the Agent's certificate signing requestCERT_DELIVERED: The signed certificate was delivered to the AgentAWAITING_HEARTBEAT: The certificate delivery was recorded and the host awaits the Agent's first heartbeatENROLLED: The Agent's first heartbeat promoted the host; set together with status ENROLLEDRECOVERY_REQUIRED: An unenroll could not be completed remotely and was not forced; the host keeps status FAILED and its Agent binding until the enrollment is reset with force=trueFAILED: An enrollment step failed or the enrollment deadline passed while ENROLLING
What a reset or unenroll established about the remote Agent: always set on a reset or unenroll response; on a status read it is set only when the stored row proves FORCED_UNCONFIRMED or RECOVERY_REQUIRED and is otherwise null; null never means the Agent confirmed anything, and even REMOTE_CONFIRMED only means the Agent answered the UNENROLL command
400 Bad Request: INVALID_ARGUMENT when the id path variable is not a number or force is not true or false
{
"errorCode": "string",
"message": "string",
"path": "string",
"timestamp": "string",
"reason": "string"
}
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
401 Unauthorized: UNAUTHENTICATED when the VTP_SESSION cookie is missing, unknown, expired or revoked
{
"errorCode": "string",
"message": "string",
"path": "string",
"timestamp": "string",
"reason": "string"
}
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
403 Forbidden: FORBIDDEN or CSRF_ERROR. CSRF_ERROR when the X-XSRF-TOKEN header is missing or wrong on a POST, PUT, PATCH or DELETE (only POST /api/v1/auth/login is exempt, and a request without a valid session gets 401 UNAUTHENTICATED instead); PASSWORD_CHANGE_REQUIRED when the account must change its password first (only GET /api/v1/auth/session, POST /api/v1/auth/logout and POST /api/v1/auth/change-password are exempt); LICENSE_REQUIRED or LICENSE_EXPIRED while the license pool is restricted (no license, or expired past grace) (exempt: every route under /api/v1/auth, GET /api/v1/user/preferences, GET /api/v1/licensing/summary and POST /api/v1/licensing/licenses)
{
"errorCode": "string",
"message": "string",
"path": "string",
"timestamp": "string",
"reason": "string"
}
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
404 Not Found: HYPERVISOR_NOT_FOUND
"ApiErrorResponse Object"
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
409 Conflict: RECOVERY_REQUIRED or ENROLLMENT_RESET_CONFLICT
"ApiErrorResponse Object"
Stable machine-readable error code. The known values are listed in ApiErrorCode; the set is not closed, so a client must tolerate an unlisted value.
Human-readable error description
Request URI path that produced the error
Timestamp when the error occurred as an ISO 8601 date-time with offset
A finer code, present only where an endpoint documents it. The Rule Pack endpoints' PACK_ENTRY_INVALID carries the import core's code here.
curl -X POST -H 'Authorization: <value>' https://{api_host}/api/v1/hypervisors/{id}/reset-enrollment