module function · N/redirect

toSuitelet()

redirect.toSuitelet(options)

Redirects to a Suitelet.

Implementation
Implemented in the compiler, not yet published
Design
Accepted redirect Suitelet(script, deployment)
Proposals
A
Signature
redirect.toSuitelet(options)
Returns
void
Governance
None
Script types
Suitelets, beforeLoad user events, and synchronous afterSubmit user events
Version
SuiteScript 2.x, documented for 2.1; since NetSuite 2015.2
call shapefrom Oracle's parameter table
1redirect.toSuitelet({2    scriptId:     /* string, required */,3    deploymentId: /* string, required */,4    isExternal:   /* boolean, optional */,5    parameters:   /* Object, optional */6});
Oracle reference for this method
ParameterTypeRequiredDescription
options.scriptIdstringrequiredThe script ID for the Suitelet.
options.deploymentIdstringrequiredThe deployment ID for the Suitelet.
options.isExternalbooleanoptionalThe default value is false - indicates an external Suitelet URL.
options.parametersObjectoptionalContains additional URL parameters as key-value pairs. Note: Parameters cannot be arrays. Use JSON.stringify/JSON.parse instead to handle arrays.
B

Supported syntax · compiles today

myntredirect Suitelet(script, deployment)
redirect Suitelet("customscript_customer_portal", "customdeploy_customer_portal")
suitescriptoutput, trimmed
1redirect.toSuitelet({2    scriptId: "customscript_customer_portal",3    deploymentId: "customdeploy_customer_portal"4});

Internal Suitelets only, with no URL parameters yet. Only in afterSubmit, like every redirect. In the compiler, not yet published: npm 0.1.0 does not have it. Verified with mynt build on 13 Oct 2026.

C

Competing syntax for toSuitelet, from GitHub Discussions. Select two or more to compare them side by side, with the syntax Mynt supports today as a baseline.

All discussions
Mynt todayredirect Suitelet("customscript_customer_portal", "customdeploy_customer_portal")

Loading proposals from GitHub…

D

Write the Mynt you wish you could write.

A good proposal shows the syntax, the SuiteScript it should become, and argues for it: why it is clearer, how it fits the rest of the language, what it makes harder.

  • Clarity. Does it say what happens, without ceremony?
  • Consistency. Does it read like load, save and Ref[field]?
  • Expressiveness. Does it cover the cases people actually write?
  • Honesty. Does it hide a NetSuite cost, such as governance, that a reader should see?

N/redirect · redirect.toSuitelet(options)

Suggest syntax for toSuitelet