ardasen commited on
Commit
7d16ae5
·
verified ·
1 Parent(s): 9b4e460

Update server.js

Browse files
Files changed (1) hide show
  1. server.js +3 -3
server.js CHANGED
@@ -63,6 +63,9 @@ app.use('/api', authenticateProxyKeyAndModel, (req, res, next) => {
63
  const modifiedBody = JSON.stringify(srcReq.body);
64
  proxyReqOpts.headers['Content-Length'] = Buffer.byteLength(modifiedBody);
65
  proxyReqOpts.body = modifiedBody;
 
 
 
66
  }
67
 
68
  return proxyReqOpts;
@@ -71,9 +74,6 @@ app.use('/api', authenticateProxyKeyAndModel, (req, res, next) => {
71
 
72
 
73
 
74
-
75
-
76
-
77
  app.get("/", (req, res) => {
78
  // res.send(This is your OpenAI Reverse Proxy URL: ${baseUrl});
79
  });
 
63
  const modifiedBody = JSON.stringify(srcReq.body);
64
  proxyReqOpts.headers['Content-Length'] = Buffer.byteLength(modifiedBody);
65
  proxyReqOpts.body = modifiedBody;
66
+
67
+ // Log the body being sent to the API
68
+ console.log('Body being sent to API:', modifiedBody);
69
  }
70
 
71
  return proxyReqOpts;
 
74
 
75
 
76
 
 
 
 
77
  app.get("/", (req, res) => {
78
  // res.send(This is your OpenAI Reverse Proxy URL: ${baseUrl});
79
  });