Environment Setup
- n8n running in Docker container
- Ollama also running in Docker container
- Both containers configured to use my corporate proxy
- Running on Linux environment
- n8n version: latest
The Issue
I’ve set up n8n with Google Chat credentials, and I’m trying to use the Google Chat nodes. However, when attempting to connect to the Google Chat API, I consistently get this error:
The service failed to process your request
ERROR: The requested URL could not be retrieved
The following error was encountered while trying to retrieve the URL: https://chat.googleapis.com/v1/spaces?
**Unsupported Request Method and Protocol**
Squid does not support all request methods for all access protocols.
What’s Working
- Regular HTTP requests within n8n work fine through the proxy
- Ollama container successfully connects through the same proxy configuration
- When I intercept the Google Chat API request and replicate it using curl with the same proxy settings, it works perfectly from the host
My Configuration
Both Docker containers are configured with proxies variables set
What I’ve Tried
- Verified my Google credentials are correct (the token is valid)
- Confirmed the proxy is accessible from the containers
- Successfully used curl with the same request parameters through the proxy
- Tried various proxy configuration formats
My Theory
I believe the issue might be that n8n is trying to make HTTPS requests directly through the proxy without using the CONNECT method, which our corporate Squid proxy requires for HTTPS tunneling. This is suggested by the error message “Unsupported Request Method and Protocol.”
When using curl, the CONNECT method is automatically used for HTTPS requests, which is why those work.
Questions
- Is there a way to configure n8n to use the CONNECT method for HTTPS requests through a proxy?
- How can I better debug the exact HTTP requests n8n is making to understand what’s different from curl?
- Are there any known issues with n8n and corporate proxies, specifically with the Google API nodes?
- Would setting up an intermediate proxy that handles the CONNECT method be a viable solution?
Any guidance would be greatly appreciated. I’ve spent several days trying to resolve this issue and believe it may be a specific interaction between n8n’s HTTP client, the Google API, and our corporate proxy implementation.