All templates
FeaturedIntegration#Slack#Postgres#MCP#Agent#Database

Slack + Postgres MCP Answer Agent

Answer Slack channel questions by letting an Agent query Postgres through MCP, then post the answer back to Slack.

Workflow at a glance

The full canvas, before you import it

Click any node to see its config.

#Slack#Postgres#MCP#Agent#Database

Click a node to select it — same as the Heym editor; the panel shows its settings.

6 nodes · Free & source-available

Slack + Postgres MCP Answer Agent

Turn a Slack channel into a database-aware assistant. A Slack Trigger receives the question, an Agent uses a configured Postgres MCP server to inspect approved tables and produce a concise answer, then a Slack node posts the response back to the channel.

What this workflow does

  1. Slack Trigger listens for new channel messages
  2. AnswerFromPostgres (Agent) receives the Slack text and has a Postgres MCP connection available as tools
  3. The Agent queries Postgres only through MCP, summarizes the result, and avoids inventing missing data
  4. SendChannelAnswer posts the final answer back to the same Slack channel
  5. AnswerLog returns the Slack send status for debugging

Use cases

  • Internal support questions backed by product or CRM tables
  • Ops questions such as "Which invoices are overdue?"
  • Lightweight BI answers inside Slack without giving everyone database credentials

MCP and Agent setup

In the Agent node, replace the placeholder Postgres MCP connection with your real database URL. The sample URL follows Heym's .env.example defaults: postgres, postgres, localhost:6543, database heym. For production, use a read-only database user and keep secrets in your own Heym instance.

The Agent prompt is written as a Text-to-SQL workflow: understand the Slack question, generate a read-only SELECT, execute it with Postgres MCP tools, then show the SQL and results clearly.

How to import this template

  1. 1Click Import → Copy JSON on this page.
  2. 2Open your Heym and navigate to a workflow canvas.
  3. 3PressCmd+V/Ctrl+V— nodes appear instantly.
  4. 4Add your API keys in the node config panels and click Run.
More workflow templates
View all templates
Heym
incident analysis · production AI
Observed across 100s of AI rollouts

AI workflows don't fail because of prompts.
They fail because of orchestration.

symptom · glue code01
5 tools
Scripts, vector DB, approval bot, tracing, browser runner — none of them talk.
symptom · visibility02
~0%
Observable behavior across the stack. Debugging is guesswork.
with heym · one runtime
1 canvas
Agents, RAG, HITL, MCP, traces & evals. Self-hosted. Observable.
AI-Native RuntimeProduction-Grade
github.com/heymrun/heym