MoneyWiz-API
A Python API to access MoneyWiz Sqlite database.
Table of Contents
Get Started
pip install moneywiz-api
from moneywiz_api import MoneywizApi
moneywizApi = MoneywizApi("<path_to_your_sqlite_file>")
(
accessor,
account_manager,
payee_manager,
category_manager,
transaction_manager,
investment_holding_manager,
) = (
moneywizApi.accessor,
moneywizApi.account_manager,
moneywizApi.payee_manager,
moneywizApi.category_manager,
moneywizApi.transaction_manager,
moneywizApi.investment_holding_manager,
)
record = accessor.get_record(record_id)
print(record)
It also offers a interactive shell moneywiz-cli.
Schema profiles
MoneywizApi resolves the default SchemaProfile from the database path when it
is constructed, then validates the profile before loading records. You do not
need to pass a profile to MoneywizApi:
from moneywiz_api import MoneywizApi
api = MoneywizApi("<path_to_your_sqlite_file>")
A SchemaProfile maps each Record field to one or more database column names
and optional converters. Field specifications are available from
moneywiz_api.schema.schema_fields, including schema_field,
datetime_field, decimal_field, nullable_decimal_field, and is_one_field.
Definitions for base classes are inherited by their subclasses. Calling
profile.validate() checks that every public dataclass field on loaded Record
subclasses has a definition; fields whose names start with _ are ignored.
To create a customized profile, start with DEFAULT_SCHEMA_PROFILE and replace
the field mapping you need:
from moneywiz_api import DEFAULT_SCHEMA_PROFILE, SchemaProfile
from moneywiz_api.model.tag import Tag
from moneywiz_api.schema.schema_fields import schema_field
column_map = {
**DEFAULT_SCHEMA_PROFILE.column_map,
Tag: {
**DEFAULT_SCHEMA_PROFILE.column_map[Tag.__name__],
"name": schema_field("CUSTOM_TAG_NAME", "ZNAME6"),
},
}
profile = SchemaProfile(column_map)
profile.validate()
SchemaProfileResolver(db_path, baseline=None).resolve() enriches a profile
with database-specific tag-join table details. When no baseline is provided, it
uses DEFAULT_SCHEMA_PROFILE. The resolved profile can be passed to MoneywizApi or the lower-level
DatabaseAccessor:
db_path = "<path_to_your_sqlite_file>"
resolved_profile = SchemaProfileResolver(db_path, profile).resolve()
api = MoneywizApi(db_path, schema_profile=resolved_profile)
SchemaProfile.create_record(row, ModelClass) resolves all public fields from
a raw row, reports field-resolution failures together, and creates the model
instance. Record
classes receive mapped field values and do not depend on SchemaProfile.
Tests
Run unit tests without a database:
uv run pytest tests/unit
Integration tests are opt-in and never read a CLI default database path. Point
MONEYWIZ_TEST_DB_PATH at a disposable MoneyWiz SQLite test database:
MONEYWIZ_TEST_DB_PATH=/absolute/path/to/test.sqlite uv run pytest tests
Contribution
This project is in very early stage, all contributions are welcomed!
Metadata
Release files for moneywiz-api 1.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| moneywiz_api-1.2.0.tar.gz | 20.1 kB | With provenance | Details for moneywiz_api-1.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| moneywiz_api-1.2.0-py3-none-any.whl | Python 3 | none | any | Details for moneywiz_api-1.2.0-py3-none-any.whl |
Total release size: 46.4 kB
Release files / moneywiz_api-1.2.0.tar.gz
| Download URL | moneywiz_api-1.2.0.tar.gz |
|---|---|
| Size | 20.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
61a5d8b98cabcdc5828e706e5a228f99e7bd2cab8600def5901ea848e9357de1
|
|
BLAKE2b-256 checksum How to use checksums |
a3632ef8fb69a110fec6c6e849b4626da2d7879ee469c6d7a6cd89b2ead6cd0c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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 28, 2026.
Transparency logRelease files / moneywiz_api-1.2.0-py3-none-any.whl
| Download URL | moneywiz_api-1.2.0-py3-none-any.whl |
|---|---|
| Size | 26.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
074589ad1b7234a018462d6475c6d6d7bfed2dd2c7610b5c499bcd4d7a969ae1
|
|
BLAKE2b-256 checksum How to use checksums |
bae7a5cd48171d812679b7ddc3446b6a9bf2fbdc4bfd66b9e5f68d0a5d10ebd4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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 28, 2026.
Transparency logSecurity for moneywiz-api 1.2.0
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
Both files in this release have been uploaded with provenance metadata.
Attestation for moneywiz_api-1.2.0.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 28, 2026.
Transparency logA 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.