RE: How would I make a WorkflowActionScript that can send a POST message?

Hi there everyone, first time posting and first time working with Netsuite.

I’ve been trying to figure out how to build some WorkflowActionScript where on this step in the workflow, it would send the “ScriptContext” to another application.

I’ve got a script deployed like that looks like this…

 * @NApiVersion 2.0
 * @NScriptType WorkflowActionScript
 * @NModuleScope public
define(["N/https", "N/log"], function (https, log) {
    function onAction(scriptContext) {
        url: "",
        body: JSON.stringify(scriptContext),
    return {
      onAction: onAction,

But it doesn’t seem to be working. Using Postman, I can POST a message to my endpoint and receive it. It seems like when the source is Netsuite, it won’t work and I’m not sure what I’ve done that isn’t working.

sunshineinabag Rookie Asked on November 23, 2021 in SuiteScript.
Add Comment
2 Answers

Looks like I found an alternative way to get data back out of Netsuite via a saved search RESTlet.

With my own integration, I can set up a polling server to get the results of the saved search and act on that.

Rookie Answered on November 26, 2021.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.