Langfuse Prompt Management MCP Server Setup Guide

Development Setup
  1. Install Dependencies

    npm install
     
  2. Build the Project

    npm run build
     
  3. Test in MCP Inspector

    npx @modelcontextprotocol/inspector node ./build/index.js
     

Usage

Step 1: Build the Project

  • Ensure the project is built using the following commands:
    npm install
     npm run build
     

Step 2: Configure Claude Desktop

  • Edit claude_desktop_config.json to add the server:
    {
      "mcpServers": {
      "langfuse": {
      "command": "node",
      "args": ["<absolute-path>/build/index.js"],
      "env": {
      "LANGFUSE_PUBLIC_KEY": "your-public-key",
      "LANGFUSE_SECRET_KEY": "your-secret-key",
      "LANGFUSE_BASEURL": "https://cloud.langfuse.com"
      }
      }
      }
     }
     
  • Replace the environment variables with your actual Langfuse API keys.

Step 3: Add New Server to Cursor

  • Configure the server in Cursor with the following command:
    LANGFUSE_PUBLIC_KEY="your-public-key" LANGFUSE_SECRET_KEY="your-secret-key" LANGFUSE_BASEURL="https://cloud.langfuse.com" node absolute-path/build/index.js
     

Notes

  • Make sure to replace <absolute-path> with the actual path to your build directory.
  • Ensure you have valid Langfuse API keys for LANGFUSE_PUBLIC_KEY and LANGFUSE_SECRET_KEY.
Share this post: