This tutorial demonstrates how to replace a product in a subscription by creating an order. You will remove a product from the subscription and add a different product to the subscription.
In this tutorial, you will set the following dates to today's date:
You will set the following dates to tomorrow's date:
To replace a product in a subscription:
Navigate to Customers > Orders.
The Orders page opens.
Click the icon at the top right:
The Create New Order page opens.
In the Account field, enter the name of the account that owns the subscription.
Click Modify Existing Subscription.
In the Select an Existing Subscription area, search for the subscription to update.
Click the Select button in front of the subscription to update.
In the Subscriptions Details area, click the icon next to the product you are to remove, then click Remove Product. The remove product window opens.
In the remove product window, specify Contract Effective Date, Service Activation Date, and Customer Acceptance Date for the operation. See Billing Trigger Dates for more information.
Click Continue.
In the Associated Subscriptions area, click the icon to display the operation options you can perform on the selected subscription, and then click Add Product.
The Order Overview page opens.
In the Contract Effective Date, Service Activation Date, Customer Acceptance Date fields, select the proper dates. See Billing Trigger Dates for more information.
The Products and Charges area lists all the available products. You can search and quickly identify a product to add.
Click the ">" next to the product to display the product rate plans, and then click Add to select a rate plan.
Click Continue.
Zuora displays an overview of the order.
Click Activate to activate the order.
You can use the "Create and activate order" operation to replace a product in a subscription.
Prior to the Orders feature being enabled, you would have used the "Update subscription", "Amend", or "CRUD: Create amendment" operation.
To replace a product in a subscription by creating an order:
Determine the values of the following variables:
Variable | Description |
---|---|
$SubscriptionNum |
The number of the subscription to update. For example, A-S00000001 . |
$AccountNum |
The number of the account that will own the order. For example, A00000001 . |
$RPIdRemove |
The ID of the rate plan to remove from the subscription. For example, 8a8081085e0d4b70015e4b844495058d . |
$ProductRPId |
The ID of the product rate plan to add to the subscription. For example, 8a8081085d834928015d9ce60ef41acf . |
$ProductRPChargeId |
The ID of the product rate plan charge to use when adding the product rate plan. For example, 8a8081085d834928015d9ce6ae821ad1 . |
$Today |
Today's date. For example, 2017-09-30 . |
$Tomorrow |
Tomorrow's date. For example, 2017-10-01 . |
Use the "Create and activate order" operation to create an order under an existing account:
Request | POST /v1/orders/ |
---|---|
Request Body |
{ "orderDate": $Today, "existingAccountNumber": $AccountNum, "subscriptions": [ { "subscriptionNumber": $SubscriptionNum, "orderActions": [ { "type": "RemoveProduct", "triggerDates": [ { "name": "ContractEffective", "triggerDate": $Today }, { "name": "ServiceActivation", "triggerDate": $Today }, { "name": "CustomerAcceptance", "triggerDate": $Today } ], "removeProduct": { "ratePlanId": $RPIdRemove } }, { "type": "AddProduct", "triggerDates": [ { "name": "ContractEffective", "triggerDate": $Tomorrow }, { "name": "ServiceActivation", "triggerDate": $Tomorrow }, { "name": "CustomerAcceptance", "triggerDate": $Tomorrow } ], "addProduct": { "productRatePlanId": $ProductRPId, "chargeOverrides": [ { "productRatePlanChargeId": $ProductRPChargeId, "pricing": { "recurringVolume": { "quantity": 20 } } } ] } } ] } ], "processingOptions": { "runBilling": false, "collectPayment": false } } |
To create the order under a new account instead of an existing account, specify the newAccount
field instead of the existingAccountNumber
field.
To preview invoices for the updated subscription, use the "Preview order" operation.
When the Orders feature is enabled in your Zuora tenant, the SOAP API is not available. You must migrate any SOAP integrations to use the REST API instead. See Migrating From the SOAP API for the SOAP equivalent of this tutorial.