Runtime verified Test scripts included

Builds an object from key=value pairs. Used only as a subexpression within other helpers.

Syntax

(hash ...pairs)

Returns object.

Parameters

Name Type Required Description
pairs any Yes, repeatable Key-value pairs, e.g. name=”Alice” age=30.

Example

Tested in a Marketing Cloud Next email on 2026-11-22:

  • {{get (hash name="Alice" age=30) "name"}} renders Alice, as documented.
  • {{hash name="Alice" age=30}} renders {name=Alice, age=30}, as documented.
Show Next test script
<!-- Marketing Cloud Next test script for the hash helper. Paste it into the HTML component of a
     Next email and open the preview. Each line prints the result Next gave when the call
     was rendered on its own (expect) next to the result of this run (got).
     Assembled from single-call test emails (dates on the page); it has not been
     run as one email. Calls that make Next fail are listed separately. -->
<p>c1 expect=[Alice] got=[{{get (hash name="Alice" age=30) "name"}}]</p>
<p>c2 expect=[{name=Alice, age=30}] got=[{{hash name="Alice" age=30}}]</p>

Marketing Cloud Next

Works as documented

Every tested call rendered the documented result. Tested 2026-11-22 by rendering in a Marketing Cloud Next email.

See also