Search…
README
How to read this book
The cURL project
Network and protocols
Install curl
Source code
Build curl
Command line basics
Using curl
HTTP with curl
Protocol basics
Responses
Authentication
Ranges
HTTP versions
Conditionals
HTTPS
HTTP POST
Simple POST
Content-Type
Posting binary
JSON
URL encoding
Convert to GET
Expect 100-continue
Chunked encoded POSTs
Hidden form fields
Figure out what a browser sends
JavaScript and forms
Multipart formposts
-d vs -F
Redirects
Modify the HTTP request
HTTP PUT
Cookies
HTTP/2
Alternative Services
HTTP/3
HSTS
HTTP cheat sheet
Scripting browser-like tasks
FTP with curl
Using libcurl
HTTP with libcurl
Bindings
libcurl internals
Index
Powered By
GitBook
Posting binary
When reading data to post from a file,
-d
will strip out carriage return and newlines. Use
--data-binary
if you want curl to read and use the given file in binary exactly as given:
curl --data-binary @filename http://example.com/
Previous
Content-Type
Next
JSON
Last modified
7mo ago
Export as PDF
Copy link
Edit on GitHub