Skip to main content
Learn how to create a simple Slack message template with dynamic data and send it to your workspace.

Watch the demo

Prerequisites

  • Slack workspace connected (see Connecting Slack)
  • Permission to create and save templates in your LithoBlocks organization
  • A test channel or your own Slack user ID
1

Create a new template

  1. Navigate to Templates in the sidebar
  2. Click Create Template
  3. Enter a name: Welcome Message
  4. Click Create Template creation dialog
You’ll be taken to the Template Builder.
2

Add your first block

  1. In the Block Toolbox above the canvas, find the Header block
  2. Click it to add it to your template
  3. In the text field, type: Welcome to the Team! Header block added
3

Add dynamic content with placeholders

  1. Click Section in the Block Toolbox
  2. In the text area, type:
The {{user.name}} and {{user.role}} are placeholders — they’re replaced with actual data when you send the message.Section block with placeholders
4

Add sample data for preview

  1. Click the Sample Data tab in the right panel
  2. Switch to JSON editor
  3. Add this sample data:
  1. Click back to the Preview tab Preview showing rendered message
You should see your placeholders replaced with the sample data.
Preview frequently to check how your message looks before sending.
5

Add a link button

  1. Add an Actions block.
  2. Set the button label to Open handbook and its action ID to open_handbook.
  3. Set its URL to your team’s handbook (use https://example.com for this test).
  4. Preview the button. No webhook is required for a link.
6

Save and send

  1. Click Save in the top right
  2. Click Send to Slack
  3. Select a channel or user
  4. The template is compiled with your sample data and sent
  5. Check your Slack workspace for the message and click Open handbook to verify the URL. Message in Slack

What you’ve built

You now have a template with:
  • Static content (header)
  • Dynamic placeholders (user name and role)
  • A link button that opens your handbook
  • Sample data for testing

Next steps

Using placeholders

Learn advanced placeholder syntax for nested objects and arrays.

Block types

Explore all available block types.

Interactive buttons

Make buttons trigger webhooks or open modals.

Button webhooks

Connect buttons to external systems.

Common issues

Make sure you have sample data in the Sample Data tab that matches your placeholder structure.
Read the validation error and check the affected block. Missing text values remain visible as placeholders; they do not by themselves fail compilation. A directive whose source is not an array can fail.
Verify the Actions block is saved and the template compiled without errors.