/mongodb:mongodb-qe-size-estimationfrom MongoDB (Self-Managed MCP)
Estimates storage and memory impact of encrypting fields in MongoDB collections with Queryable Encryption (QE). Walks through field-by-field sizing based on encryption schema.
Ships in MongoDB (Self-Managed MCP). Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Validate the user's inputs, whether manual or via an encryption schema, against the following:
An encrypted field may be "unindexed" meaning it has no query types enabled. Fields of BSON type object or array only support unindexed encryption, though other BSON types can also be unindexed. Otherwise, allowed query types based on a field's BSON type are:
A string field may have both "prefix" and "suffix" enabled, in which case "queries" may be an array of two objects. This is the only valid case where one field is indexed for multiple query types.
No other BSON type + query type combinations are permitted.
Don't accept "preview" query types such as "suffixPreview". These are from earlier Public Preview releases of those query types, so the sizing formulas for their GA versions don't apply.
If the user's input violates any of the preceding rules, reject it. If a user doesn't specify BSON type, only check that each field either has no query types enabled, exactly one valid query type, or exactly two (prefix and suffix). Enumerate validation failures, list allowed combinations, and don't proceed until the user provides valid input.
Create an empty qe-sizing-calculations.md file in the OS temp directory ($TMPDIR, or /tmp if unset). If a qe-sizing-calculations.md file already exists at that location, inform the user and ask for confirmation to delete it and create a new one for the new set of calculations.
State: "This skill calculates the maximum storage impact of enabling Queryable Encryption on a collection. Values are saved to the file if you want to verify the calculations or see per-field numbers. Note that prefix, suffix, and substring queries on encrypted fields require MongoDB 9.0, and aren't supported in earlier versions.
All values are worst-case. You may see a smaller impact on storage or memory in practice.
Do you want to provide field information manually, or use an encryption schema file?"
If the user opts for an encryption schema, request it as either pasted content or a file path, and expect JSON format. Validate the schema against this skill's "Validation" section. If the schema is valid but includes fields with "range" queries enabled, inform the user that no calculations are available for those fields, so their impact is estimated as 0.
Ask the user how many documents in the collection have encrypted fields. If they don't know, a safe default is the total number of documents in the collection. Save this value to qe-sizing-calculations.md as:
N:
Save this value to qe-sizing-calculations.md as:
numUnindexed:
Save this value to qe-sizing-calculations.md as:
numIndexed:
Save the sum of numUnindexed and numIndexed to qe-sizing-calculations.md as:
numEntries:
Write a section heading to qe-sizing-calculations.md:
== FIELD VALUES ===============================================================
As you get information, write it to qe-sizing-calculations.md in the following format, omitting any lines that don't apply. For unindexed fields, this means omitting the Query Type.
<the name provided by the user, or the dot notation "path" value if taken from the encryption schema> Query Type: <equality, range, prefix, suffix, substring, or "prefix and suffix"> mlen: <include if Query Type is substring. Integer from 2-50, inclusive> lb: <include if Query Type is "prefix", "suffix", or "substring". Integer 1+ for prefix and suffix queries, or 2+ for substring queries> ub: <include if Query Type is "prefix", "suffix", or "substring". Integer 1+ for prefix and suffix queries, or 2-6 for substring queries> lb_prefix: <include if Query Type is "prefix and suffix". Integer 1+> ub_prefix: <include if Query Type is "prefix and suffix". Integer 1+> lb_suffix: <include if Query Type is "prefix and suffix". Integer 1+> ub_suffix: <include if Query Type is "prefix and suffix". Integer 1+> v: <omit if Query Type is range, otherwise include. Integer representing the average byte length of the unencrypted values for the field>
If the user provided an encryption schema, do this once:
If the user didn't provide an encryption schema, do this per field:
Do this per field:
Check the list below, and ask the user for the values that aren't already populated. Write all values to the qe-sizing-calculations.md file.
mlen: (LLM Note: only include if no schema provided, and Query Type is substring) Max Length, the maximum allowable length of the string. lb: (LLM Note: only include if no schema provided, and Query Type is "prefix", "suffix", or "substring") Lower Bound, the minimum searchable characters. ub: (LLM Note: only include if no schema provided, and Query Type is "prefix", "suffix", or "substring") Upper Bound, the maximum searchable characters. lb_prefix: (LLM Note: only include if no schema provided, and Query Type is "prefix and suffix") Lower Bound for prefix queries, the minimum searchable characters. ub_prefix: (LLM Note: only include if no schema provided, and Query Type is "prefix and suffix") Upper Bound for prefix queries, the maximum searchable characters. lb_suffix: (LLM Note: only include if no schema provided, and Query Type is "prefix and suffix") Lower Bound for suffix queries, the minimum searchable characters. ub_suffix: (LLM Note: only include if no schema provided, and Query Type is "prefix and suffix") Upper Bound for suffix queries, the maximum searchable characters. v: (LLM Note: skip if Query Type is range since we have no calculation for those, otherwise needed once per field). Average byte length of the unencrypted values for the field. If the user provides character length, accept it as equivalent.
Validate values against the formatting snippet at the start of this step. Validate that lb ≤ ub ≤ mlen (if present). Validate that lb_prefix ≤ ub_prefix and lb_suffix ≤ ub_suffix (if present). If a value falls outside allowable bounds, reject it and inform the user. Do not proceed without a valid value.
If mlen < v, warn the user that the full field value isn't queryable, but accept it as valid.
Repeat until you have populated the full number of entries, numEntries, in qe-sizing-calculations.md.
This step populates calculation information to file, including intermediate steps.
For every entry in qe-sizing-calculations.md:
For fields with no Query Type:
T: 0 Document Storage (bytes): <run the calculation: 71 + ceil((v+6)/16) * 16>
For fields with a Query Type of "equality":
T: 1 Document Storage (bytes): <run the calculation: 1.2 * (255 * T + 122 + ceil((v + 6) / 16) * 16)>
For fields with a Query Type of "range", there is currently no formula, so record an entry with values of 0:
T: 0 Document Storage (bytes): 0
For fields with a Query Type of "prefix" or "suffix":
T formula: T = 1 + (ub - lb + 1) T calculation: <The T formula template with all placeholders populated by the field's values, but not calculated> T: <run the calculation in "T calculation" and write the result here> Document Storage (bytes): <run the calculation: 1.2 * (255 * T + 122 + ceil((v + 6) / 16) * 16)>
For fields with a Query Type of "prefix and suffix":
T formula: T = 1 + (ub_prefix - lb_prefix + 1) + (ub_suffix - lb_suffix + 1) T calculation: <The T formula template with all placeholders populated by the field's values, but not calculated> T: <run the calculation in "T calculation" and write the result here> Document Storage (bytes): <run the calculation: 1.2 * (255 * T + 122 + ceil((v + 6) / 16) * 16)>
For fields with a Query Type of "substring":
T formula: T = 1 + (ub - lb + 1) * (2 * mlen + 2 - ub - lb) / 2 T calculation: <The T formula template with all placeholders populated by the field's values, but not calculated> T: <run the calculation in "T calculation" and write the result here> Document Storage (bytes): <run the calculation: 1.2 * (255 * T + 122 + ceil((v + 6) / 16) * 16)>
These values are collection-level and calculated as totals across all entries.
At the end of the qe-sizing-calculations.md file, silently write the following lines:
== COLLECTION-LEVEL TOTALS ==================================================== N: <copy the N value from the top of the file down to this section, for easier reading> T_Total: Index Storage (bytes): <run the calculation: 1.2 * (67 * T_Total + 640)> Total Disk Storage (bytes): <run the calculation: N * (Index Storage + (the sum of all Document Storage values))> Memory (bytes): <run the calculation: N * (52 * T_Total + 17)>
Output the following, and include the units:
Total Disk Storage Impact: <the Total Disk Storage value from qe-sizing-calculations.md, converted to decimal GB (1000³ bytes) > Required Memory: <the Memory value from qe-sizing-calculations.md, converted to binary GiB (1024³ bytes)> Fields by Impact (descending): <sort all fields in qe-sizing-calculations.md by T, descending, then list them as: Name (<either the Query Type, or unindexed>): T>
If the encryption schema or manual inputs included fields with range queries enabled, list those fields and remind the user that their impact wasn't calculated.
Present advice. Don't provide any advice the user has explicitly rejected, such as suggesting different query types if they insist a field needs to allow substring queries. Only raise problems, don't mention something if it passes all checks. If you suggest changing values to a specific number, populate the Step 6 T formula template for that query type with the suggested values, calculate it with available mathematical tools, and quote only that result.
Also inform the user of the path to the qe-sizing-calculations.md file, and ask if they want to review the data, or delete the temporary file. Remind them that the temporary file contains the names of encrypted fields and their average plaintext lengths, and should be deleted once finished.
What SKILL.md sets; muted values are Claude Code's defaults
8 skills in this plugin
/mongodb-atlas-stream-processingManages MongoDB Atlas Stream Processing (ASP) workflows. Handles workspace provisioning, data source/sink connections, processor lifecycle operations, debugging diagnostics, and tier sizing. Supports Kafka, Atlas clusters, S3, Apache Iceberg (with Unity and Horizon catalogs), HTTPS, and Lambda integrations for streaming data workloads and event processing. NOT for general MongoDB queries or Atlas cluster management. Requires MongoDB MCP Server with Atlas API credentials./mongodb-connectionOptimize MongoDB client connection configuration (pools, timeouts, patterns) for any supported driver language. Use this skill when working/updating/reviewing on functions that instantiate or configure a MongoDB client (eg, when calling `connect()`), configuring connection pools, troubleshooting connection errors (ECONNREFUSED, timeouts, pool exhaustion), optimizing performance issues related to connections. This includes scenarios like building serverless functions with MongoDB, creating API endpoints that use MongoDB, optimizing high-traffic MongoDB applications, creating long-running tasks and concurrency, or debugging connection-related failures./mongodb-mcp-setupGuide users through installing and configuring the MongoDB MCP server. Use this skill when a user wants to connect their agent to MongoDB/Atlas through MCP, when the MongoDB MCP server is installed but its environment variables aren't configured, or when they don't have the server or credentials set up yet./mongodb-natural-language-queryingGenerate read-only MongoDB queries (find) or aggregation pipelines using natural language, with collection schema context and sample documents. Use this skill whenever the user asks to write, create, or generate MongoDB queries, wants to filter/query/aggregate data in MongoDB, asks "how do I query...", needs help with query syntax, or discusses finding/filtering/grouping MongoDB documents. Also use for translating SQL-like requests to MongoDB syntax. Does NOT handle Atlas Search ($search operator), vector/semantic search ($vectorSearch operator), fuzzy matching, autocomplete indexes, or relevance scoring - use search-and-ai for those. Does NOT analyze or optimize existing queries - use mongodb-query-optimizer for that. Does NOT handle aggregation pipelines that involve write operations. Requires MongoDB MCP server./mongodb-query-optimizerHelp with MongoDB query optimization and indexing. Use only when the user asks for optimization or performance: "How do I optimize this query?", "How do I index this?", "Why is this query slow?", "Can you fix my slow queries?", "What are the slow queries on my cluster?", etc. Do not invoke for general MongoDB query writing unless user asks for performance or index help. Prefer indexing as optimization strategy. Use MongoDB MCP when available./mongodb-schema-designMongoDB schema design patterns and anti-patterns. Use when designing data models, reviewing schemas, migrating from SQL, or troubleshooting performance issues caused by schema problems. Triggers on "design schema", "embed vs reference", "MongoDB data model", "schema review", "unbounded arrays", "one-to-many", "tree structure", "16MB limit", "schema validation", "JSON Schema", "time series", "schema migration", "polymorphic", "TTL", "data lifecycle", "archive", "index explosion", "unnecessary indexes", "approximation pattern", "document versioning".3 plugins in one repository ship this exact skill · first indexed Oct 10, 2026
npx claudepluginhub mongodb/agent-skills --plugin mongodbOther plugins' skills for the same job