This API modify or amend a Customer Purchase Orders without changing the value of the order line items (Composite API).

API Details


APISignature
amendCustomerPOwebService static Apttus_Config2.CPQStruct.AmendCustomerPOResponseDOamendCustomerPO(Apttus_Config2.CPQStruct.AmendCustomerPORequestDO)

Parameters

Name

Type

Description

request

Apttus_Config2.CPQStruct.AmendCustomerPORequestDO

The request data object.

Request Data Object - Apttus_Config2.CPQStruct.AmendCustomerPORequestDO

Field

Type

Required?

Description

CustomerPOId

ID

Yes

Reference to the order. Order Id can be any one of the following:

  • Order in "Accept, Partially Processed" status that requires amendment
  • Order in "In Amendment" status for which additional line item changes are required
CustomerPOItemsList<CustomerPOItem__C>NoCPO Items to be amended

API Response

Response Data Object - CPQStruct.AmendCustomerPOResponseDO

Field

Type

Description

AmendCustomerPOSOStandard Data ObjectThe fields of the AmendOrder Object

AmendedCustomerPOItems

List

List of amended order items

Code Sample

The following sample enables you to amend an order for a valid order with an Order Id.

// create the amend request CPQStruct.AmendCustomerPORequestDO request = new CPQStruct.AmendCustomerPORequestDO(); 
request.customerPOId = customerPO.ID;  
request.CustomerPOItems = CustomerPOItems; 
CPQStruct.AmendCustomerPOResponseDO result = CustomerPOWebService.amendCustomerPO(request);
system.debug(result.AmendCustomerPOSO); 
system.debug(result.AmendedCustomerPOItems);
CODE