How to use attribute set at the same flow?

(Pavel Doronin) #1

What I do:

  1. “Ask a question”
  2. “Set attribute” = answer
  3. “Add a row” to google table with attribute value.

Problem: the logic doesn’t work at the same flow.

But. If I do the flow second time in my bot - “Add a row” works - but it uses attribute value from the first time I run the flow.

Can you help plz?

Thx!

(Daniel Beckett) #2

Hi Pavel,

It sounds like you may need an Attribute > Get Attribute action to pull through the updated value before your add a row action.

Feel free to share some details about your flow with the support team if you’re still having trouble getting it to work. You can contact us by emailing support@flowxo.com

Thanks,
Dan

(Pavel Doronin) #3

Actually I tried. But that doesn’t work too.

I will try more.

Thx.

(Karen Barker) #4

Hi Pavel,

When you are updating the row are you using trigger.attribute to populate the row or are you using the getAttribute.value?

You do need to reference the GetAttribute action to use the updated value of the attribute. :slight_smile:

#5

Hi,
i have same problem.

I set an attributes with a fields of a json objects returned by a webhook {{create_bot_record.data__data__flowxo_bots_id}} but using attributes in next steps {{welcome.attributes__Lead}} the value is empty.

I tried to use getAttributes but {{welcome.attributes__Lead}} was empty.

{{welcome.attributes__Lead}} has a value the second time bot was triggered (without close web chat).
Every time bot is trigger again my attributes have the value of previous set.

Where am i wrong ?

(Daniel Beckett) #6

Hi,

It may be easier for us to assist with this if you email the support team - support@flowxo.com

If you can share some extra information from your ‘Interactions’ (formerly logs) that would also be great.

Thanks,
Dan

#7

Hi,

It would help to know how this was resolved, we are seeing the same problem… we retrieve values from metadata at the beginning of the flow and store them in attributes. The log shows they were succesfully set, but when we go an try to use them like {{your_flow.attributes__attributename}}. Yet the attributes don’t show up (its empty).

Any idea why this is happening?

Thanks

1 Like
(John Jackson) #8

The attributes you get through on the trigger (by a bot message or catchall) won’t change through the flow.

So if an attribute may have changed through the flow, you have to add a ‘Get an Attribute’ action then use the value that is output by this action. This will always be the current attribute value at the time you run the action.

You may find this tutorial useful:

(Scroll down to the section Get an Attribute).