Abiquo Documentation Cookies Policy

Our Documentation website uses cookies to improve your experience. Please visit our Cookie Policy page for more information about cookies and how we use them.


Abiquo 4.4

Skip to end of metadata
Go to start of metadata

Contents:

Events Resource

The Events Resource enables you to retrieve the platform events that are available to display according to your event privileges, your user scope, and the privileges of your user role. For example, users with the CLOUD_ADMIN, ENTERPRISE_ADMIN, or USER roles will have access to different events. 

Main URI of the Resource

This class operates mainly over the Resource URI: /events

Exposed Methods

List events

Retrieve the list of Abiquo events that can be accessed by your role, for example, CLOUD_ADMIN, ENTERPRISE_ADMIN, USER.

Paging Method

This method works with paging. Check out Basic Behaviors for information about how it works

Synopsis: GET http://example.com/api/events
Roles Required: AUTHENTICATED
Request Headers: Accept: application/vnd.abiquo.events+json; version=4.4; application/vnd.abiquo.events+xml; version=4.4;  Content-type: ;
Request Parameters:

Parameter

Required

Default Value

Description

startwith

false

0

First element to retrieve

by

false

timestamp

Search to retrieve. Available values are: {DATACENTER, RACK,
PHYSICALMACHINE, STORAGESYSTEM, STORAGEPOOL, VOLUME, NETWORK, SUBNET, ENTERPRISE,
USER, VIRTUALDATACENTER, VIRTUALAPP, VIRTUALMACHINE, SEVERITY, PERFORMEDBY,
ACTIONPERFORMED, COMPONENT, STACKTRACE, DATEFROM, DATETO}

has

false

 

A value to filter the search.

limit

false

25

Number of elements to retrieve.

asc

false

false

The order of the elements retrieved (ascending -> true, descending -> false). Ascending by default.

datacenter

false

 

Filter from events list by datacenter name.

rack

false

 

Filter from events list by rack name. (eg: rack=JC-1542992d-309).

physicalMachinefalse Filter from events list by physical machine name. (eg: physicalMachine=JC-70211e79-980).
storageSystemfalse 

Filter from events list by storage system name.

storagePoolfalse Filter from events list by storage pool name (eg: storagePool=abiquo).
volumefalse Filter from events list by volume name (eg: volume=abiquovol).
networkfalse Filter from events list by network name (eg: network=myprivatenetwork1).
subnetfalse Filter from events list by subnetwork name
enterprisefalse Filter from events list by enterprise name (eg: enterprise=myfirstenterprise).
userfalse Filter from events list by user name (eg: user=mycustomer).
virtualDatacenterfalse Filter from events list by virtual datacenter name (eg: virtualDatacenter=BCNvirtualdatacenter).
virtualAppfalse Filter from events list by virtual appliance name (eg: virtualApp=JC-29d17bd8-81e).
virtualMachinefalse Filter from events list by virtual machine name
severityfalse Severity level filter to filter from event list (eg: severity=INFO).
performedByfalse Filter from events list by name of user who performed the action (eg: performedBy=customer1).
actionPerformedfalse Filter from event list by the actions performed (eg: actionperformed=VM_DELETE).
componentfalse Show only events from the component specified (eg: component=VIRTUAL_MACHINE).
stacktracefalse Filter from event list by words matching the stack trace (eg: stacktrace=moved).
datefromfalse Retrieve events from the date specified as the number of seconds since 00:00 1/1/1970 UTC in string format (eg: datefrom=1359370517)
datetofalse Retrieve events to the date specified as the number of seconds since 00:00 1/1/1970 UTC in string format (eg: dateto=1359370517)

Request Message Body Entity:
Response Message Body Entity: Events Media Type
Request Example:

 Click here to show or hide the request example

GET_evts_AC_evts_j.0001.txt

cURL:

curl -X GET http://localhost:9000/api/events \ 
	 -H 'Accept:application/vnd.abiquo.events+json; version=4.2' \ 
	 -u user:password --verbose 

Success status code: 200

Request payload:

--none--

Response payload:

{
  "totalSize": 2, 
  "links": [
    {
      "href": "http://localhost:9009/api/events?limit=25&by=timestamp&asc=false", 
      "rel": "first"
    }, 
    {
      "href": "http://localhost:9009/api/events?startwith=0&limit=25&by=timestamp&asc=false", 
      "rel": "last"
    }
  ], 
  "collection": [
    {
      "stacktrace": "51", 
      "idEnterprise": 734, 
      "links": [], 
      "idStorageSystem": 50, 
      "physicalMachine": "51", 
      "storagePool": "51", 
      "idUser": 50, 
      "id": 2, 
      "virtualApp": "51", 
      "idVirtualApp": 50, 
      "severity": "INFO", 
      "virtualMachine": "51", 
      "idStoragePool": "51", 
      "storageSystem": "51", 
      "performedBy": "51", 
      "idVirtualMachine": 50, 
      "idVirtualDatacenter": 50, 
      "actionPerformed": "51", 
      "idRack": 50, 
      "virtualDatacenter": "51", 
      "idNetwork": 50, 
      "subnet": "51", 
      "timestamp": "2017-12-05T15:21:53.000+0000", 
      "component": "51", 
      "volume": "51", 
      "idDatacenter": 50, 
      "user": "51", 
      "idVolume": "51", 
      "datacenter": "51", 
      "idSubnet": 50, 
      "network": "51", 
      "enterprise": "51", 
      "rack": "51", 
      "idPhysicalMachine": 50
    }, 
    {
      "stacktrace": "53", 
      "idEnterprise": 734, 
      "links": [], 
      "idStorageSystem": 52, 
      "physicalMachine": "53", 
      "storagePool": "53", 
      "idUser": 52, 
      "id": 3, 
      "virtualApp": "53", 
      "idVirtualApp": 52, 
      "severity": "INFO", 
      "virtualMachine": "53", 
      "idStoragePool": "53", 
      "storageSystem": "53", 
      "performedBy": "53", 
      "idVirtualMachine": 52, 
      "idVirtualDatacenter": 52, 
      "actionPerformed": "53", 
      "idRack": 52, 
      "virtualDatacenter": "53", 
      "idNetwork": 52, 
      "subnet": "53", 
      "timestamp": "2017-12-05T15:21:53.000+0000", 
      "component": "53", 
      "volume": "53", 
      "idDatacenter": 52, 
      "user": "53", 
      "idVolume": "53", 
      "datacenter": "53", 
      "idSubnet": 52, 
      "network": "53", 
      "enterprise": "53", 
      "rack": "53", 
      "idPhysicalMachine": 52
    }
  ]
}

Get events by component

 Click here to expand...

GET_evts_AC_evts_j_component.0001.txt

cURL:

curl -X GET http://localhost:9000/api/events?component=109 \ 
	 -H 'Accept:application/vnd.abiquo.events+json; version=4.2' \ 
	 -u user:password --verbose 

Success status code: 200

Request payload:

--none--

Response payload:

{
  "totalSize": 1, 
  "links": [
    {
      "href": "http://localhost:9009/api/events?component=109&limit=25&by=timestamp&asc=false", 
      "rel": "first"
    }, 
    {
      "href": "http://localhost:9009/api/events?component=109&startwith=0&limit=25&by=timestamp&asc=false", 
      "rel": "last"
    }
  ], 
  "collection": [
    {
      "stacktrace": "109", 
      "idEnterprise": 736, 
      "links": [], 
      "idStorageSystem": 108, 
      "physicalMachine": "109", 
      "storagePool": "109", 
      "idUser": 108, 
      "id": 6, 
      "virtualApp": "109", 
      "idVirtualApp": 108, 
      "severity": "INFO", 
      "virtualMachine": "109", 
      "idStoragePool": "109", 
      "storageSystem": "109", 
      "performedBy": "109", 
      "idVirtualMachine": 108, 
      "idVirtualDatacenter": 108, 
      "actionPerformed": "109", 
      "idRack": 108, 
      "virtualDatacenter": "109", 
      "idNetwork": 108, 
      "subnet": "109", 
      "timestamp": "2017-12-05T15:21:53.000+0000", 
      "component": "109", 
      "volume": "109", 
      "idDatacenter": 108, 
      "user": "109", 
      "idVolume": "109", 
      "datacenter": "109", 
      "idSubnet": 108, 
      "network": "109", 
      "enterprise": "109", 
      "rack": "109", 
      "idPhysicalMachine": 108
    }
  ]
}

Get events by dates

 Click here to expand...

GET_evts_AC_evts_j_datefrom_dateto.0001.txt

cURL:

curl -X GET http://localhost:9000/api/events?datefrom=0&dateto=1512573776 \ 
	 -H 'Accept:application/vnd.abiquo.events+json; version=4.2' \ 
	 -u user:password --verbose 

Success status code: 200

Request payload:

--none--

Response payload:

{
  "totalSize": 2, 
  "links": [
    {
      "href": "http://localhost:9009/api/events?datefrom=0&dateto=1512573776&limit=25&by=timestamp&asc=false", 
      "rel": "first"
    }, 
    {
      "href": "http://localhost:9009/api/events?datefrom=0&dateto=1512573776&startwith=0&limit=25&by=timestamp&asc=false", 
      "rel": "last"
    }
  ], 
  "collection": [
    {
      "stacktrace": "354", 
      "idEnterprise": 745, 
      "links": [], 
      "idStorageSystem": 353, 
      "physicalMachine": "354", 
      "storagePool": "354", 
      "idUser": 353, 
      "id": 16, 
      "virtualApp": "354", 
      "idVirtualApp": 353, 
      "severity": "INFO", 
      "virtualMachine": "354", 
      "idStoragePool": "354", 
      "storageSystem": "354", 
      "performedBy": "354", 
      "idVirtualMachine": 353, 
      "idVirtualDatacenter": 353, 
      "actionPerformed": "354", 
      "idRack": 353, 
      "virtualDatacenter": "354", 
      "idNetwork": 353, 
      "subnet": "354", 
      "timestamp": "2017-12-05T15:22:55.000+0000", 
      "component": "354", 
      "volume": "354", 
      "idDatacenter": 557, 
      "user": "354", 
      "idVolume": "354", 
      "datacenter": "354", 
      "idSubnet": 353, 
      "network": "354", 
      "enterprise": "354", 
      "rack": "354", 
      "idPhysicalMachine": 353
    }, 
    {
      "stacktrace": "352", 
      "idEnterprise": 745, 
      "links": [], 
      "idStorageSystem": 351, 
      "physicalMachine": "352", 
      "storagePool": "352", 
      "idUser": 351, 
      "id": 15, 
      "virtualApp": "352", 
      "idVirtualApp": 351, 
      "severity": "INFO", 
      "virtualMachine": "352", 
      "idStoragePool": "352", 
      "storageSystem": "352", 
      "performedBy": "352", 
      "idVirtualMachine": 351, 
      "idVirtualDatacenter": 351, 
      "actionPerformed": "352", 
      "idRack": 351, 
      "virtualDatacenter": "352", 
      "idNetwork": 351, 
      "subnet": "352", 
      "timestamp": "2017-12-05T15:21:55.000+0000", 
      "component": "352", 
      "volume": "352", 
      "idDatacenter": 557, 
      "user": "352", 
      "idVolume": "352", 
      "datacenter": "352", 
      "idSubnet": 351, 
      "network": "352", 
      "enterprise": "352", 
      "rack": "352", 
      "idPhysicalMachine": 351
    }
  ]
}

 

Get an event

Retrieve a single Abiquo event if it can be accessed by your Abiquo role, for example, CLOUD_ADMIN, ENTERPRISE_ADMIN, USER.

Synopsis: GET http://example.com/api/events/{event}
Roles Required: AUTHENTICATED
Request Headers: Accept: application/vnd.abiquo.event+json; version=4.4; application/vnd.abiquo.event+xml; version=4.4;  Content-type: ;
Request Parameters:

Parameter

Required

Default Value

Description

 

 

 

 

Request Message Body Entity:
Response Message Body Entity: Event Media Type
Request Example:

 Click here to show or hide the request example
GET_evts_X_AC_evt_j.0001.txt

cURL:

curl -X GET http://localhost:9000/api/events/1 \ 
	 -H 'Accept:application/vnd.abiquo.event+json; version=4.2' \ 
	 -u user:password --verbose 

Success status code: 200

Request payload:

--none--

Response payload:

{
  "stacktrace": "11", 
  "idEnterprise": 732, 
  "links": [], 
  "idStorageSystem": 10, 
  "physicalMachine": "11", 
  "storagePool": "11", 
  "idUser": 10, 
  "id": 1, 
  "virtualApp": "11", 
  "idVirtualApp": 10, 
  "severity": "INFO", 
  "virtualMachine": "11", 
  "idStoragePool": "11", 
  "storageSystem": "11", 
  "performedBy": "11", 
  "idVirtualMachine": 10, 
  "idVirtualDatacenter": 10, 
  "actionPerformed": "11", 
  "idRack": 10, 
  "virtualDatacenter": "11", 
  "idNetwork": 10, 
  "subnet": "11", 
  "timestamp": "2017-12-05T15:21:53.000+0000", 
  "component": "11", 
  "volume": "11", 
  "idDatacenter": 10, 
  "user": "11", 
  "idVolume": "11", 
  "datacenter": "11", 
  "idSubnet": 10, 
  "network": "11", 
  "enterprise": "11", 
  "rack": "11", 
  "idPhysicalMachine": 10
}