TinyShip 2.10.0 Released
This release matches GitHub v2.10.0: lifetime already-owned protection, per-user AI rate limiting, and user API keys. The Cloudflare edition tinyship-cf is synchronized at 1.3.0 (aligning those three items; still without #50 AI credit billing / video task tables).
Highlights
- Lifetime already owned: If the account already has lifetime access, initiate/resume returns
lifetime_already_owned(HTTP 409); the pricing page shows an "Already owned" CTA to the Dashboard; credit packs and time-limited plans remain purchasable (#55) - Per-user AI rate limit: Chat, image, and video share a fixed window (default 20 requests / 60s, overridable via
AI_RATE_LIMIT_*/config/ai.ts); over-limit responses are 429 +Retry-After; newai_rate_limittable (main-repo migration 0009, independent of credit billing) (#56) - User API keys: The Dashboard can create, list, and revoke
tsk_keys (hashed only, max 5); AI chat / image / video acceptAuthorization: Bearer tsk_…or a session; an invalid or revoked Bearer does not fall back to cookies (401); main-repo migration 0010 (#57)
Testing
- Lifetime: unit tests + Playwright (Next / Nuxt / TanStack)
- Rate limit:
tests/unit/ai/rate-limit.test.ts - API Key:
pnpm ai:check+ Playwrightapi-keys.spec.ts(4/4 on each framework)
Upgrade
This release includes database changes (0009_ai_rate_limit and 0010 API Key on the main repo). Migrate before deploying:
pnpm db:migrate # PostgreSQL
pnpm db:migrate:sqlite # SQLite / D1Environments initialized with db:push that have an empty migration history table should not switch directly to running a full migrate, as this will attempt to recreate tables starting from 0000.
On tinyship-cf 1.3.0 the corresponding migrations are 0008 (rate limit) and 0009 (API Key), because CF has not yet synchronized the main repo's ai_video_task 0008.