We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2d78c7b commit e576e2eCopy full SHA for e576e2e
1 file changed
app/api/waitlist/subscribe/route.ts
@@ -4,16 +4,16 @@ export async function POST(request: NextRequest) {
4
try {
5
const body = await request.json();
6
7
- // Get the backend URL from environment or config
+
8
const backendUrl =
9
process.env.NEXT_PUBLIC_API_URL || 'http://localhost:8000/api';
10
11
- // Forward the request to the backend
12
const response = await fetch(`${backendUrl}/waitlist/subscribe`, {
13
method: 'POST',
14
headers: {
15
'Content-Type': 'application/json',
16
- // Forward any relevant headers
17
...(request.headers.get('user-agent') && {
18
'User-Agent': request.headers.get('user-agent')!,
19
}),
0 commit comments