Welcome to Zuora Product Documentation

Explore our rich library of product information

Bulk update helpers

Helpers for bulk updating charges, rate plans, amendments, tiers, and products in Zuora CPQ timelines.

Each bulk update entry supports:

Parameter

Type

Required

Description

timelineIdstringNoRestrict the update to one timeline.
filterFunctionNoCallback deciding which records to update.
updateobjectYesField patch object.

updateCharges(updates)

Signature:

updateCharges(
    updates: Array<{
        timelineId?: string,
        filter?: (charge, plan, timeline, context) => boolean,
        update: object
    }>
): CustomEvent

Example:

this.dispatchEvent(
    zqf.updateCharges([
        {
            timelineId,
            filter: (charge) => charge.record.Name === 'Rec Per Unit Charge',
            update: {
                zqu__Discount__c: 15
            }
        }
    ])
);

updateChargesInInterval(intervalId, updates)

Signature:

updateChargesInInterval(
    intervalId: number | string | object,
    updates: Array<{
        timelineId?: string,
        filter?: (charge, plan, timeline, context) => boolean,
        update: object
    }>
): CustomEvent

updateRatePlans(updates)

Signature:

updateRatePlans(
    updates: Array<{
        timelineId?: string,
        filter?: (plan, timeline, context) => boolean,
        update: object
    }>
): CustomEvent

updateRatePlansInInterval(intervalId, updates)

Signature:

updateRatePlansInInterval(
    intervalId: number | string | object,
    updates: Array<{
        timelineId?: string,
        filter?: (plan, timeline, context) => boolean,
        update: object
    }>
): CustomEvent

updateAmendments(updates)

Signature:

updateAmendments(
    updates: Array<{
        timelineId?: string,
        filter?: (amendment, plan, timeline, context) => boolean,
        update: object
    }>
): CustomEvent

Example:

this.dispatchEvent(
    zqf.updateAmendments([
        {
            timelineId,
            filter: (amendment) => amendment.record.zqu__Type__c === 'UpdateProduct',
            update: {
                zqu__ContractEffectiveDate__c: '2026-07-13'
            }
        }
    ])
);

updateAmendmentsInInterval(intervalId, updates)

Signature:

updateAmendmentsInInterval(
    intervalId: number | string | object,
    updates: Array<{
        timelineId?: string,
        filter?: (amendment, plan, timeline, context) => boolean,
        update: object
    }>
): CustomEvent

updateTiers(updates)

Signature:

updateTiers(
    updates: Array<{
        timelineId?: string,
        filter?: (tier, charge, index, plan, timeline, context) => boolean,
        update: object
    }>
): CustomEvent

updateTiersInInterval(intervalId, updates)

Signature:

updateTiersInInterval(
    intervalId: number | string | object,
    updates: Array<{
        timelineId?: string,
        filter?: (tier, charge, index, plan, timeline, context) => boolean,
        update: object
    }>
): CustomEvent

updateProducts(groups)

Signature:

updateProducts(groups?: {
    charges?: Array<{ timelineId?: string, filter?: Function, update: object }>,
    tiers?: Array<{ timelineId?: string, filter?: Function, update: object }>,
    ratePlans?: Array<{ timelineId?: string, filter?: Function, update: object }>,
    amendments?: Array<{ timelineId?: string, filter?: Function, update: object }>
}): CustomEvent

Example:

this.dispatchEvent(
    zqf.updateProducts({
        charges: [
            {
                timelineId,
                update: {
                    zqu__Quantity__c: 6
                }
            }
        ],
        ratePlans: [
            {
                timelineId,
                update: {
                    Name: 'Interval Product Update'
                }
            }
        ]
    })
);

updateProductsInInterval(intervalId, groups)

Signature:

updateProductsInInterval(
    intervalId: number | string | object,
    groups?: {
        charges?: Array<{ timelineId?: string, filter?: Function, update: object }>,
        tiers?: Array<{ timelineId?: string, filter?: Function, update: object }>,
        ratePlans?: Array<{ timelineId?: string, filter?: Function, update: object }>,
        amendments?: Array<{ timelineId?: string, filter?: Function, update: object }>
    }
): CustomEvent