Skip to content

Latest commit

 

History

History
217 lines (157 loc) · 8.77 KB

File metadata and controls

217 lines (157 loc) · 8.77 KB

Documentation Index

Welcome to the Crypto Data Aggregator documentation! This guide will help you understand, use, and contribute to the project.


📚 Documentation Overview

Document Description Audience
README Project overview, quick start, features Everyone
CONTRIBUTING How to contribute to the project Contributors
API Reference Complete API endpoint documentation Developers
Swagger Docs Interactive API documentation Developers
AI Agents AI agent discoverability guide AI Developers
Archive System Historical data collection Developers
Architecture System design and data flow Developers
Tech Stack Technologies, libraries, and tools Developers
Components React component reference Developers
Data Sources External APIs and caching Developers
Development Local setup and workflow Contributors
Testing Testing guide and best practices Contributors
Deployment Production deployment guide DevOps
Performance Optimization strategies Developers
Security Security guidelines Everyone
PWA Progressive Web App features Developers
x402 Integration x402 payment protocol guide Developers
Troubleshooting Common issues and solutions Everyone
Changelog Version history and changes Everyone

🚀 Quick Links

Getting Started

For Developers

Architecture Deep Dives

Operations


🏗️ Architecture at a Glance

┌─────────────────────────────────────────────────────────────────┐
│                         Browser                                  │
│  ┌──────────────┐  ┌──────────────┐  ┌──────────────────────┐  │
│  │    React     │  │   SWR        │  │   LocalStorage       │  │
│  │  Components  │──│   Cache      │  │  (Portfolio/Alerts)  │  │
│  └──────────────┘  └──────────────┘  └──────────────────────┘  │
└────────────────────────────┬────────────────────────────────────┘
                             │ HTTP
┌────────────────────────────┼────────────────────────────────────┐
│                    Next.js Server                                │
│  ┌──────────────┐  ┌──────────────┐  ┌──────────────────────┐  │
│  │ API Routes   │──│ Memory Cache │──│  External APIs       │  │
│  │ (Edge)       │  │ (TTL-based)  │  │  CoinGecko/DeFiLlama │  │
│  └──────────────┘  └──────────────┘  └──────────────────────┘  │
└─────────────────────────────────────────────────────────────────┘

📦 Tech Stack Summary

Category Technology Version
Framework Next.js 16.x
UI Library React 19.x
Language TypeScript 5.x
Styling Tailwind CSS 4.x
Data Fetching SWR 2.x
Charts Recharts 2.x
Animations Framer Motion 12.x
Testing Vitest 4.x

View full tech stack →


🔌 API Quick Reference

Market Data

GET /api/market/coins          # Top coins by market cap
GET /api/market/coins/:id      # Single coin details
GET /api/market/history/:id    # Historical prices
GET /api/market/ohlc/:id       # OHLC candlestick data
GET /api/market/search?q=      # Search coins

DeFi

GET /api/defi                  # DeFi protocols
GET /api/defi/chains           # Blockchain TVL

Other

GET /api/sentiment             # Fear & Greed Index
GET /api/trending              # Trending coins
GET /api/charts/:id            # Chart data

View full API reference →


🎯 Feature Documentation

Portfolio Tracking

  • Store holdings locally (no account needed)
  • Track P&L, cost basis, allocation
  • Export as JSON/CSV

See: Components → Portfolio

Price Alerts

  • Set price above/below targets
  • Browser notifications
  • Persisted in localStorage

See: Components → Alerts

PWA Features

  • Installable on mobile/desktop
  • Offline browsing
  • Background updates

See: PWA Guide


🛠️ Development Workflow

  1. Setup: ./scripts/setup.sh or npm install
  2. Develop: npm run dev - Start dev server
  3. Test: npm run test - Run tests
  4. Check: npm run check-all - Lint + typecheck + test
  5. Commit: Husky runs pre-commit hooks automatically
  6. PR: Follow PR template

View full development guide →


📖 Additional Resources

External Documentation

API Provider Docs


📝 Contributing to Docs

Found an error or want to improve the docs?

  1. Fork the repository
  2. Edit files in /docs
  3. Submit a PR with your changes

Documentation follows these conventions:

  • Markdown format with proper headings
  • Code examples with syntax highlighting
  • Tables for structured data
  • Mermaid diagrams for architecture

📧 Getting Help