MongoDB Atlas MCP Server

Official
MIT License
74
10
  • Apple
  • Linux

Integrations

  • Provides tools for managing MongoDB Atlas projects, including creating and configuring clusters, managing database users, setting up network access, and retrieving connection strings.

MongoDB Atlas MCP Server

Ein MCP-Server (Model Context Protocol) zur Verwaltung von MongoDB Atlas-Projekten. Dieses Paket bietet Tools zum Erstellen und Verwalten von MongoDB Atlas-Clustern, Benutzern und Netzwerkzugriff über die MCP-Schnittstelle.

Demo-Video

Sehen Sie sich das Demonstrationsvideo an, um den MongoDB Atlas MCP Server in Aktion zu sehen.

Merkmale

MCP-Tools

  • create_atlas_cluster – Erstellen Sie einen neuen MongoDB Atlas-Cluster in einem vorhandenen Projekt
  • setup_atlas_network_access - Netzwerkzugriff für ein Atlas-Projekt konfigurieren
  • create_atlas_user – Erstellen Sie einen neuen Datenbankbenutzer mit der Rolle „atlasAdmin“.
  • get_atlas_connection_strings - Verbindungszeichenfolgen für einen Cluster abrufen
  • list_atlas_projects – Listet alle Atlas-Projekte auf, auf die mit dem bereitgestellten API-Schlüssel zugegriffen werden kann
  • list_atlas_clusters – Listet alle Cluster in einem bestimmten Atlas-Projekt auf

Installation

npm install mcp-mongodb-atlas

Verwendung

Als Befehlszeilentool

Sie können den Atlas Project Manager direkt von der Befehlszeile aus ausführen:

# Using environment variables export ATLAS_PUBLIC_KEY="your-public-key" export ATLAS_PRIVATE_KEY="your-private-key" npx mcp-mongodb-atlas # Or passing keys as arguments npx mcp-mongodb-atlas "your-public-key" "your-private-key"

Mit Cline (VSCode-Erweiterung)

Um es mit Cline in VSCode zu verwenden, fügen Sie die Serverkonfiguration zu Ihrer MCP-Einstellungsdatei hinzu:

{ "mcpServers": { "atlas": { "command": "npx", "args": ["mcp-mongodb-atlas"], "env": { "ATLAS_PUBLIC_KEY": "your-public-key", "ATLAS_PRIVATE_KEY": "your-private-key" }, "disabled": false, "autoApprove": [] } } }

Die MCP-Einstellungsdatei befindet sich unter:

  • macOS: ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json
  • Windows: %APPDATA%\Code\User\globalStorage\saoudrizwan.claude-dev\settings\cline_mcp_settings.json
  • Linux: ~/.config/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json

Mit Cursor

Zur Verwendung mit Cursor gehen Sie in den Einstellungen zu „Cursor-Einstellungen“ > „MCP“ und fügen Sie einen neuen Server mit der folgenden Konfiguration hinzu:

  1. Name : atlas (oder ein beliebiger Name Ihrer Wahl)
  2. Befehl : npx mcp-mongodb-atlas
  3. Argumente : Geben Sie Ihre API-Schlüssel als Argumente an
## Suggested Command npx mcp-mongodb-atlas <public_key> <private_key>

Neuere Versionen können die Datei ~/.cursor/mcp.json mit Folgendem festlegen:

{ "mcpServers": { "atlas": { "command": "npx", "args": ["mcp-mongodb-atlas"], "env": { "ATLAS_PUBLIC_KEY": "your-public-key", "ATLAS_PRIVATE_KEY": "your-private-key" }, "disabled": false, "autoApprove": [] } } }
  1. Umgebungsvariablen (optional):
    • ATLAS_PUBLIC_KEY : Ihr öffentlicher MongoDB Atlas-Schlüssel
    • ATLAS_PRIVATE_KEY : Ihr privater MongoDB Atlas-Schlüssel

Mit Claude Desktop

Zur Verwendung mit Claude Desktop fügen Sie die Serverkonfiguration hinzu:

Unter macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Unter Windows: %APPDATA%/Claude/claude_desktop_config.json

{ "mcpServers": { "atlas": { "command": "npx", "args": ["mcp-mongodb-atlas"], "env": { "ATLAS_PUBLIC_KEY": "your-public-key", "ATLAS_PRIVATE_KEY": "your-private-key" } } } }

API-Schlüssel

Sie benötigen MongoDB Atlas API-Schlüssel, um dieses Tool zu verwenden. So erstellen Sie API-Schlüssel:

  1. Melden Sie sich bei Ihrem MongoDB Atlas-Konto an
  2. Gehen Sie zu Access Manager > API-Schlüssel
  3. Erstellen Sie einen neuen API-Schlüssel mit den entsprechenden Berechtigungen
  4. Speichern Sie die öffentlichen und privaten Schlüssel

Entwicklung

Klonen Sie das Repository und installieren Sie Abhängigkeiten:

git clone https://github.com/mongodb-developer/mcp-mongodb-atlas.git cd mcp-mongodb-atlas npm install

Erstellen Sie das Projekt:

npm run build

Für die Entwicklung mit automatischem Rebuild:

npm run watch

Debuggen

Da MCP-Server über stdio kommunizieren, kann das Debuggen eine Herausforderung darstellen. Wir empfehlen die Verwendung des MCP Inspector:

npm run inspector

Der Inspector stellt eine URL für den Zugriff auf Debugging-Tools in Ihrem Browser bereit.

Lizenz

MIT

-
security - not tested
A
license - permissive license
-
quality - not tested

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

Ein MCP-Server, der es Benutzern ermöglicht, MongoDB Atlas-Cluster, Benutzer und Netzwerkzugriff über Befehle in natürlicher Sprache zu erstellen und zu verwalten.

  1. Demo-Video
    1. Merkmale
      1. MCP-Tools
    2. Installation
      1. Verwendung
        1. Als Befehlszeilentool
        2. Mit Cline (VSCode-Erweiterung)
        3. Mit Cursor
        4. Mit Claude Desktop
      2. API-Schlüssel
        1. Entwicklung
          1. Debuggen
        2. Lizenz

          Related MCP Servers

          • -
            security
            A
            license
            -
            quality
            A Model Context Protocol (MCP) server that enables LLMs to interact directly with MongoDB databases. Query collections, inspect schemas, and manage data seamlessly through natural language.
            Last updated -
            340
            75
            TypeScript
            MIT License
            • Apple
          • -
            security
            A
            license
            -
            quality
            Full featured MCP Server for MongoDB database analysis.
            Last updated -
            334
            108
            JavaScript
            MIT License
            • Apple
          • -
            security
            A
            license
            -
            quality
            An MCP server that enables large language models to interact directly with MongoDB databases, allowing them to query collections, inspect schemas, and manage data through natural language.
            Last updated -
            340
            MIT License
            • Apple
          • -
            security
            A
            license
            -
            quality
            A Model Context Protocol (MCP) server that enables LLMs to interact directly with MongoDB databases, allowing them to query collections, inspect schemas, and manage data seamlessly through natural language.
            Last updated -
            340
            MIT License
            • Apple

          View all related MCP servers

          ID: d9peo804ly