A JSSP is a JavaScript Server Page generated by Adobe Campaign that mixes static markup with <% %> JavaScript blocks. It runs on every request (no publication, no cache) which makes it the tool for dynamic pages and custom JSON APIs.
The page name sets the URL: my_nms:my-page.jssp is served at https://xxx.campaign.adobe.com/my_nms/my-page.jssp.
Choosing a web level
But a JSSP is the low level, before writing one, Adobe Campaign gives you 2 modes before you write any page: the Web App for simple web pages, and the SOAP router for server APIs. A JSSP is the low level you use when either one canβt express what you need. Pick the highest level that fits:
| Β | Simple (low code) | Complex (code) |
|---|---|---|
| Web page | Web App. Best for: Subscription pages | JSSP. Best for: Performances, custom HTML |
| API | SOAP router. Best for: XML-only APIs | JSSP. Best for: Custom permissions, JSON APIs |
Hereβs the request-processing pipeline for each level:
request ββΆ VALIDATE βΆ AUTHENTICATE βΆ ROUTE βΆ EXECUTE ββΆ response
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Web App βΆ @endDate checkAuthentication page Transition page JS page template
(nms:webApp) (NL.JSSPContext) (UI.Controller)
SOAP βΆ XML envelope sessiontoken SOAPAction xtk:javascript serialize XML
well-formed (SOAP fault on error)
JSSP βΆ β β β JSSP code setContentType + write
βββββββββββββ all yours: parsing, permissions, error handling βββββββββββββ
The managed levels run the whole chain and call your code last; a JSSP drops you in at stage one with an empty chain - the Inversion of Control trade-off behind the matrix.
Like raw SQL in the Database levels, a JSSP is only as safe as the code you put in it: it runs on every request and, once escalated with π logonEscalation, with an operatorβs rights. Stay on the managed levels until you actually need to drop down.
Reference
-
π requestβ read parameters, body, headers, client IP -
π responseβ headers, cookies, redirects -
π setContentTypeβ set theContent-Type, always first -
π writeβ emit the response body -
π logonEscalationβ gain database access (runs Anonymous by default)
Going further
For a full, screenshot-led walkthrough, see the JSSP tutorial. This page is the API reference.