Workflow MCP
Reference

Environment Variables

All environment variables for Workflow MCP

Environment Variables

Complete reference for all environment variables used by Workflow MCP.

HTTP Server

VariableDefaultDescription
PORT-Server port (Render/Heroku standard, takes precedence)
MCP_PORT3000Server port
MCP_HOST0.0.0.0Bind address
MCP_BASE_PATH/mcpMCP endpoint path
MCP_WORKSPACE_DIRprocess.cwd()Working directory for session files

CORS

VariableDefaultDescription
CORS_ORIGINS*Allowed origins (comma-separated for multiple)

Example:

CORS_ORIGINS=https://app.example.com,https://admin.example.com

OAuth (GitHub)

VariableDefaultDescription
MCP_OAUTH_ENABLEDfalseEnable OAuth authentication
GITHUB_CLIENT_ID-GitHub OAuth App client ID
GITHUB_CLIENT_SECRET-GitHub OAuth App client secret
GITHUB_CALLBACK_URL-OAuth callback URL (optional)

Node.js

VariableDefaultDescription
NODE_ENV-Set to production for production builds

Examples

Local Development

MCP_PORT=3000
MCP_WORKSPACE_DIR=/home/user/projects/myapp

Render Deployment

# Set in Render dashboard
MCP_WORKSPACE_DIR=/tmp/workflow-workspace
CORS_ORIGINS=https://myapp.com

Docker with OAuth

docker run -p 3000:3000 \
  -e MCP_OAUTH_ENABLED=true \
  -e GITHUB_CLIENT_ID=xxx \
  -e GITHUB_CLIENT_SECRET=xxx \
  -e MCP_WORKSPACE_DIR=/data \
  -v ./data:/data \
  workflow-mcp

.env File

For local development, create a .env file:

# Server
MCP_PORT=3000
MCP_HOST=localhost
MCP_WORKSPACE_DIR=./

# OAuth (optional)
# MCP_OAUTH_ENABLED=true
# GITHUB_CLIENT_ID=your_client_id
# GITHUB_CLIENT_SECRET=your_client_secret

# CORS (optional)
# CORS_ORIGINS=http://localhost:5173

Note: The HTTP server doesn't automatically load .env files. Use a tool like dotenv-cli:

npx dotenv-cli -- node packages/http/dist/index.js

Or source it in your shell:

export $(cat .env | xargs)
node packages/http/dist/index.js

On this page