Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Insert excerpt
_Banners
_Banners
nameactionflow
nopaneltrue

  • Understanding Actionflows
  • Creating Actionflows
  • Wiring Actionflows


    Output Record

    An HTTP action has two output connection points, See Output Connection points below. An HTTP request will be triggered for each input record and generate one output record, which will be sent on either the out or error output. 

    The resulting record, attributes returned by the request, are identical for both out and error outputs:

    1. body: The content returned by a successful request. For example, JSON content.

    2. contentType: The type of response provided by the target HTTP request. For example, application/json; charset=utf-8.
    3. status: the returned status code.For example, 200.

    4. status message: the returns status message. For example, OK.

    Tip

    Connect to a JSON Action to the output connection to interpret the JSON response into individual records.

    Excerpt

    Overview

    Image Modified

    Use a 

    Insert excerpt
    _action_http
    _action_http
    nopaneltrue
     to make HTTPS requests to external APIs;

    Insert excerpt
    _property_tabs
    _property_tabs
    namebasic-h
    nopaneltrue

    Basic Settings

    Expects literal values or expressions encapsulated within ${} syntax, for example ${in.MyValue}.

    FieldDescriptionExample ValueNameName given to the Email Action Node. This will be displayed on the actionflow canvas.BankHolidaysHTTP MethodThe HTTP method. A drop-down field containing: GET, POST, GET or POST, HEAD, PUT, DELETE, other. If other is specified a text box will allow the entering of a custom value which is not empty and contains only uppercase letters.GetURL Template

    A template that computes the URL of the request.

    Expects literal values or expressions encapsulated within ${} syntax, for example ${in.MyValue}.

    https://www.gov.uk/bank-holidays.jsonBody Template

    An optional field. If this evaluates to only whitespace then it is not included in the request.

    Expects literal values or expressions encapsulated within ${} syntax, for example ${in.MyValue}.

    Error ExpressionAn optional JEP expression to determine if the response is an error and so sent on the error output. The expression will have access to the input record (in) and the mapped output response (_result).Log TrafficLogs the response of the HTTP request.Maximum HTTP Log LengthRestricts the size of the log traffic.Use Raw URL

    If enabled the URL Temaplete value is sent in exactly the format it is provided to the HTTP Action. If not enabled PhixFlow will transpose values to form a valid URL, such as replacing spaces with %20%.

    Insert excerpt
    HTTP Action Configuration
    HTTP Action Configuration
    nameBasicSettings
    nopaneltrue

    Input Connection Points

    Can Accept a single

    Insert excerpt
    _driving_input_connection_point
    _driving_input_connection_point
    nopaneltrue
    .

    multiple  Insert excerpt_request_input_connection_point

    _request_input_connection_pointnopaneltrues

    The grid contains a list of all input connection points and their type.

    • To add a new input connection point, in the section toolbar click 
      Insert excerpt
      _add
      _add
      nopaneltrue
       to open a new input connection point and set its properties; see Input Connection Points.
    • To edit an existing input connection point, double-click it in the list to open its properties.
    • To remove an input connection point, select one and in the section toolbar click 
      Insert excerpt
      _delete
      _delete
      nopaneltrue
      .

    Output Connection Points

    The grid contains a list of output connection points, by default this will be out and error.

    Output Connection PointDescription
    OutContains the resulting record of the request. 
    ErrorContains the resulting record of the request where it satisfies the error expression specified on the HTTP
    Action
    Node

    Configuration

    The configuration of each output is identical:

    FieldDescriptionExampleNameName of the outputoutOutput TypeA drop-down field containing: String, Raw Data, JSON.StringSkip Invalid RecordsDefault CharsetA drop-down field containing character set options including utf-8.utf-8PathThe JSON path to apply. If empty this will default to '$' which matches the entire object.

    // $ returns everything, this syntax traverses down two levels using two full // stops.

    $..events

    JSON LenientAttributes

    Adding and Editing

    To add a new output path, in the section toolbar click  Insert excerpt_add_addnopaneltrue to open a new output path and set the expression; see Output Connection Points.
  • To edit an existing output path, double-click it in the list to open its properties.
  • To remove an output path, select one and in the section toolbar click  Insert excerpt_delete_deletenopaneltrue.

    Learn More

    Output Record

    An HTTP Node has two output connection points out and error. An HTTP Node is triggered for each input record and will generate one output record which will be sent on either the out or error output. 

    The resulting record contains the attributes specified by the output connection point, successful records are passed down the out connection point and records containing an error are passed down the error connection point. The stricture of the records by default is as follows:

    Insert excerpt
    HTTP Action Configuration
    HTTP Action Configuration
    nameOutputAttributes
    nopaneltrue

    Tip

    Connect to a JSON Node or XML Node to the output connection to interpret the response into individual records.

    Headers

    Are typically used to specify information for the request such as character sets, session tokens or passwords. Headers can make use of the Secret Key Details see below. For more information see HTTP Header

    For example,

    • Name: Content-Type
    • Value:  text/xml; charset=UTF-8


    Insert excerpt
    HTTP Action Configuration
    HTTP Action Configuration
    nameParameters
    nopaneltrue

    See HTTP Action Configuration for an example.

    Secret Key Details

    Secret Keys allow sensitive data such as passwords or security tokens to be encrypted and stored in the PhixFlow Database.

    Secret keys have a name which they can be referenced by using the syntax ${_datasource.keyName}. For full details on secret keys, see Secret Key and Local Secret.

    Retry

    Retry allows automatic reattempting of the the HTTP connection under the conditions specified by the Retry Expression.

    For example:

    • A transmission error or timeout occurs

    • Specific status codes are returned

    • Specific response body or headers are returned

    Tip

    Care should be taken if setting an automatic retry in response to a timeout as it may not always be appropriate, e.g. if the HTTP action causes a job to be started on a target system, receiving a timeout does not mean that the job was not started, therefore retrying (and possibly starting multiple processes or updates on a target system) might not be the desired solution.

    Expressions use _result to access the last response and tracking information. The initial requests will get a partially populated _result record. Using _result allows the action to modify the request, such as to follow redirects or links, or submit a token returned by the previous request.

    FieldDescription
    Retry Expression

    The default is false.

    Enter an expression that when it evaluates to true, the connection will be reattempted, instead of continuing through the Actionflow.

    When a Retry Expression is entered, the following options are available:
    Retry Interval Expression (ms)

    The default value is 1000

    Enter an expression that when it evaluates to an integer, it determines the amount of time between attempted requests.

    Maximum Retries

    The default value is 3

    This is the maximum number of times the HTTP action will try the HTTP connection before continuing. This must be an integer between 1 and 60.

    Description

    We recommend that you always enter a description to explain the purpose of this item.

    Advanced

    FieldDescription
    Connection Timeout (s)The maximum time to wait to while attempting to create a connection, measured in seconds. The default for this is set to 300 seconds.
    Response Packet Timeout (s)The maximum time to wait between responses from the data packets, measured in seconds. The default for this is set to 180 seconds.
    Prioritise throughput over ordering

    When this option is ticked records are processed in parallel to optimise performance. This means the order records are processed is nondeterministic.

    When unticked (default), records are processed in the order they are provided.

    More Options > Run Action

    Individual

    Insert excerpt
    _http
    _http
    nopaneltrue
    action nodes can be run in isolation from the rest of the Actionflow, using the
    Insert excerpt
    _run_action
    _run_action
    nopaneltrue
    option, found under the
    Insert excerpt
    _more_options
    _more_options
    nopaneltrue
    menu on the HTTP action's Properties. See Running Actions and Actionflows.



    Panel
    borderColor#00374F
    titleColorwhite
    titleBGColor#00374F
    borderStylesolid
    titleSections on this page
    Table of Contents
    indent12px
    stylenone




    Learn More

    For links to all pages in this topic, see Understanding ActionflowsActionflow Properties