最近一直用postman测试请求,今天临时需要给客户在linux下测试请求

raw的方式请求 v调试使用 H指定头部格式  X指定请求的方法  d用于发送 POST 请求的数据体
curl -vk -H 'Content-Type:application/json'-X POST -d '{"你的参数":"参数值","你的参数2":"参数值2"}'  https://ip:port/gway/controllerservice


默认是按照form-data的方式访问请求 d是post方式 k是https 
curl -kd "参数1=值1&参数2=值2"    https://ip:port/gway/controllerservice


使用-d参数以后,HTTP 请求会自动加上标头Content-Type : application/x-www-form-urlencoded。并且会自动将请求转为 POST 方法,因此可以省略-X POST