This means that the agent is installed on the Hyper-V host which is being registered.
This section includes the following topics:
- Input Parameters
- Output Parameters
Input Parameters
The following table provides the parameters and descriptions.
Parameter | Description |
sessionId | String. Containing a GUID, obtained via a call to API Hyper-V Create Host Browsing Session. |
hostName | Name of the remote computer where Hyper-V is running. The agent will attempt to connect to this host. |
authenticationMode | String. Allowed values are Sspi or Credentials. |
credentials | Allows entering a username and password when authenticationMode = Credentials. |
Example
Example for credential based auth on a remote host:
{
"sessionId": "5d05495f-39e5-4e4e-ad0c-e351cc2c78f3",
"hostName": "TestComputer1",
"authenticationMode": "credentials",
"credentials": {
"userName": "user1",
"password": "password1"
}
)
Output Parameters
The following table provides the parameters and descriptions.
Parameter | Description |
identifier id | Integer. Store this value as needed by the final restore as virtual machine API call. |
hostName | String. Store this value in case you want to use it as the virtual machine name part of the restore as VM API call. |
hostUnsupported | Boolean. When false, means the host is not supported, and the reason can be found via the hostUnsupportedReason parameter. When true, hostUnsupportedReason is value 0. |
hostUnsupportedReason | Integer. Showing the reason why the host is unsupported. Value is 0 when hostUnsupported = false. The following values are possible:
|
Example
{
"identifier": {
"id": 2
},
"hostName": "TestComputer1",
"hostUnsupportedReason": 0,
"hostUnsupported": false
}
Example POST
POST /v2/accounts/test_acc/computers/0000/restore/hyperv/host/add
Input Parameters
{
"sessionId": "e0b73795-9c48-429f-8a29-ec43831ca157",
"hostName": "WIN-3BUJ2MBR3RE",
"authenticationMode": "sspi"
}
Output Parameters
Response status: 200 Accepted (for online operation)
Example Response
{
"data": {
"identifier": {
"id": 2
},
"hostName": "win-3buj2mbr3re",
"serverState": 0,
"serverStateReason": 0,
"hostUnsupportedReason": 0,
"hostUnsupported": false
}
}
}