-
-
Notifications
You must be signed in to change notification settings - Fork 0
Home
Dave Williams edited this page Jun 16, 2025
·
2 revisions
Welcome to the comprehensive documentation for the dave.io platform - a modern serverless full-stack application built on Nuxt 3 and Cloudflare Workers with AI integration, JWT authentication, and automated OpenAPI documentation.
- New to dave.io? Start with the Overview to understand the platform's purpose and capabilities
- Developer Setup: Check out Development Environment for setup instructions
- API Usage: See API System for endpoint documentation and examples
- CLI Tools: Explore CLI Tools for development utilities
- Overview - Project introduction, features, and system purpose
- Core Architecture - Platform foundation and request processing flow
- Platform Stack - Technology stack and runtime requirements
- Data Storage & Metrics - KV storage patterns and metrics collection
- API System - Comprehensive API documentation and endpoints
- API Design & OpenAPI - Schema-first development and documentation
- AI Services - Alt-text generation and ticket management automation
- Image Processing - Image optimization and transformation
- Token Management - JWT token lifecycle and management
- URL Redirects - Short link management with analytics
- System & Health Endpoints - Monitoring and health checks
- Authentication & Security - Security overview and best practices
- JWT Authentication System - Token-based authentication with hierarchical permissions
- Security & CI/CD - Security measures and deployment pipelines
- Frontend & User Interface - Vue.js frontend architecture
- Vue Components - Component library and patterns
- Styling & Design System - Design tokens and theming
- Special Pages - Custom page implementations
- Development Environment - Setup and development workflow
- Tool Management - Development tools and configuration
- Code Quality & Linting - Code standards and quality tools
- CLI Tools - Command-line utilities and automation
- Testing & Deployment - Testing strategies and deployment processes
- Alt-text Generation: Automatic alt-text for images using Cloudflare AI (LLAVA model)
- Ticket Management: Linear ticket automation with title and description generation
- Content Enhancement: AI-powered content enrichment and optimization
-
Hierarchical JWT Permissions: Parent permissions grant child access (
apiβapi:tokens) - Token Lifecycle Management: Creation, verification, listing, and revocation via CLI
- Revocation Support: KV-based token blacklisting for security
- Cloudflare Workers: Serverless execution on global edge network
- KV Storage: Hierarchical key-value storage with metrics collection
- D1 Database: SQL database for structured authentication data
- Images Service: Global CDN with BLAKE3 content addressing
- Schema-First API Design: Zod schemas drive validation and OpenAPI docs
- CLI Tool Ecosystem: Comprehensive command-line tools for all operations
- ~3 Second Dev Startup: Fast development iteration with Bun runtime
- Comprehensive Testing: Unit, integration, and HTTP API test suites
| Layer | Technology | Purpose |
|---|---|---|
| Runtime | Bun 1.2.16 + Node.js 22.16.0 | Package management and development |
| Framework | Nuxt 3.17.5 + Nitro 2.11.12 | Full-stack Vue.js with universal server |
| Platform | Cloudflare Workers | Serverless edge computing |
| Language | TypeScript 5.8.3 | Type-safe development |
| Validation | Zod 3.25.64 | Schema validation and OpenAPI |
| Authentication | JOSE 6.0.11 | JWT token handling |
| Testing | Vitest 3.2.3 | Unit and integration testing |
| Code Quality | Biome 1.9.4 + Trunk | Formatting and multi-linting |
# System health check
curl http://localhost:3000/api/ping
# AI alt-text generation (requires authentication)
curl -H "Authorization: Bearer <token>" \
"http://localhost:3000/api/ai/alt?url=https://example.com/image.jpg"
# Image optimization (public)
curl -X POST -F "image=@image.jpg" -F "quality=80" \
http://localhost:3000/api/images/optimise
# AI ticket title generation (public)
curl -X POST -H "Content-Type: application/json" \
-d '{"description": "Fix login bug on mobile"}' \
http://localhost:3000/api/ai/tickets/title# JWT token management
bun jwt init && bun jwt create --sub "api:metrics" --expiry "30d"
# KV data operations
bun kv export --all && bun kv import backup.yaml
# Interactive API testing
bun try --auth ai alt url "https://example.com/image.jpg"
# Automated API testing
bun run test:api --ai-only --url https://dave.ioThis platform follows strict development standards:
- Schema-First Development: All APIs defined with Zod schemas before implementation
- Comprehensive Testing: Unit tests for all business logic, integration tests for APIs
- Type Safety: Full TypeScript coverage with strict configuration
- Quality Gates: Biome + Trunk linting, type checking, and test validation
- Breaking Changes Welcome: Platform prioritizes correctness over backward compatibility
For detailed development guidelines, see Development Environment and Code Quality & Linting.
Last Updated: June 16, 2025 | Commit: d5375e61