Skip to content

Commit 95e3b9f

Browse files
committed
docs: update README for setup instructions and clarify STDIO mode usage
feat: add script entry point for mcp-metricflow in pyproject.toml
1 parent 2d3ce74 commit 95e3b9f

File tree

2 files changed

+21
-31
lines changed

2 files changed

+21
-31
lines changed

README.md

Lines changed: 18 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,10 @@ A Model Context Protocol (MCP) server that provides MetricFlow CLI tools through
1616
- [mcp-metricflow](#mcp-metricflow)
1717
- [Table of Contents](#table-of-contents)
1818
- [Overview](#overview)
19-
- [Installation](#installation)
19+
- [Setup](#setup)
2020
- [Configuration](#configuration)
2121
- [Running the MCP Server](#running-the-mcp-server)
22-
- [STDIO Mode (Claude Desktop)](#stdio-mode-claude-desktop)
23-
- [Claude Desktop Configuration](#claude-desktop-configuration)
22+
- [STDIO Mode](#stdio-mode)
2423
- [SSE Mode](#sse-mode)
2524
- [API Key Authentication](#api-key-authentication)
2625
- [Available Tools](#available-tools)
@@ -32,18 +31,14 @@ A Model Context Protocol (MCP) server that provides MetricFlow CLI tools through
3231

3332
This project provides a Model Context Protocol (MCP) server that wraps MetricFlow CLI commands, making them accessible through both Server-Sent Events (SSE) and Standard Input/Output (STDIO) interfaces. It enables seamless integration with Claude Desktop and other MCP-compatible clients.
3433

35-
## Installation
34+
## Setup
3635

3736
```bash
38-
# Clone the repository
39-
git clone https://github.com/datnguye/mcp-metricflow.git
40-
cd mcp-metricflow
41-
42-
# Install dependencies
43-
uv sync
37+
# Install uv at https://docs.astral.sh/uv/getting-started/installation/
4438

4539
# Copy environment template
4640
cp .env.template .env
41+
# ...and then jump to # Configuration section to fulfill it
4742
```
4843

4944
## Configuration
@@ -52,7 +47,7 @@ Edit the `.env` file with your specific configuration:
5247

5348
```bash
5449
# Required: Path to your dbt project
55-
DBT_PROJECT_DIR=/path/to/your/dbt/project
50+
DBT_PROJECT_DIR=/path/to/your/dbt/project e.g. /Users/dat/repos/il/jaffle-shop
5651

5752
# Optional: Other configurations
5853
DBT_PROFILES_DIR=~/.dbt
@@ -70,31 +65,27 @@ MCP_REQUIRE_AUTH=false
7065

7166
## Running the MCP Server
7267

73-
### STDIO Mode (Claude Desktop)
68+
### STDIO Mode
7469

75-
For integration with Claude Desktop, use STDIO mode:
70+
For integration with Claude Desktop (or any other MCP Client tool), use STDIO mode with the following `uvx` command:
7671

7772
```bash
78-
uv run python src/main_stdio.py
73+
uvx --env-file /path/to/.env mcp-metricflow
7974
```
8075

81-
#### Claude Desktop Configuration
82-
83-
Add this to your Claude Desktop MCP configuration:
76+
Add this configuration to the respective client's config file:
8477

8578
```json
8679
{
8780
"mcpServers": {
88-
"metricflow": {
89-
"command": "uv",
90-
"args": ["run", "python", "/path/to/mcp-metricflow/src/main_stdio.py"],
91-
"cwd": "/path/to/mcp-metricflow",
92-
"env": {
93-
"DBT_PROJECT_DIR": "/path/to/your/dbt/project",
94-
"DBT_PROFILES_DIR": "~/.dbt",
95-
"MF_PATH": "mf"
96-
}
97-
}
81+
"dbt-mcp": {
82+
"command": "uvx",
83+
"args": [
84+
"--env-file",
85+
"<path-to-.env-file>",
86+
"mcp-metricflow"
87+
]
88+
},
9889
}
9990
}
10091
```
@@ -203,7 +194,3 @@ Finally, super thanks to our *Contributors*:
203194

204195
## TODO
205196
- Test STDIO mode
206-
207-
## GitAds Sponsored
208-
[![Sponsored by GitAds](https://gitads.dev/v1/ad-serve?source=datnguye/mcp-metricflow@github)](https://gitads.dev/v1/ad-track?source=datnguye/mcp-metricflow@github)
209-
<!-- GitAds-Verify: HRQ1S4W8N5U676OK6MBIJNH3EPKCGG64 -->

pyproject.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ dependencies = [
1313
"mcp>=1.3.2",
1414
]
1515

16+
[project.scripts]
17+
mcp-metricflow = "src.main_stdio:main"
18+
1619
[project.optional-dependencies]
1720
dev = [
1821
"black>=25.1.0",

0 commit comments

Comments
 (0)