<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content
0D5KZ00001AUdVV0A1Okta Identity EngineWorkflowsAnswered2026-04-03T09:00:22.000Z2025-07-24T08:20:10.000Z2025-07-31T15:21:05.000Z

3dl5q (3dl5q) asked a question.

Passing additional fields from main workflow to helper workflow

Hi there,

 

I'm currently trying to pass a single string output to a "List - For Each" card which has a helper flow associated with it. I need the string value to be passed to the helper flow so I can assign it to a separate function within that Helper flow.

 

I can generate it string within the helper flow but this would cause that it regenerates at every run which would not be an efficient way to tackle this problem.


  • TimL.58332 (Workflows)

    @3dl5q (3dl5q)​  -- This is typically how you would handle it in scenario's where the built-in authentication option(s) on the API Connector won't work for the endpoint you are utilizing and you need to manually generate your own bearer token.

     

    The "If/Error" card in Workflows is a (Try / Catch) block. So you can "Try" to perform the API call then if the call fails with a 401 due to the bearer token expiration in the "Error/Catch" block you can call a flow similarly to what I demonstrated previously that generates a new bearer token, stores it, and can return it back to you. Then in the Error block you just perform the same API call again with the same inputs but now with the new token.

     

    Keep in mind this only works if you keep your currency to (1) on List - For Each. Otherwise you could have multiple threads that get a 401 at the same time, they both try to generate a new token, update the table etc.. and they could end up writing an invalid token to the table. With concurrency of (1) it would always be in order.

    Expand Post
    Selected as Best
  • BrandonB.06003 (Customer)

    List - for each can only be used with lists. so id suggest putting the strings into a list. there are a number of functions to build lists. To pass fields into the child flow, define them in the far-left-most card in your helper flow. click where it says "click or drag to create" and define the input. then reselect the flow on the list for each and itll show that input

  • TimL.58332 (Workflows)

    @3dl5q (3dl5q)​  - Your use case sounds more like a "Call Flow" or "Call Flow - Async" type use case. You would first setup your Helper Flow and define what inputs you want to populate (in your instance it sounds like a single variable). Once the Helper is added, input is defined, and the flow is saved. In another flow you can leverage Call Flow and select this helper flow. The input you defined on the Helper will be the input on the Call Flow card. You can then pass a value into it.

     

    The advantage to Call Flow is you can also define a variable on the bottom of the card. And in the Helper flow on a "Return" card if you define the same variable it will be passed back up to the Call Flow card.

     

    Here is an example:

    Call flow card with input and Helper flow selected.

    imageHelper flow has stringValue defined as the input. Notice that Call Flow shows what you defined in the helper but it allows an "input" field where I typed in: testString.

     

    Concatenate is utilized to demonstrate "processing" and the final value is passed into the Return which has finalValue defined as the variable to match the variable "finalValue" defined on the Call flow

    image 

    Results:

    Processing occurs and Return is performed with the updated value.

    image 

    Value is passed back to up to Call Flow

    image 

     

     

    Expand Post
    • 3dl5q (3dl5q)

      To provide more context, the problem I'm dealing with sits more to where I need to edit a list of items being processed with static data either from the main flow or from a helper flow inside a helper flow to handle the logic.

       

      Additional context:

      • I have a Jamf Pro - Read Computer Group card that outputs a computer list:

      [

       {

        "Mac Address": "XX:XX:XX:XX:XX:01",

        "Serial Number": "SERIAL-001",

        "ID": 24,

        "Name": "MacBookPro-SERIAL-001",

        "Alt Mac Address": "YY:YY:YY:YY:YY:01"

       },

       {

        "Mac Address": "XX:XX:XX:XX:XX:02",

        "Serial Number": "SERIAL-002",

        "ID": 25,

        "Name": "MacBookAir-SERIAL-002",

        "Alt Mac Address": "YY:YY:YY:YY:YY:02"

       },

       {

        "Mac Address": "XX:XX:XX:XX:XX:03",

        "Serial Number": "SERIAL-003",

        "ID": 27,

        "Name": "MacBookAir-SERIAL-003",

        "Alt Mac Address": "YY:YY:YY:YY:YY:03"

       }

      ]

      • The immediate next calling card is Jamf Pro - Generate Bearer Token which outputs a single string value.
      • I then need to use the List - For Each function to process a Jamf Pro action for each computer from the first calling card computer list, except for that action to be done, I need to pass the bearer token. I can do this internally in the helper flow but that would generate a new token on every time the helper flow is run per item, this is where my problem is.
      • I've tried combining and construction a new list with the string value added into the list format that gets inputed in the List - For Each card in the main workflow by using the List - Add To Front to add the token string to the beginning of the list. List - For each just ignores the token value and only shows the computers so I cannot pass additional data in that list unless the token itself is nested under each computer.
      Expand Post
  • 3dl5q (3dl5q)

    Another thought I had was to make use of another helper flow inside the List - For Each helper flow that handles the token logic end to end. i.e once called it should check and store token, if expired then generate new one and return to the 1st helper flow, if not expired then return the stored token instead. This would solve the problem too.

    • TimL.58332 (Workflows)

      @3dl5q (3dl5q)​  -- This is typically how you would handle it in scenario's where the built-in authentication option(s) on the API Connector won't work for the endpoint you are utilizing and you need to manually generate your own bearer token.

       

      The "If/Error" card in Workflows is a (Try / Catch) block. So you can "Try" to perform the API call then if the call fails with a 401 due to the bearer token expiration in the "Error/Catch" block you can call a flow similarly to what I demonstrated previously that generates a new bearer token, stores it, and can return it back to you. Then in the Error block you just perform the same API call again with the same inputs but now with the new token.

       

      Keep in mind this only works if you keep your currency to (1) on List - For Each. Otherwise you could have multiple threads that get a 401 at the same time, they both try to generate a new token, update the table etc.. and they could end up writing an invalid token to the table. With concurrency of (1) it would always be in order.

      Expand Post
      Selected as Best
This question is closed.
Loading
Passing additional fields from main workflow to helper workflow