Commit Graph

6 Commits

Author SHA1 Message Date
primal
bd76ea1108 Trim shortener.go - keep only URL creation, remove click tracking
Click tracking now handled by tracker service.
Reduced from 250 to 79 lines.
2026-02-02 13:28:10 -05:00
primal
aea101a5e7 Update short URLs to use news.1440.news 2026-02-02 13:23:24 -05:00
primal
3f277ec165 Remove item ID column references - items now use composite PK (guid, feed_url)
- Remove ID field from Item struct
- Remove ID field from SearchItem struct
- Update all SQL queries to not select id column
- Change MarkItemPublished to use feedURL/guid instead of id
- Update shortener to use item_guid instead of item_id
- Add migration to convert item_id to item_guid in short_urls table
- Update API endpoints to use feedUrl/guid instead of itemId

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-01 23:51:44 -05:00
primal
283a221efd Use url.1440.news for shorter URLs (28 chars vs 32)
- Changed short URL format from app.1440.news/r/{code} to url.1440.news/{code}
- Added Traefik routing for url.1440.news domain
- Root handler checks Host header to route url.1440.news requests
- Legacy /r/ path still supported for backwards compatibility

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 22:52:45 -05:00
primal
1ab45033cd Use app.1440.news domain for short URLs
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 22:49:04 -05:00
primal
94d64373ed Add URL shortener for link tracking and shorter posts
- New short_urls and clicks tables for URL mapping and analytics
- /r/{code} redirect endpoint with click tracking
- Short URLs use 6-char base64 hash codes (26 chars total)
- Publish loop now shortens article links and enclosure URLs
- Enables podcast audio URLs to fit in posts (139 → 26 chars)
- Tracks: timestamp, referrer, user agent, anonymized IP

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 22:43:42 -05:00