“Dental Floss Refill” appears in the “name” property in each list item. You can see the path to that property in the screenshot below from Best JSON Viewer and JSON Beautifier Online after I pasted in your JSON response.
So to get that property for each list item, you have to get the following properties from app variable JSON text
(since that is the JSON object in your code):
“records[1]._objects[1].name”
“records[1]._objects[2].name”
“records[1]._objects[3].name”
Assuming there are a variety of list lengths (not always 3 items), you would need to do a for each item
loop where the in list
value would be the property “records[1]._objects” of app variable JSON text
. And you would check to see if that value (in your code, the value is app variable seenproduct
) is equal to “Dental Floss Refill.” If it is equal, you would increase the value of a variable by 1.
I have more info about JSON parsing here: API JSON Tutorial (Video).