Variable paths
Dynamic content blocks support two data sources, each with its own variable path.Automation event data
When your block is linked to an automation event plugin, event data is accessed through theautomation namespace:
app_identifier— Your app’s unique identifier, assigned in the Kit App Store.event_node_identifier— Theidentifierof the linked automation event plugin element (the event node chosen viarelated_plugin_id), not the dynamic content block plugin’s ownidentifier.field_name— A key from the event data stored for that subscriber (typically aligned with the fields your polling integration puts in each event’scontext).
yourapp and the linked event node’s identifier is abandoned_checkout, you’d access the checkout URL like this:
Subscriber custom fields
Subscriber custom fields are accessible directly via thesubscriber namespace, regardless of whether the block uses an event node:
company:
In the email editor preview for a dynamic content block, Kit renders Liquid using preview context built from
default_values and (when linked) the automation namespace—not the full send-time Liquid environment. In particular, subscriber is not injected on that preview path, so {{ subscriber.* }} may render empty in the editor even though it works at send time. Always verify behavior in a sent test email when mixing subscriber and automation variables.Writing your template
Guard the entire block
Always wrap your content in a top-level conditional. This ensures the block renders gracefully if the automation data isn’t present—for example, if the email is sent outside the expected workflow:Iterate over arrays
Use Liquid’sfor tag to loop over arrays. The limit filter caps the number of items rendered. Always cap loops in email templates to avoid unexpectedly long emails:
Conditionally show fields
Use{% if %} to guard optional fields. Subscribers may have different data states, so don’t assume every field is always populated:
Show overflow counts
When you limit the number of items shown, you can tell subscribers how many more they have:Available Liquid filters
Kit’s email rendering uses Liquid with a supported subset of filters (similar to common Liquid, but not identical to every filter documented for other Liquid hosts). Prefer filters you have verified in a sent test email or editor preview. Commonly useful ones in dynamic content blocks:Liquid in button URLs
Creators can reference the sameautomation.* Liquid variables in regular email button URLs—not just inside dynamic content blocks—on automation sequence emails. For example, a creator can set a button’s URL to {{ automation.yourapp.abandoned_checkout.checkout_url }} and Kit will render the per-subscriber URL at send time.
This means a dynamic block isn’t the only place your event context becomes useful. Buttons, links, and plain-text body Liquid in automation sequence emails all read from the same automation.* namespace your event plugin populates.
Context size limits
To protect the send pipeline, Kit applies the following limits to per-subscriber automation context:
Events that exceed 64 KB on their own are dropped before storage; merges that would push a subscriber’s row over the limit are skipped. Other subscribers in the same batch continue to progress through the VA, and the existing context on the row is preserved. Drops are logged but do not surface to the creator.
Design your
context payloads accordingly: prefer pre-trimmed lists (e.g. top 5 items), compact field names, and pre-formatted display strings over raw nested objects.
Preview vs. send time
Your template is rendered twice:- At design time (editor preview) — Kit renders your template using
default_valuesmerged into theautomationnamespace when an event node is linked (see plugin configuration). Preview does not mirror the full send-time Liquid drop (for example,subscriberis not available on this preview path). - At send time — Kit renders the same stored template with real per-recipient data, including automation context from Visual Automations (when applicable) and the normal
subscriberLiquid drop for subscriber fields.
default_values produce HTML that looks close to what real data would render—creators use this preview to judge how the block will look—and validate anything that depends on subscriber in a sent email, not only in the editor.
Email compatibility
The same security and compatibility rules that apply to standard content blocks also apply to your rendered Liquid template output. Kit sanitizes the final HTML before delivery. Avoid these in your template:- Scripts and iframes
- Audio and video elements
- Form, input, or command elements
- External CSS stylesheets and CSS
url()values
- Use inline
styleattributes instead of CSS classes—email clients strip external stylesheets - Use table-based layouts (
<table>,<tr>,<td>) for reliable rendering across email clients - Keep your maximum width at 600px
- Include
target="_blank"on all links - Use absolute URLs for all images and links
- Guard image fields with
{% if %}so missing images don’t produce broken<img>tags