Laminar
  • Laminar
  • Platform
    • Overview
    • Getting Started
    • Advanced
      • Workflows
        • Global Workflow Object
        • HTTP Request Batching
        • Workflow Exit Points
        • Invoke Secondary Workflows
      • Configurations
      • Flows
        • Flow Types
          • HTTP Request
          • Data Transformations
        • Supported Languages
      • Managing Notifications
    • Best Practices
    • Keywords
      • lam.resolveThenExecute
      • lam.exit
      • lam.execute
      • lam.asyncExecute
      • lam.httpRequest
      • lam.httpRequests
  • API
    • Executing a Workflow
    • Creating a Configuration
    • Authentication
    • Changelog
  • External Links
    • Book a Demo
    • Sign In
Powered by GitBook
On this page
  • Global Workflow Object Structure
  • Usage and Functionality

Was this helpful?

  1. Platform
  2. Advanced
  3. Workflows

Global Workflow Object

Learn about the GWO in Laminar

Global Workflow Object Structure

View an example Global Workflow Object
{
  "step_1": {
    "data": {
      "totalUsers": 4,
      "averageAge": 31.25,
      "totalItemsSold": 81,
      "users": [
        {
          "name": "Alice",
          "email": "alice@example.com",
          "totalSpent": 22
        },
        {
          "name": "Bob",
          "email": "bob@example.com",
          "totalSpent": 20
        },
        {
          "name": "Charlie",
          "email": "charlie@example.com",
          "totalSpent": 24
        }
      ]
    },
    "response": {
      "message": "Received POST request",
      "contents": {
        "totalUsers": 4,
        "averageAge": 31.25,
        "totalItemsSold": 81,
        "users": [
          {
            "name": "Alice",
            "email": "alice@example.com",
            "totalSpent": 22
          },
          {
            "name": "Bob",
            "email": "bob@example.com",
            "totalSpent": 20
          },
          {
            "name": "Charlie",
            "email": "charlie@example.com",
            "totalSpent": 24
          }
        ]
      }
    }
  },
  "step_2": {
    "data": {
      "lam.result": [
        {
          "lam.workflowId": 49,
          "lam.payload": {
            "lam.queryParams": {
              "email": "alice@example.com"
            },
            "lam.body": {
              "name": "Alice",
              "email": "alice@example.com",
              "totalSpent": 22
            }
          }
        },
        {
          "lam.workflowId": 49,
          "lam.payload": {
            "lam.queryParams": {
              "email": "charlie@example.com"
            },
            "lam.body": {
              "name": "Charlie",
              "email": "charlie@example.com",
              "totalSpent": 24
            }
          }
        }
      ]
    },
    "response": {}
  }
}

The Global Workflow Object is tailored to keep track of data transformations and responses throughout the workflow's execution:

  • Input (optional): Initial data input passed via POST request if the workflow starts with a flow that has no source.

  • Flow Steps: Each flow within the workflow contributes to this object, where each step might include:

    • Data: This part holds the results of data transformations by the flow.

    • Response: Stores the output or response received from the destination API after the data is processed and sent.

Usage and Functionality

  • Sequential Execution: Each flow accesses and possibly modifies the Global Workflow Object, allowing subsequent flows to utilize the transformed data and responses from previous steps.

  • Conditional Logic: The object structure supports workflows where flows can be dynamically adjusted or skipped based on conditions evaluated during the workflow execution.

PreviousWorkflowsNextHTTP Request Batching

Last updated 12 months ago

Was this helpful?