3

I have a Process that sends an email to the customer a few days after using our Live Agent chat implementation. I need to add criteria to the Process that if the Time-Out Checkbox on Case is checked, it will not send the email.

I tried building a Process on Live Chat Transcript Event that if the Type = Visitor Idle Time-Out it would update the case, but the lookup from Live Chat Transcripts to Cases is not exposing the case for updating within Process Builder.

I know a trigger would be best here, but I'd like to know if it's possible to kick off a flow from Process Builder that can handle doing this field update and any pointers to building it out.

Thanks in advance!

2 Answers 2

1

As crmprogdev mentioned, you'll want to go the Visual Flow route (Triggered/Called by Process Builder). I'll provide a bit more detail on the how-to (based just on what you've said).

You're referring to an issue that happens when the fields typically aren't yet set and the Process Builder is trying to fire. The best way is for us to fire the Flow from the Process Builder and then do everything in our Flow.

You're going to be able to accomplish this with most likely just two elements in your Flow. One to lookup the Transcript record and the other to update your Case.

First things first: Create two variables

1 - var_TranscriptId [text - set to Input/Output]

2 - var_CaseId [text]

First Element: Record Lookup

Set the Object to be your Transcript. Criteria is Id = var_TranscriptId (passed in from Process Builder). In your setting values, set the Case lookup to the var_CaseId variable.

Second Element: Record Update

Set the Object to be Case. Criteria is Id = var_CaseId. In your fields to update, grab the Time-Out checkbox and then type in 'false' into the right box and you'll see the flow variable for an unchecked boolean that you can use... and just select that.

Connect the two elements, set the first as your starting element. Go to your Process Builder, keep the same criteria you had, and now instead of an update fire your Flow and pass in the TranscriptId value into the Flow.

You can also check out my site www.salesforcesidekick.com for some how-to and examples on Flow.

1

Depending on where you need this to execute, you may be in a bit of a catch-22 here. If you can flag these separately before your time-based email workflow gets called, what I have in mind should do the trick. One of the things you can do from Process Builder is execute a Visual Flow. That's the equivalent of what used to be called a Flow Trigger. See The Power of Flow: Advanced Workflow Techniques for more on these. They've since been deprecated, but the concept is still the same; flows that run without the need of a visualforce page or any kind of user interaction.

I strongly suspect that executing a visual flow would allow you to run the logic you need to do the look-up. What I'm not certain of is whether it would then allow you to do the time-based workflow. If you can execute it in a different context, you could definitely do both. In the same execution context, some things can be chained, but I've not done any Process Builder stuff of late to know if after executing the flow, you'd be able to fire time-based events or not. I don't think you can run them from flows any longer in their current implementation, but I could be mistaken on that part. If you can either separate the two events or chain them, you'll be all set.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .