Code: Select all
@REQUIRE "hurl"
; PostType doesn't work with hurl (works with the "default" adapter)
DownloadFile("http://ptsv2.com/t/hollyw/post" , {Post="{\"test\": 1}", PostType="application/json", Verbose=True, Adapter = "hurl"})
Wait(50)
; A work-around for hurl, don't use with "default" to avoid double headers
DownloadFile("http://ptsv2.com/t/hollyw/post" , {Post="{\"test\": 2}", CustomHeaders = "Content-Type: application/json\r\n", Verbose=True, Adapter = "hurl"})