美文网首页
shell "org.springframework.web.H

shell "org.springframework.web.H

作者: 洛丽塔的云裳 | 来源:发表于2020-03-26 15:07 被阅读0次

    原代码:

    changeNumber='test'
    req=`curl -X POST -H "'Content-type':'application/json'" -d '{"parameter": "'$changeNumber'", "name": "test", "token": "test", "callback": "" }' http://test.xxx.com/api/tool/210363`
    echo $req
    

    修复后正常

    -H "'Content-type':'application/json'" 应该是: -H "Content-type: application/json"

    changeNumber='test'
    req=`curl -X POST -H "Content-type:application/json" -d '{"parameter": "'$changeNumber'", "name": "test", "token": "d6240cf6a5664862b6da674c417ff38f", "callback": "" }' http://kirin.baidu-int.com/api/tool/210363`
    echo $req
    

    相关文章

      网友评论

          本文标题:shell "org.springframework.web.H

          本文链接:https://www.haomeiwen.com/subject/fydcuhtx.html