Inspiration

Every Linux machine runs software written by people it never directly pays.

My Debian machine has 3,564 installed packages built from 1,856 source packages, yet I couldn't easily identify who maintains most of the software I depend on.

Open-source funding has a visibility problem. Even when organizations want to give back, they face three questions: which projects should be funded, who should receive the money, and how can the distribution be trusted?

Dividend answers one question: "What does this machine run on, and who should be paid for it?"

What it does

  1. Scan: Discover installed Debian/Ubuntu packages and their source packages.
  2. Map: Connect source packages to their upstream software projects.
  3. Allocate: Distribute a monthly budget using deterministic, versioned rules, with project caps, minimum payouts, and cent-exact calculations.
  4. Reserve: Keep funding for projects without opted-in maintainers as reserved amounts rather than paying unverified recipients.
  5. Review: Let donors inspect project allocations, contribution evidence, and funding reasons before approval.
  6. Fund: Use PayPal Orders for donor-approved funding and PayPal Payouts for eligible maintainer distributions, with individual payout status tracking.

How AI and PayPal are used

AI — DeepSeek through Modal

Dividend integrates DeepSeek-V4.1-Flash-1017, hosted on Modal, for AI-powered Evidence Review.

The model analyzes supplied contributor and pull-request records to:

  • Generate executive summaries of contributor activity.
  • Distinguish merged pull requests from code review participation.
  • Highlight contributor contributions and supporting PR evidence.
  • Help donors understand the evidence behind funding decisions.

AI assists with interpreting evidence; it does not calculate funding amounts, approve proposals, or execute payments. Those responsibilities remain with Dividend's deterministic allocation and payment workflows.

PayPal — PayPal Developer Platform (Sandbox)

Dividend uses PayPal as its payment infrastructure to move from an approved funding proposal to trackable payment operations.

The integration uses the following PayPal capabilities:

  • PayPal Sandbox REST API and OAuth 2.0: Authenticates Dividend's backend with PayPal using Sandbox business account credentials.
  • Orders v2 API: Creates a PayPal order for the donor-approved funding proposal. The donor is redirected to PayPal to review and approve the payment.
  • Order Capture API: Captures the approved order explicitly after the donor's approval. Dividend records the capture result and reconciles the payment details and applicable fees.
  • Payouts API: Creates payout batches to distribute funds to configured maintainer recipients. Each recipient is represented by an individual payout item.
  • Payout Item Status API: Checks individual payout outcomes, including successful, pending, failed, and unclaimed states. A successful batch does not automatically mean every recipient has received their money.
  • Reconciliation and idempotency: Tracks payment operations, uses request identifiers to protect against duplicate operations, and reconciles uncertain outcomes before retrying.

How PayPal fits into the funding workflow

  1. The donor reviews the funding proposal and its allocation breakdown.
  2. Dividend calculates the amount to charge, accounting for applicable payment fees.
  3. The donor approves the proposal, and Dividend creates a PayPal order.
  4. The donor approves the order through the PayPal Sandbox checkout.
  5. Dividend explicitly captures the approved payment.
  6. Where configured, Dividend initiates maintainer payouts through PayPal Payouts.
  7. Dividend tracks individual payout statuses and records financial operations in its persistent ledger.

How I built it

Dividend is a modular monolith built with Python, FastAPI, SQLAlchemy, SQLite, React 19, TypeScript, and Vite, with Docker support.

I designed the financial workflow around deterministic calculations, explicit donor approval, persistent records, and an auditable ledger.

The allocation engine accounts for project funding, reserved amounts, and payment fees so that intended maintainer allocations are not silently reduced by transaction costs.

I used Codex as a development assistant while designing, implementing, and testing the application.

Challenges

  • Package mapping: One upstream project can produce multiple Debian source packages, making accurate mapping essential.
  • Maintainer attribution: Discovering a repository does not automatically establish who should receive funding.
  • PayPal payout states: A batch can report SUCCESS while an individual payout remains UNCLAIMED.
  • Payment fees: Fixed and percentage-based fees require careful calculations.
  • Payment reliability: Unknown payment outcomes must be reconciled before retrying.
  • Incomplete funding metadata: Reliable maintainer identity and donation information are not available for every project.

What I learned

The biggest lesson was to keep financial decisions deterministic and use AI where interpretation is useful.

A strict evidence-validation approach is more reliable than trusting an AI-generated answer blindly. I also learned that payment success must be verified at the individual transaction level.

Honest limitations

Dividend currently demonstrates payments using PayPal Sandbox, not real-money transactions.

Maintainer records in the demo are synthetic, and opt-in is simulated. The current AI Evidence Review analyzes supplied contributor evidence; broader live GitHub evidence collection and automated upstream resolution still need further integration.

Production use would require verified maintainer identities, a real claim and consent workflow, and eligibility and approval for live PayPal Payouts.

What's next

  • Live GitHub contribution evidence for maintainer attribution.
  • Automated and validated upstream project resolution.
  • Verified maintainer claim and opt-in workflows.
  • Organizational funding and pledge reporting.

Dividend aims to make open-source funding more transparent, explainable, and accountable—because the software we depend on deserves a sustainable ecosystem.

Built With

Share this project:

Updates

Submission history