1curl -X POST -H "Content-Type: application/json" \
2 -d '{"username":"abc","password":"abc"}' \
3 https://api.example.com/v2/login
4
1# dont forget the content type, else it will throw an error
2
3curl -X POST -H "Content-Type: application/json" \
4 -d '{"username":"abc","password":"abc"}' \
5 https://api.example.com/v2/login
1curl --data '' https://example.com/resource.cgi
2
3curl -X POST https://example.com/resource.cgi
4
5curl --request POST https://example.com/resource.cgi
6