hi @Sirri  ,

Since approval_managers is defined as Array.String in your Action output, you can map it directly to a For Each loop. Each iteration will give you one sys_id.

However, your script must return an actual array, not a comma-separated string. Your current assignment is correct:

outputs.approval_managers = managerArr;

In your Subflow, configure it like this:

  1. Call your custom Action to retrieve the managers.

  2. Add a For Each flow logic and select the approval_managers output pill from your Action as the collection.

  3. Inside the loop, use the current item's value as the manager sys_id.

  4. If you need to trigger approvals for all managers, configure the approval logic so the flow waits for all required approvals before proceeding.

You don't need to split the output again if the Action is returning an array correctly. If your output is instead a comma-separated string, split it into an array before using the For Each loop.

I can't configure the Subflow directly in your instance or capture actual instance screenshots, but the steps above match the output type shown in your screenshot.

 

If this helped, mark it helpful and accept the solution.

Regards, Tejas