This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Calling Scripts via Application Server RESTful API using Common_StartScripts permission not working

Hi,

We are trying to call a custom script via the Application Server RESTful API. 

We have made sure that the user who does this has an application role assigned which has the permission group Common_StartScripts. 
This application role also has the permissions groups Common_TriggerEvents and Common_StartCustomizerMethods, and the user can successfully call both events and methods directly via the API. 

When we call the custom script the following error is shown: 

(part of the returned json)

"number": 810323,
      "message": "You are not authorized to run this method.”

 

We believe the error could be due to the reason that the custom scripts within its code calls the FillOrder method. This is perhaps an issue as this method can only be executed via job server. Perhaps via the API when this script is called it presents this error before even running it? 
Currently we can call the custom script via a process chain which is tied to an Event, and  this event is then called via the API.

Is the above assumption correct or are we missing something?

Any help its greatly appreciated as usual.

Kind regards,

Ash

Parents
  • Thanks for the response again Markus
    We will from now on create a normal PersonWantsOrg object and not use the FillOrder method. Previously we thought without using FillOrder an approval would not be triggered.

    The last point of setting IsServiceAccount = 1 would not work for our use case as the person who initially authenticates with the Application server is of Employee type and not System user. But this information is useful nonetheless for future reference.

    Thanks again.
    Ash
Reply
  • Thanks for the response again Markus
    We will from now on create a normal PersonWantsOrg object and not use the FillOrder method. Previously we thought without using FillOrder an approval would not be triggered.

    The last point of setting IsServiceAccount = 1 would not work for our use case as the person who initially authenticates with the Application server is of Employee type and not System user. But this information is useful nonetheless for future reference.

    Thanks again.
    Ash
Children
No Data