cancel
Showing results for 
Search instead for 
Did you mean: 

HTTP Component - JSON Rest response - issue accessing data after FOR EACH

kyledlear
Deputy Chef I
Deputy Chef I

Hi,

I have gotten a large JSON response from a webservice using the http action,

This has nested data in arrays, which are represented by the schema.

I am able to creatre a repeat action, with a for each on the element that looks like  : 

FOR EACH item in #{_('data.rest.bbf31283.response.data.total-product-pricing')} do

However, in the next step whilst it iterates for each item in this array, it doesn't add to the receipt data, and I can't seem to reference the for each step in order to create a list containing the items to use in futher steps.

What I am trying to do is create a list of items, that can be used in a slack / teams message later on.

2 REPLIES 2

ahanumantharaya
Deputy Chef III
Deputy Chef III

Hi,
you can call functional recipe for each iteration or you need to use log inside for each. Thats the only way you can see data in and out.
Thanks,
Amar.

marlon-muela
Workato employee
Workato employee

Hello @kyledlear !
This is Marlon from the support team.

You might encounter an issue, especially if the list/array you use is three or more levels from an existing list/object.

A workaround is to highlight the list from the data tree and then, drag and drop it on the repeat action.