Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| DO_NOT_TRACK | No | When set to 1, disables telemetry collection | |
| MDB_MCP_LOG_PATH | No | Folder to store logs | |
| MDB_MCP_READ_ONLY | No | When set to true, only allows read and metadata operation types, disabling create/update/delete operations | |
| MDB_MCP_TELEMETRY | No | When set to disabled, disables telemetry collection | |
| MDB_MCP_API_CLIENT_ID | No | Atlas API client ID for authentication | |
| MDB_MCP_DISABLED_TOOLS | No | A comma-separated list of tool names, operation types, and/or categories of tools that will be disabled | |
| MDB_MCP_API_CLIENT_SECRET | No | Atlas API client secret for authentication | |
| MDB_MCP_CONNECTION_STRING | No | MongoDB connection string for direct database connections (optional users may choose to inform it on every tool call) |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| aggregate | Run an aggregation against a MongoDB collection |
| collection-indexes | Describe the indexes for a collection |
| collection-schema | Describe the schema for a collection |
| collection-storage-size | Gets the size of the collection |
| connect | Connect to a MongoDB instance. The config resource captures if the server is already connected to a MongoDB cluster. If the user has configured a connection string or has previously called the connect tool, a connection is already established and there's no need to call this tool unless the user has explicitly requested to switch to a new MongoDB cluster. |
| count | Gets the number of documents in a MongoDB collection using db.collection.count() and query as an optional filter parameter |
| db-stats | Returns statistics that reflect the use state of a single database |
| explain | Returns statistics describing the execution of the winning plan chosen by the query optimizer for the evaluated method |
| export | Export a query or aggregation results in the specified EJSON format. |
| find | Run a find query against a MongoDB collection |
| list-collections | List all collections for a given database |
| list-databases | List all databases for a MongoDB connection |
| mongodb-logs | Returns the most recent logged mongod events |
| atlas-connect-cluster | Connect to MongoDB Atlas cluster |
| atlas-get-performance-advisor | Get MongoDB Atlas performance advisor recommendations, which includes the operations: suggested indexes, drop index suggestions, schema suggestions, and a sample of the most recent (max 50) slow query logs |
| atlas-inspect-access-list | Inspect Ip/CIDR ranges with access to your MongoDB Atlas clusters. |
| atlas-inspect-cluster | Inspect MongoDB Atlas cluster |
| atlas-list-alerts | List MongoDB Atlas alerts |
| atlas-list-clusters | List MongoDB Atlas clusters |
| atlas-list-db-users | List MongoDB Atlas database users |
| atlas-list-orgs | List MongoDB Atlas organizations |
| atlas-list-projects | List MongoDB Atlas projects |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| config | Server configuration, supplied by the user either as environment variables or as startup arguments |
| debug-mongodb | Debugging information for MongoDB connectivity issues. Tracks the last connectivity attempt and error information. |