Why
On staging, POST /card-account/cards took about 25 s: KeySecure card/apply alone takes about 10 s, plus the top-up transfer and the package lookup. The shared axios client times out at 15 s, so the app showed an error even though the card had been created. A second tap could then issue a second card and charge a second fee.
Change
-
useIssueCardnow posts withtimeout: 60_000. Every other request keeps the 15 s default. - The per-request timeout is kept on the 401 refresh replay, because the replay re-sends the same config.
Tests
-
pnpm test -- src/api/card-account: 41/41 pass. The issue-post assertion now requirestimeout: 60000, and it fails if that is removed. - eslint and
pnpm type-checkare clean. - Opus gate: PASS WITH SHOULD-FIX. The should-fix: after a timeout, refresh the card list, the summary and the fiat balance on any outcome, so a created card still shows up. It follows on this branch.