Platform Functions
The Platform.Function.* API — Data Extension CRUD, dates, HTTP helpers, SOAP wrappers, and content helpers. Most calls do not require Platform.Load.
Verification pending
Differs from official docs
Most methods here are invoked as Platform.Function.MethodName(...).
Data Extensions
Read and write rows in SFMC Data Extensions.
Lookup
Get a single field value from a DE row matching filter criteria. Keeps the column's native type.
→ string|number|boolean|Date|null
LookupRows
Get multiple rows from a DE matching filter criteria. Yields null — not an empty array — on no match.
→ object[]|null
LookupOrderedRows
Get sorted rows with a max count and filter. Yields null — not an empty array — on no match.
→ object[]|null
InsertData
Add a new row to a Data Extension.
→ number
UpdateData
Modify existing rows matching filter criteria.
→ number
UpsertData
Insert or update a row based on filter match.
→ number
DeleteData
Remove rows matching filter criteria.
→ number
InsertDE
Same insert as InsertData, but returns null.
→ null
UpdateDE
Same update as UpdateData, but returns null.
→ null
UpsertDE
Same upsert as UpsertData, but returns null.
→ null
DeleteDE
Same delete as DeleteData, but returns null.
→ null
Dates
Now
Current SFMC server date and time.
→ Date
SystemDateToLocalDate
Convert system date to subscriber local timezone (send contexts).
→ Date
LocalDateToSystemDate
Convert a local date value to the SFMC system date.
→ Date
URLs, redirects, and browser detection
UrlEncode
Percent-encode a complete URL (optional reserved-character mode).
→ string
RedirectTo
Email href helper for attribute-driven redirect URLs (AMPscript/WS-FUEL).
→ string
IsCHTMLBrowser
Detect HTML vs text email clients.
→ boolean
Logic and parsing
ParseJSON
Parse a JSON string to a JavaScript object.
→ object
GUID
Generate a new globally unique identifier string.
→ string
IsEmailAddress
Validate a string as an email address format.
→ boolean
IsPhoneNumber
Evaluate whether a string is a valid phone number.
→ boolean
RaiseError
Stop execution and raise an error with optional skip-send.
→ void
SOAP API helpers
Low-level SOAP API wrappers. For most SOAP operations, prefer WSProxy instead.
CreateObject
Instantiate a Marketing Cloud SOAP API object.
→ object
SetObjectProperty
Set a property on a SOAP API object.
→ null
AddObjectArrayItem
Append an item to a SOAP API object array property.
→ void
InvokeCreate
Execute a SOAP Create call.
→ string
InvokeRetrieve
Execute a SOAP Retrieve call. Yields null both on error and on no match — read the status array to tell them apart.
→ object[]|null
InvokeUpdate
Execute a SOAP Update call.
→ string
InvokeDelete
Execute a SOAP Delete call.
→ string
InvokePerform
Execute a SOAP Perform action.
→ string
InvokeConfigure
Execute a SOAP Configure call.
→ string
InvokeExecute
Execute a SOAP Execute call.
→ object[]
InvokeExtract
Execute a SOAP Extract call.
→ string
InvokeSchedule
Execute a SOAP Schedule call.
→ string
HTTP
Simple HTTP functions — for full REST control see Script.Util.HttpRequest.
HTTPGet
Perform an HTTP GET request.
→ string
HTTPPost
Perform an HTTP POST with content type and payload. Yields the HTTP status code, not the body.
→ number
Output helpers
Page output is produced by the Core Write() global or by Platform.Response.Write(). Platform.Function.Stringify does exist and is documented alongside its bare-name Core form under Stringify.
Content
ContentBlockByKey
Render a Content Builder asset by customer key.
→ string
ContentBlockByName
Render a Content Builder asset by folder path and name.
→ string
ContentBlockByID
Render a Content Builder asset by numeric ID.
→ string
ContentImageByKey
Output an img tag for a Content Builder image by key.
→ string
ContentImageByID
Output an img tag for a Content Builder image by ID.
→ string
BeginImpressionRegion
Start a named impression tracking region.
→ void
EndImpressionRegion
End an impression region.
→ null
TreatAsContent
Evaluate AMPscript/HTML server-side. Security: never pass unvalidated user input.
→ string
ContentArea (deprecated)
Retrieve a classic Content Area by numeric ID. No longer supported.
→ string
ContentAreaByName (deprecated)
Retrieve a classic Content Area by name. No longer supported.
→ string