Full request timeout
--max-time limits the entire operation, including connection, redirects, request upload, and response download. Use it when a user-facing workflow needs a hard upper bound.
Set cURL request timeouts with --max-time, --connect-timeout, and generated code equivalents for API calls that should fail predictably instead of hanging.
Try Timeout Conversion--max-time limits the entire operation, including connection, redirects, request upload, and response download. Use it when a user-facing workflow needs a hard upper bound.
--connect-timeout only limits the time spent establishing the connection. It is useful when DNS, TCP, TLS, or proxy setup is unreliable.
The converter keeps timeout settings in JSON output and maps them into supported target languages where a direct timeout option exists.
curl --connect-timeout 3 --max-time 15 -H 'Accept: application/json' https://api.example.com/slow-report
--connect-timeout covers only connection setup, while --max-time covers the whole cURL operation.
Most production API clients should define timeouts so slow or unreachable services do not block workers indefinitely.