11

求助如何通过没有文档的接口上传文件

 2 years ago
source link: https://www.v2ex.com/t/821966
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

V2EX  ›  程序员

求助如何通过没有文档的接口上传文件

  LxnChan · lxnchan · 15 小时 16 分钟前 · 650 次点击

现在有一个 API ,没有文档没有参数说明。

现在需要一个 shell 脚本,通过这个 API 上传一份文件。

我感觉应该是一种通用的模板,所以想问一下大家,如何按照上面的格式通过curl上传文件?

Ps:请勿发表无用观点诸如:换 API 、没文档谁知道等等。

第 1 条附言  ·  12 小时 23 分钟前

我想问一下boundary参数会自动生成吗,另外还有就是如果直接-F "[email protected]"的话--data-binary参数会不会直接等于文件的二进制内容呀


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK