We're updating help docs to reflect our new product naming. Gladly Sidekick (AI) is now called just Gladly, and Gladly Hero (the Platform) is now Gladly Team. Some articles may display outdated names while we update everything. Thank you for your patience! Learn more

Step Types

Prev Next

Steps are the individual operations that run when an App Action is triggered. They execute sequentially, and each step can reference inputs and the results of any previous step. Gladly supports four step types, each suited for a different purpose.

Key concepts include App Platform, HTTP Request, Transformation, and Secrets.

App Platform

Use an App Platform step to execute an action from the Gladly App Platform within your workflow. This step type connects your App Action to pre-built integrations that have been configured for your organization.

Configuration fields:

Field

Description

Name

The step name, written in snake_case or camelCase (e.g., get_order or getOrder)

Gladly App Platform Action

Select the action to execute from the dropdown

Example:

Name: get_order
Gladly App Platform Action: Look Up Order by Order Number

App Platform Actions

App Platform actions are configured separately in the Gladly App Platform.

Using Loop with App Platform Steps

The App Platform step includes a Loop option, which allows the step to repeat for each item in an array. This is useful when you need to process multiple records in a single App Action run — for example, checking the status of several orders at once.

To enable looping, click the Loop icon in the top right corner of an App Platform step. The step will update to App Platform loop and display additional configuration fields.

App platform interface showing step name and action configuration for Shopify integration.

Configuration fields when Loop is enabled:

Field

Description

Name

The step name, written in snake_case or camelCase

Query

The JSONPath query pointing to the array that will be iterated over in the loop (e.g., $.fetch_orders.result.orderIds)        

Gladly App Platform Action

Select the action to execute for each item in the array

Input

Once a Gladly App Platform Action is selected, the Input section displays the fields required by that action. Map each field to the appropriate value using JSONPath. Use $.it to pass the current loop item into a field (e.g., if your array contains email addresses, set the emailAddress field to $.it)        

Loop Variables

The current loop item is stored in the $.it.. variable. For example, if your array contains order IDs, reference the current ID as $.it.

To deactivate looping, click the Loop icon again (shown as Unloop step).

Example:

Step 1: fetch_orders
  Returns an array of order IDs

Step 2: get_order_details (App Platform + Loop)
  Loop Query: $.fetch_orders.result.orderIds
  App Platform Action: Look Up Order by Order Number

HTTP Request

Use an HTTP Request step to make calls to external APIs.

Configuration fields:

Field

Description

Name

The step name, written in snake_case or camelCase (e.g., fetch_order or fetchOrder)        

Method

The HTTP method: GET, POST, PUT, PATCH, or DELETE

URL

The endpoint URL. You can reference inputs and previous step results using JSONPath (e.g., $.params.orderId)        

Authentication

Optional. Select an authentication method (see Authentication Options below)

Headers

Optional. Add one or more request headers

Timeout (ms)

Maximum time in milliseconds to wait for a response. Defaults to 30000

Authentication options:

Option

Description

None

No authentication

Bearer Token

Adds an Authorization header with a token

Basic Auth

Username and password

API Key Header

Custom header with an API key

Example:

Name: fetch_order
Method: GET
URL: https://api.example.com/orders?id={{$.params.orderId}}
Headers:
  X-API-Key: {{$.secrets.API_KEY}}

Transformation

Use a Transformation step to manipulate or reformat data between steps using JavaScript. This is useful for filtering   arrays, reshaping data structures, or combining results from multiple previous steps.

Configuration fields:

Field

Description

Name

The step name, written in snake_case or camelCase (e.g., transform_data or transformData)

JavaScript

The JavaScript code to execute. Supports ECMAScript 5.1, including regex and strict mode. Autocomplete triggers when typing 3+ letters or after a.

Limitations:

  • ECMAScript 5.1 only — ES6+ features are not supported

  • No async/await

  • No external libraries

  • Strict mode is enforced

Available context within a Transformation step:

  • Inputs via $.params.*    

  • Previous step results via $.stepName.result    

  • Built-in customer context via $.context.*    

Examples:

Filter an array:

(function() {
  var items = $.fetch_items.result.data;
  return items.filter(function(item) {
    return item.status === 'active';
  });
})();

Reformat a data structure:

(function() {
  var order = $.fetch_order.result;
  return {
    orderId: order.id,
    total: order.amount / 100,
    items: order.line_items.length
  };
})();

Combine results from multiple steps:

(function() {
  var customer = $.fetch_customer.result;
  var orders = $.fetch_orders.result;
  return {
    customerName: customer.name,
    orderCount: orders.length,
    lastOrderDate: orders[0].created_at
  };
})();

Secrets

Use a Secrets step to store sensitive credentials — such as API keys, tokens, or passwords — securely within your App   Action. Secrets defined in this step can then be referenced in other steps, such as HTTP Request headers or URLs,   without exposing the credential value directly.

Configuration fields:

Field

Description

Name

The name used to reference this secret in other steps. Use UPPER_SNAKE_CASE (e.g., API_KEY, SHOPIFY_TOKEN)        

Value

The secret value, which will be securely stored and used in your App Action

Description

Optional. Describes what the secret represents and its purpose, for team visibility and maintenance

You can add multiple secrets to a single Secrets step by clicking + Add.

Referencing secrets in other steps:

Once defined, secrets are referenced using the following syntax:

{{$.secrets.SECRET_NAME}}

Example — using a secret in an HTTP Request header:

Headers:
  Authorization: Bearer {{$.secrets.API_TOKEN}}
  X-API-Key: {{$.secrets.SHOPIFY_API_KEY}}

Example — using a secret in a URL:

URL: https://api.example.com?key={{$.secrets.API_KEY}}

Secret Values

Secret values are encrypted and not visible in logs or test results. Ensure the secret name matches exactly when     referencing it in other steps, as names are case-sensitive.  

Contact Support

Can’t find the answer you need? Get in touch with the Gladly Support Team for assistance.

Contact Us