I'm trying to pass four collection variables to be processed in apex but having a difficult time implementing invocable variables to allow for more than the single parameter an invocable method can take.
I suspect it has to do with the List<List> syntax, but I can't seem to get it right. Can someone point me in the right direction? Is this even possible? Should I just call separate apex actions instead? That seems inefficient.
With the below output, I cannot get the variables to appear for input in flow. When I change them back to normal lists, they show up correctly, but only present null values to the invocable method executing on them.
public without sharing class fileUploadController {
public class flowInputs {
@InvocableVariable
public List<List<String>> psrTestList;
@InvocableVariable
public List<List<String>> poaTestList;
}
@InvocableMethod
public static void psr(List<List<flowInputs>> request) {
List<String> results = new List<String>();
for (List<flowInputs> r : request) {
system.debug('test '+ r);
}
}