快速总结
Taleo有一个单独的操作"Dispatcher WSDL“,它应该返回一个用于WebAPI WSDL的URL .其目的是允许URL对所有意图和目的进行软编码。
对于操作getURL,WcfTestClient.exe XML视图显示在SOAP信封中返回了一个URL。
但是,WcfTestClient.exe格式的视图显示
Name: (return) Value: (**null**) Type: **NullObject**我的c# vs2010 .NET 4代码;taleoURL总是空的
DispatcherAPIClient dispatcherClient = new DispatcherAPIClient("rpcrouter");
string taleoOrgCode = "TALEOSK";
string taleoURL = dispatcherClient.getURL(taleoOrgCode);
if (taleoURL == null) Console.WriteLine("null returned for " + taleoOrgCode);这个null很奇怪,因为这里是来自WcfTestClient.exe的XML响应:
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<s:Header xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" />
<SOAP-ENV:Body>
<ns1:getURLResponse xmlns:ns1="urn:TBEDispatcherAPI" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<return xsi:type="xsd:string">https://tbe.taleo.net/NA12/ats/services/rpcrouter</return>
</ns1:getURLResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>https://tbe.taleo.net/NA12/ats/services/rpcrouter是<返回>元素的值。
为了能够使用上面的链接,显然我需要taleoURL为null。
Taleo指南第154-155页指出getURL定义为string getURL(string orgCode)
http://tbe.taleo.net/products/TBE_API_Guide.pdf来自
http://www.taleo.com/solutions/taleo-business-edition-web-integration-api
也是
http://tbe.taleo.net/wsdl/DispatcherAPI.wsdl
http://tbe.taleo.net/wsdl/WebAPI.wsdl
下面是DispatcherAPI.wsdl的请求/响应部分:
<wsdl:message name="getURLRequest">
<wsdl:part name="orgCode" type="xsd:string" />
</wsdl:message>
<wsdl:message name="getURLResponse">
<wsdl:part name="getURLReturn" type="xsd:string" />
</wsdl:message>我最好的猜测是我漏掉了什么。
在这种情况下,我自己的无知不是福。
MSDN和谷歌对此毫无帮助。
谢谢..。格里
发布于 2011-01-14 18:15:33
我刚开始和Taleo WebAPI合作,我也遇到了同样的问题。
更新:我将引用从VS2010 C#服务引用更改为“老式”Web引用,然后它开始工作。我仍在研究一个“真正的”解决方案,但这确实有效。
https://stackoverflow.com/questions/4677154
复制相似问题