UNPKG

@paddle/paddle-node-sdk

Version:

A Node.js SDK that you can use to integrate Paddle Billing with applications written in server-side JavaScript.

19 lines (18 loc) 772 B
import { AdjustmentProrationNotification } from './adjustment-proration-notification.js'; import { AdjustmentItemTotalsNotification } from './adjustment-item-totals-notification.js'; export class AdjustmentItemNotification { id; itemId; type; amount; proration; totals; constructor(adjustmentItem) { this.id = adjustmentItem.id; this.itemId = adjustmentItem.item_id; this.type = adjustmentItem.type; this.amount = adjustmentItem.amount ? adjustmentItem.amount : null; this.proration = adjustmentItem.proration ? new AdjustmentProrationNotification(adjustmentItem.proration) : null; this.totals = adjustmentItem.totals ? new AdjustmentItemTotalsNotification(adjustmentItem.totals) : null; } }