Connection drops are normal for HTTP/REST APIs. Various infrastructure layers (load balancers, proxies, firewalls) have timeout limits. All API clients must implement automatic reconnection logic with exponential backoff - this is not optional.
Cause: Application Load Balancer (ALB) timeout, set to 10 minutes by design. If your connection has no activity for 10 minutes, the ALB will close it.Solution: Implement automatic reconnection logic in your client. If you’re not sending traffic for 10 minutes, your code should handle reconnect gracefully.Note: The 10-minute timeout is intentional and will not be increased. Proper client implementation (connection pooling, keepalives, reconnection) is the correct solution.
gRPC streams can drop with “14 UNAVAILABLE” errors for two reasons:(a) 10-minute ALB timeout: If you create a gRPC channel but don’t open a stream immediately, or if there’s no actual traffic on the stream for 10 minutes, the ALB will timeout the connection.(b) Keepalives alone may not prevent timeout: The ALB needs to see actual traffic, not just HTTP/2 PING frames.Solutions:
Implement automatic reconnection when streams drop (error code 14 or EOF)
Open streams promptly after creating channels
If you have long idle periods, consider periodic lightweight API calls to keep the connection active
Cause: Connections being severed on the hosts. Recent infrastructure fixes should have resolved this issue.Solution: Implement 180-second timeout detection on your end. Trigger automatic reconnection when no data received for 180+ seconds. This error should be rare after recent stability improvements.
Cause: Transient network issues, stale connections, or load balancer timeouts.Solution: Implement exponential backoff with 2-3 retries for connection errors:
Recommendation: Add 15-second timeouts on client side to prevent hanging requests. A small percentage of calls may never resolve - timeout protection is essential.
If your curl command drops to a new line with a blinking cursor, this indicates a formatting issue with the command itself, not a connection problem.Common causes:
Windows instances and Python applications may encounter HTTP/2 compatibility issues:Windows: Ensure HTTP/2 is enabled in your system settings.Python: Use the httpx library instead of requests:
import httpx# Use httpx for HTTP/2 supportwith httpx.Client(http2=True) as client: response = client.get( "https://api.preprod.polymarketexchange.com/v1/health", headers={"Authorization": f"Bearer {token}"} )
If you receive SSL certificate verification errors:In production code: Never disable certificate verification. This creates security vulnerabilities.For debugging only: You can temporarily disable verification to test connectivity:
# DEBUGGING ONLY - DO NOT USE IN PRODUCTIONimport requestsresponse = requests.get(url, verify=False)
Proper solution: Ensure your system has up-to-date CA certificates installed.
Expected response: {"status":"ok"} with HTTP 200No authentication required - this endpoint is publicly accessible.If the health check fails, the API may be experiencing issues. Check the status page or contact support.
Assistant
Responses are generated using AI and may contain mistakes.