Skip to Content

get service provider payload

Hi experts,

I'm providing a webservice based on a function group and differnt functions within to process data within a Solman system. Also I am able to consume a webservice from an external system. For the consumer I am able to get the payload data following the hints from the help page

Querying the Payload - Creating and Configuring Service Providers and Service Consumers - SAP Library.

Now, I also would like to get the payload data from the incoming request. I tried it as the help page states using the

method GET_PAYLOAD_HANDLER. But system responses with "Zxxx is not a class/interface"...

Can anyone give me some advise?

Thanks & regards, RP

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Posted on Jul 20, 2016 at 01:03 PM

    In the link of the sap Library you mentioned, the sample code is about "independently of a proxy instance" ; we usually query it using a proxy instance as follows (no need of a class) as (almost correctly) explained in other sap Library page :

     lo_clientProxy TYPE REF TO co_clientProxy, 
     lo_payload_protocol TYPE REF TO if_wsprotocol_payload 
     lo_payload        TYPE REF TO if_ws_payload. 
    CREATE OBJECT lo_clientProxy. 
    *Get Protocol Class Using Method GET_PROTOCOL 
     lo_payload_protocol ?=  
     lo_clientProxy->get_protocol( if_wsprotocol=>payload ). 
    CALL METHOD lo_clientProxy->execute_synchronous 
     EXPORTING output  = ls_request 
     IMPORTING input   = ls_response. 
    *Use Protocol Methods 
     lo_payload = lo_payload_protocol->get_sent_request_payload( ). 
    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.