使用PostMan测试WebService接口
使用PostMan测试WebService接口

参考资料:
通过XML请求WebServer https://blog.csdn.net/qq_33933408/article/details/53149435
WebService发布与访问并通过Postman测试WebService接口 https://blog.csdn.net/up123456789/article/details/79474446
一、操作步骤
1、设置URL
2、设置请求模式:Post
3、设置Header:添加 Content-Type ,值为 text/xml;charset=utf-8
4、设置Body:勾选raw
5、输入Body内容:(详见 二)
二、请求WebService时的Body结构
<?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>
<getWeather xmlns="http://WebXml.com.cn/">
<theCityCode>string</theCityCode>
<theUserID>string</theUserID>
</getWeather>
</soap:Body>
</soap:Envelope>
详细说明:
(1) getWeather是方法名。
(2)theCityCode、theUserID是方法参数。
三、WebService响应时的Body结构
<?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>
<getWeatherResponse xmlns="http://WebXml.com.cn/">
<getWeatherResult>
<string>string</string>
<string>string</string>
</getWeatherResult>
</getWeatherResponse>
</soap:Body>
</soap:Envelope>
详细说明:
(1)getWeatherResult是方法的返回值。

使用PostMan测试WebService接口的更多相关文章
- 使用PostMan测试WebService接口教程
一.操作步骤 1.设置URL 2.设置请求模式:Post 3.设置Header:添加 Content-Type ,值为 text/xml;charset=utf-8 4.设置Body:勾选raw 5. ...
- postman测试webservice接口
- 【SoapUI、Postman、WebServiceStudio、Jmeter】接口测试工具结合测试webservice接口(发送XML格式参数)
目录: SoapUI测试webservice接口,发送XML格式参数 Postman测试webservice接口,发送XML格式参数 WebServiceStudio.exe测试webservice接 ...
- 关于python测试webservice接口的视频分享
现在大公司非常流行用python做产品的测试框架,还有对于一些快速原型产品的开发也好,很好地支持OO编程,代码易读.Python的更新挺快的,尤其是第三方库. 对于测试人员,代码基础薄弱,用pytho ...
- Python之测试webservice接口
前段时间学习了Python操作http接口,觉得挺容易的.最近项目组也有接触webservice接口,心里想想是否Python也可以操作这类接口.于是利用伟大的度娘,花了6个小时研究出来了,所以迫不及 ...
- python实现建立soap通信(调用及测试webservice接口)
实现代码如下: #调用及测试webservice接口 import requests class SoapConnect: def get_soap(self,url,data): r = reque ...
- 『动善时』JMeter基础 — 50、使用JMeter测试WebService接口
目录 1.什么是WebService 2.WebService和SOAP的关系 3.什么是WSDL 4.测试WebService接口前的准备 (1)如何判断是WebService接口 (2)如何获取W ...
- 『动善时』JMeter基础 — 51、使用JMeter测试WebService接口
目录 1.什么是WebService 2.WebService和SOAP的关系 3.什么是WSDL 4.测试WebService接口前的准备 (1)如何判断是WebService接口 (2)如何获取W ...
- Postman如何测试Webservice接口?
一般情况下使用soapui工具测试ws接口,那么能不能使用postman测试呢?当然可以,往下看. 1. 首先请求类型为post 填写上ws地址 ,url地址后不追加?wsdl 2. 设置请求头 he ...
随机推荐
- PHP获取文件大小的几种方法!
一.get_header($url,true): $url = 'http://www.xxx.com/MoJing_win_x86_64_V5.125.zip'; $res = get_header ...
- Selenium(七)多窗口切换、等待方法、alert对话框处理
一.多窗口切换 1.打开百度首页 2.在百度中搜索博客园 3.从搜索结果中跳转到博客园 4.博客园首页和百度搜索页面切换 handle:句柄 二.等待方法 time.sleep(5) 先导入方法 参数 ...
- Selenium(五)鼠标和键盘事件
1.模拟鼠标找到大分类下的子分类.以网易严选为例. 如果直接找到 坚果炒货 这个元素,然后点击它来实现跳转,是会报错的. 模拟鼠标停留--点击行为: 页面已成功跳转 2.键盘事件 模拟搜索操作: ...
- Idea中提交SVN或git时,忽略某些文件不提交
第一步:点击 setting 第二步:点击Editor下的File Types 第三步:编辑,在后面添加 *.iml;*.idea;*.gitignore;*.sh;*.classpath;*.pro ...
- C# Dynamic动态对象
1.ExpandoObject dynamic expObj = new ExpandoObject(); expObj.FirstName = "Daffy"; expObj.L ...
- 用IE滤镜实现多种常用的CSS3效果
CSS3是当下非常火的一个话题之一,很多浏览器都已经开始支持这一特性,然后IE这个拥有庞大用户群体的平台,却无法提供这样的支持,即便是IE9发布,也无法改变这一事实,然而,幸运的是,IE并非在这方面毫 ...
- linux下替换不同目录下的文件的字符串
需求: 查找当前目录下的所有子目录中的catalina.sh文件中的JAVA_OPTS=开头的文件,替换为 JAVA_OPTS='-server -Xms800m -Xmx800m -XX:PermS ...
- 时间戳、String、Date转换
时间戳(String or long) =>Date long s=1557230621043L; Date date=new Date(s); System.out.println(date) ...
- Find a multiple POJ - 2356 【鸽巢原理应用】
Problem DescriptionThe input contains N natural (i.e. positive integer) numbers ( N <= 10000 ). E ...
- @Async 异步注释 @EnableAsync
@SpringBootApplication @ComponentScan(basePackages = "com.fddsfsg") //@EnableSwagger2 @Ena ...