BingAI on GCP Cloud Function #276
-
Hi there, I'm trying to run the BingAI module on a Firebase Function, but I'm facing an issue. I've already extracted the BingAI code to make it as lean as possible, and it works on Firebase emulators. However, when I deploy the code to GCP, I get an error. Specifically, I'm receiving an empty response body when I make a request using fetch. " const response = await fetch( Do you think the issue is because Google servers are being recognized by Bing? Would using a proxy help to fix this problem? Thanks for your help! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Yeah, that can be a sign of the IP being blocked. Try setting a proxy. |
Beta Was this translation helpful? Give feedback.
-
Hi Joel, To make it work, I used the WebShare proxy provider, which provides 10 proxies with a 1 GB bandwidth limit for free and requires no credit card. To enable password-protected proxies, I made changes to the "BingAIClient.js" code as follows: Since WebShare uses HTTP proxy, I changed HttpsProxyAgent to HttpProxyAgent: I updated the ProxyAgent inputs to allow password-protected proxies: I changed HttpsProxyAgent to HttpProxyAgent with some input changes: I hope this information is useful to others who may be encountering similar challenges. |
Beta Was this translation helpful? Give feedback.
Yeah, that can be a sign of the IP being blocked. Try setting a proxy.