Recent searches


No recent searches

Understanding branching conditions (Legacy)



image avatar

Aimee Spanier

Zendesk Documentation Team

Edited Feb 03, 2025


2

21

21 comments

Hi Aimee Spanier, we are testing this in our sandbox, but the branch conditions are not working as expected.  For some reason, it always goes to the Else branch even though the conditions for one of the other branches should have been met.

3


Hi Aimee Spanier, i have the same problem. 

For the reason i don't know, it always go back in the else's branch. 

How can i fix this. 

thanks

0


image avatar

Harper Dane

Zendesk Luminary

I was running into the same issue as the users above, and I believe I've found the problem.

If you are making an IF/ELSE condition based on a dropdown selection, you must enter the field selection's Tag as the "IF" condition, not the selection Value (agent/customer-facing name).

You can find the field Tag / key in Admin > Objects & Rules > Tickets > Fields. Use the key listed for your selection from the Tags column, not the Value column.

For example, we have a field named "Order Issues" and one of the dropdown options says "File a warranty claim". The Tag / key for that selection is listed as claim_file

Therefore, my IF statement in Flow Builder needs to say claim_filenot  "File a warranty claim".

Hope this helps!

 

 

3


Hey Harper Dane, thanks for that tip!

After changing the value to the tag, it works as expected.  

0


Hi Aimee Spanier, is there any possibility to remove the branch limit?

Branch by condition can have up to six branches, including the Else branch.

Is there any reason to limit it to just 6 branches?

1


Is there an option to create variables based on the Present Options function? It seems rather limiting to only allow this information to come from API calls or whatever custom fields you already have on a ticket.

1


image avatar

Lisa Tam

Zendesk Product Manager

Hey Walter,

Can you share your use-case where you need more than 6 branches? I'm wondering if nested conditions could help with your use case.

0


image avatar

Lisa Tam

Zendesk Product Manager

Hey Rachael, 
Would the collect information step help with your use case where you can collect information from the end user via a form dropdown? This data can then be used with Branch by condition.

0


Hi Lisa Tam,

Thanks for your response.  I've considered using nested conditions, but our review team does not feel it is a good experience for the customers in this specific scenario.  Without giving away too much information, the options we need to provide to the customer exceed 6.  And using nested conditions would result in making it almost like we are interrogating a customer.  :)

0


Lisa Tam Hello, any visibility into when variables will include authenticated user information?
E.g. if we want to separate flows for authenticated and nonauthenticated users or use external_id/email to get more user info via API? 

1


Good question by Anton, I think this would be a major improvement. 😉

0


image avatar

Destiny

Zendesk Customer Care

Hello Madalina,
 
Thank you for getting in touch.
 
I recognize that you are experiencing challenges in trying to make the Flow Builder's branch condition limits align with your needs, and you are also inquiring about the possibility of expanding these limits in the future.
 
It has come to my attention that our team is currently working on a feature that should cater to your requirements, but unfortunately, I don't have any specific details on the expected time of arrival or on the enhancement of the branch limit. In the interim, I recommend exploring the use of Nested conditions within the Flow Builder, which might provide a solution for your current situation. You can find more information about this approach here: Understanding branching conditions.
 
Please feel free to reach out if you require additional guidance or have other questions. Cheers~!

0


I have recently implemented adding conditions to my flow using a dropdown option. Is there a way for the chatbot analytics to capture the choices I added in the dropdown fields? Additionally, how can I track those interactions that did not result in a handover?

0


image avatar

Dainne Kiara Lucena-Laxamana

Zendesk Customer Care

Hi Jhamine, 

We do offer Answer Bot analytics in Explore but are limited to the following: Analyzing your Flow Builder activity. Hope this helps!

0


You can only nest conditions up to three levels deep. Each level, including the top level, can contain up to six conditions.

We would like this limit to be increased. For example, we have 10 transaction types and need a condition for each, with this limit (maximum 6) we can't create a proper custom flow 

0


Looking for some assistance here please. I'm looking to use this feature to validate customer information by comparing two variables.

 

Email = provided by the customer through ‘ask for details’

customeremail = retrieved through a prior API call and stored as a variable 

 

Is this possible? Or perhaps there's a different way to compare info collected with known information stored from API responses?

1


Thanks for the development on the Zendesk bot so far, it's really nice.

Is it not possible to compare two variables? It is so limited that we have to enter the values to compare with variables manually, what if we want users to make a selection and compare it with the values obtained via API call which is stored in a variable?

0


Is it planned to add a condition for an empty/ not empty variable? Thanks :)

2


Martine Hirth It's possible

1


Viachaslau Thank you, it's working now !

0


I plan to set custom fields or tags using the Core API:

 

zE("messenger:set", "conversationFields", [

  { id: "123456789", value: 100.50 }

])

 

How do I get the conversationField, or tag to show up in the conditions of the branch by condition?

For ticket fields, I only see email and name. 

Messaging Metadata shows only Provided name, Provided email, Authenticated external ID and Authenticated Status.

I know I can set variables using REST api calls to my server, but in this case it's all about what page of my web application the user is on, and/or some button they clicked on, which I need to ‘hard set’ to go to an Answer that is specific to that. 

 

Let's say I have a page of my site called “Playing in sandboxes” and they initiate their chat from this page.

 

I would 

zE("messenger:set", "conversationFields", [

  { id: "123456789", value: sandboxes }

])

And then I would have an answer set as my default_open which would have as the first step a branch by condition which would check for this Ticket Field. If it was “sandboxes” I'm going to route to the answer where the first Send Message says: Hey I see you are playing in the sandbox! Great! Do you have a question for yourself, or your kid? 

I don't want to have every interaction with the chat start with “how can I help you” when throughout my app there are pages where.. if the chat is initiated from that page there is a 99% chance I don't need to ask them how I can help. 

 

The specific use case is more like a - click this button to connect to a Sandbox Expert… then the chat bot will load a form which gathers some pre-conversation questions.. then transfers to a live agent. 

 

How do I do this?

0


Please sign in to leave a comment.