Retrieving payment plans from a billing system

Your billing plugin must be able to retrieve all the allowed payment plans from your billing system for a quoted PolicyPeriod. PolicyCenter uses this information in the user interface on the Payment screen. PolicyCenter displays the list of payment plans so the user can choose one of the payment plans for PolicyCenter jobs that create a new period. Job types that create a new period are submission, renewal, and rewrite.

Retrieving payment plan data objects

Implement both signatures of the following plugin method:

  • retrieveAllPaymentPlans – Retrieves payment plans for a policy period or for a particular billing method that an alternate billing account uses

Both methods return an array of Gosu objects that implement the PaymentPlanData interface. One method takes a PolicyPeriod entity instance as a parameter. The other method takes a BillingMethod entity instance, an account number String for the alternate billing account, and the Currency to use for the payment plan as parameters. Take these parameter values from a particular PolicyPeriod entity instance.

Populating payment plan data objects

The gw.plugin.billing package contains the PaymentPlanData base interface and two further interfaces, InstallmentPlanData and ReportingPlanData, that extend PaymentPlanData for installment and reporting plan types. An abstract class, AbstractPaymentPlanData, implements the PaymentPlanData base interface. Two implementations that integrate with BillingCenter exist in the same package. Use these implementations to guide the development of integration to your own billing system:

  • InstallmentPlanDataImpl – Use for installment plans
  • ReportingPlanDataImpl – Use for report payment plans

The fully qualified class names look like gw.api.billing.PaymentPlanClass.

To support displaying the available payment plans in the user interface, set the following properties on each PaymentPlanData object:

  • BillingId – The ID that the billing system uses for the plan.
  • PaymentPlanType – The PaymentMethod type code of the plan, either Installments or ReportingPlan.
  • Notes – Optional. A String value containing notes related to the plan.

For an installment payment plan, set the following additional properties:

  • Name – The name of the plan.
  • DownPayment – A non-negative MonetaryAmount value that is the down payment of the plan, typically the largest installment.
  • Fee – A non-negative MonetaryAmount value that is the fee to pay at the same time as each installment of the plan.
  • InvoiceFrequency – The BillingPeriodicity type code of the plan, for example monthly or quarterly.
  • Installment – A non-negative MonetaryAmount value that is the installment payment of the plan.
  • OneTimeFee – A non-negative MonetaryAmount value that is typically the fee to pay at the same time as the down payment.
  • Total – A non-negative MonetaryAmount value that is the total payment of the plan. This value is the sum of the down payment, all fees, all taxes, and all installments combined.
  • TotalFees – A non-negative MonetaryAmount value that is the total fees to pay for the plan. This value is the sum of the one-time fee and all the installment fees.

For a reporting payment plan, set the following additional properties:

  • Name – The name of the plan if your class does not extend ReportingPlanDataImpl. ReportingPlanDataImpl sets the Name property to the Name property of the audit schedule of the reporting plan.
  • ReportingPatternCode – The code that the billing system uses for the audit schedule of the reporting plan.