fix: replace NEXT_PUBLIC_API_URL with Next.js Route Handler proxy for runtime backend URL

Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
Agent-Logs-Url: https://github.com/christianlouis/pop_puller_to_gmail/sessions/59e2f604-9ad3-46ef-8670-fd6b3b7c14b2
This commit is contained in:
copilot-swe-agent[bot]
2026-03-24 01:16:01 +00:00
parent 82b221e4ff
commit 76bf0b3f0c
5 changed files with 47 additions and 5 deletions
+1 -4
View File
@@ -1,10 +1,7 @@
import axios from "axios";
const API_BASE_URL =
process.env.NEXT_PUBLIC_API_URL || "http://localhost:8000";
const api = axios.create({
baseURL: `${API_BASE_URL}/api/v1`,
baseURL: `/api/v1`,
headers: {
"Content-Type": "application/json",
},