Skip to main content

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

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cosmodol-0.0.5.tar.gz (45.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cosmodol-0.0.5-py3-none-any.whl (30.6 kB view details)

Uploaded Python 3

File details

Details for the file cosmodol-0.0.5.tar.gz.

File metadata

  • Download URL: cosmodol-0.0.5.tar.gz
  • Upload date:
  • Size: 45.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.32 {"installer":{"name":"uv","version":"0.11.32","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}

File hashes

Hashes for cosmodol-0.0.5.tar.gz
Algorithm Hash digest
SHA256 355dfccf9f3d03fe7d7d5fa3cf9032c6e1f9cd5e0395c7f3da78a5ab56142457
MD5 372fb9354ea9dad511ad0103e07ae981
BLAKE2b-256 0dbbe432ce614b3cca5709cf8d4b1be89c7c582ed8eaabc5f09837785964845a

See more details on using hashes here.

File details

Details for the file cosmodol-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: cosmodol-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 30.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.32 {"installer":{"name":"uv","version":"0.11.32","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}

File hashes

Hashes for cosmodol-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 c3bcc608c28f3092e0b8ebc1e733f026168ccc827fa532c042652facccac1d13
MD5 0cfae1fec36093f05a42bc884b3af03b
BLAKE2b-256 6510a7dfb19a19360809aca0cbc13862b538b85c2e4325321580a46c77e79a8e

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.0.5 This release

2 files

0.0.4

2 files

0.0.3

2 files

0.0.2

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page