curl and jq 8 · Authentication and headers
Use basic authentication
Send a username, with curl prompting for the password.
curl -u username https://api.example.com/me
Official curl and jq 8 documentation
More authentication and headers commands
All authentication and headers commands · curl and jq 8 cheatsheet