Set up SubmitContractOrder Plugin

Knowledge Center > Zuora CPQ > Zuora Connector for Salesforce CPQ > Configure Zuora Connector for Salesforce CPQ > Set up SubmitContractOrder Plugin

Set up SubmitContractOrder Plugin

This functionality is only available if you have the Orders feature enabled.

When you submit Salesforce Contract to Zuora, Zuora Connector for Salesforce CPQ will backfill the subscription-related information to the Salesforce records. To enable the backfill process, you must add the required custom fields. 

Add Required Custom Fields in Zuora

To enable the Order backfill upon Contract submission to Zuora, you must add the following custom fields to Zuora Order Action.

The custom fields must be added as indexed custom fields.

Object Custom Field Label  API Name
Zuora Order Action SBQQ Subscription Number sfdcSubscriptionNumber__c
SBQQ Subscription Id sfdcSubscriptionId__c
Description sfdcDescription__c

Add Required Custom Fields in Salesforce

You must add the equivalent custom fields in Salesforce Contract and SBQQ__Subscription__c. The following table lists all the required custom fields.

Object Custom Field Label  API Name
Salesforce Contract Cancellation Order Number CancellationOrderNumber__c
Salesforce SBQQ__Subscription__c Zuora Order Number OrderNumber__c
Zuora Order Id OrderId__c
Zuora Order Action Id OrderActionId__c
Zuora Order Action Type OrderActionType__c
Zuora Charge Number ChargeNumber__c

Validation

When you click Send Order on the Contract Detail page,  an Order Summary will be generated. Upon deserialization of the SubmitContractOrder.Result, the following validation will be run before an Order Summary object is successfully created:

return orderAction.type != null 
 && orderAction.customFields != null
 && orderAction.customFields.get('sfdcSubscriptionNumber__c') != null
 && orderAction.customFields.get('sfdcSubscriptionId__c') != null
 && orderAction.customFields.get('sfdcDescription__c') != null;

Although an Order Summary only consists of the OrderAction type and OrderAction description, it will not be created unless all the required custom fields of the OrderAction are populated. Missing value of any required custom field will cause the backfill to fail. 

Field Mappings

The following table lists the field mappings of the backfill process.

Salesforce CPQ Object

Salesforce Field

Zuora Field

Zuora Object

Notes

SBQQ__Subscription__c

OrderNumber__c

OrderNumber

Order

 

SBQQ__Subscription__c

OrderId__c

Id

Order

 

SBQQ__Subscription__c

OrderActionId__c

Id

OrderAction

 

SBQQ__Subscription__c

OrderActionType__c

-

-

Derived programmatically and stored in salesforce.

Possible values are : AddProduct, UpdateProduct, RemoveProduct, and RenewSubscription.

SBQQ__Subscription__c

ChargeNumber__c

ChargeNumber

RatePlanCharge

 

SBQQ__Subscription__c

RatePlanId__c

RatePlanId

RatePlanCharge

 

SBQQ__Subscription__c

RatePlanChargeId__c

Id

RatePlanCharge

 

Limits

The backfill process has the following limits:

  • As the Orders REST API only supports querying an Order by the OrderNumber, the Order Backfill process service could not handle the case where the OrderNumber is not back populated due to timeout or any other unexpected reason after the creation of the subscription.
  • As the Orders REST API does not support querying Orders by a list of OrderNumbers, the Orders have to be queried one by one. There might be a performance issue if the volume is high in a specific transaction. In that case, the mitigation is to skip the backfill process if the Contract has been backfilled previously.
  • Multi-Entity is not supported.
  • ZSBConnectorUtils.makeAmendmentSummaries() does not return correct amendment details for subscriptions with UpdateProduct actions when the Orders feature is enabled for your tenant. 
Last modified

Tags

This page has no custom tags.

Classifications

(not set)