Skip to main content
Glama

Doppler MCP Server

by aledlie
index.ts1.51 kB
#!/usr/bin/env node import { Server } from "@modelcontextprotocol/sdk/server/index.js"; import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js"; import { CallToolRequestSchema, ListToolsRequestSchema, McpError, ErrorCode, } from "@modelcontextprotocol/sdk/types.js"; import { executeCommand } from "./doppler.js"; import { toolDefinitions } from "./tools.js"; const server = new Server( { name: "doppler-mcp-server", version: "1.0.0", }, { capabilities: { tools: {}, }, } ); // List available tools server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools: toolDefinitions, }; }); // Handle tool calls server.setRequestHandler(CallToolRequestSchema, async (request) => { const { name, arguments: args } = request.params; try { const result = await executeCommand(name, args || {}); return { content: [ { type: "text", text: JSON.stringify(result, null, 2), }, ], }; } catch (error) { const errorMessage = error instanceof Error ? error.message : String(error); throw new McpError(ErrorCode.InternalError, `Doppler CLI error: ${errorMessage}`); } }); // Start the server async function main() { const transport = new StdioServerTransport(); await server.connect(transport); console.error("Doppler MCP Server running on stdio"); } main().catch((error) => { console.error("Fatal error in main():", error); process.exit(1); });

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/aledlie/doppler-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server