Check the HTTP status code response with the curl command (#Linux #Shell)

curl -s --head http://example.com | grep HTTP
HTTP/1.1 200 OK

curl -s --head -X POST https://yahoo.com | grep HTTP
HTTP/2 301

Original by Github issue

https://github.com/YumaInaura/YumaInaura/issues/2984

Recommended Posts

Check the HTTP status code response with the curl command (#Linux #Shell)
curl command show http status code in response (#Linux #Shell)
Check the memory status of the server with the Linux free command
Check the operating status of the server with the Linux top command
Check the code with flake8
Check server I / O device usage with the Linux iostat command
Check the memory protection of linux kerne with the code for ARM
Status check command used (sometimes) on linux
Linux [shell command]
Specify the Django http status code and return.
Adjust file permissions with the Linux command chmod
An article that just tries a little HTTP request with the curl command
[Linux] Execute git pull regularly with the crontab command
Compare HTTP GET / POST with cURL (command) and Python (programming)
[Python] Create a screen for HTTP status code 403/404/500 with Django
Until the shell finds the command
Linux PC spec check command
Grant an access token with the curl command and POST the API
How to monitor the execution status of sqlldr with the pv command
[Infrastructure] Linux command, shell script collection
Decrypt the QR code with CNN
[Linux] OS recovery with restore command
[linux] kill command to kill the process
Using cgo with the go command
Hit the top command with htop
Visualize the response status of the census 2020
Replace the directory name and the file name in the directory together with a Linux command.
You can also check the communication of DB and cache with curl
The --security option cannot be used with the dnf command on CentOS Linux