summaryrefslogtreecommitdiff
path: root/Biz/PodcastItLater/DESIGN.md
blob: 29c483733478777c4bfce60ee3510f1f090747a0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# PodcastItLater Design & Architecture

## Overview
Service converting web articles to podcast episodes via email/web submission.

## Architecture
- **Web**: `Biz/PodcastItLater/Web.py` (Ludic + HTMX + Starlette)
- **Worker**: `Biz/PodcastItLater/Worker.py` (Background processing)
- **Core**: `Biz/PodcastItLater/Core.py` (DB & Shared Logic)
- **Billing**: `Biz/PodcastItLater/Billing.py` (Stripe Integration)

## Key Features
1.  **User Management**: Email-based magic links, RSS tokens.
2.  **Article Processing**: Trafilatura extraction -> LLM cleanup -> TTS.
3.  **Billing (In Progress)**: Stripe Checkout/Portal, Freemium model.

## Path to Paid Product (Epic: t-143KQl2)

### 1. Billing Infrastructure
- **Stripe**: Use Stripe Checkout for subs, Portal for management.
- **Webhooks**: Handle `checkout.session.completed`, `customer.subscription.*`.
- **Tiers**:
    - `Free`: 10 articles/month.
    - `Paid`: Unlimited (initially).

### 2. Usage Tracking
- **Table**: `users` table needs `plan_tier`, `subscription_status`, `stripe_customer_id`.
- **Logic**: Check usage count vs tier limit before allowing submission.
- **Reset**: Usage counters reset at billing period boundary.

### 3. Admin Dashboard
- View all users and their status.
- Manually retry/delete jobs.
- View metrics (signups, conversions).

## UX Polish (Epic: t-1vIPJYG)
- **Mobile**: Ensure all pages work on mobile.
- **Feedback**: Better error messages for failed URLs.
- **Navigation**: Clean up navbar, account management access.

## Audio Improvements
- **Intro/Outro**: Add metadata-rich intro ("Title by Author").
- **Sound Design**: Crossfade intro music.