Skip to content

Instantly share code, notes, and snippets.

@eonist
Created August 20, 2025 15:59
Show Gist options
  • Save eonist/43cb25e430cfc9e16df3e1d67761ea58 to your computer and use it in GitHub Desktop.
Save eonist/43cb25e430cfc9e16df3e1d67761ea58 to your computer and use it in GitHub Desktop.
block kit.md

Yes, the Slack Bot API offers extensive UI elements beyond text through a framework called Block Kit, which provides rich formatting and interactive components for creating sophisticated user interfaces within Slack messages.[2]

Block Kit Framework

Block Kit is Slack's UI framework that allows you to build complete workflows right inside Slack that work seamlessly across desktop and mobile devices without additional code or configuration. You build messages from individual or groups of pre-defined blocks including text, thumbnail images, dividers, and interactive elements like buttons, dropdown menus, and date pickers.[2]

Available UI Elements

Visual Components:

  • Text sections with markdown formatting support
  • Thumbnail images and static images[2]
  • Dividers for visual separation[2]
  • Header blocks for titles and section headers[3]

Interactive Components:

  • Buttons (with different styles like primary, danger)[3]
  • Dropdown menus and select lists[2]
  • Multi-select menus[5]
  • Date pickers[2]
  • Plain-text inputs (single or multi-line)[5]
  • Checkboxes and radio buttons

Advanced Features

Modals: You can create modal dialogs that capture and maintain focus until the user submits or dismisses them. Modals can contain input blocks with plain-text inputs, select menus, or multi-select menus, making them powerful for complex user interactions.[5]

Actions Blocks: These allow you to group multiple interactive elements together, such as approval/rejection buttons for workflow processes.[3]

Implementation

Block Kit UIs are defined as JSON structures. Slack provides a Block Kit Builder tool for visually creating sample messages that automatically generate the corresponding JSON. When users interact with these components, Slack sends interaction payloads to your configured Request URL via HTTP POST.[3][2]

The interactive components transform your Slack app from simple information relays into powerful workflow partners that can manipulate, update, and send data back to external services based on user actions.[3]

1 2 3 4 5 6 7 8 9 10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment