Skip to main content

Produce comprehensive financial reports for your on-chain org

Project description

DAO Treasury is a comprehensive financial reporting and treasury management solution designed specifically for decentralized organizations. Built as an extension to eth-portfolio's Portfolio Exporter, DAO Treasury automates the collection and visualization of financial data, enabling organizations to monitor and report on treasury activities with clarity and transparency.

Key Features

  • Financial Reporting for DAOs: Extends core portfolio functionalities to generate detailed reports tailored for on-chain organizations.
  • Dashboard Provisioning: Utilizes Grafana dashboards—defined in JSON files within the .grafana/provisioning directories—to offer real-time, dynamic visualizations of treasury data.
  • Automated Data Export: Features a treasury export tool that, once configured (with a supported brownie network and Docker), continuously captures financial snapshots at set intervals.
  • Custom Buckets for Wallets: Assign custom categories ("buckets") to specific wallet addresses for more granular reporting using the --custom-bucket CLI option.
  • Ease of Contribution: Non-technical users can easily update or create dashboard visuals using Grafana’s intuitive UI. The Contributing Guidelines document provides a step-by-step guide to defining new visuals and dashboards and integrating those changes into the repository, ensuring that anyone can contribute to the visual reporting aspect of the project.

Requirements

  • Python 3.10 or higher.
  • At least 16GB of RAM.
  • All dependencies installed as specified in the project’s pyproject.toml file.

Prerequisites

  • First, you will need to bring your own archive node. This can be one you run yourself, or one from one of the common providers (Tenderly, Alchemy, QuickNode, etc.). Your archive node must have tracing enabled (free-tier Alchemy nodes do not support this option).
  • You must configure a brownie network to use your RPC.
  • You will need an auth token for Etherscan's API. Follow their guide to get your key, and set env var ETHERSCAN_TOKEN with its value.
  • You'll also need Docker installed on your system. If on MacOS, you will need to leave Docker Desktop open while DAO Treasury is running.

Debug logging

DAO Treasury relies on ypricemagic for price lookups. If you need to spot long-running price calls, enable the y.stuck? logger at DEBUG. Details: y.stuck? logger.

Installation

pip install dao-treasury

Usage

Run the treasury export tool:

# For pip installations:
dao-treasury run --wallet 0x123 --network mainnet --interval 12h

For local development (from source installation), use:

poetry run dao-treasury run --wallet 0x123 --network mainnet --interval 12h

Assigning Custom Buckets to Wallets:

You can assign custom categories ("buckets") to specific wallet addresses for more granular reporting. Use the --custom-bucket option one or more times, each with the format address:bucket_name:

dao-treasury run --wallet 0x123 --network mainnet --custom-bucket "0x123:Operations" --custom-bucket "0x456:Grants" --custom-bucket "0x789:Investments"

CLI Options:

Only optional arguments are listed here. Required arguments (such as --wallet or --wallets) are shown in the usage examples above.

  • --network: The id of the brownie network the exporter will connect to (default: mainnet)
  • --interval: The time interval between each data snapshot (default: 12h)
  • --concurrency: The max number of historical blocks to export concurrently. (default: 30)
  • --daemon: Run the export process in the background (default: False) (NOTE: currently unsupported)
  • --sort-rules: Directory containing sort rules definitions for transaction categorization.
  • --nicknames: File containing address nicknames for reporting.
  • --grafana-port: Set the port for the Grafana dashboard where you can view data (default: 3004)
  • --renderer-port: Set the port for the report rendering service (default: 8091)
  • --victoria-port: Set the port for the Victoria metrics reporting endpoint (default: 8430)
  • --start-renderer: If set, both the Grafana and renderer containers will be started for dashboard image export. By default, only the grafana container is started.
  • --custom-bucket: Assign a custom bucket/category to a wallet address for reporting. Specify as address:bucket_name. Can be used multiple times.

After running the command, the export script will run continuously until you close your terminal. To view the dashboards, open your browser and navigate to http://localhost:3004. Log in with the Grafana admin credentials you set via GF_SECURITY_ADMIN_USER and GF_SECURITY_ADMIN_PASSWORD (or enable anonymous access with DAO_TREASURY_GRAFANA_ANON_ENABLED=true).

Docker

When you run DAO Treasury, eth-portfolio will build and start 4 required Docker containers on your system. Additionally, DAO Treasury will build and start 2 more required containers:

  • grafana

    • Provides a web-based dashboard for visualizing your treasury data.
    • Pre-configured with dashboards and plugins for real-time monitoring.
    • Uses persistent storage to retain dashboard settings and data.
    • Accessible locally (default port 3004, configurable via --grafana-port).
    • Requires login by default using GF_SECURITY_ADMIN_USER and GF_SECURITY_ADMIN_PASSWORD.
    • Optional anonymous access via DAO_TREASURY_GRAFANA_ANON_ENABLED=true (Viewer-only).
    • Sign-ups are disabled for safety.
    • Validates admin credentials on startup and fails fast if they are incorrect.
    • Integrates with the renderer container for dashboard image export.
    • Loads dashboards and data sources automatically via provisioning files.
  • renderer

    • Runs the official Grafana image renderer service.
    • Enables Grafana to export dashboards as images for reporting or sharing.
    • Operates on port 8091 by default (configurable via --renderer-port).
    • Tightly integrated with the Grafana container for seamless image rendering.
    • Note: The renderer container is only started if you pass the --start-renderer CLI flag.

How it works:

  1. DAO Treasury collects and exports treasury data.
  2. Grafana displays this data in pre-built dashboards for analysis and reporting.
  3. The renderer container allows dashboards to be exported as images directly from Grafana (if enabled).

Additional Information:

  • All containers are orchestrated via Docker Compose and started automatically as needed.
  • Grafana provisioning ensures dashboards and data sources are set up out-of-the-box.
  • All dashboard data and settings are persisted for durability.
  • Dashboard images can be generated for reporting via the renderer (if enabled).

Screenshots

DAO Transactions Dashboard

image

Contributing

We welcome contributions to DAO Treasury! For detailed guidelines on how to contribute, please see the Contributing Guidelines.

Enjoy!

Project details


Release history Release notifications | RSS feed

This version

1.0.1

Download files

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

Source Distribution

dao_treasury-1.0.1.tar.gz (80.1 kB view details)

Uploaded Source

Built Distributions

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

dao_treasury-1.0.1-cp312-cp312-win_amd64.whl (281.7 kB view details)

Uploaded CPython 3.12Windows x86-64

dao_treasury-1.0.1-cp312-cp312-win32.whl (258.5 kB view details)

Uploaded CPython 3.12Windows x86

dao_treasury-1.0.1-cp312-cp312-musllinux_1_2_x86_64.whl (503.7 kB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

dao_treasury-1.0.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (505.5 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

dao_treasury-1.0.1-cp312-cp312-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl (524.6 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ i686manylinux: glibc 2.5+ i686

dao_treasury-1.0.1-cp312-cp312-macosx_11_0_arm64.whl (331.6 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

dao_treasury-1.0.1-cp311-cp311-win_amd64.whl (279.6 kB view details)

Uploaded CPython 3.11Windows x86-64

dao_treasury-1.0.1-cp311-cp311-win32.whl (257.2 kB view details)

Uploaded CPython 3.11Windows x86

dao_treasury-1.0.1-cp311-cp311-musllinux_1_2_x86_64.whl (491.3 kB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

dao_treasury-1.0.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (484.4 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

dao_treasury-1.0.1-cp311-cp311-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl (490.4 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ i686manylinux: glibc 2.5+ i686

dao_treasury-1.0.1-cp311-cp311-macosx_11_0_arm64.whl (329.8 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

dao_treasury-1.0.1-cp310-cp310-win_amd64.whl (280.1 kB view details)

Uploaded CPython 3.10Windows x86-64

dao_treasury-1.0.1-cp310-cp310-win32.whl (257.7 kB view details)

Uploaded CPython 3.10Windows x86

dao_treasury-1.0.1-cp310-cp310-musllinux_1_2_x86_64.whl (499.0 kB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

dao_treasury-1.0.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (493.3 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

dao_treasury-1.0.1-cp310-cp310-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl (498.6 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ i686manylinux: glibc 2.5+ i686

dao_treasury-1.0.1-cp310-cp310-macosx_11_0_arm64.whl (334.8 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

Details for the file dao_treasury-1.0.1.tar.gz.

File metadata

  • Download URL: dao_treasury-1.0.1.tar.gz
  • Upload date:
  • Size: 80.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for dao_treasury-1.0.1.tar.gz
Algorithm Hash digest
SHA256 a4cf477dde156ee578d4a0c8b9a3fb8eeb0ce1352c9ee13f50f1ec18e8cb2542
MD5 780c0cd8cf11dc76fd7d71fd7ca3adfb
BLAKE2b-256 a6273a6e915032f26681ecece0b7c2a744ba9da1af42e86fee3ce2ea3df102be

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 14961e22145872204620884e300a9c1514f191d6714a6b301b49598a0ad350ba
MD5 d3943f62a036d2b0aa3f549a274658e5
BLAKE2b-256 3deb29b41de4c2f75b31c548119b18194b34e40c2578ca6d16e1e310b810c4ee

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp312-cp312-win32.whl.

File metadata

  • Download URL: dao_treasury-1.0.1-cp312-cp312-win32.whl
  • Upload date:
  • Size: 258.5 kB
  • Tags: CPython 3.12, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for dao_treasury-1.0.1-cp312-cp312-win32.whl
Algorithm Hash digest
SHA256 545dcce51e2f83562010d694aada40193760cb029172dcd76e3eb95f2c782be6
MD5 307125b27f43a3ba73816a6e6f680f85
BLAKE2b-256 3eb2b1fdb8c7efdbdb667e57bd00d4dca7e0b7ac6621227d21ddcfe41744bfa9

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp312-cp312-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 b839fbecf0aab709dfec53e0a17b658a7a9242f68a420e45df447e04d1e09b64
MD5 e55d1c7a62d7a06fc4a56a628fd7083f
BLAKE2b-256 03961a8407a3e6be867e30a516daebe2744d3ac0dc942db93c438fe5556667ef

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 7da4b9571b6a76ddb7fdb0de621cdbba6450e7eede429621ca26173a3174c856
MD5 b407b7f21431daefc9d99f2452ee2aa1
BLAKE2b-256 dcc6f4f5ad31f558bfc900e15aa37e75b46f298ba5146b16f351e67d93b8ead2

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp312-cp312-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp312-cp312-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl
Algorithm Hash digest
SHA256 5ac91b67bd692ebeb7f4c307736acfb4a263e07539b22696bbc8a563f0339a0c
MD5 cb9a0e22fe5f2862e625bf9d62aac6d6
BLAKE2b-256 2425bfd7ec0182ba17713635a4fc6d85e810ffee4138fc5bc2e36d44eabcbf29

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 6165621c11b124417989677639e634d8fb586c61b04ae8b4f88fcad76de6b780
MD5 a693d0d2058b78eeabbc0a8054c78fff
BLAKE2b-256 800865b6addd43f4319b6f2f93051ea8263ede00f15cbc2897ccff7a1dcfb8d3

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 a435195d63b536b789ef48919349f8ca2610a1b7da01dddeae97be7be4a90de2
MD5 4acbb063b4c62209812a0c1707a1d36d
BLAKE2b-256 89a6ddd3297a884de3bb96417730544508765ff647c16cb7a3f81fc257dca5fd

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp311-cp311-win32.whl.

File metadata

  • Download URL: dao_treasury-1.0.1-cp311-cp311-win32.whl
  • Upload date:
  • Size: 257.2 kB
  • Tags: CPython 3.11, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for dao_treasury-1.0.1-cp311-cp311-win32.whl
Algorithm Hash digest
SHA256 dc099718b5c49508ef6916e7bac88efcc11d015ae6a9fe5dc684c8fa5b2880ca
MD5 4113583fd8052f2d5a76c343cae01120
BLAKE2b-256 c766891dc88f77f9fc3b0e5e2b3a6993a3785a366d130fce89f563a7e6d13381

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp311-cp311-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 34204388bddabf28623dde8d039e3d7fac5c9bc1a618270d847f03cfeada3a78
MD5 31916728a138b677069b71a53f556822
BLAKE2b-256 f47ded941417ffd8f8a6237101bd093f5f1c46d1c02abcd23a1f42f0c6ad936c

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 a679c9be1eaf9f97bbc9109674a2bddee7f6638c2e009ba5cabba11100c71800
MD5 88657411944512e2fe7db4f46d0c4008
BLAKE2b-256 24d1e701be795185da8aee931118c2564ecf8f39fbe7f972562d9b555bf353e9

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp311-cp311-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp311-cp311-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl
Algorithm Hash digest
SHA256 f61a64a2502f012af08e3463d0ab13b7ea8bf852141206963430bc7b73697ad1
MD5 8f57ccbf68afbcfd87c209d6fcecb45a
BLAKE2b-256 b7b6b26f1b7346f7e2acadd57917e4e2e6efd0e4f391186fd0442e94388423ee

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ac4a610cb536b50630d64e2502384f9b1bc12300c9e7d81619c4e83c3c7add0f
MD5 440beb0dc5ce64a0bdff76c2fd03afbe
BLAKE2b-256 1ddee9cb6a90ce3a24dbb9abc5913c279dd36466fb5af500111f95469631b832

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 e49718fa38bd7068479d15dd506412223be96eac05062c1332c6bd637f89f703
MD5 84a0d7a216f1c301d5f8efb4838c3b32
BLAKE2b-256 b5f6e22d056e116eade4bb19b4ba5ed75302b585c05d670d61a702dac0ef4ff6

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp310-cp310-win32.whl.

File metadata

  • Download URL: dao_treasury-1.0.1-cp310-cp310-win32.whl
  • Upload date:
  • Size: 257.7 kB
  • Tags: CPython 3.10, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for dao_treasury-1.0.1-cp310-cp310-win32.whl
Algorithm Hash digest
SHA256 8ef5032880d833a80e76932e776211eaed8352d83175fe18d9e36ba09097b3b1
MD5 ff3c00b6bdfe430b737df26c4fd17c30
BLAKE2b-256 80f99d8b0e57224ee19f11853e290f26dbfb7640f6165cbf6abcee596e25206a

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp310-cp310-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 3b68d0aff7fc9238beab6990da596f446d098a418fa5f4dbf7ae646f58fbaab1
MD5 ab34ee35d7184355d78110af99871aba
BLAKE2b-256 94f1d3b911f048c9007fbd79a144a205c2b31fc1188ea41af757cb9e4a2e40e4

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 632240521d2cd06e99314b219768aa8233fe416f4a0e099f3ef8d59b4ea82de8
MD5 ef903836b94035f328688445f1c17837
BLAKE2b-256 ea589af822c197d260fbaf5b703eb6cd70cdb8890e22f2a0320616a0fa20e670

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp310-cp310-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp310-cp310-manylinux1_i686.manylinux_2_28_i686.manylinux_2_5_i686.whl
Algorithm Hash digest
SHA256 571e03b2bc01cf8113a4b8a98e68272d24b31cbcb9167db2121cd5ad96117c3d
MD5 6b9f32c269fd6616d21307f67ce66127
BLAKE2b-256 8bdf0dd2b6020db803d3e4efc861b1b6a89178a3f45ca6f11905d3e06447d701

See more details on using hashes here.

File details

Details for the file dao_treasury-1.0.1-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dao_treasury-1.0.1-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 b8a97bd24ba49b832837dbce43a04d52baa7beb1cb8e2668654048111884c13b
MD5 ca822ea487b7eb12a89ad519182055ef
BLAKE2b-256 5ac3d4f998a42334e55077766d376e8804d3da074f7835bacace82ff019efcc4

See more details on using hashes here.

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