cancel
Showing results for 
Search instead for 
Did you mean: 

How to Call Web Service BusinessPartnerSUITEBulkReplicateConfirmation_Out in System Caller BADI

mines
Participant
0 Kudos
360

We have a requirement to sent CR status , User details and few other details in  BusinessPartnerSUITEBulkReplicateConfirmation_Out when CR is Rejected.

So, how to call this BusinessPartnerSUITEBulkReplicateConfirmation_Out Web service in System Caller Badi and how to modify Webservice note during CR Rejected. 

View Entire Topic
Sijin_Chandran
Active Contributor
0 Kudos

Hello, 

1.)


how to modify Webservice note during CR Rejected. 

With the above ask I guess you want to alter the contents of Note property which we have under Log node/entity of BusinessPartnerSUITEBulkReplicateConfirmation_Out , if yes then utilize the below BADI's Method which gets triggered when the BP is successfully replicated and the Confirmation is sent outwards to the caller system.

BADI: MDG_SE_BP_BULK_REPLRQ_IN

Method: IF_MDG_SE_BP_BULK_REPLRQ_IN~OUTBOUND_PROCESSING

Sijin_Chandran_0-1742885851863.png

the above Structure has the LOG node in that.

2.) 


So, how to call this BusinessPartnerSUITEBulkReplicateConfirmation_Out Web service in System Caller Badi


ABAP Class "CO_MDG_BP_RPLCTCO" is the Internal ABAP Class(SE24) artefact for this WebService,

So try calling the same as highlighted below using "LOGICAL_PORT" you would have configured in the SOAMANAGER,

*DATA xxxxxxxx TYPE REF TO CO_MDG_BP_RPLCTCO.

TRY.
CREATE OBJECT xxxxxxxx
* EXPORTING
* destination =
* logical_port_name =
.
CATCH cx_ai_system_fault .
ENDTRY.

*TRY.
CALL METHOD xxxxxxxx->bp_suitebulk_replct_conf
EXPORTING
output =
.
* CATCH cx_ai_system_fault.
*ENDTRY.

Used the below option of ABAP Editor "Pattern" for getting the above code,

Sijin_Chandran_1-1742886145856.png

Give the above solutions a try.

Thanks,

Sijin

milkamble65
Discoverer
0 Kudos

Thanks @Sijin_Chandran for the reply.

In our case, we need to send the BP confirmation out payload to CPI. So the service call, does create object still work with logical port or calling destination is required?

Sijin_Chandran
Active Contributor
0 Kudos
@milkamble65 WebService "BusinessPartnerSUITEBulkReplicateConfirmation_Out" in S4 System is indeed a Web Service of Category 'Service Consumer' that means we are consuming a Service from Other system(the Target system). Since here the Target system is CPI so my question is would you be creating a Service Provider exactly mimicking the 'BusinessPartnerSUITEBulkReplicateConfirmation_Out' in CPI? I remember we consuming a SOAP WS from CPI long before and if I am not wrong we were able to get it done using PORT only. Using Destination in this context am not aware of.