怎么用curl命令发送一个请求并且在参数txt中传输一段文本
使用以下命令:
curl -X POST -H "Content-Type: text/plain" -d '你要传输的文本内容' http://example.com/endpoint
其中:
-X POST指定请求方法为 POST。-H "Content-Type: text/plain"指定请求头中的 Content-Type 为 text/plain。-d '你要传输的文本内容'指定请求体中的文本内容。http://example.com/endpoint是接收请求的 URL。
原文地址: https://www.cveoy.top/t/topic/hcDP 著作权归作者所有。请勿转载和采集!