Go to main content

Oracle® ILOM Web Service REST API

Exit Print View

Updated: December 2019
 
 

Retrieve Resources Using GET Requests

Use a GET request to retrieve information about an Oracle ILOM resource.


Note -  HTTP GET requests will only retrieve data and not have any other effect on the data.

Request Format

GET <Resource_Path> HTTP/1.1
<Header Name> : <Header Value>

Request Header Fields Required

The required request header fields are as follows: Authorization, Accept, and Host.

For a description of these required header fields, see Common Request Header Fields.

Response Status Codes

  • Success: HTTP Status = 200 OK

  • Failure: HTTP Status = 4xx, 5xx

Response Body (Success Status)

When an entity corresponding to the requested resource is found, Oracle ILOM returns the details associated with the requested resource in the response body. In which case, the details in the response body can include: name|value pair properties, a collection of target resources, and a collection of non-CRUD actions supported for the target resource.


Note -  To identify the exact response body media type, refer to the Oracle ILOM Swagger Model (swagger.json) description. For more details, see Discovering Management Resources.
{
    "Target": "<target URI path>", 
    "property1 name": "property1 value",
    ...
    "propertyn name": "propertyn value",
    "Targets": [
        {
            "name": "<name of target1>", 
            "uri": "<URI path of target1>"
        }, 
        ...
        {
            "name": "<name of targetx>", 
            "uri": "<URI path of targetx>"
        } 
    ],
    "Actions": [
        {
            "name": "action1"
        }, 
        ...
        {
            "name": "actionx"
        }
    ]
}

Where:

  • The "Target" property would define the resource path.

  • The "Property name:value" pairs would define the property name and value.

  • The "Targets", if any, would define a collection of other accessible resources.

  • The "Actions", if any, would define non-CRUD actions that are applicable to the resource.

Response Body (Failed Status)

When an entity corresponding to the requested resource is not found, the response body returned includes an HTTP failure status code, as well as details describing the failure. For more details, see REST API Error Response.

Example: HTTP Request

In the following HTTP example, a request is sent to the server SP to retrieve information about the /System resource.

GET /rest/v1/System HTTP/1.1
Accept: application/json

Upon successfully locating the /System resource, the Oracle ILOM REST API returns the /System resource details in a JSON response body format, for example:

{
    "Actions": [
        {
            "name": "power-on"
        }, 
        {
            "name": "power-off"
        }, 
        {
            "name": "soft-power-off"
        }, 
        {
            "name": "reset"
        }
    ], 
    "Target": "/rest/v1/System", 
    "Targets": [
        {
            "name": "Open_Problems", 
            "uri": "/rest/v1/System/Open_Problems"
        }, 
        {
            "name": "Processors", 
            "uri": "/rest/v1/System/Processors"
        }, 
        {
            "name": "Memory", 
            "uri": "/rest/v1/System/Memory"
        }, 
        {
            "name": "Power", 
            "uri": "/rest/v1/System/Power"
        }, 
        {
            "name": "Cooling", 
            "uri": "/rest/v1/System/Cooling"
        }, 
        {
            "name": "Storage", 
            "uri": "/rest/v1/System/Storage"
        }, 
        {
            "name": "Networking", 
            "uri": "/rest/v1/System/Networking"
        }, 
        {
            "name": "PCI_Devices", 
            "uri": "/rest/v1/System/PCI_Devices"
        }, 
        {
            "name": "Firmware", 
            "uri": "/rest/v1/System/Firmware"
        }, 
        {
            "name": "BIOS", 
            "uri": "/rest/v1/System/BIOS"
        }, 
        {
            "name": "Log", 
            "uri": "/rest/v1/System/Log"
        }
    ], 
    "actual_power_consumption": 20, 
    "health": "Service Required", 
    "health_details": "PS1 (Power Supply 1) is faulty.", 
    "host_primary_mac_address": "<MAC address>", 
    "ilom_address": "<IP address>", 
    "ilom_mac_address": "<MAC address>", 
    "locator_indicator": false, 
    "model": "ORACLE SERVER X5-2L", 
    "open_problems_count": 1, 
    "part_number": "X5-2L-P1.LAST-20", 
    "power_state": "Off", 
    "primary_operating_system": "Not Available", 
    "primary_operating_system_detail": "<details>", 
    "qpart_id": "<QPART id>", 
    "serial_number": "<serial number>", 
    "system_fw_version": "<ILOM fw version>", 
    "system_identifier": "", 
    "type": "Rack Mount"
}