Skip to Content
author's profile photo Former Member
Former Member

How to edit HTTP-Header-Fields from a generated consumer-proxy ?

Hey,

i want to consume a webservice via SOAP, i've already created a proxyclass with a given WSDL and manually created a logical-port via SOAMANAGER.

Is there any possibility to edit the HTTP-Header-Fields of a generated consumer-proxy, because the generated HTTP-Header has a wrong field. In the gernerated header there is an extra field for soapaction="urn:getVersion" but it should be integrated in the Content-Type field.

working header generated header

POST https://cig.dhl.de/services/sandbox/soap HTTP/1.1

Accept-Encoding: gzip,deflate

Content-Type: application/soap+xml;charset=UTF-8;action="urn:getVersion"

Content-Length: 549

Host: cig.dhl.de

Connection: Keep-Alive

User-Agent: Apache-HttpClient/4.1.1 (java 1.5)

POST /services/sandbox/soap HTTP/1.1

Content-Type: application/soap+xml; charset=utf-8

Content-Length: 584

accept-language: de sap-language: D

soapaction: "urn:getVersion"

accept: application/soap+xml

callingtype: SA sap-srt_id: 20160107/152338/v1.00_final_6.40/000C295946371ED5ADA9470FDE7ABF8D

user-agent: SAP NetWeaver Application Server (1.0;731) host: cig.dhl.de

accept-encoding: gzip

I`ve used SOAPUI to create a working request with a working header and i`ve also created a working request in SAP using this methods:

CALL METHOD lo_http_client->request->set_header_field

CALL METHOD lo_http_client->send

CALL METHOD lo_http_client->receive

+ SOAP-Message with concatenated strings.


I have to use the generated proxyclass to use it's methods but therefore i need to edit the HTTP-Header first.

Are there any solutions for this problem ?

Thank you for your help !




Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Jan 08, 2016 at 11:58 AM

    Hey guys,

    i solved the problem by myself, i had to configure the logical-port settings in the SOAMANAGER.

    there is a tab called "transport settings", i had to select "MTOM" at the optimized XML-transfer field.

    Everything is working fine now.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.