Integrator - HTTP Service - OutboundXML Handler - Custom Content-Type in HTTP Header
Posted: Wed Aug 22, 2018 7:03 pm
Hi all,
I am Using LI HTTP Service - OutboundXML Handler. In the SEND command I set custom Content-Type in HTTP Header like so:
SEND HOST(example.org) SECURE(*YES) CONTENT(application/soap+xml;action="urn:Example/Greece/GetExample") SERVICE_EXCHANGE(*FIELD) URI(/GetExample.svc) HANDLER(OutboundXML) XSL(cdrq)
However, when LI constructs the HTTP Request, for some reason, it inserts the custom Content-Type in HTTP Header always in lowercase.
=== From Trace File ===
Using content type : application/soap+xml;action="urn:example/greece/getexample"; charset=utf-8
=== From Trace File ===
As a result, when I try to make the call the remote web sevrice rejects the request as the NameSpace address is case sensitive. Moreover, I cannot use the SET command in order to set custom HTTP headers as the header I want to set is already defined by the CONTENT(*SOAP) keyword in the SEND Command.
=== Example of HTTP Headers when using SET Command to set custom HTTP Header & CONTENT(*SOAP) keyword in SEND Command ===
POST /GetExample.svc HTTP/1.1
Host: example.org
User-Agent: LANSA Integrator UserAgent/13.2.0 (Server)
Content-Type: application/soap+xml; charset=utf-8
Content-Length: 728
X-User-Agent-Locale: el_GR
X-User-Agent-Identity: USERAGENT:znMiXgfpbiMV3dVEwkJIfYyEyZM=
Content-Type: application/soap+xml;charset=UTF-8;action="urn:Example/Greece/GetExample"
=== Example of HTTP Headers when using SET Command to set custom HTTP Header & CONTENT(*SOAP) keyword in SEND Command ===
So, how can we make LI to set HTTP Headers and especially Content-Type to Proper-Case values rather Lower-Case values.
Thanks in advance for your answers.
Regards,
Nick.
I am Using LI HTTP Service - OutboundXML Handler. In the SEND command I set custom Content-Type in HTTP Header like so:
SEND HOST(example.org) SECURE(*YES) CONTENT(application/soap+xml;action="urn:Example/Greece/GetExample") SERVICE_EXCHANGE(*FIELD) URI(/GetExample.svc) HANDLER(OutboundXML) XSL(cdrq)
However, when LI constructs the HTTP Request, for some reason, it inserts the custom Content-Type in HTTP Header always in lowercase.
=== From Trace File ===
Using content type : application/soap+xml;action="urn:example/greece/getexample"; charset=utf-8
=== From Trace File ===
As a result, when I try to make the call the remote web sevrice rejects the request as the NameSpace address is case sensitive. Moreover, I cannot use the SET command in order to set custom HTTP headers as the header I want to set is already defined by the CONTENT(*SOAP) keyword in the SEND Command.
=== Example of HTTP Headers when using SET Command to set custom HTTP Header & CONTENT(*SOAP) keyword in SEND Command ===
POST /GetExample.svc HTTP/1.1
Host: example.org
User-Agent: LANSA Integrator UserAgent/13.2.0 (Server)
Content-Type: application/soap+xml; charset=utf-8
Content-Length: 728
X-User-Agent-Locale: el_GR
X-User-Agent-Identity: USERAGENT:znMiXgfpbiMV3dVEwkJIfYyEyZM=
Content-Type: application/soap+xml;charset=UTF-8;action="urn:Example/Greece/GetExample"
=== Example of HTTP Headers when using SET Command to set custom HTTP Header & CONTENT(*SOAP) keyword in SEND Command ===
So, how can we make LI to set HTTP Headers and especially Content-Type to Proper-Case values rather Lower-Case values.
Thanks in advance for your answers.
Regards,
Nick.