mongodb

mongodb is a skill for Claude Code, Codex from ericrisco/rsc-harness. It costs 118 tokens per session (4,886 once invoked), scanned A, original, MIT.

A guide to MongoDB, a database that stores data as flexible documents rather than rows in tables.

In plain words
What is it for?
Use it to design document structures, investigate slow queries, build aggregation pipelines, and run multi-document transactions.
Why use it?
It helps you model documents, choose indexes, and write queries that do not scan unnecessary data or exceed MongoDB's limits.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions CLAUDE.md; positional $N argument.

Good fit Use it to design document structures, investigate slow queries, build aggregation pipelines, and run multi-document transactions.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ericrisco/rsc-harness/mongodb
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add ericrisco/rsc-harness --skill mongodb
Clone the repo
git clone --depth 1 https://github.com/ericrisco/rsc-harness

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for mongodb

README.md
[![agentmods](https://agentmods.dev/badge/skills/ericrisco/rsc-harness/mongodb/github.svg)](https://agentmods.dev/skills/ericrisco/rsc-harness/mongodb)
Your own site
<a href="https://agentmods.dev/skills/ericrisco/rsc-harness/mongodb"><img src="https://agentmods.dev/badge/skills/ericrisco/rsc-harness/mongodb/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for mongodb

Your own site · 80×15
<a href="https://agentmods.dev/skills/ericrisco/rsc-harness/mongodb"><img src="https://agentmods.dev/badge/skills/ericrisco/rsc-harness/mongodb.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 118 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,886 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00118 $0.04886
Opus 5.5 $0.00047 $0.01954
Sonnet 5.5 $0.00024 $0.00977
Haiku 4.5 $0.00012 $0.00489

Measured 1mo ago against content hash bf13001664bd, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

mongodb scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/verify.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/mongodb/SKILL.md · 343 lines

How it starts

The opening of the file, as written. The whole thing — 343 lines — stays where its author put it; the contents beside it link to each section on GitHub.

MongoDB — modeling, indexing, aggregation, transactions, ops

Engine-level MongoDB 8.2 guidance: model documents for the queries you actually run, pick the index the planner will use, write aggregation pipelines that stay index-eligible, run multi-document transactions with correct retry, and operate/secure a deployment. Driver-agnostic — every example is mongosh shell syntax that maps 1:1 to the official drivers (Node, Python, Go, Java, Rust). This skill owns the server's query and the index it picks, not any ODM's API.

When to use / When NOT to use

When to use:

  • Document modeling: embed vs reference, the 16 MB cap, one-to-many/many-to-many, the subset/extended-reference/bucket/computed/outlier patterns, taming unbounded array growth.
  • Index decisions: single-field, compound (the ESR ordering rule), multikey, partial, TTL, text, wildcard, 2dsphere; and when an index is NOT worth it.
  • Any query that is slow or scans too much; reading explain("executionStats").
  • Aggregation pipelines: stage order so $match/$sort hit an index, $lookup cost, $unwind explosion, $group/$sort memory limits and allowDiskUse, $merge/$out, faceting.
  • Multi-document transactions: sessions, withTransaction retry semantics, read/write concern.
  • Operating/securing: replica set, read preference, write concern, Atlas tier choice, Atlas Search & Vector Search, Queryable Encryption, role-based access, connection-pool knobs.

When NOT to use:

  • Relational schema / SQL / EXPLAIN ANALYZE → postgresdb. Different engine, planner, and concurrency model.
  • ODM/driver API ergonomics (Mongoose pre-save hooks, the Node driver's bulkWrite return shape, updateMany's result object) → that tool's own docs. This skill owns the server query and the index the server picks, not the JS object the driver hands back.
  • App-layer caching as a product (Redis-in-front-of-reads).
  • Cloud-console click-paths — we give the shell command / connection string, not the Atlas UI tour.
  • Picking a vector store across engines (Pinecone vs Weaviate). Atlas Vector Search inside Mongo is in scope; cross-engine selection is not.

Read the full file on GitHub · 343 lines

Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 343 lines · 118 tokens per session scan A bf13001664bd

Subscribe to this mod's changes

mongodb is a skill published in the GitHub repository ericrisco/rsc-harness (231 stars, last pushed today), licensed MIT. It adds 118 tokens to every session and 4,886 once invoked, about $0.0005 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

mongodb

MongoDB - NoSQL document database with flexible schema design, aggregation pipelines, indexing strategies, and Spring Data integration.

bobmatnyc/claude-mpm-skills · 24 tokens

huawei-cloud-dds-dcs-instance-management

Huawei Cloud DDS (Document Database Service) and DCS (Distributed Cache Service) unified management skill. Provides 16 operations across five capability domains: (1) Query — list/get DDS/DCS instances, DCS node info, DCS custom templates; (2) Analysis — analyze DDS deployment architecture and DCS security posture; (3)…

huaweicloud/huaweicloud-devkit · 258 tokens

mongodb-expert

Expert-level MongoDB database design, aggregation pipelines, indexing, replication, and production operations. Use when the user mentions NoSQL, database, aggregation, or performance, or when the task involves CRUD Operations, Query Operators, Aggregation Pipeline, or Indexing.

personamanagmentlayer/pcl · 56 tokens

nosql-database-design

Designs a NoSQL data model by leading with access pattern analysis. Covers DynamoDB single-table design (PK/SK/GSI) and MongoDB embedding vs referencing, consistency models, and capacity planning. Invoked when the user asks to design a DynamoDB schema, MongoDB data model, or NoSQL data model.

soulcodex/agentic · 71 tokens

traverse-multi-hop

Expresses a multi-hop lineage question as a single variable-length path match against native graph storage, bounded by an explicit hop depth and an explicit relationship-type allowlist, instead of a recursive relational join that grows one level per hop.

ayeshakhalid192007-dev/graph-engineering-crash-course · 51 tokens

transact-graph-write

Wraps every write to a shared graph edge in a transaction tied to the exact row version it was computed against, and retries a rejected write against the row's current state instead of dropping it or blindly reapplying stale values.

ayeshakhalid192007-dev/graph-engineering-crash-course · 51 tokens