Programmatic Languages35% of the exam
SSJS error handling, WSProxy and Script Activities
When a Script activity succeeds or fails, how try/catch and logging data extensions keep it running, why WSProxy beats the Core SOAP wrappers and never throws on its own, and how timeouts, memory, batching and HTTP caching shape scripts that scale.
Implement standard development best practices using Marketing Cloud programming languages.
~7 min read · 12 practice questions ·
What the exam expects
- Predict whether a Script activity completes or fails when code raises, catches or times out.
- Log handled errors to a data extension and surface WSProxy errors that don't throw.
- Choose WSProxy over Core library SOAP methods, and know where WSProxy can run.
- Keep large jobs inside memory and time limits with batching, paging and a different tool when needed.
- Keep external calls fast and safe: cache-friendly URLs, standard ports and guarded JSON parsing in email.
- Key terms: Script activity (an Automation Studio activity that runs SSJS); unhandled exception (an error no catch block handles); WSProxy (the native SSJS object for SOAP API calls); non-send context (code that doesn't run while a message renders, such as a Script activity or CloudPage); HasMoreRows (the retrieve flag that says another page exists).
Key facts
Script activity success
- Detail
- Completes unless an unhandled exception or timeout
Caught errors
- Detail
- Don't fail the activity
WSProxy errors
- Detail
- Returned in Status; use
ErrorUtil.ThrowWSProxyError()to throw
Memory ceiling
- Detail
- More than 6GB fails the activity
Timeout
- Detail
- 30 minutes; rethink scripts over 10 minutes
WSProxy availability
- Detail
- All non-send contexts
More pages
- Detail
HasMoreRowstrue; page withgetNextBatch()
Rows.Update() no match
- Detail
- Returns an error
Validate Syntax
- Detail
- Checks syntax only, not a successful run
HttpGet() caching
- Detail
- One call per unique URL in a send
Sources for this section (8)
- Validate SSJS using WSProxydeveloper.salesforce.com (opens in a new tab)
- Server-Side JavaScriptdeveloper.salesforce.com (opens in a new tab)
- Script Activityhelp.salesforce.com (opens in a new tab)
- Use SSJS via WSProxydeveloper.salesforce.com (opens in a new tab)
- Advanced Retrieves via WSProxydeveloper.salesforce.com (opens in a new tab)
- Rows.Updatedeveloper.salesforce.com (opens in a new tab)
- Create a Script Activityhelp.salesforce.com (opens in a new tab)
- HttpGet()developer.salesforce.com (opens in a new tab)
- Why doesn't a passing Validate Syntax check prove a Script activity will succeed?
- When does HttpGet() skip the email for a subscriber?
- What does Rows.Remove() return?
- Which WSProxy retrieve parameter carries RetrieveOptions such as BatchSize?
- Why should a logging data extension have a data retention policy?
The questions are free to read. Answers with their sources and self-grading are included with the pack.
Keep reading with the Marketing Cloud Engagement Developer pack
- Core concepts
- Exam traps
- Worked scenario
The pack includes:
- All 25 lessons of the Marketing Cloud Engagement Developer guide, with reading progress
- Interactive decision walks and step-by-step sequence steppers
- Practice exams purchase adds inline bank questions and topic practice (12 questions for this lesson)
- An official source cited for every claim
- An AI tutor that answers from the guide
- Choose guide-only, practice-only, or save $4 with both