Skip to content

Console

All operations require authentication.

2 operationsv2/publicCloud/project
Agent setup

Get console outputProduction

GET
/v2/publicCloud/project/{projectId}/compute/instance/{instanceId}/consoleOutput

Get console output

Returns the serial console output (boot / system log) of the instance as text. Useful for diagnosing boot problems without opening an interactive console session. This is a read-only, synchronous call.

Use the optional length query parameter to retrieve only the last N lines (the tail) of the log. Omit it to return all available output.

Path parameters

instanceId
required
stringuuid

Instance ID

projectId
required
string

Project ID

Query parameters

length
integer

Number of lines to retrieve from the end of the console log. When omitted, returns all available output.

Response

200ConsoleOutputsuccessful operation
output
read-only
string

Captured console log of the instance as a single text blob, typically the most recent lines of console output

404objectError 404 response

Example uses instanceId = 00000000-0000-0000-0000-000000000000, projectId = string

$ curl https://api.eu.ovhcloud.com/v2/publicCloud/project/{projectId}/compute/instance/{instanceId}/consoleOutput \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
{ "output": "string"}

Create a remote consoleProduction

POST
/v2/publicCloud/project/{projectId}/compute/instance/{instanceId}/console

Create a remote console

Opens a remote console session to the instance and returns the connection details (a url and, depending on the protocol, an access token) for a client to connect. This is a synchronous call — no desired-state reconciliation — and the returned URL is short-lived, so request a fresh console when it expires.

Protocol and type

Choose the console via the request body:

  • protocol — the console transport, for example VNC, SPICE, SERIAL.
  • type — the concrete console kind for that protocol, for example NOVNC for VNC, SERIAL for SERIAL.

The instance must be in a state that supports a console, otherwise the request is rejected with ResourceInInvalidState.

Path parameters

instanceId
required
stringuuid

Instance ID

projectId
required
string

Project ID

Request body (required)

protocol
required
RemoteConsoleProtocolEnum

Desired console protocol (see RemoteConsoleProtocolEnum: VNC, SPICE, SERIAL)

ValuesSERIALSPICEVNC
type
required
RemoteConsoleTypeEnum

Desired console display type (see RemoteConsoleTypeEnum: NOVNC, XVPVNC, SPICE_HTML5, SERIAL). It must be consistent with the chosen protocol.

ValuesNOVNCSERIALSPICE_HTML5XVPVNC

Response

200RemoteConsolesuccessful operation
protocol
read-only
RemoteConsoleProtocolEnum

Protocol of the opened console session (see RemoteConsoleProtocolEnum: VNC, SPICE, SERIAL)

ValuesSERIALSPICEVNC
type
read-only
RemoteConsoleTypeEnum

Display type of the opened console session (see RemoteConsoleTypeEnum: NOVNC, XVPVNC, SPICE_HTML5, SERIAL)

ValuesNOVNCSERIALSPICE_HTML5XVPVNC
url
read-only
string

Connection URL. URL to connect to the remote console. It is short-lived and grants temporary access to the instance's console.

404objectError 404 response
409objectError 409 response

Example uses instanceId = 00000000-0000-0000-0000-000000000000, projectId = string

$ curl https://api.eu.ovhcloud.com/v2/publicCloud/project/{projectId}/compute/instance/{instanceId}/console \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
{ "protocol": "SERIAL", "type": "NOVNC", "url": "string"}