Web API

Version: 4.0.8

Web API integration allows you to execute any Web API and retrieve results.

Connect Web API with LogicHub

  1. Navigate to Automations > Integrations.
  2. Search for Web API.
  3. Click Details, then the + icon. Enter the required information in the following fields.
    • Label: Enter a connection name.
    • Reference Values: Define variables here to templatize integration connections and actions. For example, you can use https://www.{{hostname}}.com where, hostname is a variable defined in this input. For more information on how to add data, see 'Add Data' Input Type for Integrations.
    • Verify SSL: Select option to verify connecting server's SSL certificate (Default is Verify SSL Certificate).
    • Remote Agent: Run this integration using the LogicHub Remote Agent.
    • Client Certificate: Upload a .p12 Client Certificate file (p12 file at action input takes precedence over connection).
    • Client Certificate Password: Enter password to read the client certificate.
    • CA Certificate: Upload a .crt CA Certificate file.
  4. After you've entered all the details, click Connect.

Actions for Web API

Execute Web API

Execute the given Web API and return the response.

Input Field

Choose a connection that you have previously created and then fill in the necessary information in the following input fields to complete the connection.

Input NameDescriptionRequired
Request TypeGET/POST/PUT/PATCH/DELETERequired
URLJinja-templated Url Endpoint.Required
HeadersJinja-templated Web api request headersOptional
ParamsJinja-templated Web api request parameters.Optional
BodyJinja-templated Web api request bodyOptional
UsernameUsername for request.Optional
PasswordPassword for request.Optional
Client CertificateUpload a .p12 Client Certificate file.Optional
Client Certificate PasswordEnter the password to read the client certificate.Optional
Expected Response FormatSelect how to parse the response based on its expected format. Raw/CSV/HTML/JSON/File. (Default is "Raw" and will pass the full body to the response field). File will write the raw response to a file (as binary data) and return the file-id.Optional
Explode ResultsIf server response is parsed as a list of values instead of a single value, return as individual rows for each value (Default is False).Optional
Multipart Form DataSelect if you are sending form data in body and body should be in JSON with no headers. Default is NoOptional

📘

Change cURL to Web API integration inputs

curl --location  --request POST 'https://beecepter/api/path/to/your/endpoint?pageSize=20&offset=60' \
--header 'Content-Type: application/json' \
-u 'admin:thisispassword' \
--data '{
    "id":23,
    "category": "A"
}'

For the above cURL request the inputs will be:

Request Type: POST

URL: https://beecepter/api/path/to/your/endpoint

Headers: {"Content-Type": "application/json"}

Params: {"pageSize":20,"offset":60}

Body: {"id":23,"category": "A"}

Username: admin

Password: thisispassword

Output

A JSON object containing multiple rows of result:

  • has_error: True/False
  • error: message/null
  • other keys of JSON response

Release Notes

  • v4.0.8 - Support for multipart form data.
  • v4.0.4 - BUG fix: Credentials Stored in Integration Connection Reference Values Are Displayed in Errors
  • v4.0.0 - Updated architecture to support IO via filesystem
  • v3.2.0 - Added optional field CA Certificate at connection level to override the default certificate.

© Devo Technology Inc. All Rights Reserved.