Retrieve Virtual Machine Events History
GET https://infrahub-api.nexgencloud.com/v1/core/virtual-machines/{virtual_machine_id}/events
Retrieves a list of all events in a virtual machine's history, offering details on actions performed on the specified virtual machine. Include the virtual machine ID in the path to access the history of events. For more details on virtual machine events history, click here.
Path parameters
virtual_machine_id integer
Required
The id
of the virtual machine from which to retrieve a history of events.
Attributes
status boolean
Indicates the status of the request to retrieve a history of events, true
(indicates success) or false
(indicates failure).
message string
A message providing information about the status of the request.
instance_events array
An array containing objects each providing details on an action executed on a virtual machine.
Show event attributes
time date-time
The timestamp when the event occurred.
type string
The type of the event (e.g., "normal").
user_id integer
The ID of the user associated with the event.
message string
A message describing the operation executed on the virtual machine.
virtual_machine_id integer
The ID of the virtual machine related to the event.
reason string
The name of the operation executed on the virtual machine.
object string
The name of the resource for which a history of events is retrieved.
org_id integer
The ID of the organization associated with the event.
curl -X GET "https://infrahub-api.nexgencloud.com/v1/core/virtual-machines/{virtual_machine_id}/events" \
-H "accept: application/json"\
-H "api_key: YOUR API KEY"
{
"status": true,
"message": "string",
"instance_events": [
{
"instance_id": 0,
"user_id": 0,
"org_id": 0,
"time": "2023-12-19T20:02:26.075Z",
"type": "string",
"reason": "string",
"object": "string",
"message": "string"
}
]
}
Returns
The response includes the following information: the status
field, which can be either true
(indicating success) or true
(indicating failure), and a message
field describing the status. Additionally, an array of instance_events
objects is returned, each offering comprehensive details about individual virtual machine events.