cosmos-setup

cosmos-setup is a command for coding agents from AzureCosmosDB/cosmosdb-claude-code-plugin. It costs 14 tokens per session (449 once invoked), scanned A, original, MIT.

A setup command for connecting the optional Azure Cosmos DB MCP Toolkit. Azure Cosmos DB is Microsoft’s cloud database service, and the toolkit lets an agent work with a live database.

In plain words
What is it for?
Use it to configure database queries, schema discovery, and vector search through the Cosmos DB toolkit.
Why use it?
It guides you through the account, toolkit, connection details, and access token needed for live database operations. The rest of the add-on can work without this connection.

Command

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 commands/azurecosmosdb/cosmosdb-claude-code-plugin/cosmos-setup
Clone the repo
git clone --depth 1 https://github.com/AzureCosmosDB/cosmosdb-claude-code-plugin

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 cosmos-setup

README.md
[![agentmods](https://agentmods.dev/badge/commands/azurecosmosdb/cosmosdb-claude-code-plugin/cosmos-setup.svg)](https://agentmods.dev/commands/azurecosmosdb/cosmosdb-claude-code-plugin/cosmos-setup)
Your own site
<a href="https://agentmods.dev/commands/azurecosmosdb/cosmosdb-claude-code-plugin/cosmos-setup"><img src="https://agentmods.dev/badge/commands/azurecosmosdb/cosmosdb-claude-code-plugin/cosmos-setup.svg" alt="Measured on agentmods" height="20"></a>
Per session 14 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 449 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 $0.00014 $0.00449
Opus 5 $0.00007 $0.00225
Sonnet 5 $0.00003 $0.00090
Haiku 4.5 $0.00001 $0.00045

Measured 5d ago against content hash 32515af2999b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cosmos-setup 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 5d 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.

commands/cosmos-setup.md · 44 lines

What it actually says

Cosmos DB MCP Setup

Help the user configure the optional Azure Cosmos DB MCP Toolkit connection. This enables live database operations (queries, schema discovery, vector search) but is not required — the plugin's skills, agent, and commands work without it.

For detailed instructions, see SETUP.md.

Steps

  1. Check prerequisites:

  2. Get connection details:

    • Ask for their deployed MCP Toolkit URL (from deployment-info.json in the MCPToolKit output)
    • Ask for their Entra App Client ID (also from deployment-info.json)
    • Help them get a JWT token by running:
      az login
      az account get-access-token --resource "YOUR-ENTRA-APP-CLIENT-ID" --query accessToken -o tsv
      
    • The --resource value is the Entra App Client ID from the MCPToolKit deployment output
  3. Set environment variables:

    • Guide them to set COSMOSDB_MCP_SERVER_URL to their toolkit URL
    • Guide them to set COSMOSDB_MCP_JWT_TOKEN to their JWT token
    • Note: JWT tokens expire after ~1 hour and need to be refreshed
  4. Create MCP config:

    • Guide them to copy .mcp.example.json to .mcp.json in their project root
    • The config references the environment variables set above
  5. Verify connection:

    • Restart Claude Code after adding .mcp.json
    • Try listing databases using the MCP tools
    • If connection fails, refer to troubleshooting in SETUP.md

$ARGUMENTS

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. 5d ago First seen · 44 lines · 14 tokens per session scan A 32515af2999b

Subscribe to this mod's changes

cosmos-setup is a command published in the GitHub repository AzureCosmosDB/cosmosdb-claude-code-plugin (2 stars, last pushed 1mo ago), licensed MIT. It adds 14 tokens to every session and 449 once invoked, about $0.0001 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.