Skip to end of banner
Go to start of banner

Generate PDF Behavior DRAFT

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Version History

Version 1 Current »

Summary

Allows LearningBuilder to make arbitrary HTTP requests to external systems and then use the response to update Workflow attributes.

Overview

This Behavior makes an API call to a generic external API and can save the response in an Attribute value.

The API endpoint that gets called is provided by an REST API Endpoint defined in App Config. We currently support Basic Authentication only.

This supports “fire and forget” API calls only that involve a single outbound API call.

APIs that require a “conversation” of multiple API calls can be supported by implementing a custom Lambda wrapper endpoint, which requires advanced technical customization.

Configuration

image-20241016-125815.png

Field

Purpose

As configured by

Indicates how the Behavior determines the API endpoint and payload details.

API Endpoint + System Template is the recommended approach. It uses REST Api Endpoints to determine the endpoint and authentication details and a /wiki/spaces/DOCS/pages/3368452109 to provide the API payload.

Template Attribute is a legacy, deprecated approach. It uses a /wiki/spaces/~557058c68854918755418796437a03843705a0/pages/4054745157, defined on a specific Workflow, to generate the API endpoint, authentication headers, and payload.

Request Timeout

How long in seconds to wait for the API call to finish before abandoning it.

The entire user request (that triggers the Behavior) must finish in 30 seconds or less, so the recommended value here is ~5 seconds in case multiple Behaviors are joined together.

Raw Response Attribute

An Attribute to store the entire API response.

This is generally intended for logging and troubleshooting purposes and generally should not be displayed to end users.

Process the response using

A /wiki/spaces/DOCS/pages/3493920788 that can optionally be used to extract a meaningful value from the raw response for storage on another Attribute.

For example, assume the API returns a JSON response like this:

{
  result: "Success",
  timestamp: "1/1/2024 12:12 PM",
  responsibleParty: "Joe Schmoe"
}

If the “Joe Schmoe” part of the response is significant and affects other parts of the system, then a custom script can be used to extract that string from the raw response.

  • No labels