
Mongo Scout Mcp
io.github.bluwork由 GitHub 账号 bluwork 发布v1.0.3更新于 Oct 24, 2026
Scout your MongoDB databases with AI - safety features, live monitoring, and data quality
概览
让助手探索、查询、监控和诊断 MongoDB 数据库,并提供数据质量检查与可选的受控写入。
- 可以做什么
- Mongo Scout MCP 将助手连接到 MongoDB 实例,提供约 50 个工具,涵盖探索、查询、诊断、监控、数据质量、关系、时间序列、索引、导出、预览和写入。常见工具包括 listCollections、inferSchema、find、aggregate、detectVolumeAnomalies、findDuplicates、findOrphans、getServerStatus、getLiveMetrics、exportCollection,以及 previewUpdate 和 previewDelete。默认以只读模式运行,insertOne、updateMany、deleteMany、bulkWrite、dropCollection 等写入工具仅在启动读写实例时可用。
- 适用场景
- 当助手需要直接检查或分析 MongoDB 数据库时值得添加:了解集合与模式、执行查询和聚合、检查数据质量(如重复文档、孤立引用、缺失字段、类型不一致)、观察服务器与查询性能,或导出集合。也适合在真正修改前预览变更。
- 运行要求
- 需要本地 Node.js 运行时,因为它以 npm 包 mongo-scout-mcp 分发并通过 stdio 启动。MongoDB 连接字符串和目标数据库名作为命令参数传入。可选环境变量 ENABLE_LOGGING 和 LOG_DIR 控制文件日志。写入需要以读写标志启动单独实例。
安装
在 SourceWeft 中
- 打开 控制台中的 Mongo Scout Mcp,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
Mongo Scout MCP
Scout your MongoDB databases with AI - A production-ready Model Context Protocol server with built-in safety features, live monitoring, and data quality tools.
What You Get
You ask:
"Anything unusual happening with order volume this month?"
Mongo Scout returns:
Volume Analysis: orders
Statistics (last 30 days)
Anomalies Detected
- Feb 14 — 5,892 documents (+7.4σ) — Valentine's Day spike
- Feb 22 — 847 documents (-4.9σ) — Payment gateway outage window
- Mar 1 — 4,201 documents (+3.3σ) — Month-start subscription renewals
Recommendations
- Feb 22 drop warrants investigation — possible data loss during outage
- Consider auto-scaling rules for predictable spikes (month boundaries, holidays)
- Set up alerts for volumes exceeding ±3σ from rolling average
That's detectVolumeAnomalies — one of 50 tools covering exploration, querying, diagnostics, monitoring, data quality, and safe writes.
Quick Start
Claude Code
Then ask: "What collections do I have and what do their schemas look like?"
Claude Desktop
Add to your Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
Cursor / VS Code
Add to your MCP settings:
Read-Only vs Read-Write
The server runs in read-only mode by default. For write operations, run a separate instance:
- mongo-scout-readonly: Safe exploration, no risk of data modification
- mongo-scout-readwrite: Write operations when explicitly needed
Tools
Explore — understand your database
listDatabases— all databases in the instancegetDatabaseStats— storage and performance statisticslistCollections— collections in the current databasegetCollectionStats— size, document count, index detailsinferSchema— schema inference from sampled documents
Query — find and analyze documents
find— query documents with filtering, sorting, projectionaggregate— run aggregation pipelinescount— count documents matching a querydistinct— unique values for a fieldtextSearch— full-text search across indexed fieldsexplainQuery— query execution plan analysis
Diagnose — spot problems early
detectVolumeAnomalies— unusual patterns in document volumeanalyzeQueryPerformance— query optimization using explain plans
Monitor — watch it live
getServerStatus— server performance metricsgetCurrentOperations— currently running operationsgetConnectionPoolStats— connection pool healthgetProfilerStats— profiler data and slow operationsgetLiveMetrics— real-time metrics with continuous updatesgetHottestCollections— collections with highest activitygetCollectionMetrics— detailed per-collection metricsgetSlowestOperations— slow query trackingrunAdminCommand— execute admin commands
Data Quality — trust your data
findDuplicates— duplicate documents by field combinationfindOrphans— orphaned references across collectionsfindMissingFields— documents missing required fieldsfindInconsistentTypes— type inconsistencies across documentsvalidateDocuments— custom validation with MongoDB$expr
Relationships — follow the references
exploreRelationships— multi-hop relationship traversal
Time Series — temporal analysis
findRecent— documents within a time windowfindInTimeRange— date range queries with optional grouping
Indexes — manage your indexes
listIndexes— all indexes for a collectioncreateIndex— create new indexesdropIndex— remove indexes
Export — get data out
exportCollection— JSON, JSONL, or CSVcloneCollection— clone with filtering and index copying
Preview — dry-run before changing anything
previewUpdate/previewDelete— see what would change before committingpreviewBulkWrite— preview bulk operations
Write (read-write only) — safe modifications
insertOne/insertMany— insert documentsupdateOne/updateMany— update with dryRun and maxDocuments limitsreplaceOne— replace a single documentfindOneAndUpdate— find and update atomicallydeleteOne/deleteMany— delete with dryRun and maxDocuments limitsbulkWrite— multiple write operations in one callrenameField— rename fields with dry-run and index migrationcreateCollection/dropCollection— collection management
Security
- Read-only by default — write operations must be explicitly enabled
- All queries are validated and sanitized
- MongoDB operator injection protection
- Connection string credential redaction in logs
- Rate limiting on all operations
- Response size limits to prevent memory exhaustion
Examples
"What collections do I have and what's the schema of users?"
"Find duplicate emails in the users collection."
"Show me order volume anomalies over the last month."
"What's happening on the server right now?"
"Find orders that reference deleted users."
"Export the products collection as CSV."
Configuration
CLI flags: --read-only (default), --read-write, --mode <mode>
Logging
File logging is disabled by default. Set ENABLE_LOGGING=true to enable. Two log files are created in LOG_DIR:
- tool-usage.log — every tool call with timestamp, name, and arguments
- error.log — errors with stack traces
Connection strings are automatically redacted in all output.
ObjectId Format
Both formats accepted:
Development
License
Apache-2.0
来源:README.md,提交 09e3774
工具
0版本历史
1- v1.0.3最新Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分