
How to Use curl to Download Files and Test URLs Step by Step
Use the curl command to download files, follow redirects, send headers and data, show response codes and timing, and fail properly in scripts.
SSH, curl, DNS, ports and HTTP APIs from the terminal, for when a connection or a request will not behave.

Use the curl command to download files, follow redirects, send headers and data, show response codes and timing, and fail properly in scripts.

Use scp and sftp to copy files over SSH, with ports, keys and recursive copies, learn how scp changed in OpenSSH 9, and when to use rsync instead.

Understand API 502 Bad Gateway and 504 Gateway Timeout from scripts and proxies: where they come from, what to check upstream, and safe retries.

Handle API 429 Too Many Requests in scripts: read Retry-After and rate limit headers, exponential backoff with jitter, curl retries, throttling and batching.

Use VS Code Remote SSH and Dev Containers: connect with your ssh config, devcontainer.json, features, ports and the problems to expect.

Set up a remote dev machine and edit over SSH: host config, connection reuse, tmux, port forwarding, editors over SSH and file sync.

Prepare JSON for a database import with jq: flatten to CSV or JSON Lines, handle nulls and types, escape safely, and load with COPY, mongoimport or SQLite.

Avoid repeated API calls in scripts: fetch once, pass data along, conditional requests with ETags, batching, pagination limits and a request counter.

Fix SSH no matching host key type found: why SHA-1 ssh-rsa was disabled, reading the server offer, HostKeyAlgorithms overrides, and re-keying.

Fix SSH no matching key exchange method found: read the server offer, old server versus new client, safe KexAlgorithms overrides and upgrades.

Fix the SSH unprotected private key file warning: set mode 600, fix ownership, handle WSL and Windows mounts, and see why open keys are refused.

Understand SSH Host key verification failed: every cause, from a changed key or unwritable known_hosts to a non-interactive session, with the fix for each.
One email when a new post is published. No spam.