home / mcp / vibedoge mcp server

VibeDoge MCP Server

Provides user identity management, session persistence, and Vibe Coding lottery integration over MCP APIs with secure token-based access.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "chenxing3060-vibedoge-mcp": {
      "url": "http://localhost:3001/api/mcp/v1",
      "headers": {
        "LOG_LEVEL": "info",
        "VIBE_CODING_API_URL": "http://localhost:3001/api/mcp/v1",
        "VIBE_CODING_BEARER_TOKEN": "your_bearer_token_here"
      }
    }
  }
}

You can seamlessly manage user identities and contextual interactions with the VibeDoge MCP Server. It provides automatic user identity creation, session persistence across devices, and integrated lottery functionality, so you can build engaging experiences without complex registrations.

How to use

You interact with the MCP server through an MCP client. Start by connecting to the MCP API to create and manage user sessions, upload lottery-related profiles, participate in draws, and fetch results. The system assigns a unique user identity automatically, maintains sessions, and awards weights to determine lottery outcomes. Use the client to trigger actions like uploading profile data, validating sessions, entering lotteries, and querying results. All actions rely on secure token-based authentication and structured data payloads.

How to install

Prerequisites: Node.js 18 or newer, a package manager (pnpm or npm), and a compatible shell. You will also need a database and cache if you plan to run backend services locally in a full stack setup.

# 1) Install a package manager (choose one)
# pnpm is recommended
npm install -g pnpm
# or use npm if you prefer
npm --version

2) Clone and install dependencies for the MCP server project.

git clone https://github.com/chenxing3060/vibedoge-mcp.git
cd vibedoge-mcp
pnpm install

3) Configure environment variables for local development. Create a .env file and set the API URL, bearer token placeholder, and log level.

cp .env.example .env
# Edit the .env file to set:
# VIBE_CODING_API_URL=http://localhost:3001/api/mcp/v1
# VIBE_CODING_BEARER_TOKEN=your_bearer_token_here
# LOG_LEVEL=info

4) Start the development server in the usual way.

# Development mode
pnpm dev
# or
npm run dev

Additional configuration and notes

The MCP server provides a base URL for HTTP access and supports local stdio-based running as well. The HTTP endpoint for MCP v1 is available at the following base URL when running locally: http://localhost:3001/api/mcp/v1.

Security and environment considerations

All API calls require a Bearer token. Ensure tokens are stored securely on the client and rotated as needed. Use HTTPS in production and apply strict input validation and data encryption for sensitive fields.

Troubleshooting tips

If you encounter authentication issues, verify that your Bearer Token matches the token in your environment and that the user session is valid. Check the health endpoint to confirm the MCP service is reachable.

Available tools

generateUserId

Create a unique MCP user ID based on timestamp and random components to initialize user identity.

createUser

Asynchronously create a new MCP user and establish an initial session token, saving the user to storage.

updateUserProfile

Update the user profile data including nickname, avatar, preferences, and lottery-related settings.

restoreFromStorage

Restore an MCP user object from local storage to resume sessions.

heartbeat

Send a lightweight heartbeat to keep the session alive and monitor activity.

clearSession

Clear the current user session and related local data.

uploadUserProfile

Upload comprehensive lottery-related user profile data to participate in weight-based draws.

participateInLottery

Submit a participation request for a specified lottery and obtain a participation record.

getLotteryResults

Query the results for a given lottery to see winners and statistics.

getUserHistory

Retrieve user's historical actions and lottery participations.

listLotteryActivities

List available lottery activities and their current status.

getLotteryStats

Fetch statistics for lottery activities, such as participation counts and odds.