bug-wget
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to send a POST request by wget same to a httpie request?


From: Peng Yu
Subject: How to send a POST request by wget same to a httpie request?
Date: Wed, 1 Jul 2020 17:32:16 -0500

$ http --form POST localhost:9000 file@1.txt

The above httpie (https://httpie.org/) command will send the following
POST request. Could anybody let me know what is the equivalent wget
command to achieve the same HTTP request? Thanks.


POST / HTTP/1.1
Host: localhost:9000
User-Agent: HTTPie/2.2.0
Accept-Encoding: gzip, deflate
Accept: */*
Connection: keep-alive
Content-Length: 171
Content-Type: multipart/form-data; boundary=36922889709f11dcba960da4b9d51a2e

--36922889709f11dcba960da4b9d51a2e
Content-Disposition: form-data; name="file"; filename="1.txt"
Content-Type: text/plain

abc

--36922889709f11dcba960da4b9d51a2e--


-- 
Regards,
Peng



reply via email to

[Prev in Thread] Current Thread [Next in Thread]