Connections from Hetzner blocked?

I am having issues connecting from my Hetzner server. Is Alpaca blocking connections from a German Hetzner Server? On my local dev environment I can connect. Application code is identical on both environmens and the server seems not to be the issue.

Ran a few tests with ChatGPT and here is the outcome:

  1. TCP Connections to 35.194.67.18 on Port 443 Time Out from Your Server:

Both nc (netcat) and telnet attempts to connect to 35.194.67.18 on port 443 from your server time out.

When using curl to access https://paper-api.alpaca.markets/v2/orders, the connection times out after resolving the host to 35.194.67.18.

  1. Connections to Other External Hosts on Port 443 Succeed
    Your server can successfully connect to other external hosts on port 443, such as www.google.com and 1.1.1.1.
  2. Traceroute to 35.194.67.18 Completes Successfully
    The traceroute from your server to 35.194.67.18 completes without any apparent issues, reaching the destination IP.
  3. No Firewall Rules Blocking Traffic on Your Server
    Your server’s firewall (iptables) shows no rules blocking outbound traffic
  4. System Settings and Network Configuration Appear Normal
    Reverse path filtering is set to loose mode (2), and the MTU is standard (1500).

Summary:
Given these findings, the issue appears to be specific to establishing TCP connections from your server to 35.194.67.18 on port 443, which is the endpoint for the Alpaca Paper Trading API at paper-api.alpaca.markets.

Since:

You can connect to paper-api.alpaca.markets from your local environment**, but not from your Hetzner server.
Your server can connect to other external services on port 443, indicating that outbound HTTPS traffic is generally allowed.
Traceroute completes successfully
, suggesting that network routing to the destination is functional.

It is highly likely that the Alpaca API server is blocking connections from your server’s IP address or from Hetzner’s IP range

Turned out that indeed the server ip was blocked for some reason. Connecting from a different IP works just fine.