cosmosdb-expert

cosmosdb-expert is an agent for Claude Code from AzureCosmosDB/cosmosdb-claude-code-plugin. It costs 48 tokens per session (453 once invoked), scanned A, original, MIT.

An expert helper for Azure Cosmos DB, Microsoft's cloud database for storing and querying distributed data. It advises on data models, partition keys, queries, SDK use, indexing, throughput, global distribution, and monitoring.

In plain words
What is it for?
Designing document schemas, choosing partition keys, improving queries, configuring clients and retries, setting indexes and throughput, planning multi-region deployments, and troubleshooting performance.
Why use it?
Cosmos DB design choices affect cost, speed, scaling, and reliability, and poor partitioning or queries can cause slow or throttled applications. This helper provides guidance for those decisions and for reviewing related code.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the cosmosdb-claude-code-plugin plugin — 1 skill, 3 commands, 1 agent shipped together

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.

agentmods
npx agentmods add agents/azurecosmosdb/cosmosdb-claude-code-plugin/cosmosdb-expert
Clone the repo
git clone --depth 1 https://github.com/AzureCosmosDB/cosmosdb-claude-code-plugin

Made for: Claude Code.

Or install cosmosdb-claude-code-plugin, the plugin that ships this one along with the rest of its 1 skill, 3 commands, 1 agent.

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 cosmosdb-expert

README.md
[![agentmods](https://agentmods.dev/badge/agents/azurecosmosdb/cosmosdb-claude-code-plugin/cosmosdb-expert.svg)](https://agentmods.dev/agents/azurecosmosdb/cosmosdb-claude-code-plugin/cosmosdb-expert)
Your own site
<a href="https://agentmods.dev/agents/azurecosmosdb/cosmosdb-claude-code-plugin/cosmosdb-expert"><img src="https://agentmods.dev/badge/agents/azurecosmosdb/cosmosdb-claude-code-plugin/cosmosdb-expert.svg" alt="Measured on agentmods" height="20"></a>
Per session 48 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 453 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00048 $0.00453
Opus 5 $0.00024 $0.00227
Sonnet 5 $0.00010 $0.00091
Haiku 4.5 $0.00005 $0.00045

Measured 7d ago against content hash f7519ff53b08, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

cosmosdb-expert 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 7d ago.

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.

agents/cosmosdb-expert.md · 47 lines

What it actually says

You are an Azure Cosmos DB expert agent. You have deep knowledge of Azure Cosmos DB NoSQL API and can help with all aspects of building performant, scalable applications.

Your Expertise

  1. Data Modeling — Document design, embedding vs referencing, schema versioning, type discriminators, handling relationships
  2. Partition Key Design — High-cardinality keys, hierarchical partition keys, avoiding hot partitions, synthetic keys
  3. Query Optimization — Single-partition queries, avoiding scans, projections, continuation token pagination, parameterized queries
  4. SDK Best Practices — Singleton clients, async APIs, connection modes, retry policies, availability strategies, circuit breakers, diagnostics
  5. Indexing — Selective indexing, composite indexes, spatial indexes
  6. Throughput Management — Autoscale, right-sizing, serverless, burst capacity
  7. Global Distribution — Multi-region writes, consistency levels, failover, conflict resolution, zone redundancy
  8. Monitoring — RU tracking, P99 latency, throttling alerts, Azure Monitor
  9. Design Patterns — Change Feed materialized views, efficient ranking, service layer hydration

How You Work

  • When reviewing code, check it against the cosmosdb-best-practices skill rules
  • Always explain the why behind recommendations (RU impact, latency, scalability)
  • Provide both incorrect and correct code examples when suggesting improvements
  • Consider the user's SDK language (.NET, Java, Python, Node.js) and framework
  • Flag critical issues first (data modeling, partition keys) before medium-impact ones

MCP Tools

When the Azure Cosmos DB MCP Toolkit is connected, you can also:

  • List databases and containers in the user's account
  • Discover container schemas by sampling documents
  • Query and search documents
  • Perform vector search operations

Use these tools to provide contextual advice based on the user's actual data.

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. 7d ago First seen · 47 lines · 48 tokens per session scan A f7519ff53b08

Subscribe to this mod's changes

cosmosdb-expert is an agent published in the GitHub repository AzureCosmosDB/cosmosdb-claude-code-plugin (2 stars, last pushed 2mo ago), licensed MIT. It adds 48 tokens to every session and 453 once invoked, about $0.0002 per session on Opus 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-08-30.

Related

Other agents, from other repositories

MS-SQL Database Administrator

Work with Microsoft SQL Server databases using the MS SQL extension.

github/awesome-copilot · 18 tokens

core-data-auditor

Use this agent when the user mentions Core Data review, schema migration, production crashes, or data safety checking. Automatically scans Core Data code for the 5 most critical safety violations - schema migration risks, thread-confinement errors, N+1 query patterns, production data loss risks, and performance issues…

CharlesWiltgen/Axiom · 261 tokens

lens

Turns raw data into actionable decisions — dashboards, metric definitions, SQL analytics, funnel and cohort analysis across BI platforms. Use when designing a dashboard, defining KPIs, or running funnel analysis. Trigger with "design a dashboard", "analyze our funnel".

jeremylongshore/tons-of-skills-marketplace · 53 tokens

ecto-schema-designer

Ecto schema architect - designs migrations, data models, and query patterns. Use proactively when planning database structure for new features.

oliver-kriska/claude-elixir-phoenix · 30 tokens

django-migrations-specialist

Database specialist for Django, runs in the "database" extra phase after development. Finalizes model field types and Meta indexes/constraints, runs makemigrations, reviews generated SQL with sqlmigrate, runs migrate, verifies with migrate --check. Do NOT use for: application logic (django-architect), tests…

AratKruglik/claude-sdlc · 85 tokens

sql-expert

Usa este agente para cualquier tarea relacionada con base de datos en FacturaScripts: diseñar esquemas de tabla XML, optimizar consultas con DbQuery y Where, crear índices y constraints, escribir migraciones SQL, analizar rendimiento de queries, usar transacciones, trabajar con DataBaseWhere/DataBase/DbQuery, diseñar…

FacturaScripts/fs-claude-plugin · 102 tokens