-H is headers. Typically network.request() takes a table as params. If you look at network.request()'s documentation there is a section on using POST with custom headers:
https://docs.coronalabs.com/api/library/network/request.html#http-post-with-custom-headers
-F is a HTML form submitter. In this case, “encoded_data” is the name of the form field. The text after the = sign is the path to the file. The @ says to actually get the data from the file as binary data.
I think you would actually need to read in the binary data and then run it through a base64 encoder and do something like:
local params = {} params.header = {} params.header.Authorization = "your access token" params.body = {} params.body.encoded\_data = yourBase64encodedBinaryFile network.request("https://api.website.com", "POST", networkListener, params )
or something like that. No guarantee that will work for you because I suspect that cURL is doing some additional processing to make the data Multipart MIME under the hood.
Rob