Commit Graph
5 Commits
Author SHA1 Message Date
Ivan Pereira 501935fe1c Simplify auth and search client, drop local JWT expiry tracking
Auth:
- Remove jwt.ts — stop decoding JWT exp claims locally
- Simplify OTP login: direct token extraction from verify response,
  remove CookieJar, BFS token extraction, session fallback, CF bypass
- Storage: drop expires field, store token-only; clear on 401/403
- Single auth path: try stored token → macOS app → OTP fallback

Search client:
- Remove Cloudflare subprocess fallback (fetchViaBunRuntime)
- Remove streamFromText, isCloudflareChallenge, BunFetchResult
- Simplify SSE fetch to single fetch() call with abort signal
- Let server validate tokens; clear cache on auth errors

Render:
- Extract shared utilities (asString, truncate) to render/util.ts
- Simplify call.ts and result.ts to import from shared module

Tests:
- Remove jwt.test.ts (module deleted)
- Add otp-flow.test.ts for email OTP authentication
- Simplify login and client tests for reduced code paths

Add debug scripts and plan documents.
2026-02-18 08:03:39 +00:00
Ivan Pereira f42531b07c Implement perplexity login/render modules and harden OAuth search flow 2026-02-17 08:25:56 +00:00
Ivan Pereira 39b8ee6b57 Add OTP fallback auth and progress handoff log 2026-02-16 18:51:09 +00:00
Ivan Pereira 86b0c37a08 Add .gitignore, untrack .env and node_modules 2026-02-16 18:44:09 +00:00
Ivan Pereira 47878d9962 Initial commit 2026-02-16 18:42:03 +00:00