开发者

How do you upload a image file and a json with curl?

I'm trying to use command line curl to test an API. The call takes in some parameters and a image file. Is there a way for me to specify the parameters using a json file, and make开发者_高级运维 the request via curl so both the image file and the json file gets uploaded to the server?


Check the curl documentation here

In the POST (HTTP) part you'll find the answer to your question.

You need to use the -F parameter

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜