Salesforce soap错误:不是枚举'ExecutionLogType'的有效值

时间:2017-02-01 16:41:57

标签: web-services soap enums salesforce soapui

任何人都可以帮我吗?我无法在任何地方找到有关此错误消息的信息。

我创建了一个webservice类,我正在使用SoapUI来检查它是否正常工作,并且我一直收到以下错误。

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
   <soapenv:Body>
      <soapenv:Fault>
         <faultcode>soapenv:Client</faultcode>
         <faultstring>'' is not a valid value for the enum 'ExecutionLogType'</faultstring>
      </soapenv:Fault>
   </soapenv:Body>
</soapenv:Envelope>

我的意见如下。我不知道如何使用字段客户端或为什么它在wsdl中生成,这个字段不在我的班级。

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:exec="http://soap.sforce.com/schemas/class/ExecutiveCareWebservice">
   <soapenv:Header>
      <exec:AllowFieldTruncationHeader>
         <exec:allowFieldTruncation>FALSE</exec:allowFieldTruncation>
      </exec:AllowFieldTruncationHeader>
      <exec:DebuggingHeader>

         <exec:categories>
            <exec:category>ALL</exec:category>
            <exec:level>DEBUG</exec:level>
         </exec:categories>
         <exec:debugLevel></exec:debugLevel>
      </exec:DebuggingHeader>
      <exec:CallOptions>
         <exec:client>1</exec:client>
      </exec:CallOptions>
      <exec:SessionHeader>
         <exec:sessionId>00D0E0000008dby!ASAAQBqFFnoPgI88ekHhKy4.N0aKNAw5sIR_1LSGSqzZ_cOg.4oH9hpyW1cB2JDC._BnMKu54FhiJ4p_ORUyIQf39MbRZoqs</exec:sessionId>
      </exec:SessionHeader>
   </soapenv:Header>
   <soapenv:Body>
      <exec:getActiveClientes>
         <exec:validationDate></exec:validationDate>
      </exec:getActiveClientes>
   </soapenv:Body>
</soapenv:Envelope>

提前致谢! 琼娜

1 个答案:

答案 0 :(得分:1)

简化您的soapenv:Header标头。我怀疑问题出在exec:DebuggingHeader标题上。特别是,exec:debugLevel可能与ExecutionLogType有关。

完全退出该标题。实际上,您需要的唯一标题是exec:SessionHeader