I need to talk to a WSA which requires a custom HTTP header "Authorization" followed by a value from a variable, so the WSA POST call would look like so:
POST https://www.wsa.com:443/ws/1.4 HTTP/1.1
Accept-Encoding: gzip,deflate
Content-Type: text/xml;charset=UTF-8
SOAPAction: "BrowseItems"
Authorization: XYZZY
Content-Length: 306
Host: www.wsa.com:443
Connection: Keep-Alive
User-Agent: Apache-HttpClient/4.1.1 (java 1.5)
<soap XML here>
I haven't been able to find a way to do this with the OE web service adapter, so I'm hoping someone else has done something like this and is willing to share how they solved this particular problem? Failing that, I'd have to go to a 3rd party language and I'd prefer to avoid that if possible.
Tim,
You are calling a WSA hosted SOAP service from an ABL client via a SERVER handle? I was not sure where the OE WSA was in your question.
In general the ABL language does not allow you access to any of the HTTP transport's headers when calling out a SOAP service.
Yes - I'm doing something like this:
CREATE SERVER hWebService.
hWebService:CONNECT("-WSDL "www.wsa.com/.../1.4").
and then making WSA calls from there.
"wsa.com" requires an "Authorization" header on the HTTP POST component of the call, which, from I'm gathering from your post, OE can't do.
Tim,
No, your ABL code cannot control the value in the HTTP Authorization header. You will need to seek alternatives.
Ok, I got some COM code from a PEGger which looks like it'll do what I want.
Thx!
Tim,
Would you consider adding an 'idea' about adding customized HTTP header support to the SOAP web service [out] support? Then hopefully others who have run into this type of problem could add their input.
Are you doing this on a windows client?
I certainly will!
Annnnd - here it is!
community.progress.com/.../add_ability_to_use_custom_http_headers_in_wsa.aspx
Yes, I did this on a windows client.
turns out I'm not the only one looking for custom HTTP headers...