How to get/access value from the response from "Create and wait for queue item" task action in Maestr

Hello,

I have created a Maestro flow, added one task and selection action “Create and wait for queue item”. Then I’m processing the queue item from other RPA bot and adding “response” in set transaction process.
Once the Maestro flow is resumed, I am trying to get that “response” from the outputs, but I’m having difficulties in it.

Below are the methods I tried but didn’t work:

  1. output(“response”)
  2. output
  3. result.response.output
  4. result.response.output("response)

am I missing something here or following wrong method?

hi @Rohit_More ,

In the Maestro task’s Output > Response section, map source response (from queue item Output) to a Maestro process variable (e.g. queueResponse ).​

Use queueResponse directly in expressions/script tasks
no output("response") or result.response.output needed.​

If raw JSON needed, map full Output to queueOutput , then in Script: JSON.parse(queueOutput).response .

@Rohit_More

First try to print your output object as it is coming as object first we can check the structure of output object and then move forward from there on how to access..mostly you might get a json string and we might need to parse it

cheers

@arjun.shiroya I have tried but I’m still getting blank in the output

@Anil_G I have printed the output variable in another RPA flow and the schema is {“response”:“response content”}
Then tried with Qresponse(“response”) but it failed (I think it’s object and not JObject).
I have tried parsing it to json but the expression editor does not allow as it does not expose the .NET methods. Also the expression need to be compliant with JS to work in runtime.

1 Like

@Rohit_More

I tried and this is working..jobject is automatically parsed during runtime without any parsing

vars.response.Output.response


Hope this helps

cheers

1 Like

@Anil_G

thanks for the response.

I also just tried with this expression and it worked: (string)vars.response.Output.response

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.