curl allows to add extra headers to HTTP requests. The HTTP headers are used to pass additional information between the client and the server. In this article i am showing the examples of how to add header in curl, how to add multiple headers and how to set authorization header from the Linux command line.
curl
JFrog Artifactory: Download Artifact using cURL
JFrog’s Artifactory is a binary repository manager. The artifacts from Artifactory can be downloaded using REST API. In this note i am showing how to download an artifact (simple file.zip) from generic Artifactory repository using curl command from the command line in Linux or from the PowerShell in Windows.
cURL: Set User-Agent
When browser connects to a website, it includes a User-Agent string in its HTTP header. Sometimes you may need to change User-Agent with curl to access some URL as a different browser. This is a small note on how to set a custom User-Agent with curl from the command line in Linux.
Check a Website Availability from the Linux Command Line
You can easily test a a website availability from the Linux command line and get the status codes from the web-server using commands like TELNET or CURL. Check a website availability with CURL Execute the following command to check whether a web site is up, and what status message the web server is showing: $ […]
What is my Public IP address?
Use one of the following commands to check your public IP address from the Linux command line. Get the Public IP address from the Linux Command Line 0. Easy to Remember Services Get your external IP address using the curl command: $ curl ifconfig.me $ curl ip.appspot.com $ curl icanhazip.com Get your external IP address […]