webserivce通过httppost方式调用

问题起源

  webserivce的通用方式调用比较复杂,大家普遍接受通过http方式调用

解决办法

  1)打开postman接口测试
  https://getman.cn/?s=c5538c4e399ba426c0cefbdb09ef318a
  2)url中输入,接口地址endpoint
  http://ip:port/services/sendmsg
  3)输入header
  Content-Type: text/xml
  SOAPAction: http://www.csapi.org/service/sendSms
  4)输入body参数
  webserice的消息请求体(soapui中的发送webserivce请求那串xml文本)
  <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sms="http://www.csapi.org/schema/sms">
     <soapenv:Header/>
     <soapenv:Body>
        <sms:sendSmsRequest>
        </sms:sendSmsRequest>
     </soapenv:Body>
  </soapenv:Envelope>
  5)点击发送即可
posted @ 2020-12-24 17:05  王吉平  阅读(154)  评论(0编辑  收藏  举报