Agent skill · software engineering · sickn33

azure-cosmos-rust

Azure Cosmos DB SDK for Rust (NoSQL API). Use for document CRUD, queries, containers, and globally distributed data.

Why this skill is useful

Provides specific Rust SDK commands and patterns for interacting with Azure Cosmos DB that the AI wouldn't reliably generate on its own.

What it needs

Requires cargo installed locally. Requires azure account access. About 2k tokens when loaded. Last updated 2026-08-07. 44,571 stars on the source repository.

What this skill does

Azure Cosmos DB SDK for Rust Client library for Azure Cosmos DB NoSQL API — globally distributed, multi-model database. The examples below require a reviewed compatible crate set and replacement of every resource placeholder. Do not use production data for demonstration writes. Installation Environment Variables Authentication Client Hierarchy Client Purpose Get From -------- --------- ---------- CosmosClient Account-level operations Direct instantiation DatabaseClient Database operations client.databaseclient() ContainerClient Container/item operations database.containerclient() Core Workflow Get Database and Container Clients Create Item Read Item Replace Item Patch Item Delete Item The reviewed current API uses an async builder/container initialization and a separate explicit item ID. Preview PATCH is not a production-ready guarantee; review its selected strategy, conflict/retry behavior and request-unit cost. Official crate reference. Key Auth (Optional) Enable key-based authentication with feature flag: Best Practices 1. Always specify partition key — required for point reads and writes 2. Use intomodel()? — to deserialize responses into your types 3. Derive Serialize and Deserialize — for all document types 4. Use Entra ID auth — prefer DeveloperToolsCredential over key auth 5. Reuse client instances — clients are thread-safe and reusable The reviewed example set uses azuredatacosmos 0.37.1 and compatible Azure core/credential crates. Record and commit Cargo.lock; source/API review is not a compiler or live-service test. Reference Links Resource Link ---------- ------ API Reference https://docs.rs/azuredatacosmos Source Code https://github.com/Azure/azure-sdk-for-rust/tree/main/sdk/cosmos/azuredatacosmos crates.io https://crates.io/crates/azuredatacosmos When to Use Use when a Rust application needs Cosmos DB NoSQL item CRUD, partition-key point reads, container access or explicitly opted-in preview patching. …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills sickn33/azure-cosmos-rust--b74d56

View the source on GitHub

Browse the @skills marketplace