Skip to main content
Data bindings populate a modal’s placeholders from the original message data. Configure them on the Open Modal action, after selecting an active modal. They do not fetch fresh data from your API when the button is clicked.

Bind a value

Suppose the message was sent with:
Create a modal placeholder named request_title, for example in the title of a Section. Bind it to request.title. In API configuration, the binding is:
A single reference preserves the source value’s type. A composed expression such as Request {{request.id}}: {{request.title}} produces text. This is string interpolation, not arbitrary computation; precompute currency, dates, totals, and custom logic upstream.

Name placeholders for the modal, not the message

A modal can be opened from buttons on any number of templates, and each button binds its own message data to the modal’s placeholders. Name placeholders for what the modal needs, so every template can supply them:
  • Bind top-level names. A binding supplies a whole name: bind ticket to request and the modal can read {{ticket.title}} and {{ticket.id}}. A binding to a dotted name such as ticket.title never reaches the modal.
  • user and team come from Slack. Every button supplies the clicking user and the workspace, so {{user.name}} needs no binding.
  • Avoid reading the message directly. A modal can also read the sending message’s data, the clicked card (rowData, this) and button without a binding. That only works for templates and buttons shaped that way; opened from another template, the placeholder shows unresolved. Bind a named placeholder instead.
In the modal builder, Preview with lists every button that opens the modal and shows which placeholders each one binds.

Map array properties

To bind people into a modal array named reviewers with different field names:
The resulting items contain label and email. Use them in modal content that accepts an array, such as a modal each directive. This mapping does not automatically add dropdown options unless the modal is configured to use that data.

Verify types and missing data

A missing source can leave its expression unresolved. Do not rely on is_required alone as a runtime fallback. Validate a complete sample, a missing optional field, and an empty array, then open the actual modal in Slack. Changing a template’s sample data does not change data stored with an already-sent message. Send a new test message after changing the binding source. Handle submission values.