SellingPlan Billing Policy For Deposits Not Applied Correctly

A merchant notified us of an issue when using our TBYB app.

They opted to use our deposit option and noticed a discrepancy between 2 checkout scenarios:

Checkout 1 (TBYB only)

  1. 1 TBYB item
  2. Correct itemization (deposit due immediately and full product price due later)

Checkout 2 (Mixed cart)

  1. 2 non-TBYB items
  2. 1 TBYB item
  3. Incorrect itemization (deposit is higher than expected and deferred payment is lower than expected)

In the mixed bag checkout, the “Due today” amount should be $99.95.

The deferred payment should be $60.

The difference is $9.95 which is what they configured as their desired deposit amount when the SellingPlan was created.

Here is our SellingPlanInput for the sellingPlanGroupCreate mutation:

[{
  name: plan.name,
  description: plan.description,
  options: ["default"],
  billingPolicy: {
    fixed: {
      checkoutCharge: {
        type: "PRICE",
        value: {
          fixedValue: plan.prepay,
        },
      },
      remainingBalanceChargeTimeAfterCheckout: trial_days_iso,
      remainingBalanceChargeTrigger: "TIME_AFTER_CHECKOUT",
    },
  },
  category: "TRY_BEFORE_YOU_BUY",
  inventoryPolicy: {
    reserve: "ON_SALE",
  },
  deliveryPolicy: {
    fixed: {
      fulfillmentTrigger: "ASAP",
    },
  },
  pricingPolicies: {
    fixed: {
      adjustmentType: "FIXED_AMOUNT",
      adjustmentValue: {
        fixedValue: 0,
      },
    },
  },
}]