Decentralized News Verification Infrastructure
An open-source public good for incentivizing truth on Ethereum and Optimism
Misinformation erodes trust, fuels conflict, and weakens democratic and social systems.
TruthBounty exists to turn fact-checking into a decentralized public good, powered by cryptoeconomic incentives rather than centralized authority.
This API provides the core infrastructure for:
- Community-driven news verification
- Reputation-based trust scoring
- Transparent, verifiable evidence storage
- On-chain rewards for honest participation
By aligning incentives with truth, TruthBounty enables communities to collectively defend information integrity.
TruthBounty is intentionally built within the Ethereum ecosystem and aligned with open-source public-good values:
- Ethereum β neutral, permissionless base layer
- Optimism β scalable, low-cost reward distribution
- IPFS β decentralized evidence storage
- Worldcoin ID β Sybil resistance for fair participation
- Drips Network β sustainable funding for maintainers and contributors
This API is designed to be forkable, composable, and reusable by:
- News platforms
- Civic-tech organizations
- Browser extensions
- DAO governance systems
- Research and media tooling
TruthBounty's runtime authority is Optimism/EVM. Deployed Optimism contracts and finalized canonical events are the source of protocol truth. This API indexes, projects and serves them.
- Chain: Optimism Mainnet (chain ID 10) and Optimism Sepolia (chain ID 11155420)
- Persistence: PostgreSQL via TypeORM. SQLite is a local development and test fallback only.
- Deployment and release manifest: docs/DEPLOYMENT.md
- Protocol and authorization boundaries: docs/API_AUTHORIZATION_MATRIX.md
- Contract artifact routing: docs/V2_ARTIFACT_ROUTING.md
- Legacy persistence inventory: docs/PRISMA_INVENTORY.md
Stellar appears in this repository only as the Drips Wave funding program that coordinates contributions. It is not a runtime, wallet, settlement or deployment target.
- News reports are submitted via the API
- Verifiers authenticate using Worldcoin ID
- Users stake tokens to participate in verification
- Evidence (links, screenshots, metadata) is stored on IPFS
- Reputation scores are recalculated in real time
- Smart contracts distribute rewards on Optimism
- Verification results are exposed via public API endpoints
The API is intentionally modular to support multiple frontends and clients.
- π‘οΈ Reputation-weighted verification using staked tokens
- π° ERC-20 reward distribution on Optimism
- π IPFS evidence storage with cryptographic proofs
- π Sybil-resistant authentication via Worldcoin ID
- π Real-time reputation scoring engine
- π€ AI-assisted fake-news detection (optional / pluggable)
- π Comprehensive audit trail for all critical actions
- π Complete traceability for claims, evidence, and rewards
| Aspect | Traditional Fact-Checking | TruthBounty |
|---|---|---|
| Control | Centralized | Community-driven |
| Incentives | None / Salaried | Tokenized rewards |
| Transparency | Opaque | On-chain + IPFS |
| Identity | Anonymous | Sybil-resistant |
| Trust Model | Editorial authority | Cryptoeconomic |
TruthBounty treats truth as infrastructure, not opinion.
| Technology | Purpose |
|---|---|
| NestJS | API framework |
| PostgreSQL | Primary database |
| TypeORM | ORM |
| Redis | Caching & sessions |
| Technology | Purpose |
|---|---|
| Ethereum / Optimism | Reward distribution |
| Ethers.js | Blockchain interaction |
| IPFS | Evidence storage |
| Worldcoin ID | Sybil resistance |
| Technology | Purpose |
|---|---|
| Docker | Containerization |
| GitHub Actions | CI/CD |
| Network | Role |
|---|---|
| Optimism (chain ID 10; Sepolia 11155420) | Only runtime and settlement chain |
| Optimism (chain ID 10, Sepolia 11155420) | Only runtime and settlement chain |
- Node.js 20 LTS and npm 10 (see docs/DEPLOYMENT.md)
- PostgreSQL 14+
- Redis 6+
- Git
- Worldcoin Developer Account (for ID verification)
# Clone repository
git clone https://github.com/DigiNodes/truthbounty-api.git
cd truthbounty-api
# Install dependencies
npm install
# Configure environment
cp .env.example .env
# Edit .env with your credentials including:
# - Database configuration
# - Worldcoin App ID and Action ID
# Start in development mode
npx nest start --watch
# Access API documentation at http://localhost:3000/apiPOST /identity/worldcoin/verify - Verify user with Worldcoin ID
GET /identity/worldcoin/status/:userId - Check verification status
GET /identity/worldcoin/verification/:nullifierHash - Lookup by nullifier hash
GET /blockchain/events - Get indexed blockchain events
POST /blockchain/reconcile - Trigger state reconciliation
# Run all tests
npm test
# Run Worldcoin-specific tests
npm test -- --testPathPattern=worldcoin
# Run with coverage
npm run test:covWe welcome contributors of all levels.
- Backend features & optimizations
- Security reviews & audits
- Documentation & diagrams
- API integrations
- Test coverage
- Fork the repository
- Create a feature branch
- Follow Conventional Commits
- Submit a PR with a clear description
- Participate in code review
See CONTRIBUTING.md for full guidelines.
We take security seriously. If you discover any security vulnerabilities, please refer to our Security Policy for instructions on how to report them. Please do not report security issues through public GitHub issues.
This project is licensed under the MIT License.