Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,15 @@ updates:
versions:
- "25.x"
- "26.x"
- package-ecosystem: "npm"
directory: "ai/slackbot-mcp-client/rich-responses/block-kit"
schedule:
interval: "daily"
ignore:
- dependency-name: "@types/node"
versions:
- "25.x"
- "26.x"
- package-ecosystem: "npm"
directory: "ai/slackbot-mcp-client/rich-responses/mcp-apps"
schedule:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ jobs:
matrix:
showcase:
- "ai/slackbot-mcp-client/no-auth"
- "ai/slackbot-mcp-client/rich-responses/block-kit"
- "ai/slackbot-mcp-client/rich-responses/mcp-apps"
- "ai/slackbot-mcp-client/slack-identity"
- "block-kit"
Expand Down
1 change: 1 addition & 0 deletions ai/slackbot-mcp-client/rich-responses/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@ Read the [docs](https://docs.slack.dev/ai/slackbot-mcp-client/returning-rich-res

## Included examples

- **[Block Kit](https://docs.slack.dev/ai/slackbot-mcp-client/returning-rich-responses#block-kit)**: Return native [Block Kit](https://docs.slack.dev/block-kit/) components in MCP tool responses. [Implementation](./block-kit/).
- **[MCP Apps](https://docs.slack.dev/ai/slackbot-mcp-client/returning-rich-responses#mcp-apps)**: Run an MCP server for the Slackbot MCP client that responds with an [interactive UI](https://modelcontextprotocol.io/extensions/apps/overview). [Implementation](./mcp-apps/).
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
SLACK_CLIENT_ID=
SLACK_CLIENT_SECRET=
SLACK_SIGNING_SECRET=
SLACK_STATE_SECRET=
BASE_URL=https://1234-56-78-90-0.ngrok-free.app
4 changes: 4 additions & 0 deletions ai/slackbot-mcp-client/rich-responses/block-kit/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
node_modules
.env*
!.env.example
installations
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
apps.dev.json
cache/
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"manifest": {
"source": "local"
},
"project_id": "00000000-0000-0000-0000-000000000000"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"hooks": {
"get-hooks": "npx -q --no-install -p @slack/cli-hooks slack-cli-get-hooks"
}
}
20 changes: 20 additions & 0 deletions ai/slackbot-mcp-client/rich-responses/block-kit/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Block Kit

Return native [Block Kit](https://docs.slack.dev/block-kit/) UI components from an MCP server tool response.

This example extends the [Slack identity](../../slack-identity/) example by adding `_meta.slack.blocks` to the tool response, rendering a profile card using the `card` block type.

Read the [docs](https://docs.slack.dev/ai/slackbot-mcp-client/returning-rich-responses#block-kit) to learn more about Block Kit responses from MCP servers.

## Setup

1. Copy `.env.example` to `.env` and fill in your Slack app credentials
2. Install dependencies: `npm install`
3. Start the server: `npm start`
4. Expose via ngrok and update `manifest.json` with your URL

## Testing

```sh
npm test
```
12 changes: 12 additions & 0 deletions ai/slackbot-mcp-client/rich-responses/block-kit/app.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { app } from "./src/app.js";

const port = Number.parseInt(process.env.PORT || "3000", 10);

(async () => {
try {
await app.start(port);
app.logger.info("⚡️ Bolt app is running!");
} catch (error) {
app.logger.error("Failed to start the app", error);
}
})();
34 changes: 34 additions & 0 deletions ai/slackbot-mcp-client/rich-responses/block-kit/biome.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"$schema": "./node_modules/@biomejs/biome/configuration_schema.json",
"vcs": {
"enabled": true,
"clientKind": "git",
"useIgnoreFile": true
},
"files": {
"ignoreUnknown": false
},
"formatter": {
"enabled": true,
"indentStyle": "space"
},
"linter": {
"enabled": true,
"rules": {
"recommended": true
}
},
"javascript": {
"formatter": {
"quoteStyle": "double"
}
},
"assist": {
"enabled": true,
"actions": {
"source": {
"organizeImports": "on"
}
}
}
}
28 changes: 28 additions & 0 deletions ai/slackbot-mcp-client/rich-responses/block-kit/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"display_information": {
"name": "MCP Client - Block Kit",
"description": "Connects app MCP server to Slackbot MCP client that responds with Block Kit"
},
"features": {
"bot_user": {
"display_name": "MCP Client - Block Kit",
"always_online": true
}
},
"oauth_config": {
"scopes": {
"bot": ["mcp:connect", "users:read", "users:read.email"]
}
},
"settings": {
"org_deploy_enabled": true,
"socket_mode_enabled": false,
"token_rotation_enabled": false
},
"mcp_servers": {
"Profile Card": {
"url": "https://1234-56-78-90-0.ngrok-free.app/mcp",
"auth_type": "slack_identity_auth"
}
}
}
Loading