
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-12-2019 04:38 AM
I want to trigger a flow designer based on the conversation with virtual agent
Solved! Go to Solution.
- Labels:
-
Predictive Intelligence

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-12-2019 05:33 AM
Flow Designer (as of pre-Madrid) is triggered in two main ways. First with a record update/insert, the other on a scheduled basis.
If you want, have VA create/update a record that triggers the flow.
In Madrid, we offer an API to start a flow or action via a script API.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-17-2020 04:43 PM
thanks we are just trying to follow best practice since we are about to do some automated VA conversations with external systems.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-07-2020 08:25 AM
hi chuck,
can you give an example script which triggers subflow or flow from the virtual agent script action?
for example I have subflow named as reset password how can I can call that from virtual agent Script Action.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-07-2020 02:51 PM
Within Flow Designer, on your Flow or Subflow, use the Code Snippets in the upper right menu.
From there, copy and paste the script where needed (eg. VA script). Mine looks like this:
(function() {
try {
var inputs = {};
inputs['current'] = ; // GlideRecord of table:
inputs['changed_fields'] = ; // Array.Object
inputs['table_name'] = 'x_66238_cls323_employee';
// Start Asynchronously: Uncomment to run in background.
// sn_fd.FlowAPI.startFlow('x_66238_cls323.employee_trigger_test', inputs);
// Execute Synchronously: Run in foreground.
sn_fd.FlowAPI.executeFlow('x_66238_cls323.employee_trigger_test', inputs);
} catch (ex) {
var message = ex.getMessage();
gs.error(message);
}
})();