Skip to content

/AWS1/IF_MPG=>REJECTAGREEMENTCANCLREQUEST()

About RejectAgreementCancellationRequest

Allows buyers (acceptors) to reject a cancellation request that is in PENDING_APPROVAL status. Once rejected, the cancellation request transitions to REJECTED status and the agreement remains active. Buyers must provide a reason for the rejection.

Only cancellation requests in PENDING_APPROVAL status can be rejected. A ConflictException is thrown if the cancellation request is in any other status.

Method Signature

METHODS /AWS1/IF_MPG~REJECTAGREEMENTCANCLREQUEST
  IMPORTING
    !IV_AGREEMENTID TYPE /AWS1/MPGAGREEMENTID OPTIONAL
    !IV_AGREEMENTCANCLREQUESTID TYPE /AWS1/MPGAGRMNTCANCLREQUESTID OPTIONAL
    !IV_REJECTIONREASON TYPE /AWS1/MPGAGRMTCANCREQREJCTRSN OPTIONAL
  RETURNING
    VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_mpgrejagrmtcancreqout
  RAISING
    /AWS1/CX_MPGACCESSDENIEDEX
    /AWS1/CX_MPGCONFLICTEXCEPTION
    /AWS1/CX_MPGINTERNALSERVEREX
    /AWS1/CX_MPGRESOURCENOTFOUNDEX
    /AWS1/CX_MPGTHROTTLINGEX
    /AWS1/CX_MPGVALIDATIONEX
    /AWS1/CX_MPGCLIENTEXC
    /AWS1/CX_MPGSERVEREXC
    /AWS1/CX_RT_TECHNICAL_GENERIC
    /AWS1/CX_RT_SERVICE_GENERIC.

IMPORTING

Required arguments:

iv_agreementid TYPE /AWS1/MPGAGREEMENTID /AWS1/MPGAGREEMENTID

The unique identifier of the agreement associated with the cancellation request.

iv_agreementcanclrequestid TYPE /AWS1/MPGAGRMNTCANCLREQUESTID /AWS1/MPGAGRMNTCANCLREQUESTID

The unique identifier of the cancellation request to reject.

iv_rejectionreason TYPE /AWS1/MPGAGRMTCANCREQREJCTRSN /AWS1/MPGAGRMTCANCREQREJCTRSN

The reason for rejecting the cancellation request (1-2000 characters). This message is visible to the seller.

RETURNING

oo_output TYPE REF TO /aws1/cl_mpgrejagrmtcancreqout /AWS1/CL_MPGREJAGRMTCANCREQOUT

Examples

Syntax Example

This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.

DATA(lo_result) = lo_client->rejectagreementcanclrequest(
  iv_agreementcanclrequestid = |string|
  iv_agreementid = |string|
  iv_rejectionreason = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  lv_agreementid = lo_result->get_agreementid( ).
  lv_agreementcancellationre = lo_result->get_agreementcanclrequestid( ).
  lv_agreementcancellationre_1 = lo_result->get_status( ).
  lv_agreementcancellationre_2 = lo_result->get_statusmessage( ).
  lv_agreementcancellationre_3 = lo_result->get_reasoncode( ).
  lv_agreementcancellationre_4 = lo_result->get_description( ).
  lv_timestamp = lo_result->get_createdat( ).
  lv_timestamp = lo_result->get_updatedat( ).
ENDIF.