Bare npm run dev (including hosted preview sessions) has no portless route, so the previous default target https://wygj-api.localhost was unreachable and every API call failed with HTTP 500. scripts/dev.sh now passes VITE_PROXY_TARGET explicitly, keeping the portless flow intact.