my-mcp-server
My MCP Server (für Anfänger)
Eigener MCP (Model Context Protocol) Server mit:
Eigenes API-Key- und URL-Modul über die Datei
.envBeispiel-Tools:
echoundcall_my_apiBereit zum Testen mit MCP Inspector
Bereit zur direkten Verwendung in VS Code (GitHub Copilot Chat)
1. Abhängigkeiten installieren
npm installRelated MCP server: mcp-server-demo
2. Datei .env erstellen
Kopiere .env.example zu .env und fülle sie mit deinem API-Key und deiner URL:
Copy-Item .env.example .envInhalt der .env:
MY_API_KEY=api-key-asli-kamu
MY_API_BASE_URL=https://api.contohkamu.com
MCP_SERVER_NAME=my-mcp-server⚠️ Committe die Datei
.envniemals in git. Diese Datei wird automatisch über.gitignoreignoriert.
3. Projekt bauen
npm run buildDieser Befehl kompiliert TypeScript in src/ zu JavaScript in build/.
4. Mit MCP Inspector testen
MCP Inspector ist ein visuelles Tool (Browser), um deine MCP-Tools ohne weiteren Client auszuprobieren.
npm run inspectorDies führt npx @modelcontextprotocol/inspector node build/index.js aus und öffnet den Inspector im Browser. Von dort kannst du:
Klicke auf den Tab Tools
Wähle das Tool
echoodercall_my_apiFülle die Parameter aus, klicke auf Run Tool und sieh dir das Ergebnis an
5. Direkt in VS Code verwenden
Die Datei .vscode/mcp.json ist bereits vorbereitet. Öffne die Command Palette → MCP: List Servers → wähle my-mcp-server → Start Server. Dieser Server liest .env automatisch über envFile.
Projektstruktur
├── .env # rahasia kamu (tidak di-commit)
├── .env.example # contoh isi .env
├── .vscode/mcp.json # konfigurasi MCP untuk VS Code
├── src/
│ ├── config.ts # loader environment variable
│ ├── apiClient.ts # modul pemanggilan API eksternal (pakai API key & URL)
│ └── index.ts # server MCP utama + daftar tool
├── package.json
└── tsconfig.jsonNeues Tool hinzufügen
Füge einen neuen Block server.registerTool("nama_tool", { ... }, async (input) => { ... }) in src/index.ts hinzu und führe dann npm run build erneut aus.
Fehlerbehebung
Fehler „Umgebungsvariable ... nicht ausgefüllt" → stelle sicher, dass
.envvorhanden und ausgefüllt ist.Tool
call_my_apischlägt fehl → prüfe, obMY_API_BASE_URLundMY_API_KEYkorrekt sind und ob der API-Endpunkt den HeaderAuthorization: Bearer <key>unterstützt.Inspector öffnet nicht → stelle sicher, dass zuerst
npm run buildausgeführt wurde.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Build and run AI workflows, agents, data tables and 1000+ API integrations from any MCP client.
Remote MCP for 1,500+ APIs. Vault-managed credentials; OAuth or API key. Search, load, and execute.
Email inboxes, webhook URLs, mock APIs and 170+ tools for coding agents over one MCP connection.
MCP server for your apps' tools and custom tools, plus hosted AI agents and approval-gated workflows
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables users to expose arbitrary HTTP APIs as configurable MCP tools by defining tool specifications in a JSON configuration file.3-
- FlicenseNot gradedqualityDmaintenanceEnables AI clients to connect to example tools, resources, and prompts over MCP, demonstrating integration with IDEs, chatbots, and agent frameworks.-

automate-mcp-serverofficial
AlicenseNot gradedqualityBmaintenanceEnables building and running MCP servers for Umbraco add-ons, with tools for API interactions, OAuth setup, and testing via MCP Inspector or Claude Code.1MIT- AlicenseNot gradedqualityBmaintenanceEnables developers to build, test, debug, and operate MCP servers from VS Code or CI, while also exposing trusted MCP capabilities to AI agents.MIT