Creating HTTP automations

The HTTP automation provider allows to send HTTP requests to a specified web service.

The specified web service must be located in the public internet. It is not possible to connect to your private data center.

The specified web service can be in your private data center or in the public internet provided the RBA server can reach the destination. Ensure that the network setup, for example firewalls can reach the API endpoint of the web service.

Note: By default, Runbook Automation sets the HTTP header Content-Type to application/json unless the HTTP automation defines the header with different content.
  1. Click Automations > New automation. Complete the following fields:
    Type
    Select HTTP.
    Name
    Provide a name that describes what this automation does. For example, IBM Watson Translate.
    Description
    Provide any helpful additional information so that the user can immediately understand which problem this automation solves.
    Prerequisites
    If this automation requires prerequisites, add this information. For example, Watson service credentials are required.
    API endpoint
    Specify the http API endpoint of the web service to which the HTTP request will be sent to. For example https://gateway.watsonplatform.net/qagw/service/v1/question/1?TestIt.
    METHOD
    Choose the HTTP method. For example POST.
    Username
    If basic authentication is required to use the web service, specify the API user name for basic authentication.
    Password
    If basic authentication is required to use the web service, specify the API password for basic authentication.
    Accept
    Specify the accept request header. The accept header is used to specify the media types which are acceptable for the response of the request. For example text/html.
    Accept-Language
    Specify the accept-language request header which is used to restrict the set of languages that are preferred for the response of the request. For example en-US.
    Additional headers
    Optionally, specify any additional request headers that are needed for the request. For example accept-charset: utf-8.
    Ignore certificate errors
    Select this check box to ignore certificate errors. Use this option only for test purposes. In production environments, ensure that the correct certificates are installed on the target web service.
    Automation output
    • Filter automation output By default, all automation output gets collected and printed to the automation output field. If you are only interested in a subset of the automation output (for example, because you want to create a chain of two automations within a runbook, where some particular information from the first automation is used as input to the second automation), then you can enable the Filter automation output toggle and specify a pattern that controls which part of the automation output gets returned.
    • Choose query syntax Depending on the type of output that gets created you can choose between three types of pattern-matching engines and their respective syntax:
      • XPath: best suited for parsing XML data
      • JSONPath: best suited for parsing JSON data
      • Regular expression: best suited for parsing unstructured data
    • Choose query syntax at runtime Select this check box if you want to allow the query syntax to be chosen when testing the automation, and also within the enclosing runbook. This check box is typically disabled.
    • Enter query pattern Enter a pattern that is supported by the selected query syntax. For example, if the JSON output object is expected to contain an attribute called "version" and you selected the "JSONPath" query syntax, then you can use the query pattern "$.version" to pick the value of the version attribute out of the overall JSON output.
    • Enter query pattern at runtime Select this check box if you want to allow the query pattern to be chosen when testing the automation, and also within the enclosing runbook.
    • Test output filter Click this link (or the Test button in the actions menu) when you are ready to test the automation. This saves the automation and directly opens the Test automation page for the current automation. For many developers, working with query patterns is an iterative process. Therefore it is recommended to enable Enter query pattern at runtime at least while you are developing the automation, and switch to Test automation to fine-tune the query pattern. The development of the query pattern is also supported within the Test automation page itself, where you can toggle between Show filtered output and Show unfiltered output after you have run the automation. You can also toggle between Edit automation and Test automation until you are satisfied with the result.
    Parameters
    Add input parameters to run the automation. Those input parameters can be referred in the entry fields. For example, a parameter text can be referred as $text.
  2. Add the automation to the runbook, see Adding automations.
  3. Run the runbook, see Run a runbook.