Skip to content

Add database MCP configuration and instructions on how to use it#5

Merged
liam-lloyd merged 1 commit into
mainfrom
add_database_mcp
Jun 2, 2026
Merged

Add database MCP configuration and instructions on how to use it#5
liam-lloyd merged 1 commit into
mainfrom
add_database_mcp

Conversation

@liam-lloyd
Copy link
Copy Markdown
Member

The first purpose of this repo is to provide a streamlined way for non-engineering staff to use Claude to query the database. To that end, this commit adds MCP server config to this repo, and instructions for how to clone the repo and set it up such that Claude will be able to read (and only read) our production database.

@liam-lloyd liam-lloyd force-pushed the add_database_mcp branch 4 times, most recently from 7b9a7bf to 1f532cd Compare June 2, 2026 19:35
Copy link
Copy Markdown
Member

@cecilia-donnelly cecilia-donnelly left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super easy and mostly there it appears!

Comment thread .mcp.json Outdated
"db": {
"type": "stdio",
"command": "bash",
"args": ["-c", "source ./.env && dbhub --dsn $DATABASE_URL"]
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This didn't work for me since I just have dbhub in node_modules, not globally, so Claude couldn't find it.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(I see this is outdated but the relevant piece is dbhub as opposed to npx dbhub or similar, which is still there)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be fixed now

Comment thread package-lock.json
@liam-lloyd liam-lloyd force-pushed the add_database_mcp branch 2 times, most recently from df5a3f8 to 4fce8c8 Compare June 2, 2026 19:53
@liam-lloyd liam-lloyd requested a review from slifty June 2, 2026 19:53
Copy link
Copy Markdown
Member

@cecilia-donnelly cecilia-donnelly left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are also a couple of README updates: remove the note about database access not being on this branch (since it is!) and change the .env instructions to use the new variable names.

Comment thread package.json Outdated
"prettier": "^3.8.3"
},
"dependencies": {
"@bytebase/dbhub": "^0.21.2"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude added "pg": "^8.21.0" as an explicit dependency here

The first purpose of this repo is to provide a streamlined way for
non-engineering staff to use Claude to query the database. To that end,
this commit adds MCP server config to this repo, and instructions for
how to clone the repo and set it up such that Claude will be able to
read (and only read) our production database.
Copy link
Copy Markdown
Member

@cecilia-donnelly cecilia-donnelly left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Working! So cool. We'll have to follow up with a skill telling Claude not to show SQL commands, etc.

@liam-lloyd liam-lloyd merged commit 2c7683e into main Jun 2, 2026
2 checks passed
@liam-lloyd liam-lloyd deleted the add_database_mcp branch June 2, 2026 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants