postman请求webService
postman请求webService
·
postman请求调用asmx接口
实例
1、请求方式: POST
2、webService地址:http://127.0.0.1:/WebService/LoginService.asmx
3、header中添加:Content-Type:text/xml;charset=utf-8
4、参数:(xml格式)
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<Login xmlns="http://tempuri.org/">
<user>admin</user>
<psd>123456</psd>
</Login>
</soap:Body>
</soap:Envelope>
如下图:
返回值
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<LoginResponse xmlns="http://tempuri.org/">
<LoginResult>{
"status": 200,
"msg": "登录成功"
}
</LoginResult>
</LoginResponse>
</soap:Body>
</soap:Envelope>
更多推荐
已为社区贡献1条内容
所有评论(0)