Skip to main content

A Python api to access moneywiz sqlite database (fork of moneywiz-api)

Project description

moneywiz-db-api

这是 moneywiz-api 的 fork 版本。 原项目已数月未更新,此版本用于持续维护和功能增强。感谢原作者 iLeoDo 的贡献。

Static Badge PyPI

A Python API to access MoneyWiz Sqlite database.

Get Started

pip install moneywiz-db-api
# 或使用 uv
uv add moneywiz-db-api
from pathlib import Path
from moneywiz_api import MoneywizApi

# macOS 默认数据库路径
DB_PATH = Path("~/Library/Containers/com.moneywiz.personalfinance"
               "/Data/Documents/.AppData/ipadMoneyWiz.sqlite").expanduser()

with MoneywizApi(DB_PATH) as api:
    # 获取所有交易
    transactions = api.transaction_manager.get_all()

    # 获取所有分类
    categories = api.category_manager.get_all()

    # 查询无分类交易
    uncategorized = api.transaction_manager.get_uncategorized()

# 或指定其他路径
with MoneywizApi(Path("/path/to/ipadMoneyWiz.sqlite")) as api:
    record = api.accessor.get_record(record_id)
    print(record)

Interactive CLI

本包提供交互式命令行工具 moneywiz-cli

# 使用默认数据库路径
moneywiz-cli

# 指定数据库路径
moneywiz-cli /path/to/moneywiz.sqlite

文档

完整接口参考(含所有 Manager 方法、数据模型字段、使用示例及 AI Agent 调用指引):

docs/api-reference.md

Contribution

This project is in very early stage, all contributions are welcomed!

Project details


Download files

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

Source Distribution

moneywiz_db_api-0.1.2.tar.gz (18.6 kB view details)

Uploaded Source

Built Distribution

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

moneywiz_db_api-0.1.2-py3-none-any.whl (27.2 kB view details)

Uploaded Python 3

File details

Details for the file moneywiz_db_api-0.1.2.tar.gz.

File metadata

  • Download URL: moneywiz_db_api-0.1.2.tar.gz
  • Upload date:
  • Size: 18.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for moneywiz_db_api-0.1.2.tar.gz
Algorithm Hash digest
SHA256 5ff558993877c483232a8e1f1a3310f9f77e4da89b09a23703506fa4dd60b12c
MD5 fedbb02648a03b05f0e9d12939cf8a48
BLAKE2b-256 d16de035a8fa0589309561307156b2c472f935bafcd11a691531cee8c0ac8140

See more details on using hashes here.

Provenance

The following attestation bundles were made for moneywiz_db_api-0.1.2.tar.gz:

Publisher: python-publish.yml on philo-veritas/moneywiz-api

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file moneywiz_db_api-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: moneywiz_db_api-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 27.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for moneywiz_db_api-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 593d7ec98d54ea1127646767510c85bc4d2964d6b17132460191eab89fe7a0f6
MD5 a92871cee9d72b495f0526bd94d0d84e
BLAKE2b-256 fa481f3a92b46997adfe53203946163f491b2d6e76bd04458ec0d7e08479fa08

See more details on using hashes here.

Provenance

The following attestation bundles were made for moneywiz_db_api-0.1.2-py3-none-any.whl:

Publisher: python-publish.yml on philo-veritas/moneywiz-api

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page