Conga Product Documentation

Welcome to the new doc site. Some of your old bookmarks will no longer work. Please use the search bar to find your desired topic.

Show Page Sections

Splitting an Order by threshold

This API divides an existing order (parent order) into multiple orders (child orders) based on the threshold defined in the Order System Properties.

Important:

Important

The split threshold can not be defined independently. Criteria should be added while calling the API. Apttus Order Management recommends you select the common fields like a price list id.

API Details

API

Signature

splitOrder

webService static Apttus_Config2.CPQStruct.SplitOrderResponseDO splitOrder(Apttus_Config2.CPQStruct.SplitOrderRequestDO)

Parameters

Name

Type

Description

request

CPQStruct.SplitOrderRequestDO

The request data object.

Request Data Object - CPQStruct.SplitOrderRequestDO

Field

Type

Required?

Description

OrderId

ID

Yes

The parent order ID to create a split order.

OrderLineNumbers

ID

Yes

order line numbers to be part of a new split order.

API Response

Response Data Object - CPQStruct.SplitOrderResponseDO

Field

Type

Description

SplitOrderSO

ID

The Id of the newly created split order.

Code Sample

The following code sample enables you to split an existing valid order into multiple orders using OrderId and OrderLineNumbers.

Sample snippet:

Apttus_Config2.CPQStruct.SplitOrderRequestDO request = new Apttus_Config2.CPQStruct.SplitOrderRequestDO();
    request.OrderId = 'a2n7A0000002tRi';
//Split based on threshold which is defined in the order system properties.Split Order Threshold
//Must add a common criterion like price list id while splitting with a threshold 
    request.SplitCriteriaFields.add('Apttus_Config2__PriceListId__c');
    Apttus_Config2.CPQStruct.SplitOrderResponseDO result = Apttus_Config2.OrderWebService.splitOrder(request);

Integration Details

Use the following information in your integrations with Conga CPQ Web Services API. Refer to Request and Response XML for information on how to get started.

Request and Response XML

Example Request

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ord="http://soap.sforce.com/schemas/class/Apttus_Config2/OrderWebService" xmlns:cpq="http://soap.sforce.com/schemas/class/Apttus_Config2/CPQStruct">
   <soapenv:Header>
      <ord:SessionHeader>
         <ord:sessionId>00D7A0000009QII!ARUAQHamHUdKQgPNeSQPZdo719RxuQc_XBiAYgTnBaswMACJu1z.5fLlZYp0P6kNf1jKKe4tVrdBb7HnO9NqePMYF.s.rdq8</ord:sessionId>
      </ord:SessionHeader>
   </soapenv:Header>
   <soapenv:Body>
      <ord:splitOrder>
         <ord:request>
            <cpq:OrderId>a2n7A0000002tvs</cpq:OrderId>
				<!Adding price list ID>
            <cpq:SplitCriteriaFields>a173C000000fHFQ</cpq:SplitCriteriaFields>
         </ord:request>
      </ord:splitOrder>
   </soapenv:Body>
</soapenv:Envelope>

Example Response

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns="http://soap.sforce.com/schemas/class/Apttus_Config2/OrderWebService" xmlns:SplitOrderResponseDO="http://soap.sforce.com/schemas/class/Apttus_Config2/CPQStruct" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <soapenv:Body>
      <splitOrderResponse>
         <result>
            <SplitOrderResponseDO:SplitOrderSO xsi:nil="true"/>
         </result>
      </splitOrderResponse>
   </soapenv:Body>
</soapenv:Envelope>

Use Case

Use Case - A Manufacturing company quotes 450 hardware items on quote Q1. An order O1 has been generated with 450 line items. The back-office ERP system leveraged for the fulfillment of hardware items can only process 100 lines in a given order. Hence, the order needs a split.

The splitOrder API allows the users to split an order based on the threshold defined in the Order System Properties.

The Split result- The split operation creates five new orders where four orders with 100 lines and one with 50 lines. The original order will be empty. However, there is no impact on the configuration defined in the quote. on the quote is not impacted.