在 wcf soap 邮递员中发送 int 数组

send array of int in wcf soap postman

假设我有一个包含 WCF SOAP 中的 List ids 参数的函数,我如何 post 一个整数数组到该 WCF SOAP vis Postman?我发誓我在 Google 中到处都看过,但没有关于它的文档。求助!!

您想使用postman 来测试您的服务,但是postman 只支持http 请求。如果要发送soap请求,需要在body中进行编辑,发送格式需要为soap-xml。对于 soap 请求,您可以使用 soapUI 来测试您的 SOAP 服务。总之,如果你的服务使用soap binding,你可以使用soapUI测试你的服务发送参数,如果你使用webhttpbinding,你可以使用postman发送参数并调用服务。

@Theobald Du:这就是我想要做的。我知道它是 soap-xml,但我不知道如何发送一个整数数组。这是我目前所拥有的:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/"> 
  <s:Body>
    <GetAvailabilities xmlns="http://tempuri.org/">
      <bodyString>leg</bodyString>
      <clinics>
     --> (list of ints to send here. This is where I am stuck)
      </clinics>
    </GetAvailabilities>
  </s:Body>
</s:Envelope>
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/"> 
  <s:Body>
    <GetAvailabilities xmlns="http://tempuri.org/">
      <bodyString>leg</bodyString>
      <clinicsxmlns:a="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
           <a:int>594</a:int>
      </clinics>
    </GetBranchAvailabilities>
  </s:Body>
</s:Envelope>

这是正确的做法。由于没有任何关于它的文档,我会把它留在那里供任何需要示例的人使用