GlideFlow not working in catalog client script

nav sid
Tera Contributor

I have a flow action created in a scoped application with ACL defined for snc_external and sn_customerservice.consumer roles. I trigger the flow action from a catalog client script using the GlideFlow API.

It gets triggered for internal users but not for the consumers or contacts i.e. users with snc_external role.

Is there something I am missing.

ACL>

navsid_0-1692979200248.png

Action Security>

navsid_1-1692979415243.png

 

3 REPLIES 3

Maik Skoddow
Tera Patron
Tera Patron

Hi @nav sid 

many information are missing here. You say "It gets triggered for internal users but not for the consumers or contacts i.e. users with snc_external role." but how exactly do you recognize that? Are there any error messages in UI or in the syslog? And enabling the flow execution for external users is not enough. Also, all the data the Flow is dealing with need ACL adjustments to expose them to external users.

Maik

nav sid
Tera Contributor

@Maik Skoddow 

I am checking the executions - when I impersonate a user with internal roles (example snc_customerservice_agent role) the action is executed and it return desired results.

When I impersonate a user with roles (snc_customerservice.consumer or customer role) there is no execution records.

- Below is the Catalog client script to call the action - 

 

Note - I am using the client code snippet from flow designer

----------------------------------
function onChange(control, oldValue, newValue, isLoading) {
    if (isLoading || newValue == '') {
        return;
    }
 
    //Type appropriate comment here, and begin script below
    var inputs = {};
    inputs['variable1'] = newValue; // String 
 
    GlideFlow.startAction('action_internal_name', inputs)
        .then(function(execution) {
            return execution.awaitCompletion();
        }, errorResolver)
        .then(function(completion) {
 
            var status = completion.status;
 
            // Available Outputs:
            var outputs = completion.outputs;
            var outputvariable1 = outputs['output1']; // String
            var outputvariable2= outputs['output2']; // String
            var outputvariable3 = outputs['output3']; // String
 
            g_form.setValue('variable1', outputvariable1);
            g_form.setValue('variable2', outputvariable2);
            g_form.setValue('variable3', outputvariable3 );
 
        });
 
    function errorResolver(error) {
        // Handle errors in error resolver
    }
}

 

If I call the same action via GlideAjax it works fine for both internal users and external users.

Re: the ACLs for data, the action is calling an external API which returns a JSON payload and generates the outputs. 

 

nav sid
Tera Contributor

@Maik Skoddow Did you get a chance to go through my reply? Is the information provided helps?