Soap Error
Hi when I try and connect to the Asset Operation web Service I get an error: "SOAP-ERROR: Parsing WSDL: Couldn't find <definitions> in '/ws/services/AssetOperationService?wsdl'".
Discussions are closed to public comments.
If you need help with Cascade CMS please
start a new discussion.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
1 Posted by Wing Ming Chan on 12 Aug, 2016 11:52 AM
Hi Matt,
Can you attach your script here so that we can help figuring out what is wrong?
Wing
2 Posted by Matt on 15 Aug, 2016 04:42 PM
function __construct()
{
try
{
use_soap_error_handler(true);
ini_set("soap.wsdl_cache_enabled", "0");
$this->auth = array('username' => '******', 'password' => '******');
$soapURL = "******/ws/services/AssetOperationService?wsdl";
# soap service
$this->service = new SoapClient
(
$soapURL,
array ('trace' => 1, 'location' => str_replace('?wsdl', '', $soapURL))
);
// $test = file_get_contents("https://utah-healthcare.cascadeserver.com/ws/services/AssetOperationService?wsdl");
$fcs = $this->service->__getFunctions();
#authentication vars
}
catch(Exception $error)
{
echo 'Caught Exception: ' . $error->getMessage() . "\n";
}
}
3 Posted by Wing Ming Chan on 15 Aug, 2016 05:01 PM
Hi Matt,
I tried your code with our wsdl and did not see any error. I suspect that it is related to your wsdl URL. Also try plugging in the $soadURL without removing "?wsdl".
By the way, I assume that you know of my library, right? Here you are building a class, wrapping up the soap client. But I have already done that. Why reinventing the wheel?
Wing
4 Posted by Matt on 15 Aug, 2016 05:06 PM
Hi Wing -
I'm not familiar with your library. I am fairly new to this job and I am working with some legacy code. Can you send me a link to your library? I'll try hitting the url without removing the "?wsdl". Thanks!
5 Posted by Wing Ming Chan on 15 Aug, 2016 05:11 PM
See my last post on http://help.hannonhill.com/discussions/web-services/1633-question-o...
Also check out what we did last Friday (Web Services: Day 1): http://www.upstate.edu/cascade-admin/web-services/courses/ws-online...
Wing
6 Posted by Ryan Griffith on 16 Aug, 2016 12:43 PM
Hi Matt,
The issue you are seeing is due to your instance using custom authentication. What is happening is when you attempt to access https://utah-healthcare.cascadeserver.com/ws/services/AssetOperatio... you are being redirected to your Shibeloth endpoint, not the WSDL.
You have a couple of options:
Please let me know if you have any questions.
Thanks!
7 Posted by Matt on 16 Aug, 2016 04:49 PM
Thanks Ryan - the backdoor option seems to be working. I'm going to give that a try for now.
8 Posted by Ryan Griffith on 16 Aug, 2016 05:01 PM
Not a problem at all, Matt.
Feel free to let us know if you would prefer the IP or domain route and we'll work with you to set that up.
I'm going to go ahead and close this discussion, please feel free to comment or reply to re-open if you have any additional questions.
Have a great day!
Ryan Griffith closed this discussion on 16 Aug, 2016 05:01 PM.