No description
- TypeScript 75.7%
- JavaScript 17.1%
- Kotlin 3.5%
- HTML 1.5%
- Shell 1.2%
- Other 1%
|
All checks were successful
server / check (push) Successful in 36s
## Ticket [BTAPI-82](http://192.168.2.100:7123/home/browse/BTAPI-82/) Remove the wealthsimple-api migration feature flag ## Summary - Deleted the `WS_API_ENABLED` / `Config.wealthsimpleApiEnabled` migration flag and collapsed every dispatcher it gated (activity fetch, doorbell forward, `/sync/status`) onto the single wealthsimple-api path. - Deleted the direct Wealthsimple GraphQL client (`client/`, `queries.ts`), credit-card account discovery, the balance read, and their now-orphaned fixtures. `assertWealthsimpleApiClientConfig()` is now unconditional at boot. - **The sync no longer depends on the local Wealthsimple session.** The `getSessionHaltReason()` gate in `tick()` was deleted outright, not just made conditional. Production bug it fixes: the local session died on 2026-09-28 and every sync was skipped as "dead" while wealthsimple-api was healthy. - `/sync/status` is sourced solely from wealthsimple-api. The 503 / `session: 'unreachable'` contract is now live, so the app's banner (BTAPP-53) must handle it. `lastResult`/`lastError` describe wealthsimple-api's job only; a stale local `halted` is no longer surfaced. - A malformed purchase in the feed now throws `WealthsimpleApiClientError` (ordinary failure streak, no cooldown). - `ws:activities` no longer prints a balance line. - A leftover `WS_API_ENABLED=true` in the deployed `.env` is ignored and can be deleted. - Tests: flag-off suites removed; regression guards added (dead local session must not affect the sync or the status) and the amount-validation tests ported onto the feed path. CLAUDE.md and comments updated to describe the single design. ### Left for BTAPI-78 `auth/`, `discovery/`, `totp/`, `request/`, `login-cli/`, `lib/data/wealthsimple-session`, the `SessionDeadError` handling, the now-dormant 401/429 cooldown path in the sync engine, the `GraphqlError` plumbing in `errors.ts`, and `WS_EMAIL` / `WS_PASSWORD` / `WS_TOTP_SECRET`. ### Manual checks still to run - Activity sync end to end against a healthy wealthsimple-api - Doorbell ring (`POST /sync/wealthsimple`) - `GET /sync/status` - `bun --cwd=./server run ws:activities` 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_018AmPhidGQpqS7QgKUdeZ7U Reviewed-on: #96 |
||
|---|---|---|
| .claude | ||
| .devcontainer | ||
| .forgejo | ||
| .vscode | ||
| app | ||
| docs | ||
| server | ||
| .env.example | ||
| .gitignore | ||
| .prettierrc | ||
| build-apk.sh | ||
| bun.lock | ||
| CLAUDE.md | ||
| docker-compose.yml | ||
| Dockerfile.dev | ||
| Dockerfile.metro | ||
| package.json | ||
| tsconfig.json | ||