Passing the result of an API call from API workflow to another

Hi,

In an API workflow there is an API call, I want to pass the result of this call to another API workflow but the parameters of the API workflows not accept “API calls” as a data type.

Temporarily I added a field to the user to store the result of the API call in the first API workflow then access this field in the second API workflow, but I belive that this is not the right way to do it.

So what is the right way to pass the result of an API call from API workflow to another?

Hi, you don’t need to save it, you can extract the result of call 1 and use that as the params of call 2. Is this back or front end?

It is a backend workflow, and I am trying to pass params from the result of call 1 to another backend workflow with no call2. I do this because the result of call 1 is a list (so I need a loop) and it contains another nested list (so I need another loop).

Extracting the text values from the result of call1 and passing these texts to another backend workflow is not work because of multiple nesting levels.

I can make call1 in the first backend workflow and then recall it in the second backend workflow, or I have to store the result of the call in DB in the first backend workflow and then access it in the second workflow, or I may move all this to the frontend, I am not sure what is the right way to go.

Well if it’s a list then its obviously a whole different story. If you need a loop to extract it, then I don’t know of any way to avoid saving the response.

1 Like

Actually I found that may I was overwhelming myself a little, I was using bad data structure and trying to make a separate data type for each nested array, actually there is no need for this, I can make one data type and store in a filed of it the whole object retrieved via API, then I can access all its nested arrays from the frontend.