adverse-sapphireβ’2y ago
Issue with returned response from API
Hello, I'm trying to integrate Stack AI API within VF.
Everything is working fine (or seems to), I'm getting "status:" 200, returned. However, when I run flow test, I'm getting "0" as an answer and I don't understand why.
I have mapped the correct variable and everything.

12 Replies
adverse-sapphireOPβ’2y ago

Can you share a screenshot of the full API call step?
We're also using stack
adverse-sapphireOPβ’2y ago
There you go @MikeG


In the
capture response step, make it response.out-0 πadverse-sapphireOPβ’2y ago
So I tried replacing "out-0" with "response.out-0", but it is still returning "0"


sorry, make it
outputs.out-0
My bad ^^adverse-sapphireOPβ’2y ago
Now it worked thanks! What's the logic behind? Why does it work with
outputs.out-0 rather than response.out-0 or simply out-0?because stack AI wraps it's response in a outputs object
So the response is
And thus to get to out-0, you need to go through outputs.
outputs.out-0adverse-sapphireOPβ’2y ago
Actually question was more "Where did you see that Stack wraps its response as
outputs.out-0, but I suppose it's all in the docs
Anyways, thanks for your time @MikeG !Ye in the docs, but also if you make an API step, you can test it out within VF itself, which will show the response π
adverse-sapphireOPβ’2y ago
Hmmm, I do not have the developer reflexes. I should quickly acquire those aha!
Thanks a lot again π
No worries! Aways happy to help if you run in to something!