Fiddler让咱们这些.neter感到很是欣慰, 是用C#写出来的,它包含一个简单却功能强大的基于JScript .NET 事件脚本子系统,它的灵活性很是棒,能够支持众多的http调试任务,而且可以使用.net框架语言进行扩展。web
调用webservice须要设置正确的请求头,如下为例子,每一个webserive的请求头可能不同,具体根据ws提供方来肯定json
请求头:api
User-Agent: Fiddler SOAPAction: "http://tempuri.org/GetObList" Host: **IP Content-Length: 329 Expect: 100-continue Content-Type: text/xml; charset=utf-8
传入值app
<?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><GetObList xmlns="http://tempuri.org/"><time>2018-01-01T00:00:00</time></GetObList></soap:Body></soap:Envelope>
点击Execute显示调用结果框架
Fiddler调试WebApi注意事项:spa
一、需指定请求上下文类型,不然有些api可能会调用报错,例如 Content-Type: application/json.net
二、调试