Obtaining the VNC Login Address
Function
This API is used to obtain the address for remotely logging in to an ECS using VNC.
URI
POST /v1/{project_id}/cloudservers/{server_id}/remote_console
|
Parameter |
Mandatory |
Description |
|---|---|---|
|
project_id |
Yes |
Specifies the project ID. For details about how to obtain the ID, see Obtaining a Project ID. |
|
server_id |
Yes |
Specifies the ECS ID. |
Request
Request parameters
Table 2 describes the request parameters.
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
remote_console |
Yes |
Object |
Definition Obtains the address for remotely logging in to an ECS. For details, see Table 3. Constraints N/A Range N/A Default Value N/A |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
type |
Yes |
String |
Definition Specifies a remote login mode. Set it to novnc. Constraints N/A Range N/A Default Value N/A |
|
protocol |
Yes |
String |
Definition Specifies a remote login protocol. Set it to vnc. Constraints N/A Range N/A Default Value N/A |
Response
Response parameters
Table 4 describes the response parameters.
|
Parameter |
Type |
Description |
|---|---|---|
|
remote_console |
Object |
Definition Obtains the address for remotely logging in to an ECS. For details, see Table 5. Range N/A |
|
Parameter |
Type |
Description |
|---|---|---|
|
type |
String |
Definition Specifies a remote login mode. Range N/A |
|
protocol |
String |
Definition Specifies a remote login protocol. Range N/A |
|
url |
String |
Definition Specifies a remote login URL. The URL for VNC login contains a one-time token. Keep the token secure and discard it after using it. Range N/A |
Example Request
Obtain the VNC login address of the ECS whose ID is 47bc79ae-df61-4ade-9197-283a74e5d70e.
POST https://{endpoint}/v1/13c67a214ced4afb88d911ae4bd5721a/cloudservers/47bc79ae-df61-4ade-9197-283a74e5d70e/remote_console
{
"remote_console": {
"protocol": "vnc",
"type": "novnc"
}
}
Example Response
{
"remote_console": {
"type": "novnc",
"protocol": "vnc",
"url": "https://nova-novncproxy.az1.dc1.domainname.com:8002/vnc_auto.html?token=0fda3eca-8232-4249-****-************&lang=EN&tLength=70"
}
}
Returned Values
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.