← 返回 Skills 市场
74
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install mongo-query
功能描述
Query MongoDB databases for debugging and troubleshooting. Use when user needs to: (1) List all databases, (2) List collections in a database, (3) Execute Mo...
安全使用建议
This skill is coherent with querying MongoDB, but proceed cautiously:
- Do NOT store full connection URIs (with usernames/passwords) in plaintext project files like TOOLS.md or repo files. Use environment variables, a secrets manager, or ephemeral credentials.
- Expect to install Python and the pymongo package locally before running the script. The registry metadata omits these — verify and install them yourself.
- If you plan to use a Kubernetes service name, the script runs kubectl port-forward: that will use your kubeconfig and can access clusters your kubectl is authorized for. Only run this if you trust the cluster and the script.
- Review the included scripts/query_mongo.py yourself (it spawns kubectl and connects to MongoDB). Look for any unexpected network endpoints or data-exfil behavior before running, and prefer running it from a non-production environment first.
- Use a least-privilege, read-only MongoDB account for queries and limit query results (use --limit). If you need persistent access, consider granting scoped service accounts or secrets storage rather than saving credentials in repository files.
If you want, I can list the exact lines in the script that start kubectl, parse/save URIs, and where credentials are used so you can review them quickly.
功能分析
Type: OpenClaw Skill
Name: mongo-query
Version: 1.0.0
The skill provides a legitimate utility for querying MongoDB databases, supporting both direct IP connections and Kubernetes port-forwarding via kubectl. The Python script (query_mongo.py) implements safe subprocess execution (avoiding shell=True) and follows the logic described in SKILL.md. While the instructions suggest the agent store connection strings in a local TOOLS.md file for session persistence, this behavior is transparently documented and aligned with the tool's purpose for debugging and troubleshooting.
能力评估
Purpose & Capability
The script's functionality (listing DBs/collections, running queries, optionally port-forwarding a Kubernetes service) matches the skill name/description. However registry metadata claimed no required binaries or credentials while SKILL.md and the script require Python/pymongo and optionally kubectl. The omission of kubectl/pymongo from declared requirements is an inconsistency.
Instruction Scope
SKILL.md correctly instructs the agent to ask the user for a full MongoDB URI (including credentials). It also recommends saving connection info into a project's TOOLS.md — instructing persistent storage of credentials in a repo is scope creep and increases risk of credential leakage. The instructions also rely on kubectl port-forward (which interacts with the user's kubeconfig) but this is not emphasized as a sensitive operation.
Install Mechanism
No install spec is provided (instruction-only), which reduces install-surface risk. The SKILL.md does require installing pymongo via pip, and the script will invoke kubectl if needed. The lack of an explicit install spec or dependency declaration in registry metadata is a mismatch but not itself malicious.
Credentials
The skill asks for full MongoDB connection URIs (username/password embedded) — that is expected for DB queries but is sensitive. It also will call kubectl which implicitly uses the user's kubeconfig and cluster credentials; SKILL.md does not declare or warn about kubeconfig access. Recommending storing the URI in TOOLS.md is disproportionate and dangerous.
Persistence & Privilege
The skill does not request always:true, does not modify other skills' configs, and the code does not persist changes itself. However the documentation's guidance to save credentials in a project file would create persistent sensitive data outside the skill and should be avoided.
如何使用
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install mongo-query - 安装完成后,直接呼叫该 Skill 的名称或使用
/mongo-query触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release of the mongodb-query skill:
- Enables querying MongoDB databases for debugging and troubleshooting.
- Supports listing databases and collections, executing queries, and checking connection health.
- Automatically handles connections via direct IP or Kubernetes service name.
- Requires --uri (MongoDB connection string); supports parameters for database, collection, queries, and K8s namespace.
- Detailed usage instructions and examples provided in documentation.
元数据
常见问题
mongodb-query 是什么?
Query MongoDB databases for debugging and troubleshooting. Use when user needs to: (1) List all databases, (2) List collections in a database, (3) Execute Mo... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 74 次。
如何安装 mongodb-query?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install mongo-query」即可一键安装,无需额外配置。
mongodb-query 是免费的吗?
是的,mongodb-query 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。
mongodb-query 支持哪些平台?
mongodb-query 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 mongodb-query?
由 GoodAtMe(@peintune)开发并维护,当前版本 v1.0.0。
推荐 Skills