erictgrubaugh
03/26/2018, 6:21 PMthrow your own SuiteScript Error using either nlapiCreateError or N/error.create, make sure your call is configured to send the appropriate notification email, then just catch it yourself and write whatever you want to the response.