transfer data from or to a server // transfer a URL
--resolve <host:port:address>
Provide a custom IP address for a specific host:port
pair. Use it like a lightweight /etc/hosts
alternative.
-s
Silence progress information - pretty much required when piping output as this includes progress information
-c <filename>
, -b <filename>
Use a cookie jar to save cookies. -c
specifies the file to save to, and -b
is required to actually send cookies.
-k
Ignore certificate validation errors
-i
Display response header information
To exclude the body from the response, you can use:
-s -D- -o/dev/null
- dump header to stdout, send rest of output to /dev/null
-I -X GET
somewhat confusing and potentially easy to mess up - fetch the header returned by a GET
request-i
and -I
are misleading-i
includes headers in output
-I
does not just show headers - it actually makes a HEAD request which in some cases can result in different headers being returned