I'll echo the idea that you don't really want to be using the /api/atelier web app this way because of the %Development requirement and the arbitrary SQL execution, and because it includes a lot of other functionality that you probably don't want people to have access to.
BUT if you're really intent on using that API, then you could make your own web application in the management portal that uses the same dispatch class that /api/atelier does and create a new resource to be the required resource to access it. Make sure your users have permission to use that resource, and then assign the appropriate table and view permissions in a role that you either give to those users or assign to the Web Application as an application role.
Are you looking for something like:
ClassMethod ExceptionTest() [ Language = python ]
{
import sys
import iris
import traceback
try:
print(1/0)
except ZeroDivisionError as e:
errobj=iris.cls("%Exception.General")._New(str(e),42)
stack_trace_list = traceback.format_tb(e.__traceback__)
if stack_trace_list:
last_instruction_line = stack_trace_list[-1].strip()
errobj.Location = last_instruction_line
a = errobj.Log()
}
Which gives:
.png)








All we can tell from this is that in the class gen.Custom.HS.Model.OEOrdItem.TabularTextResultsEMR, you have a method called GetData, and on line 872 of the .1 file for that class, you have a variable named rs that is undefined.