fix(front): correct the API base URL env var name (WO-01) - #115
Merged
Conversation
The client read `NEXT_PUBLIC_API_URL`, but `.env.example:33` and `docs/DEPLOYMENT.md:62` (Vercel step 3) both fix the name as `NEXT_PUBLIC_API_BASE_URL`. Because of the `?? "http://localhost:8000"` fallback the mismatch failed silently: no build or runtime error, just every deployed API call going to localhost. Default value kept unchanged, so local development is unaffected. Refs #82 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
…API base URL Next.js loads env files from the Next project root (frontend/), not from the repo root, so the documented `cp .env.example .env` never reaches the browser bundle. The mistake is invisible locally because the fallback in api.ts is the same http://localhost:8000 the template sets — it only bites when pointing the frontend at a non-local backend. Adds the template, negates it in frontend/.gitignore (Next's default `.env*` would swallow it), and points README step 2 at it. Found while implementing #82; fixed here rather than tracked separately. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
7 tasks
This was referenced Jul 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Corrects the frontend's API base URL environment variable name:
NEXT_PUBLIC_API_URL→NEXT_PUBLIC_API_BASE_URL, and addsfrontend/.env.local.exampleso Next.js picks it up.One variable name. The effect is that the deployed frontend stopped talking to
localhost.Why
Closes #82
How IBM Bob helped
Claude Code agents under the dispatch protocol from the completeness audit: one executor per work order in a cold context, and an independent verifier that receives only the Definition of Done.
Screenshots / output
n/a — configuration change. The verifiable criterion is that the deployed frontend points at the real backend rather than
localhost.Checklist
make test)make lint)docs/.env.exampledocs/api_contract.yamlREADME.mdupdated