Skip to main content

dhis2w-core

Shared runtime for dhis2w-cli and the dhis2w-mcp MCP server: profile discovery, plugin registry, auth factory, token store, and the first-party plugins (metadata, data, analytics, users, tracker, files, messaging, apps, route, maintenance, doctor, customize, system, profile, dev).

dhis2w-core is the bridge between dhis2w-client (the pure async API client) and the user-facing surfaces (CLI, MCP). End users typically don't install this directly — they install dhis2w-cli or dhis2w-mcp (the MCP plugin pack, in its own repository), which pull dhis2w-core in transitively.

Install

# Direct (rare — usually you want dhis2w-cli or dhis2w-mcp instead)
uv add dhis2w-core

What's in the box

  • Profile system — auto-discovers a profile from .dhis2/profiles.toml (CWD walk-up) or ~/.config/dhis2/profiles.toml. Profile model + profile_from_env() env-var fallback.
  • Plugin host — a pluginkit manager that walks dhis2w_core.v{41,42,43,44}.plugins.* plus the dhis2w.plugins.v1 entry-point group for external packs. Each plugin answers the contribute(version_key) extension point with a Contribution naming its CLI and MCP modules.
  • Auth factory — turns a Profile into the matching AuthProvider from dhis2w-client, wires the token store, manages OAuth2 PKCE redirect capture.
  • Token store — SQLite-backed (aiosqlite) at .dhis2/tokens.sqlite, keyed by profile name.
  • open_client(profile) context manager — the canonical "give me a connected client" entry point for plugin services.

Plugins shipped

metadata, data, analytics, tracker, user, user_group, user_role, route, apps, messaging, files, maintenance, doctor, customize, system, profile, dev, browser (CLI-only, opt-in via [browser] extra).

Each plugin lives at packages/dhis2w-core/src/dhis2w_core/v{41,42,43,44}/plugins/<name>/ (per-version subpackage; one tree per DHIS2 major) with service.py (typed business logic) and cli.py (Typer commands). The plugin's FastMCP tools live in the dhis2w-mcp pack as dhis2w_mcp/tools/v{N}/<name>.py — both surfaces call the same service.py.

Documentation

Full architecture: https://winterop-com.github.io/dhis2w/architecture/overview/.

dhis2w-core is one member of the dhis2w workspace.

Metadata

Release files for dhis2w-core 1.32.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for dhis2w-core 1.32.1
File Size Uploaded Provenance
dhis2w_core-1.32.1.tar.gz 781.5 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for dhis2w-core 1.32.1
File Interpreter ABI Platform
dhis2w_core-1.32.1-py3-none-any.whl Python 3 none any Details

Total release size: 1.7 MB

Release files / dhis2w_core-1.32.1.tar.gz

Download URL dhis2w_core-1.32.1.tar.gz
Size 781.5 kB
Tags Source
SHA-256 checksum
How to use checksums
b2e8e2cbe837874266353e41b7964904f099aad2488027693604e44a5402828b
BLAKE2b-256 checksum
How to use checksums
17fb3d4ff8d64e698041ec2089b1636e2461f6517b5c401d8c96cb9c9e3e9584
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 18, 2026.

Transparency log

Release files / dhis2w_core-1.32.1-py3-none-any.whl

Download URL dhis2w_core-1.32.1-py3-none-any.whl
Size 940.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
73e212abdecca15087e8d5ad0c8747f058a42b702e1eec58c59042cbba7aa7cc
BLAKE2b-256 checksum
How to use checksums
9cc5e02419adbac2d8de49a3df72b1f988c2272a284f299c7ff7c0622d50a1f3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 18, 2026.

Transparency log

Security for dhis2w-core 1.32.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for dhis2w_core-1.32.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 18, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.32.1 This release

2 release files Full provenance

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