You can create a custom plan using an already-created plan template. You can create a custom plan for:

  • An Order Line Item (OLI) or a set of OLIs containing One-Time or Recurring products.
  • An Asset Line Item (ALI) (CPQ cart line) or a set of line items containing One-Time or Recurring products.

A custom plan can be of a milestone or term-based type.

Currently, the API works for the Standalone products. It may not work for some of the Bundle scenarios.

 

For more on how Billing works on the Conga Platform, see Understanding the Billing Architecture on Conga Platform.

Use Case: Creating a Milestone Plan Using a Template for an OLI and ALI

Before creating a milestone custom plan, you must create a plan template. To learn more about creating a plan template, see Creating a Plan Template. 

The requirement is to bill the customer in two installments, 30% of the contract amount on the third day of the first month and the remaining 70% after one month. You have supplied the following details in the plan template:

Plan Template ID

Plan Type

Periods Needed

Number of Installments

Based On

Computation Method

Start Date Based On

Active

PT-1MilestoneFalse2PercentageCustom

Start Date from the Line Item

False

Details of the two lines (because there are two installments, hence two line items) are as follows: 

ID

Plan Template ID

Offset Type

Offset Number

Percent

Payment Term

PTL-1PT-1Days330.00000000Term 1
PTL-2PT-1Month170.00000000Term 2

Once the above template is Active, it can be used to create a custom plan using an API. You'll now see how a plan is created for the transaction lines (OLIs/Line Items) using the above template.

Prerequisites

  • For creating a custom plan for an OLI
    • OLI is not Activated.

    • The order is not Activated.

    • The intended OLI for which a billing plan is to be created must refer to the same Order.

  • For creating a custom plan for Line Items
    • The intended Line Items for which a billing plan is to be created refers to the same Proposal.

API Input Parameters

To create a custom plan you must enter the following parameters for every set of OLI or ALI:

  • Name: My_Custom_Plan_1
  • Use Plan Template: True

    If you mark this field as True, you must enter the plan template ID in the next step. 

  • Plan Template ID: PT-1
  • Description: Describe the custom plan for the ABC Company (optional).

  • OLI ID or Line Item ID: O-1 or Line Item-1

The start date is  (start date on OLI). When the custom plan is created it shows the following values:

Custom Plan ID

ID (Order or Proposal)

Plan Template

Description

Name

No. of Installments

Plan Type

Periods Needed

Based On

Computation Method

Status

CP-1O-1 PT-1Custom Plan for ABC CompanyMy_Custom_Plan_12MilestoneFalsePercentageCustomNew

The Plan Items for the OLIs (or Line Items) are auto-created with the following details:

ID

Custom Plan ID

Percent

Milestone Expected Date

Payment Term

CPL-1CP-130.00000000

04-January-2024

Term 1
CPL-2CP-170.00000000

04-February-2024

Term 2

When you initiate billing, the billing header will have two billing schedule records containing 30.0000000% and 70.00000000% of the TCV (Sales) respectively.

Activating the Order and Initiating the Billing

When you activate the OLI, associate the above custom plan to it, and initiate the billing process, the Billing Schedule Records (BSRs), and the Billing Schedule Details (BSDs) guided per the custom plan are created. These milestone BSRs and BSDs are slightly different from the recurring products.

On the BSRs:

  • The Actual Fee Amount field is Null.
  • The Ready for Invoice Date field is Null.
  • The Status is Pending Milestone.
  • The Payment Term field has the same value as indicated in the plan line item.

On the BSDs:

  • The Record Type field is Milestone.
  • The Milestone Expected Date field has the same value as indicated in the plan line item.

  • The Milestone Percent field has the same value as indicated in the plan line item.

  • The Milestone Status is Expected

  • The Derived Invoice Status field is Pending.

Consider the example:

A new sale is initiated for a service with a TCV (Sales) of USD 1,200.00. The above milestone custom plan is associated with the OLI before its activation.  The start date is 01-January-2024 and the end date is 31-December-2024.

You have activated the order (OLI-1) and initiated the billing to create two BSRs and BSDs per the custom plan.

BSRs have the following data:

BSR IDBH IDActual Fee AmountReady for Invoice DatePayment TermInvoice Status
BSR-1BH-1NullNullTerm 1Pending Milestone
BSR-2BH-1NullNullTerm 2Pending Milestone

BSDs have the following data:

BSD IDBSR IDRecord TypeCategoryActual Fee AmountMilestone PercentMilestone Expected DateMilestone StatusDerived Invoice Status
BSD-1BSR-1MilestoneFeeNull30.00000000

04-January-2024

ExpectedPending
BSD-2BSR-2MilestoneFeeNull70.00000000

04-February-2024

ExpectedPending

You must complete the milestone-type BSDs to compute the actual fee amount. The process to complete the milestone-type BSDs is given in Completing the Milestone.

Before you complete the milestone, you must query the milestone-type BSDs using an API.

Querying BSDs of Milestone Type

You can query the milestone BSDs based on Order Line Item ID, Billing Header ID, or Billing Schedule Records ID. To query for milestone-type BSDs, you must pass the values for the following parameters:

Object ID: Pass the Order Line Item ID, Billing Header ID, or Billing Schedule Records ID.

Milestone Expected From Date: You can pass a date or keep it as Null.

Milestone Expected To Date: You can pass a date or keep it as Null.

Show Data For: You can select from All or Pending.

The Milestone Expected From Date and Milestone Expected To Date fields are optional. You can choose to enter either or skip both.

When you initiate the API to query milestone-type BSDs based on the input criteria in the above fields, it filters the relevant results.

In the above example, if you enter OLI-1 in the Object field and select All in the Show Data For field, you can see the following data for the filtered BSDs:

OLI IDBH IDBSR IDBSD IDRecord TypeMilestone Expected DatePercentMilestone Completion DateMilestone Status
OLI-1BH-1BSR-1BSD-1Milestone

04-January-2024

30.00000000NAExpected
OLI-1BH-1BSR-2BSD-2Milestone

04-February-2024

70.00000000NAExpected

Completing the Milestone

The actual fee amount is not computed instantly when the milestone-type BSDs are created. You must complete the milestone to invoke the logic to compute the actual fee amount of the BSD. To complete the milestone, enter the following values:

  • Billing Schedule Detail Record ID

  • Milestone Completion Date

  • Milestone Completed By - Default for logged-in users.

When you call the API to complete the milestone with the above set of data, the following fields are updated on the BSD, BSR, and BH:

On the BSD:

  • The Actual Fee Amount field on the BSD is updated to a value equal to the product of Milestone Percent and the Current Unbilled Amount.
  • The Milestone Status is updated to Complete, Derived Invoice Status to Pending, and the Milestone Completion Date to the date you entered.

On the BSR:

  • The values for the Actual Fee Amount and Ready for Invoice Date fields are fetched from the Actual Fee Amount and Milestone Completion Date fields of the BSD.
  • Invoice Status is updated to Pending Billing.

On the BH, the Pending Invoice Amount field is updated accordingly with the rolled-up amount from the BSR.

In the above example, suppose you want to complete the milestone of BSD-1. You entered the BSD ID as BSD-1 and the Milestone Completion Date as 05-March-2024.

On execution, the BSD shows the following data:

BSD IDBSR IDActual Fee AmountMilestone Expected DateMilestone Completion DateMilestone StatusDerived Invoice Status
BSD-1BSR-1USD 360.0004-January-202405-March-2024CompletedPending

The BSR is populated with the following data:

BSR IDBH IDActual Fee AmountReady For Invoice DateInvoice Status
BSR-1BH-1USD 360.0005-March-2024Pending Billing

The actual fee amount is calculated and updated on the BSD after it is completed, then this amount is rolled up to the BSR. From the BSR the value is fetched and updated on the BH. So the Pending Invoice Amount field on the BH is updated to USD 360.00 which is 30.00000000% of USD 1,200.00.

Creating a Term-Based Plan Using a Template for an OLI and ALI

Before you start creating a term-based custom plan, you must create a plan template. To learn more about creating a plan template, see Creating a Plan Template. 

The requirement is to bill the customer in three equal installments, in the fourth month, the seventh month, and the ninth month. You have supplied the following details in the plan template:

Name

Plan Type

Periods Needed

Number of Installments

Based On

Computation Method

Start Date Based On

Active

PT-2Term basedTrue3PercentageEqual Distribution

Start Date from the Line Item

False

Details of the three lines (because the number of installments is 3, hence three line items) are as follows: 

ID

Plan Template ID

Offset Type

Offset Number

Percent

Payment Term

PTL-1PT-2Month1NATerm 1
PTL-2PT-2Month3NATerm 2
PTL-3PT-2Month2NATerm 3

Once the above template is Active, it can be used to create a custom plan using an API. You'll now see how a Plan is created for the transaction lines (OLIs or Line Items) using the above template.

Prerequisites and input parameters remain the same as mentioned in Creating a Milestone Custom Plan using a Template for an OLI and ALI.

The start date is  and the end date is (start and end date of the OLI). When the custom plan is created it shows the following values:

Custom Plan ID

ID (Order or Proposal)

Plan Template

Description

Name

No. of Installments

Plan Type

Periods Needed

Based On

Computation Method

Status

CP-1O-2PT-2Custom Plan for ABC CompanyMy_Custom_Plan_13Term BasedFalsePercentageCustomNew

The Plan Items for the OLIs (or Line Items) will be auto-created with the following details:

ID

Custom Plan ID

Percent

Period Start Date

Period End Date

Ready For Invoice Date

Payment Term

CPL-1CP-233.33333333

 

 

 

Term 1
CPL-2CP-233.33333333

 

 

 

Term 2
CPL-3CP-233.33333334

 

 

 

Term 3

When you initiate billing, the billing header will have three billing schedule records, containing 33.33333333% of the TCV (Sales).