CLI Setup
Step-by-step guide to self-hosting Wellpipe with the CLI.
Prerequisites
- Node.js 18+ - Download here
- Terminal access - Command line or PowerShell
- WHOOP developer credentials - Create here
Quick Setup
The fastest way to get started:
npx @wellpipe/cli init
This interactive wizard will:
- Create a
.envfile with your configuration - Guide you through connecting your WHOOP account
- Configure Claude Desktop automatically
Manual Setup
If you prefer step-by-step:
1. Install the CLI
Option A: Run with npx (no install)
npx @wellpipe/cli
Option B: Install globally
npm install -g @wellpipe/cli
2. Create Configuration
Create a .env file in your project directory:
WHOOP_CLIENT_ID=your_client_id
WHOOP_CLIENT_SECRET=your_client_secret
Get these from your WHOOP Developer account.
3. Authenticate with WHOOP
wellpipe auth whoop
# or
npx @wellpipe/cli auth whoop
This will:
- Open your browser to WHOOP's authorization page
- Wait for you to authorize
- Save tokens to your
.envfile
4. Configure Claude Desktop
Add Wellpipe to your Claude Desktop config:
Mac: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"wellpipe": {
"command": "npx",
"args": ["@wellpipe/cli"]
}
}
}
5. Restart Claude Desktop
Completely quit (Cmd+Q on Mac) and reopen Claude Desktop.
Look for the tools icon to verify connection.
CLI Commands
| Command | Description |
|---|---|
wellpipe init | Interactive setup wizard |
wellpipe auth whoop | Authenticate with WHOOP |
wellpipe status | Show connection status |
wellpipe | Start MCP server |
Checking Status
Verify your setup:
wellpipe status
Output should show:
- WHOOP: Connected
- Token expiry date
- Available commands
File Structure
After setup, you'll have:
your-directory/
├── .env # Credentials and tokens
└── node_modules/ # (if installed locally)
Important: Add .env to your .gitignore to avoid committing secrets.
Updating
Update to the latest version:
npm update -g @wellpipe/cli
# or with npx, just run it again
npx @wellpipe/cli@latest
Troubleshooting
"Command not found"
If wellpipe isn't recognized:
- Use
npx @wellpipe/cliinstead - Or ensure npm global bin is in your PATH
"Cannot find .env"
The CLI looks for .env in the current directory:
cdto your project directory- Or run
wellpipe initto create it
"Port already in use"
OAuth callback uses port 3000 by default:
wellpipe auth whoop --port 3001
"Invalid client ID"
Check your WHOOP developer app settings:
- Client ID matches
.env - Redirect URI is exactly
http://localhost:3000/api/callback/whoop
Token Expired
Re-authenticate when tokens expire:
wellpipe auth whoop
Using with Claude Desktop
Once configured, Claude Desktop will automatically use your local MCP server.
Verify Connection
- Open Claude Desktop
- Look for tools icon (hammer/wrench)
- Click it to see Wellpipe tools
Test It
Ask Claude:
"How did I sleep last night?"
It should use your local Wellpipe installation to fetch data.
Next Steps
- Create WHOOP developer account if you haven't already
- Try asking Claude about your health data