Versions Compared

Key

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

...

Your use of this download is governed by Stonebranch’s Terms of Use, which are available at https://www.stonebranch.com/integration-hub/Terms-and-Privacy/Terms-of-Use/

Overview

A Web service is a method of communication between two electronic devices over a networkAWS Glue is a serverless data-preparation service for extract, transform, and load (ETL) operations. It makes it easy for data engineers, data analysts, data scientists, and ETL developers to extract, clean, enrich, normalize, and load data.

This Universal Extension provides the capability to call endpoints of foreign APIs. It is beneficial for Stonebranch SaaS customers that are accessing the Universal Controller in the Stonebranch AWS Cloud and having their Universal Agents deployed in their datacenter. As the integration is triggered from the Universal Agent, no additional firewall port for the Universal Agent needs to be openedtha capability to submit a new AWS Glue Job.

Software Requirements

This integration requires a Universal Agent and a Python runtime to execute the Universal Task.

...

The input fields for this Universal Extension are described in the following table.

FieldInput typeDefault valueTypeDescription
ProtocolRequiredHTTP(S)/RESTChoiceThe communication protocol to be used towards the foreign API.
HTTP VersionRequired1.1ChoiceThe Hypertext Transfer Protocol version.
Authorization TypeRequiredBasicChoiceThe authorization type to be used for communicating with the foreign API. The following options are available:
  • None
    No authorization details are sent with the request.
  • Basic
    Basic authentication involves sending a username and password with the request.
  • OAuth2 Token
    The request authenticates using an access key.
CredentialsOptional-CredentialsCredentials for "Basic" Authorization Type. They are comprised of:
  • username
  • password
Required when Authorization Type is "Basic".
OAuth2 TokenOptional-Large TextThe token for "OAuth2 Token" Authorization Type.
Required when Authorization Type is "OAuth2 Token".
Add Authorization Data ToOptionalRequest HeaderChoiceSpecifies where to include the OAuth2 Token in the request. The following options are available:
  • Request Header
    The token is included in the request header with key: "Authorization" and value: <Authorization Header Prefix>< token_value>.
  • Request URL
    The token is added as a query parameter in the request with key: "access_token" and value: <token_value>.
Required when Authorization Type is "OAuth2 Token".
Authorization Header PrefixOptionalBearerTextThe prefix for the OAuth2 Token. The token value is appended to the Authorization Header Prefix in the request Authorization header. For example: Bearer <token_value>.
Required when Add Authorization Data To is "Request Header".
URLRequired-TextThe URL to be called.
HTTP MethodRequiredGETChoiceThe HTTP method to be used in the request.
The following options are available:
  • GET
  • POST
  • PUT
  • PATCH
  • DELETE
TimeoutOptional-IntegerThe time (in seconds) that the request will wait for the server to send data before closing the connection. If Timeout is not filled, the request will wait (hang) until the connection is closed.
URL Query ParametersOptional-ArrayThe list of parameters key/value pairs to be sent in the query string for the request.
Payload TypeOptionalRawChoiceThe type of data to be sent in the request body. The following options are available:
  • Raw
    A "Content-Type" header is set based on the selected MIME Type.
  • Form-Data
    "x-www-form-urlencoded" is set as a "Content-Type" header.
Required when HTTP Method is "POST", "PUT" or "PATCH".
Payload SourceOptionalFormChoiceFor Payload Type of value "Raw", it specifies how the payload will be provided. The following options are available:
  • Form
    The Payload field will be available to manually insert the required payload.
  • Script
    The The Payload Script field will be available to insert the required payload as a script.
Required when Payload Type is "Raw".
MIME TypeOptionalapplication/jsonChoiceThe MIME type to be used in the request's header. The following options are available:
  • application/javascript
  • application/json
  • application/xml
  • text/html
  • text/plain
  • text/xml
  • Other
Required when Payload Type is "Raw".
Other Value For MIME TypeOptional-TextThe MIME type to be included in request's header in case "Other" is selected as MIME Type value.
Required when MIME Type is "Other".
Form DataOptional-ArrayThe list of parameters key/value pairs to be sent in the request body. The request header will include ""x-www-form-urlencoded" as a "Content-Type" in this case.
PayloadOptional-Large TextThe payload to be sent in the request body.
Required when Payload Source is "Form".
Payload ScriptOptional-ScriptThe script to be used as a payload source.
Required when Payload Source is "Script".
HTTP HeadersOptional-ArrayThe list of HTTP Headers key/value pairs to be sent with the request.
If "Content-Type" header is provided, it will be disregarded by the extension, as the MIME Type field is used for this purpose.
ProxiesOptional-TextThe proxy servers to be used, in the format of values separated by comma. For example: http​://ip1:port1,ftp​://ip2:port2
Use SSLRequiredFalseBooleanSpecifies if SSL protocol should be used for the communication with the foreign API.
SSL Hostname CheckOptionalTrueBooleanDetermines if the host name of the certificate should be verified against the hostname in the URL.
Required when Use SSL is checked.
Trusted Certificates FileOptional-TextPath and file name of the trusted certificate or CA bundle to use in certificate verification. The file must be in PEM format.
Private Key CertificateOptional-TextPath and file name of the private key file for client side authentication. The file must be in PEM format.
Public Key CertificateOptional-TextPath and file name of the public key certificate for client side authentication. The file must be in PEM format.
Print Result Body To
Introduced in version 1.1.0
OptionalSTDOUTChoiceSpecifies where to print the web service output payload. Currently available options are:
  • --None--
  • STDOUT
Process Exit Code Mapping
Introduced in version 1.1.0
RequiredFalseBooleanFlag that determines whether exit code mapping is enabled or not.
Path Expression
Introduced in version 1.1.0
Optional-ChoiceField visible only when Process Exit Code Mapping is checked and it is required when visible.
The JSON path that is used to check the provided patterns that are set-up on the Response Exit Code Mapping array.
Response Exit Code Mapping
Introduced in version 1.1.0
Optional-ArrayField visible only when Process Exit Code Mapping is checked and it is required when visible.
Array that maps patterns to exit codes.
Provided exit codes should be in the range [100-255].

SSL Certificate Authority File Discovery

...

Task Results:
EXIT_CODE_MAPPING_RESULT

Task Output

Output Fields

FieldTypePreserved on re-runDescription
Response CodeTextFalseThe webservice response code.

Exit Codes

The exit codes for this Universal Extension are described in the following table.

Exit CodeStatus Classification CodeStatus Classification DescriptionStatus Description
0SUCCESSSuccessful ExecutionSUCCESS: Task executed successfully <Additional information>.
1FAILFailed ExecutionFAIL: <Unexpected error description>
3AUTHORIZATION_ERRORInsufficient PermissionsAUTHORIZATION_ERROR: The authorization credentials provided for the request are invalid.
21FOREIGN_API_REQUEST_ERRORBad request to third party APIFOREIGN_API_REQUEST_ERROR: Client side error when sending the request.
22FOREIGN_API_RESPONSE_ERRORValidation error response from third party APIFOREIGN_API_RESPONSE_ERROR: Server side error.
23FOREIGN_SERVER_ERRORDestination URL not found or redirectedFOREIGN_SERVER_ERROR: Not Found
24EXIT_CODE_MAPPING_ERRORError occurred during Exit Code MappingEXIT_CODE_MAPPING_ERROR: Invalid Path Expression
EXIT_CODE_MAPPING_ERROR: No match found for the provided expression
EXIT_CODE_MAPPING_ERROR: Response body not in JSON format
EXIT_CODE_MAPPING_ERROR: Unable to parse the JSON body

Extension Output

The extension output result has the following fields:

...

This document references the following documents:

NameLocationDescription
Universal Templateshttps://docs.stonebranch.com/confluence/display/UC71/Universal+TemplatesUser documentation for creating Universal Templates in the Universal Controller user interface.
Credentialshttps://docs.stonebranch.com/confluence/display/UC71/Credentials#Credentials-CredentialDetailsFieldDescriptionsUser Documentation for Credentials Details Field Description
Universal Taskshttps://docs.stonebranch.com/confluence/display/UC71/Universal+TasksUser documentation for creating Universal Tasks in the Universal Controller user interface.