cosmodol
Azure Cosmos DB Data Object Layer — access Cosmos DB through a dict-like
dol Mapping / MutableMapping interface.
To install: pip install cosmodol
Scope
cosmodol targets the NoSQL (Core / SQL) API of Azure Cosmos DB via the official
azure-cosmos Python SDK.
If your Cosmos DB account was provisioned with the MongoDB API, use
pymongo directly with
mongodol — Cosmos's MongoDB-API accounts speak the
MongoDB wire protocol, and cosmodol cannot reach them.
For Azure Blob Storage, see the sibling package
azuredol.
Quick start
from cosmodol import cosmos_store
# Single-partition store (simplest)
store = cosmos_store(
connection_string="AccountEndpoint=https://localhost:8081/;AccountKey=…",
database="mydb",
container="mycontainer",
partition_key_value="my-partition",
)
store["k1"] = {"name": "Alice", "age": 30}
store["k1"] # → {"id": "k1", "_pk": "my-partition", "name": "Alice", "age": 30}
"k1" in store # → True
del store["k1"]
See also
- Architecture (misc/docs/architecture.md) — the layered design.
- Design decisions (misc/docs/design_decisions.md) — defaults and rationale.
- Cosmos DB reference (misc/docs/cosmos_db_reference.md) — distilled SDK and service facts.
dol— the underlying data-object-layer toolkit.
Metadata
Release files for cosmodol 0.0.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| cosmodol-0.0.7.tar.gz | 60.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| cosmodol-0.0.7-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 108.4 kB
Release files / cosmodol-0.0.7.tar.gz
| Download URL | cosmodol-0.0.7.tar.gz |
|---|---|
| Size | 60.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2f66bbd75231d7028582bf6d65056ef371d359063b689f1fdc6a845e3e1b0b8c
|
|
BLAKE2b-256 checksum How to use checksums |
8c1e31b5c52181658611630a7a10be5d409122b2eab8077a16b7ce67422f5741
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.13.0 {"installer":{"name":"uv","version":"0.13.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / cosmodol-0.0.7-py3-none-any.whl
| Download URL | cosmodol-0.0.7-py3-none-any.whl |
|---|---|
| Size | 47.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
641fa7f25804e2b84103b39c3611fbe9275a80e97ff22e4cfc43891aeeb9a1e1
|
|
BLAKE2b-256 checksum How to use checksums |
a5c94b8c5bc870989888a49939b33269c508b1fd7895d50fa0ab9ba9e3f1433e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.13.0 {"installer":{"name":"uv","version":"0.13.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|