Thanks for your interest in contributing. This document covers how to set up the project, the codebase structure, and the process for submitting changes.
- Node.js 18+
- A GitHub personal access token (read-only repo scope)
- A Stellar testnet account
git clone https://github.com/Darkdruce/OpenDrip-
cd OpenDrip-
npm installcp config/.env.example config/.envFill in config/.env:
GITHUB_TOKEN=your_github_token
STELLAR_SECRET=your_stellar_secret_key
STELLAR_NETWORK=testnetnpm run devThis starts both the API (localhost:3001) and the web dashboard (localhost:3000).
Each concern lives in its own package under packages/. The API in apps/api imports from these packages directly via relative paths.
packages/
stellar/ — Stellar SDK wrappers (wallet, payments, transactions)
drips/ — Drips pool and stream management
github/ — GitHub API integration (metrics, contributors)
payments/ — Distribution engine and treasury
reputation/ — Scoring algorithm
apps/
api/ — Express REST API
web/ — Next.js dashboard
Edit packages/reputation/index.ts:
const WEIGHTS = {
commits: 1,
mergedPRs: 3,
issuesResolved: 2,
docsContributions: 1.5,
// add new metric here
};Also update ContributorMetrics interface and the GitHub fetch logic in packages/github/contributors.ts.
- Create a file in
apps/api/src/routes/yourroute.ts - Export a default Express
Router - Register it in
apps/api/src/index.ts:
import yourRouter from "./routes/yourroute";
app.use("/your-path", yourRouter);- Create a folder under
packages/yourpackage/ - Add an
index.tsthat exports the public API - Import it in other packages or routes using a relative path
./node_modules/.bin/tsc --noEmitThis checks all packages and the API. The web app has its own tsconfig.json and is checked separately by Next.js.
Tests live in tests/unit/ and tests/integration/. They are plain TypeScript files that can be run with ts-node:
npx ts-node tests/unit/scoring.test.ts
npx ts-node tests/integration/pools.test.tsWhen adding new logic, add a corresponding test file.
- Keep PRs focused — one feature or fix per PR
- Run
tsc --noEmitbefore submitting — no type errors - Update relevant docs if you change API behaviour or scoring logic
- Use clear commit messages:
feat:,fix:,docs:,refactor:
| Item | Difficulty |
|---|---|
| Drips on-chain stream integration | Hard |
| Sponsor deposit dashboard | Medium |
| Per-second payout streaming | Hard |
| Multi-repo contributor aggregation | Medium |
| DAO governance for weight config | Hard |
| AI-based contribution analysis | Medium |
| Cross-chain funding pools | Hard |
Pick one, open an issue to discuss the approach, then submit a PR.