From 0ade88c6d893c186dee3605b4a4a195615185401 Mon Sep 17 00:00:00 2001 From: kimsubsub Date: Thu, 14 May 2026 23:28:19 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20Vercel=20API=20=ED=94=84=EB=A1=9D?= =?UTF-8?q?=EC=8B=9C=20rewrite=20=EB=B3=B4=EA=B0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/be1.js | 8 ++++++++ api/be3.js | 8 ++++++++ vercel.json | 4 ++-- 3 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 api/be1.js create mode 100644 api/be3.js diff --git a/api/be1.js b/api/be1.js new file mode 100644 index 0000000..13e0ea6 --- /dev/null +++ b/api/be1.js @@ -0,0 +1,8 @@ +const { proxyRequest } = require('./_proxy'); + +module.exports = function handler(request, response) { + return proxyRequest(request, response, { + envName: 'BE1_PROXY_TARGET_URL', + pathQueryParam: 'path', + }); +}; diff --git a/api/be3.js b/api/be3.js new file mode 100644 index 0000000..b014c05 --- /dev/null +++ b/api/be3.js @@ -0,0 +1,8 @@ +const { proxyRequest } = require('./_proxy'); + +module.exports = function handler(request, response) { + return proxyRequest(request, response, { + envName: 'BE3_PROXY_TARGET_URL', + pathQueryParam: 'path', + }); +}; diff --git a/vercel.json b/vercel.json index 22835b4..6dafc4e 100644 --- a/vercel.json +++ b/vercel.json @@ -2,11 +2,11 @@ "rewrites": [ { "source": "/be1/:path*", - "destination": "/api/be1/:path*" + "destination": "/api/be1?path=:path*" }, { "source": "/be3/:path*", - "destination": "/api/be3/:path*" + "destination": "/api/be3?path=:path*" }, { "source": "/(.*)",