Go to main content

Oracle® ILOM Web Service REST API

Exit Print View

Updated: December 2019
 
 

How To Access Oracle ILOM Web Service API Using Swagger

A machine readable description of the Oracle ILOM REST API is available in Swagger format. This description of the Web Service REST API includes information on every resource available under the five top-level resources: /About, /System, /SP, /SYS, and /Host. The applicable HTTP verbs, resource property types, configurable properties, and a description string for each available property are available in the Swagger description

You can obtain a Swagger description of the Oracle ILOM Web Service REST API by issuing a URL to the swagger.json file on the managed SP device, for instance:

https://<target_SP_IP_address>/swagger.json.

The following instructions explain how to install the Swagger UI tool and use it to access the swagger.json file on the SP:

  1. Extract the Swagger UI zip file (downloaded from http://swagger.io) to a directory on the local file system. For example:
    /C:/Users/your_username/Downloads/ 
  2. Open a web browser and enter the file path to the Swagger UI tool. For example:
    file:///C:/Users/your_username/Downloads/swagger-ui-master/dist/index.html 

    The Swagger UI appears in the web browser.

  3. In the Swagger UI search box, enter the URI to the swagger.json file. For example:
    https://SP _IP_address:443/swagger.json

    Where: SP_IP_address represents the IP address of the target SP device.

    If the swagger.json appears in the web browser, proceed to Step 5. Otherwise, if the swagger.json file fails to load and the following message appears, proceed to Step 4 for troubleshooting instructions.

    Can't read from Service. It may not have the appropriate access-control-origin settings.
  4. (Optional Troubleshooting Step) If the swagger.json file failed to display in Step 3, follow these steps:

    Note -  The web browser might have not accepted the web server certificate on the SP.
    1. Open another web browser window and enter the following URL:
      https://SP_IP_address/swagger.json 
    2. Follow the instruction on the browser dialogs to add an exception for the SP.

      The swagger.json file appears in the browser window.

    3. Return to Swagger UI browser window (described in Step 3) and click the Explore button.

      The swagger.json file appears.

  5. To view the full swagger description of the Oracle ILOM Web Service REST API, click the Expand Operations link.
  6. To use the Swagger UI tool to access and modify Oracle ILOM resources, do the following:
    1. Click the Authorize button.

      A prompt appears prompting you to enter a generated X-REST-Token data value.

    2. Enter the X-Rest-Token data value that was generated from your user credentials, as described in the Token-Based Authentication.

      At the time of login, the web service uses the token data value to authenticate your Oracle ILOM user credentials on the target SP device.