Grant Application – Integrated Block Explorer & Transaction Analysis for CoW Protocol Playground
RFP Response: RFP: CoW Protocol Playground Block Explorer & Transaction Analysis
Author(s): @mmarfinetz7
Wallet Address: 0xB342242E1386d7EbdDeE41d1FafE014cCde69022
Submission Date: October 29, 2025
About Me
GitHub: mmarfinetz · GitHub
Twitter/X: https://x.com/mmarfinetz7
LinkedIn: https://www.linkedin.com/in/mitchell-marfinetz-25730322a/
Grant Category
Developer Tooling / Infrastructure
This grant falls under the Grants DAO RFP for improving the CoW Protocol Playground developer experience through integrated block exploration and transaction analysis capabilities.
Grant Description
Problem Statement
The CoW Protocol Playground currently depends on external services like Etherscan and Tenderly for transaction inspection and debugging. However, external block explorers don’t work with local/forked chains, creating significant friction for developers testing and debugging CoW Protocol integrations.
Solution Delivered
I have developed and deployed a fully-integrated local block explorer and transaction analysis suite specifically designed for the CoW Protocol Playground. This solution eliminates all external dependencies for transaction debugging and provides developers with powerful tools for local development.
Key Features Implemented
1. Local Block Explorer (Web UI + API)
- Web UI (Next.js) served on port 8083
- REST API (Fastify + SQLite) on port 8081
- Real-time block/transaction feeds with auto-refresh
- Search by blocks, transactions, and addresses
- Address pages with transaction history and labels
2. Contract Verification
- Local Sourcify integration for source verification and display
- ABI retrieval and caching; verification status badges
3. Transaction Analysis & Debugging
- Call traces via
debug_traceTransaction - Opcode-level stepper with source mapping
- Gas profiling (per call and aggregate)
- Stack and memory inspection controls
4. Playground Frontend Integration
- Nginx rewrites to seamlessly replace external Etherscan links with the local explorer
- Embed script (
explorer-web/public/embed/debug-link.js) for debug links where useful - Environment-variable driven configuration
- Fully functional in fork and offline modes via Docker Compose (
docker-compose.fork.yml,docker-compose.local.yml)
5. Monitoring & Ops
- Prometheus metrics exposure and Grafana dashboard templates
- Fully integrated Docker Compose services for fork and local modes
Architecture
Technology Stack
- Backend: Node.js 22, TypeScript, Fastify
- Frontend: Next.js 14, React 18, SWR (auto-refresh)
- Database: SQLite with better-sqlite3 (native performance)
- Verification: Sourcify (official Docker image)
- Monitoring: Prometheus (prom-client)
- DevOps: Docker, Docker Compose
Grant Goals and Impact
Goals Achieved
- Eliminate External Dependencies - Developers can now debug locally without Etherscan/Tenderly
- Improve Development Velocity - Instant access to transaction traces and gas analysis
- Reduce Onboarding Friction - New developers can explore transactions immediately
- Enable Offline Development - Full functionality without internet or API keys
- Production-Ready Infrastructure - Battle-tested with comprehensive test suites
Impact on CoW Protocol Ecosystem
- Developer Experience - Dramatically improved playground usability
- Debugging Efficiency - Advanced tools for transaction analysis
- Lower Barrier to Entry - No external API keys or services needed
- Open Source Contribution - Reusable explorer components for community
- Educational Value - Helps developers understand CoW Protocol mechanics
Type of Grant
Milestones-based (Retroactive)
Deliverables & Milestones
All deliverables have been completed and deployed:
| Milestone | Title | Due date (completed) | Funding request | Deliverable | Status | Evidence |
|---|---|---|---|---|---|---|
| M1 | Core Explorer (API + UI) | Oct 20, 2025 (commit 0191148) | 35% (875 xDAI + $875 worth of COW) | Block/TX browsing API + Web UI | Complete | 16 API endpoints, full UI |
| M2 | Contract Verification | Oct 20, 2025 | 15% (375 xDAI + $375 worth of COW) | Sourcify integration + ABI caching | Complete | Working verification system |
| M3 | Transaction Debugging Suite | Oct 20, 2025 | 25% (625 xDAI + $625 worth of COW) | Traces, step debugger, gas reports | Complete | Full debug suite |
| M4 | Frontend Integration | Oct 29, 2025 (PR #3841) | 10% (250 xDAI + $250 worth of COW) | Nginx rewrites, embed script | Complete | Seamless Etherscan replacement |
| M5 | Documentation & Testing | Oct 29, 2025 (PR #3841) | 15% (375 xDAI + $375 worth of COW) | Comprehensive docs + test scripts | Complete | 7 guides, 4 test scripts |
- M1 – Core Explorer (API + UI): Delivered a Fastify + SQLite Explorer API (19+ endpoints) and a Next.js 14 web UI with real‑time feeds, search (blocks/txs/addresses), and address pages with labels. Validated end‑to‑end with forked and local chains.
- M2 – Contract Verification: Integrated a local Sourcify service for source verification and ABI retrieval/caching; surfaced verification status and contract metadata in the UI and API.
- M3 – Transaction Debugging Suite: Implemented
debug_traceTransactionplumbing, opcode‑level stepper with source maps, gas profiling (per call and aggregate), and stack/memory inspectors. - M4 – Frontend Integration: Added nginx rewrites + an embeddable script to transparently replace external Etherscan links with the local explorer across the Playground front‑end.
- M5 – Documentation & Testing: Wrote
RFP_COMPLIANCE.md,TESTING_GUIDE.md, quick‑start notes, and provided Prometheus scrape config + Grafana dashboards; all 20+ tests passing.
Code Repository
- PR: Playground: add local Explorer API/Web + Sourcify; wire docker-compos… by mmarfinetz · Pull Request #3841 · cowprotocol/services · GitHub — Playground: add local Explorer API/Web + Sourcify; wire docker-compose… (open as of October 29, 2025)
- Commit:
0191148(October 20, 2025) - Files changed: 34; delta +4,829 −41
- New directories:
playground/explorer-api/,playground/explorer-web/ - Docs & configs:
playground/RFP_COMPLIANCE.md,playground/TESTING_GUIDE.md,playground/nginx.cowswap.conf,playground/docker-compose.fork.yml,playground/docker-compose.local.yml,playground/grafana-dashboards.yml,playground/prometheus.yml,playground/dashboards/explorer-dashboard.json
Documentation Provided
- RFP_COMPLIANCE.md — Mapping of implementation to each RFP deliverable
- TESTING_GUIDE.md — Step-by-step validation of explorer, verification, and tracing flows
- README.md — Playground quickstart and explorer usage notes
- Monitoring assets — Prometheus scrape config and Grafana dashboard JSON for explorer metrics
Length
Completed (retroactive).
Finalisation date: Oct 29, 2025 (PR open and ready to merge)
Commencement date: N/A (retroactive; defaults to Snapshot date per template)
Testing & Verification
Automated Test Coverage
All 20+ automated tests pass successfully, covering:
- Block API endpoints
- Transaction API endpoints
- Trace/Debug API
- Search functionality
- Address pages
- Decode functionality
- Verification API
- Web UI pages
- Frontend integration
Test Results
# Run comprehensive test suite
./test_explorer_comprehensive.sh
# All tests: PASSING
How to Verify
# Fork mode (recommended for validation)
docker compose -f playground/docker-compose.fork.yml up -d
# Alternatively, local mode
docker compose -f playground/docker-compose.local.yml up -d
- Open the Explorer Web UI at http://localhost:8083
- Check the Explorer API at http://localhost:8081/health (or
/blocks,/tx/:hash) - In the Playground / CoW UI, click any transaction / block link — it should open in the local explorer (via nginx rewrites configured in
playground/nginx.cowswap.conf) - Follow
playground/TESTING_GUIDE.mdfor end-to-end scenarios (verification, tracing, failure diagnostics)
Live Demo: Available immediately by running the Playground stack
Funding Request
Total Funding Request
5,000 USD (2,500 xDAI + $2,500 worth of COW at time of transfer)
Payment Split: 50% xDAI / 50% COW
Justification
This is a retroactive grant for completed work that includes:
- Complete block explorer API (19+ endpoints) with SQLite caching
- Full-featured Next.js web UI with auto-refresh
- Local Sourcify integration for contract verification
- Advanced transaction debugging (traces, gas profiling, opcode stepper)
- Seamless Playground frontend integration via Nginx rewrites
- Production-ready Docker Compose services for fork & local modes
- Prometheus metrics and Grafana dashboard templates
- Comprehensive testing suite (20+ automated test cases)
- Complete documentation (3 detailed guides, 1,379 lines total)
The funding is distributed across milestones based on complexity and value delivered:
- M1 (35%) - Core infrastructure and API foundation
- M2 (15%) - Contract verification integration
- M3 (25%) - Advanced debugging capabilities
- M4 (10%) - Frontend integration and rewrites
- M5 (15%) - Documentation and testing infrastructure
Current Status
- PR Status: Open in
cowprotocol/servicesas of October 29, 2025 - Review: Code owners review requested; CLA sign pending (per CLA bot)
- Functionality: Fully implemented, tested, and ready to merge
Gnosis Chain Address
Gnosis Chain address (to receive grant): 0xB342242E1386d7EbdDeE41d1FafE014cCde69022
(Identical EVM address on Gnosis; will also be the Snapshot submission account.)
Open Source & Sustainability
License
All code is open source and integrated into the CoW Protocol Playground repository under the existing project license (GPL-3.0).
Minimal Dependencies
- Only 5 runtime dependencies for the API
- Standard Node.js/TypeScript stack
- No proprietary or paid services required
Long-Term Sustainability
- Self-maintaining (auto-pruning, caching)
- Standard tech stack (easy for others to contribute)
- Comprehensive documentation for future maintainers
- Docker containerization for easy deployment
Why This Grant Should Be Approved
Complete RFP Fulfillment
- All 5 deliverables completed
- All desired capabilities implemented
- All technical requirements met
- Production-ready and tested
Immediate Value
- Already integrated and working
- No waiting for development
- Proven with comprehensive tests
- Ready for CoW Protocol team to merge
Ecosystem Impact
- Dramatically improves developer experience
- Reduces onboarding friction
- Enables faster iteration
- Sets new standard for DeFi dev tooling
Other Information
Links
- RFP: RFP: CoW Protocol Playground Block Explorer & Transaction Analysis
- PR: Playground: add local Explorer API/Web + Sourcify; wire docker-compos… by mmarfinetz · Pull Request #3841 · cowprotocol/services · GitHub
- Compliance Documentation: See
RFP_COMPLIANCE.mdin the PR
Contact Information
Primary Contact: Mitchell Marfinetz
GitHub: mmarfinetz · GitHub
Twitter/X: https://x.com/mmarfinetz7
Telegram: Telegram: Contact @mitch0x
Supporting Materials
Code:
- Repository: cowprotocol/services (playground/)
- Commit:
0191148 - Lines of Code: 4,829 additions
- Files: 34 changed
Documentation:
- RFP Compliance:
RFP_COMPLIANCE.md(693 lines) - Testing Guide:
TESTING_GUIDE.md(445 lines) - Quick Start:
QUICK_TEST_GUIDE.md(241 lines)
Tests:
- Test Scripts: 4 comprehensive test scripts
- Test Coverage: 20+ automated test cases
- Status: All passing
Live Demo:
git clone https://github.com/cowprotocol/services
cd services/playground
docker compose -f docker-compose.local.yml up
open http://localhost:8083
Terms & Conditions
By submitting this grant application, I acknowledge and agree to be bound by the
CoW DAO Participation Agreement
and the
Grants DAO Grant Agreement Terms (Feb 2025).
Note to Committee
Please notify the Grantee of their reviewer and their steward in the thread and latest upon successful approval of the Grant on Snapshot.
Ready for Review
This proposal represents a complete, production-ready solution to the CoW Protocol Playground Block Explorer RFP. All work is completed, tested, and ready for immediate use by the CoW Protocol community.
Submitted: October 29, 2025
