Conga, SOAP and Web Services - Where to Begin?
7 posts
• Page 1 of 1
Conga, SOAP and Web Services - Where to Begin?
I want to write a little application which drags data down from an external Web Service, at present there's quite a large gap between what I know and what I need to know.
What I've done so far is to quickly look at Conga and Conga documentation - encapsulated the code to grab from the Windows Time Server (after finding that Windows needed a restart after I thought I'd enabled simple TCP/IP services).
What the supplier of the Web Service tells me by way of documantation is stuff like...
POST /broadband/v3.11/serviceengine.asmx HTTP/1.1
Host: webservices.zen.co.uk
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "https://webservices.zen.co.uk/broadband/v3.11/Authenticate"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<Authenticate xmlns="https://webservices.zen.co.uk/broadband/v3.11/">
<username>string</username>
<password>string</password>
</Authenticate>
</soap:Body>
</soap:Envelope>
With different versions for SOAP 1.1 and 1.2.
When I blindly try some experiments, this sort of thing happens...
DRC.Clt 'C1' 'https://webservices.zen.co.uk/broadband/v3.11' 0 'Text' 1000
1106 ERR_INVALID_HOST /* Host identification not resolved */
I'm wondering (and asking them) whether the Zen documentation is current.
The Conga documentation implies that I need to supply a port number, Zen's doesn't mention a port number.
How do I format all of this SOAP stuff and send it to the server?
Is Conga the way to go, or should I use something else?
Apologies if these all seem like silly questions - I'm feeling a need for navigation through these strange areas.
What I've done so far is to quickly look at Conga and Conga documentation - encapsulated the code to grab from the Windows Time Server (after finding that Windows needed a restart after I thought I'd enabled simple TCP/IP services).
What the supplier of the Web Service tells me by way of documantation is stuff like...
POST /broadband/v3.11/serviceengine.asmx HTTP/1.1
Host: webservices.zen.co.uk
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "https://webservices.zen.co.uk/broadband/v3.11/Authenticate"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<Authenticate xmlns="https://webservices.zen.co.uk/broadband/v3.11/">
<username>string</username>
<password>string</password>
</Authenticate>
</soap:Body>
</soap:Envelope>
With different versions for SOAP 1.1 and 1.2.
When I blindly try some experiments, this sort of thing happens...
DRC.Clt 'C1' 'https://webservices.zen.co.uk/broadband/v3.11' 0 'Text' 1000
1106 ERR_INVALID_HOST /* Host identification not resolved */
I'm wondering (and asking them) whether the Zen documentation is current.
The Conga documentation implies that I need to supply a port number, Zen's doesn't mention a port number.
How do I format all of this SOAP stuff and send it to the server?
Is Conga the way to go, or should I use something else?
Apologies if these all seem like silly questions - I'm feeling a need for navigation through these strange areas.
Visit http://apl.dickbowman.com to read more from Dick Bowman
-
Dick Bowman - Posts: 235
- Joined: Thu Jun 18, 2009 4:55 pm
Re: Conga, SOAP and Web Services - Where to Begin?
Conga "on it's own" is insufficient for dealing with "Web Services", which require the use of "SOAP" messages. The workspace "SAWS" (Stand-Alone Web Services) is based upon Conga and was supposed to be shipped with v12.1, but it missed the boat and we've been distracted since then. I've attached the latest version of it, including documentation. We are making a couple of small changes to it and will upload the latest version to http://www.dyalog.com/library by the end of the week.
I hope the attached documentation is enough to get you going, if not please ask more questions!
I hope the attached documentation is enough to get you going, if not please ask more questions!
- Attachments
-
- saws.zip
- (1.1 MiB) Downloaded 805 times
-
Morten|Dyalog - Posts: 454
- Joined: Tue Sep 09, 2008 3:52 pm
- ashepp0@gmail.com
- Posts: 1
- Joined: Wed Apr 21, 2010 6:06 pm
Re: Conga, SOAP and Web Services - Where to Begin?
Thank you Morten for the SAWS workspace - I think this will help me make progress.
Ran through a couple of the examples successfully, but I haven't achieved my goal of reaching the specific Web Service I need. I have my suspicions that Zen have changed their service but not updated their documentation (when I asked them they suggested that everything was self-documented - which might be helpful for people who know what they're doing and don't need the documentation). I have some other stuff related to this service and may get onto looking at it - but the volcanic ash clouds have cleared and the sun is shining, so it might not be this month. Looks like a question of figuring out the mapping between the SOAP they publish and the arguments to SAWS.Call (nearest I am to success at the moment is 100 TIMEOUT, which suggests I am at least troubling them).
One thing that puzzles me is SOAP 1.1 versus 1.2 - do we care?
A suggestion - if it doesn't cause you too much work. Since external services are subject to change I wonder whether it would be helpful for Dyalog to themselves offer a Web Service that we can use for development and testing - where you provide the "documentation" of the SOAP/response as per my first message and also the SAWS calls/arguments. Maybe this is just my ignorance speakeing and it'll all become blindingly clear to me in a few days.
Ran through a couple of the examples successfully, but I haven't achieved my goal of reaching the specific Web Service I need. I have my suspicions that Zen have changed their service but not updated their documentation (when I asked them they suggested that everything was self-documented - which might be helpful for people who know what they're doing and don't need the documentation). I have some other stuff related to this service and may get onto looking at it - but the volcanic ash clouds have cleared and the sun is shining, so it might not be this month. Looks like a question of figuring out the mapping between the SOAP they publish and the arguments to SAWS.Call (nearest I am to success at the moment is 100 TIMEOUT, which suggests I am at least troubling them).
One thing that puzzles me is SOAP 1.1 versus 1.2 - do we care?
A suggestion - if it doesn't cause you too much work. Since external services are subject to change I wonder whether it would be helpful for Dyalog to themselves offer a Web Service that we can use for development and testing - where you provide the "documentation" of the SOAP/response as per my first message and also the SAWS calls/arguments. Maybe this is just my ignorance speakeing and it'll all become blindingly clear to me in a few days.
Visit http://apl.dickbowman.com to read more from Dick Bowman
-
Dick Bowman - Posts: 235
- Joined: Thu Jun 18, 2009 4:55 pm
Re: Conga, SOAP and Web Services - Where to Begin?
I've attached the latest copy of the SAWS workspace.
After doing a SAWS.Init...
Using SAWS.TRACE←1, you can see the following invocation of SAWS.Call seems to produce a SOAP 1.1 call in the proper format. However, at least on my machine, the request times out as well.
'https://webservices.zen.co.uk' ⍬ 'broadband/v3.11/serviceengine.asmx' SAWS.Call
'broadband/v3.11' 'Authenticate'('username' 'foo' 'password' 'boo')
Updated documentation to follow soon...
Two of the changes in this version of SAWS are to allow services to be invoked over HTTPS and to select an appropriate default port number (80 for HTTP, 443 for HTTPS) unless a different port is specified in the second element of the left argument to SAWS.Call.
Hope this helps!
After doing a SAWS.Init...
Using SAWS.TRACE←1, you can see the following invocation of SAWS.Call seems to produce a SOAP 1.1 call in the proper format. However, at least on my machine, the request times out as well.
'https://webservices.zen.co.uk' ⍬ 'broadband/v3.11/serviceengine.asmx' SAWS.Call
'broadband/v3.11' 'Authenticate'('username' 'foo' 'password' 'boo')
Updated documentation to follow soon...
Two of the changes in this version of SAWS are to allow services to be invoked over HTTPS and to select an appropriate default port number (80 for HTTP, 443 for HTTPS) unless a different port is specified in the second element of the left argument to SAWS.Call.
Hope this helps!
- Attachments
-
- saws-20100422.zip
- (158.9 KiB) Downloaded 760 times
-
Brian|Dyalog - Posts: 116
- Joined: Thu Nov 26, 2009 4:02 pm
- Location: West Henrietta, NY
Re: Conga, SOAP and Web Services - Where to Begin?
Dick Bowman wrote:I wonder whether it would be helpful for Dyalog to themselves offer a Web Service that we can use for development and testing.
Not a bad idea, but I don't think we can find resources to set this up "perfectly reliably" in the short term. The example in the SAWS document seems to be working fine:
- Code: Select all
#.SAWS.DRC.Init''
⎕←z←'www.webserviceX.NET/' 80 'stockquote.asmx' SAWS.Call '' 'GetQuote' ('symbol' 'k')
0 GetQuote 1 GetQuoteResult <StockQuotes><Stock><Symbol>K</Symbol><Last>53.98</Last><Date>4/22/2010</Date><Time>4:00p ... blah blah blah ...
⍝ Doubly nested XML, but we can dig it out:
⎕xml ⊃(2 2⊃z)[1;3]
0 StockQuotes 3
1 Stock 3
2 Symbol K 5
2 Last 53.98 5
2 Date 4/22/2010 5
...etc...
2 Name Kellogg Company C 5
-
Morten|Dyalog - Posts: 454
- Joined: Tue Sep 09, 2008 3:52 pm
Re: Conga, SOAP and Web Services - Where to Begin?
My concern is that "they" might decide to change the Web Service interface at some point in the future - leaving us with examples that fail. Which I suspect may be what's happened with the Zen Internet example I posted. If anyone is interested in that - I have been able to grab data from it via a third-party Perl interface, so we know that something's working over there.
Visit http://apl.dickbowman.com to read more from Dick Bowman
-
Dick Bowman - Posts: 235
- Joined: Thu Jun 18, 2009 4:55 pm
7 posts
• Page 1 of 1
Return to Windows: GUI, COM/OLE/ActiveX
Who is online
Users browsing this forum: No registered users and 1 guest
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group