@leaflow/sdk 0.0.0-dev.352.g85966ed → 0.0.0-dev.355.g42152f5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/billing/type/funds/v1/generated/models.d.ts +4 -4
- package/dist/billing/type/funds/v1/generated/validators/funds.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/models.d.ts +379 -779
- package/dist/billing/type/order/v1/generated/models.js +12 -44
- package/dist/billing/type/order/v1/generated/validators/accountBalance.zod.d.ts +22 -11
- package/dist/billing/type/order/v1/generated/validators/accountBalance.zod.js +8 -8
- package/dist/billing/type/order/v1/generated/validators/activeResource.zod.js +8 -5
- package/dist/billing/type/order/v1/generated/validators/allowance.zod.js +3 -3
- package/dist/billing/type/order/v1/generated/validators/applicability.zod.d.ts +22 -11
- package/dist/billing/type/order/v1/generated/validators/applicability.zod.js +12 -3
- package/dist/billing/type/order/v1/generated/validators/applicablePlan.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/billingAccount.zod.js +5 -5
- package/dist/billing/type/order/v1/generated/validators/billingAccountUpdate.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/billingScheme.zod.d.ts +14 -0
- package/dist/billing/type/order/v1/generated/validators/billingScheme.zod.js +11 -0
- package/dist/billing/type/order/v1/generated/validators/cancellation.zod.d.ts +6 -3
- package/dist/billing/type/order/v1/generated/validators/cancellation.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/validators/cancellationCreate.zod.js +3 -3
- package/dist/billing/type/order/v1/generated/validators/cancellationItem.zod.d.ts +6 -3
- package/dist/billing/type/order/v1/generated/validators/cancellationItem.zod.js +6 -5
- package/dist/billing/type/order/v1/generated/validators/cancellationList.zod.d.ts +6 -3
- package/dist/billing/type/order/v1/generated/validators/cancellationRefundPreview.zod.d.ts +6 -3
- package/dist/billing/type/order/v1/generated/validators/cancellationRefundPreview.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/cancellationRefundPreviewItem.zod.d.ts +6 -3
- package/dist/billing/type/order/v1/generated/validators/cancellationRefundPreviewItem.zod.js +7 -4
- package/dist/billing/type/order/v1/generated/validators/contact.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/creditGrant.zod.d.ts +22 -11
- package/dist/billing/type/order/v1/generated/validators/creditGrantList.zod.d.ts +22 -11
- package/dist/billing/type/order/v1/generated/validators/creditGroup.zod.d.ts +22 -11
- package/dist/billing/type/order/v1/generated/validators/creditGroup.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/creditNote.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/validators/currency.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/discount.zod.d.ts +23 -12
- package/dist/billing/type/order/v1/generated/validators/discount.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/validators/discountList.zod.d.ts +23 -12
- package/dist/billing/type/order/v1/generated/validators/entitlement.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/funds.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/validators/invoice.zod.d.ts +0 -1
- package/dist/billing/type/order/v1/generated/validators/invoice.zod.js +8 -8
- package/dist/billing/type/order/v1/generated/validators/invoiceItem.zod.d.ts +2 -0
- package/dist/billing/type/order/v1/generated/validators/invoiceItem.zod.js +10 -4
- package/dist/billing/type/order/v1/generated/validators/invoiceItemList.zod.d.ts +2 -0
- package/dist/billing/type/order/v1/generated/validators/invoiceItemProration.zod.js +1 -3
- package/dist/billing/type/order/v1/generated/validators/invoiceList.zod.d.ts +0 -1
- package/dist/billing/type/order/v1/generated/validators/invoiceStatus.zod.d.ts +0 -1
- package/dist/billing/type/order/v1/generated/validators/invoiceStatus.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/invoiceSummary.zod.d.ts +0 -1
- package/dist/billing/type/order/v1/generated/validators/invoiceSummary.zod.js +3 -3
- package/dist/billing/type/order/v1/generated/validators/monthlyStatement.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/objectIdentity.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/order.zod.d.ts +7 -4
- package/dist/billing/type/order/v1/generated/validators/order.zod.js +10 -12
- package/dist/billing/type/order/v1/generated/validators/orderItem.zod.d.ts +7 -3
- package/dist/billing/type/order/v1/generated/validators/orderItem.zod.js +16 -14
- package/dist/billing/type/order/v1/generated/validators/orderItemList.zod.d.ts +7 -3
- package/dist/billing/type/order/v1/generated/validators/orderItemStatus.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/orderList.zod.d.ts +7 -4
- package/dist/billing/type/order/v1/generated/validators/orderRefundQuote.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/orderRefundQuoteInput.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/orderStatus.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/paidWith.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/payInvoiceRequest.zod.js +6 -6
- package/dist/billing/type/order/v1/generated/validators/payTogetherRequest.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/paymentAction.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/validators/paymentCancellationReason.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/paymentMethodSetupResult.zod.js +2 -4
- package/dist/billing/type/order/v1/generated/validators/paymentOption.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/paymentOptionMethod.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/paymentPreview.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/validators/paymentResult.zod.js +5 -8
- package/dist/billing/type/order/v1/generated/validators/paymentStatus.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/placedOrder.zod.d.ts +0 -1
- package/dist/billing/type/order/v1/generated/validators/price.zod.d.ts +7 -5
- package/dist/billing/type/order/v1/generated/validators/price.zod.js +14 -11
- package/dist/billing/type/order/v1/generated/validators/priceList.zod.d.ts +7 -5
- package/dist/billing/type/order/v1/generated/validators/priceOption.zod.d.ts +7 -5
- package/dist/billing/type/order/v1/generated/validators/priceOption.zod.js +7 -3
- package/dist/billing/type/order/v1/generated/validators/priceType.zod.d.ts +14 -0
- package/dist/billing/type/order/v1/generated/validators/priceType.zod.js +11 -0
- package/dist/billing/type/order/v1/generated/validators/productID.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/projectAssignment.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/purchaseOperation.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/quote.zod.d.ts +6 -3
- package/dist/billing/type/order/v1/generated/validators/quote.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/validators/quoteCancellation.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/quoteItem.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/validators/quoteItemInput.zod.d.ts +5 -2
- package/dist/billing/type/order/v1/generated/validators/quoteItemInput.zod.js +8 -8
- package/dist/billing/type/order/v1/generated/validators/quoteRenewal.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/quoteRenewalResult.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/quoteRequest.zod.d.ts +5 -2
- package/dist/billing/type/order/v1/generated/validators/quoteRequest.zod.js +5 -5
- package/dist/billing/type/order/v1/generated/validators/quotedDiscount.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/rate.zod.d.ts +11 -0
- package/dist/billing/type/order/v1/generated/validators/rate.zod.js +14 -6
- package/dist/billing/type/order/v1/generated/validators/rateList.zod.d.ts +11 -0
- package/dist/billing/type/order/v1/generated/validators/refund.zod.js +3 -3
- package/dist/billing/type/order/v1/generated/validators/refundPolicy.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/refundReason.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/renewRequest.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/renewalOrderRequest.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/renewalPrice.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/scheduledChange.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/spendRow.zod.d.ts +8 -0
- package/dist/billing/type/order/v1/generated/validators/spendRow.zod.js +11 -0
- package/dist/billing/type/order/v1/generated/validators/spendRowList.zod.d.ts +8 -0
- package/dist/billing/type/order/v1/generated/validators/spendRowList.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/statement.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/statementItem.zod.d.ts +1 -0
- package/dist/billing/type/order/v1/generated/validators/statementItem.zod.js +4 -0
- package/dist/billing/type/order/v1/generated/validators/statementSummary.zod.d.ts +1 -0
- package/dist/billing/type/order/v1/generated/validators/statementType.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/subscription.zod.d.ts +7 -3
- package/dist/billing/type/order/v1/generated/validators/subscription.zod.js +20 -14
- package/dist/billing/type/order/v1/generated/validators/subscriptionCancellation.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/subscriptionList.zod.d.ts +7 -3
- package/dist/billing/type/order/v1/generated/validators/subscriptionRestriction.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/terminationPolicy.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/tier.zod.js +1 -1
- package/dist/billing/type/order/v1/generated/validators/topUp.zod.js +8 -8
- package/dist/billing/type/order/v1/generated/validators/topUpCreate.zod.js +4 -4
- package/dist/billing/type/order/v1/generated/validators/transaction.zod.js +6 -6
- package/dist/billing/type/order/v1/generated/validators/usageCharge.zod.d.ts +1 -0
- package/dist/billing/type/order/v1/generated/validators/usageCharge.zod.js +8 -7
- package/dist/billing/type/order/v1/generated/validators/usageChargeList.zod.d.ts +1 -0
- package/dist/billing/type/order/v1/generated/validators/usageType.zod.d.ts +14 -0
- package/dist/billing/type/order/v1/generated/validators/usageType.zod.js +11 -0
- package/dist/billing/type/order/v1/generated/validators/withdrawal.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/withdrawalItem.zod.js +2 -2
- package/dist/billing/type/order/v1/generated/validators/withdrawalSource.zod.js +1 -1
- package/dist/billing/type/quote/v1/generated/models.d.ts +4 -4
- package/dist/billing/type/quote/v1/generated/validators/funds.zod.js +4 -4
- package/dist/billing/v1/generated/functions.d.ts +176 -310
- package/dist/billing/v1/generated/functions.js +175 -309
- package/dist/billing/v1/generated/models.d.ts +429 -863
- package/dist/billing/v1/generated/models.js +13 -49
- package/dist/billing/v1/generated/schemas.zod.d.ts +166 -383
- package/dist/billing/v1/generated/schemas.zod.js +213 -372
- package/dist/billing/v1/generated/validators/accountBalance.zod.d.ts +22 -11
- package/dist/billing/v1/generated/validators/accountBalance.zod.js +8 -8
- package/dist/billing/v1/generated/validators/activeResource.zod.js +8 -5
- package/dist/billing/v1/generated/validators/allowance.zod.js +3 -3
- package/dist/billing/v1/generated/validators/applicability.zod.d.ts +22 -11
- package/dist/billing/v1/generated/validators/applicability.zod.js +12 -3
- package/dist/billing/v1/generated/validators/applicablePlan.zod.js +1 -1
- package/dist/billing/v1/generated/validators/billingAccount.zod.js +5 -5
- package/dist/billing/v1/generated/validators/billingAccountUpdate.zod.js +1 -1
- package/dist/billing/v1/generated/validators/billingScheme.zod.d.ts +14 -0
- package/dist/billing/v1/generated/validators/billingScheme.zod.js +11 -0
- package/dist/billing/v1/generated/validators/cancellation.zod.d.ts +6 -3
- package/dist/billing/v1/generated/validators/cancellation.zod.js +4 -4
- package/dist/billing/v1/generated/validators/cancellationCreate.zod.js +3 -3
- package/dist/billing/v1/generated/validators/cancellationItem.zod.d.ts +6 -3
- package/dist/billing/v1/generated/validators/cancellationItem.zod.js +6 -5
- package/dist/billing/v1/generated/validators/cancellationList.zod.d.ts +6 -3
- package/dist/billing/v1/generated/validators/cancellationRefundPreview.zod.d.ts +6 -3
- package/dist/billing/v1/generated/validators/cancellationRefundPreview.zod.js +1 -1
- package/dist/billing/v1/generated/validators/cancellationRefundPreviewItem.zod.d.ts +6 -3
- package/dist/billing/v1/generated/validators/cancellationRefundPreviewItem.zod.js +7 -4
- package/dist/billing/v1/generated/validators/contact.zod.js +2 -2
- package/dist/billing/v1/generated/validators/creditGrant.zod.d.ts +22 -11
- package/dist/billing/v1/generated/validators/creditGrantList.zod.d.ts +22 -11
- package/dist/billing/v1/generated/validators/creditGroup.zod.d.ts +22 -11
- package/dist/billing/v1/generated/validators/creditGroup.zod.js +1 -1
- package/dist/billing/v1/generated/validators/creditNote.zod.js +4 -4
- package/dist/billing/v1/generated/validators/currency.zod.js +1 -1
- package/dist/billing/v1/generated/validators/discount.zod.d.ts +23 -12
- package/dist/billing/v1/generated/validators/discount.zod.js +4 -4
- package/dist/billing/v1/generated/validators/discountList.zod.d.ts +23 -12
- package/dist/billing/v1/generated/validators/entitlement.zod.js +1 -1
- package/dist/billing/v1/generated/validators/funds.zod.js +4 -4
- package/dist/billing/v1/generated/validators/invoice.zod.d.ts +0 -1
- package/dist/billing/v1/generated/validators/invoice.zod.js +8 -8
- package/dist/billing/v1/generated/validators/invoiceItem.zod.d.ts +2 -0
- package/dist/billing/v1/generated/validators/invoiceItem.zod.js +10 -4
- package/dist/billing/v1/generated/validators/invoiceItemList.zod.d.ts +2 -0
- package/dist/billing/v1/generated/validators/invoiceItemProration.zod.js +1 -3
- package/dist/billing/v1/generated/validators/invoiceList.zod.d.ts +0 -1
- package/dist/billing/v1/generated/validators/invoiceStatus.zod.d.ts +0 -1
- package/dist/billing/v1/generated/validators/invoiceStatus.zod.js +2 -2
- package/dist/billing/v1/generated/validators/invoiceSummary.zod.d.ts +0 -1
- package/dist/billing/v1/generated/validators/invoiceSummary.zod.js +3 -3
- package/dist/billing/v1/generated/validators/listInvoicesParams.zod.d.ts +0 -1
- package/dist/billing/v1/generated/validators/listPricesParams.zod.d.ts +5 -2
- package/dist/billing/v1/generated/validators/listPricesParams.zod.js +4 -1
- package/dist/billing/v1/generated/validators/listSpendParams.zod.d.ts +1 -0
- package/dist/billing/v1/generated/validators/listSpendParams.zod.js +3 -1
- package/dist/billing/v1/generated/validators/monthlyStatement.zod.js +2 -2
- package/dist/billing/v1/generated/validators/objectIdentity.zod.js +1 -1
- package/dist/billing/v1/generated/validators/order.zod.d.ts +7 -4
- package/dist/billing/v1/generated/validators/order.zod.js +10 -12
- package/dist/billing/v1/generated/validators/orderItem.zod.d.ts +7 -3
- package/dist/billing/v1/generated/validators/orderItem.zod.js +16 -14
- package/dist/billing/v1/generated/validators/orderItemList.zod.d.ts +7 -3
- package/dist/billing/v1/generated/validators/orderItemStatus.zod.js +1 -1
- package/dist/billing/v1/generated/validators/orderList.zod.d.ts +7 -4
- package/dist/billing/v1/generated/validators/orderRefundQuote.zod.js +1 -1
- package/dist/billing/v1/generated/validators/orderRefundQuoteInput.zod.js +1 -1
- package/dist/billing/v1/generated/validators/orderStatus.zod.js +1 -1
- package/dist/billing/v1/generated/validators/paidWith.zod.js +1 -1
- package/dist/billing/v1/generated/validators/payInvoiceRequest.zod.js +6 -6
- package/dist/billing/v1/generated/validators/payTogetherRequest.zod.js +2 -2
- package/dist/billing/v1/generated/validators/paymentAction.zod.js +4 -4
- package/dist/billing/v1/generated/validators/paymentCancellationReason.zod.js +1 -1
- package/dist/billing/v1/generated/validators/paymentMethodSetupResult.zod.js +2 -4
- package/dist/billing/v1/generated/validators/paymentOption.zod.js +1 -1
- package/dist/billing/v1/generated/validators/paymentOptionMethod.zod.js +1 -1
- package/dist/billing/v1/generated/validators/paymentPreview.zod.js +4 -4
- package/dist/billing/v1/generated/validators/paymentResult.zod.js +5 -8
- package/dist/billing/v1/generated/validators/paymentStatus.zod.js +1 -1
- package/dist/billing/v1/generated/validators/price.zod.d.ts +7 -5
- package/dist/billing/v1/generated/validators/price.zod.js +14 -11
- package/dist/billing/v1/generated/validators/priceList.zod.d.ts +7 -5
- package/dist/billing/v1/generated/validators/priceOption.zod.d.ts +7 -5
- package/dist/billing/v1/generated/validators/priceOption.zod.js +7 -3
- package/dist/billing/v1/generated/validators/priceType.zod.d.ts +14 -0
- package/dist/billing/v1/generated/validators/priceType.zod.js +11 -0
- package/dist/billing/v1/generated/validators/productID.zod.js +1 -1
- package/dist/billing/v1/generated/validators/projectAssignment.zod.js +2 -2
- package/dist/billing/v1/generated/validators/purchaseOperation.zod.js +1 -1
- package/dist/billing/v1/generated/validators/quote.zod.d.ts +6 -3
- package/dist/billing/v1/generated/validators/quote.zod.js +4 -4
- package/dist/billing/v1/generated/validators/quoteCancellation.zod.js +2 -2
- package/dist/billing/v1/generated/validators/quoteItem.zod.js +4 -4
- package/dist/billing/v1/generated/validators/quoteItemInput.zod.d.ts +5 -2
- package/dist/billing/v1/generated/validators/quoteItemInput.zod.js +8 -8
- package/dist/billing/v1/generated/validators/quoteRenewal.zod.js +1 -1
- package/dist/billing/v1/generated/validators/quoteRenewalResult.zod.js +2 -2
- package/dist/billing/v1/generated/validators/quoteRequest.zod.d.ts +5 -2
- package/dist/billing/v1/generated/validators/quoteRequest.zod.js +5 -5
- package/dist/billing/v1/generated/validators/quotedDiscount.zod.js +1 -1
- package/dist/billing/v1/generated/validators/rate.zod.d.ts +11 -0
- package/dist/billing/v1/generated/validators/rate.zod.js +14 -6
- package/dist/billing/v1/generated/validators/rateList.zod.d.ts +11 -0
- package/dist/billing/v1/generated/validators/refund.zod.js +3 -3
- package/dist/billing/v1/generated/validators/refundPolicy.zod.js +1 -1
- package/dist/billing/v1/generated/validators/refundReason.zod.js +1 -1
- package/dist/billing/v1/generated/validators/renewRequest.zod.js +2 -2
- package/dist/billing/v1/generated/validators/renewalOrderRequest.zod.js +2 -2
- package/dist/billing/v1/generated/validators/renewalPrice.zod.js +1 -1
- package/dist/billing/v1/generated/validators/scheduledChange.zod.js +2 -2
- package/dist/billing/v1/generated/validators/spendRow.zod.d.ts +8 -0
- package/dist/billing/v1/generated/validators/spendRow.zod.js +11 -0
- package/dist/billing/v1/generated/validators/spendRowList.zod.d.ts +8 -0
- package/dist/billing/v1/generated/validators/spendRowList.zod.js +1 -1
- package/dist/billing/v1/generated/validators/statement.zod.js +2 -2
- package/dist/billing/v1/generated/validators/statementItem.zod.d.ts +1 -0
- package/dist/billing/v1/generated/validators/statementItem.zod.js +4 -0
- package/dist/billing/v1/generated/validators/statementSummary.zod.d.ts +1 -0
- package/dist/billing/v1/generated/validators/statementType.zod.js +1 -1
- package/dist/billing/v1/generated/validators/subscription.zod.d.ts +7 -3
- package/dist/billing/v1/generated/validators/subscription.zod.js +20 -14
- package/dist/billing/v1/generated/validators/subscriptionCancellation.zod.js +2 -2
- package/dist/billing/v1/generated/validators/subscriptionList.zod.d.ts +7 -3
- package/dist/billing/v1/generated/validators/subscriptionRestriction.zod.js +1 -1
- package/dist/billing/v1/generated/validators/terminationPolicy.zod.js +1 -1
- package/dist/billing/v1/generated/validators/tier.zod.js +1 -1
- package/dist/billing/v1/generated/validators/topUp.zod.js +8 -8
- package/dist/billing/v1/generated/validators/topUpCreate.zod.js +4 -4
- package/dist/billing/v1/generated/validators/transaction.zod.js +6 -6
- package/dist/billing/v1/generated/validators/usageCharge.zod.d.ts +1 -0
- package/dist/billing/v1/generated/validators/usageCharge.zod.js +8 -7
- package/dist/billing/v1/generated/validators/usageChargeList.zod.d.ts +1 -0
- package/dist/billing/v1/generated/validators/usageType.zod.d.ts +14 -0
- package/dist/billing/v1/generated/validators/usageType.zod.js +11 -0
- package/dist/billing/v1/generated/validators/withdrawal.zod.js +2 -2
- package/dist/billing/v1/generated/validators/withdrawalItem.zod.js +2 -2
- package/dist/billing/v1/generated/validators/withdrawalSource.zod.js +1 -1
- package/dist/canopy/v1/generated/functions.d.ts +1 -1
- package/dist/canopy/v1/generated/functions.js +1 -1
- package/dist/canopy/v1/generated/models.d.ts +379 -779
- package/dist/canopy/v1/generated/models.js +12 -44
- package/dist/canopy/v1/generated/schemas.zod.d.ts +1 -1
- package/dist/canopy/v1/generated/schemas.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/accountBalance.zod.d.ts +22 -11
- package/dist/canopy/v1/generated/validators/accountBalance.zod.js +8 -8
- package/dist/canopy/v1/generated/validators/activeResource.zod.js +8 -5
- package/dist/canopy/v1/generated/validators/allowance.zod.js +3 -3
- package/dist/canopy/v1/generated/validators/applicability.zod.d.ts +22 -11
- package/dist/canopy/v1/generated/validators/applicability.zod.js +12 -3
- package/dist/canopy/v1/generated/validators/applicablePlan.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/billingAccount.zod.js +5 -5
- package/dist/canopy/v1/generated/validators/billingAccountUpdate.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/billingScheme.zod.d.ts +39 -0
- package/dist/canopy/v1/generated/validators/billingScheme.zod.js +36 -0
- package/dist/canopy/v1/generated/validators/cancellation.zod.d.ts +6 -3
- package/dist/canopy/v1/generated/validators/cancellation.zod.js +4 -4
- package/dist/canopy/v1/generated/validators/cancellationCreate.zod.js +3 -3
- package/dist/canopy/v1/generated/validators/cancellationItem.zod.d.ts +6 -3
- package/dist/canopy/v1/generated/validators/cancellationItem.zod.js +6 -5
- package/dist/canopy/v1/generated/validators/cancellationList.zod.d.ts +6 -3
- package/dist/canopy/v1/generated/validators/cancellationRefundPreview.zod.d.ts +6 -3
- package/dist/canopy/v1/generated/validators/cancellationRefundPreview.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/cancellationRefundPreviewItem.zod.d.ts +6 -3
- package/dist/canopy/v1/generated/validators/cancellationRefundPreviewItem.zod.js +7 -4
- package/dist/canopy/v1/generated/validators/contact.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/createServiceResponseBody.zod.d.ts +0 -1
- package/dist/canopy/v1/generated/validators/creditGrant.zod.d.ts +22 -11
- package/dist/canopy/v1/generated/validators/creditGrantList.zod.d.ts +22 -11
- package/dist/canopy/v1/generated/validators/creditGroup.zod.d.ts +22 -11
- package/dist/canopy/v1/generated/validators/creditGroup.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/creditNote.zod.js +4 -4
- package/dist/canopy/v1/generated/validators/currency.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/discount.zod.d.ts +23 -12
- package/dist/canopy/v1/generated/validators/discount.zod.js +4 -4
- package/dist/canopy/v1/generated/validators/discountList.zod.d.ts +23 -12
- package/dist/canopy/v1/generated/validators/entitlement.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/funds.zod.js +4 -4
- package/dist/canopy/v1/generated/validators/invoice.zod.d.ts +0 -1
- package/dist/canopy/v1/generated/validators/invoice.zod.js +8 -8
- package/dist/canopy/v1/generated/validators/invoiceItem.zod.d.ts +2 -0
- package/dist/canopy/v1/generated/validators/invoiceItem.zod.js +10 -4
- package/dist/canopy/v1/generated/validators/invoiceItemList.zod.d.ts +2 -0
- package/dist/canopy/v1/generated/validators/invoiceItemProration.zod.js +1 -3
- package/dist/canopy/v1/generated/validators/invoiceList.zod.d.ts +0 -1
- package/dist/canopy/v1/generated/validators/invoiceStatus.zod.d.ts +0 -1
- package/dist/canopy/v1/generated/validators/invoiceStatus.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/invoiceSummary.zod.d.ts +0 -1
- package/dist/canopy/v1/generated/validators/invoiceSummary.zod.js +3 -3
- package/dist/canopy/v1/generated/validators/monthlyStatement.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/objectIdentity.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/order.zod.d.ts +7 -4
- package/dist/canopy/v1/generated/validators/order.zod.js +10 -12
- package/dist/canopy/v1/generated/validators/orderItem.zod.d.ts +7 -3
- package/dist/canopy/v1/generated/validators/orderItem.zod.js +16 -14
- package/dist/canopy/v1/generated/validators/orderItemList.zod.d.ts +7 -3
- package/dist/canopy/v1/generated/validators/orderItemStatus.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/orderList.zod.d.ts +7 -4
- package/dist/canopy/v1/generated/validators/orderRefundQuote.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/orderRefundQuoteInput.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/orderStatus.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/paidWith.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/payInvoiceRequest.zod.js +6 -6
- package/dist/canopy/v1/generated/validators/payTogetherRequest.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/paymentAction.zod.js +4 -4
- package/dist/canopy/v1/generated/validators/paymentCancellationReason.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/paymentMethodSetupResult.zod.js +2 -4
- package/dist/canopy/v1/generated/validators/paymentOption.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/paymentOptionMethod.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/paymentPreview.zod.js +4 -4
- package/dist/canopy/v1/generated/validators/paymentResult.zod.js +5 -8
- package/dist/canopy/v1/generated/validators/paymentStatus.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/placedOrder.zod.d.ts +0 -1
- package/dist/canopy/v1/generated/validators/price.zod.d.ts +7 -5
- package/dist/canopy/v1/generated/validators/price.zod.js +14 -11
- package/dist/canopy/v1/generated/validators/priceList.zod.d.ts +7 -5
- package/dist/canopy/v1/generated/validators/priceOption.zod.d.ts +7 -5
- package/dist/canopy/v1/generated/validators/priceOption.zod.js +7 -3
- package/dist/canopy/v1/generated/validators/priceType.zod.d.ts +39 -0
- package/dist/canopy/v1/generated/validators/priceType.zod.js +36 -0
- package/dist/canopy/v1/generated/validators/productID.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/projectAssignment.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/purchaseOperation.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/quote5f60d00.zod.d.ts +6 -3
- package/dist/canopy/v1/generated/validators/quote5f60d00.zod.js +4 -4
- package/dist/canopy/v1/generated/validators/quoteA200529.zod.d.ts +6 -3
- package/dist/canopy/v1/generated/validators/quoteCancellation.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/quoteItem.zod.js +4 -4
- package/dist/canopy/v1/generated/validators/quoteItemInput.zod.d.ts +5 -2
- package/dist/canopy/v1/generated/validators/quoteItemInput.zod.js +8 -8
- package/dist/canopy/v1/generated/validators/quoteRenewal.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/quoteRenewalResult.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/quoteRequest.zod.d.ts +5 -2
- package/dist/canopy/v1/generated/validators/quoteRequest.zod.js +5 -5
- package/dist/canopy/v1/generated/validators/quotedDiscount.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/rate.zod.d.ts +11 -0
- package/dist/canopy/v1/generated/validators/rate.zod.js +14 -6
- package/dist/canopy/v1/generated/validators/rateList.zod.d.ts +11 -0
- package/dist/canopy/v1/generated/validators/refund.zod.js +3 -3
- package/dist/canopy/v1/generated/validators/refundPolicy.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/refundReason.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/renewRequest.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/renewalOrderRequest.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/renewalPrice.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/scheduledChange.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/spendRow.zod.d.ts +8 -0
- package/dist/canopy/v1/generated/validators/spendRow.zod.js +11 -0
- package/dist/canopy/v1/generated/validators/spendRowList.zod.d.ts +8 -0
- package/dist/canopy/v1/generated/validators/spendRowList.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/statement.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/statementItem.zod.d.ts +1 -0
- package/dist/canopy/v1/generated/validators/statementItem.zod.js +4 -0
- package/dist/canopy/v1/generated/validators/statementSummary.zod.d.ts +1 -0
- package/dist/canopy/v1/generated/validators/statementType.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/subscription.zod.d.ts +7 -3
- package/dist/canopy/v1/generated/validators/subscription.zod.js +20 -14
- package/dist/canopy/v1/generated/validators/subscriptionCancellation.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/subscriptionList.zod.d.ts +7 -3
- package/dist/canopy/v1/generated/validators/subscriptionRestriction.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/terminationPolicy.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/tier.zod.js +1 -1
- package/dist/canopy/v1/generated/validators/topUp.zod.js +8 -8
- package/dist/canopy/v1/generated/validators/topUpCreate.zod.js +4 -4
- package/dist/canopy/v1/generated/validators/transaction.zod.js +6 -6
- package/dist/canopy/v1/generated/validators/usageCharge.zod.d.ts +1 -0
- package/dist/canopy/v1/generated/validators/usageCharge.zod.js +8 -7
- package/dist/canopy/v1/generated/validators/usageChargeList.zod.d.ts +1 -0
- package/dist/canopy/v1/generated/validators/usageType.zod.d.ts +39 -0
- package/dist/canopy/v1/generated/validators/usageType.zod.js +36 -0
- package/dist/canopy/v1/generated/validators/withdrawal.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/withdrawalItem.zod.js +2 -2
- package/dist/canopy/v1/generated/validators/withdrawalSource.zod.js +1 -1
- package/dist/compute/v1/generated/functions.d.ts +15 -15
- package/dist/compute/v1/generated/functions.js +13 -13
- package/dist/compute/v1/generated/models.d.ts +37 -29
- package/dist/compute/v1/generated/models.js +6 -6
- package/dist/compute/v1/generated/schemas.zod.d.ts +69 -69
- package/dist/compute/v1/generated/schemas.zod.js +15 -15
- package/dist/compute/v1/generated/validators/allocateFloatingIPQuoteRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/allocateFloatingIPQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/allocateFloatingIPRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/allocateFloatingIPRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/allocateFloatingIPResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/allocateFloatingIPResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/attachDiskRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/attachDiskRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/attachFloatingIPRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/attachFloatingIPRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/attachPortRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/attachPortRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/backupCapacityPack.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/backupCapacityPack.zod.js +3 -3
- package/dist/compute/v1/generated/validators/backupCapacityPackListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/backupCapacityPackListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/backupListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/backupListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/backupOperation.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/backupOperation.zod.js +2 -2
- package/dist/compute/v1/generated/validators/backupResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/backupResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/backupService.zod.d.ts +10 -10
- package/dist/compute/v1/generated/validators/backupService.zod.js +7 -7
- package/dist/compute/v1/generated/validators/billingChoice.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/billingChoice.zod.js +6 -4
- package/dist/compute/v1/generated/validators/billingPeriod.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/billingPeriod.zod.js +2 -2
- package/dist/compute/v1/generated/validators/bindFloatingIPRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/bindFloatingIPRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/bootDisk.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/bootDisk.zod.js +2 -2
- package/dist/compute/v1/generated/validators/checkoutMode.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/checkoutMode.zod.js +2 -2
- package/dist/compute/v1/generated/validators/checkoutOptions.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/checkoutOptions.zod.js +2 -2
- package/dist/compute/v1/generated/validators/commandResultResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/commandResultResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/consoleOutputResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/consoleOutputResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/consoleResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/consoleResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createBackupCapacityPackQuoteRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/createBackupCapacityPackQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createBackupCapacityPackRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/createBackupCapacityPackRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createBackupCapacityPackResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createBackupCapacityPackResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createBackupRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createBackupRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createBackupServiceRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createBackupServiceRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createBackupServiceResponseBody.zod.d.ts +9 -9
- package/dist/compute/v1/generated/validators/createBackupServiceResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createDiskQuoteRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/createDiskQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createDiskRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/createDiskRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createDiskResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createDiskResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createImageQuoteRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/createImageQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createImageRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/createImageRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createImageResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createImageResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createPeeringRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createPeeringRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createPortRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createPortRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createPrivateNetworkRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createPrivateNetworkRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createRouteRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createRouteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createSecurityGroupRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createSecurityGroupRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createSecurityRuleRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createSecurityRuleRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createSnapshotRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createSnapshotRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/createSubnetRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/createSubnetRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/cursorPagination.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/cursorPagination.zod.js +2 -2
- package/dist/compute/v1/generated/validators/diskAttachment.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/diskAttachment.zod.js +2 -2
- package/dist/compute/v1/generated/validators/diskAttachmentList.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/diskAttachmentList.zod.js +2 -2
- package/dist/compute/v1/generated/validators/diskListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/diskListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/diskOperation.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/diskOperation.zod.js +2 -2
- package/dist/compute/v1/generated/validators/diskResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/diskResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/diskTypeListResponseBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/diskTypeListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/diskTypePurpose.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/diskTypePurpose.zod.js +2 -2
- package/dist/compute/v1/generated/validators/diskTypeResource.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/diskTypeResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/error.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/error.zod.js +2 -2
- package/dist/compute/v1/generated/validators/existingBootDisk.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/existingBootDisk.zod.js +2 -2
- package/dist/compute/v1/generated/validators/floatingIPListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/floatingIPListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/floatingIPOperation.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/floatingIPOperation.zod.js +2 -2
- package/dist/compute/v1/generated/validators/floatingIPResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/floatingIPResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/funds.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/funds.zod.js +6 -6
- package/dist/compute/v1/generated/validators/getInstanceConsoleOutputParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/getInstanceConsoleOutputParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/iPv4Binding.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/iPv4Binding.zod.js +2 -2
- package/dist/compute/v1/generated/validators/iPv4PoolListResponseBody.zod.d.ts +8 -8
- package/dist/compute/v1/generated/validators/iPv4PoolListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/iPv4PoolResource.zod.d.ts +8 -8
- package/dist/compute/v1/generated/validators/iPv4PoolResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/iPv6ResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/iPv6ResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/imageListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/imageListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/imageOperation.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/imageOperation.zod.js +2 -2
- package/dist/compute/v1/generated/validators/imageResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/imageResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/imageVisibility.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/imageVisibility.zod.js +2 -2
- package/dist/compute/v1/generated/validators/instanceListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/instanceListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/instanceOperation.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/instanceOperation.zod.js +2 -2
- package/dist/compute/v1/generated/validators/instanceResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/instanceResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/instanceRestriction.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/instanceRestriction.zod.js +2 -2
- package/dist/compute/v1/generated/validators/instanceTypeListResponseBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/instanceTypeListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/instanceTypeResource.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/instanceTypeResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/launchInstanceQuoteRequestBody.zod.d.ts +11 -11
- package/dist/compute/v1/generated/validators/launchInstanceQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/launchInstanceRequestBody.zod.d.ts +11 -11
- package/dist/compute/v1/generated/validators/launchInstanceRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/launchInstanceResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/launchInstanceResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listAvailabilityZonesParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listAvailabilityZonesParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listBackupCapacityPacksParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listBackupCapacityPacksParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listBackupsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listBackupsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listDiskTypesParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listDiskTypesParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listDisksParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listDisksParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listFloatingIpsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listFloatingIpsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listImagesParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listImagesParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listInstanceDisksParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listInstanceDisksParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listInstancePortsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listInstancePortsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listInstanceTypesParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listInstanceTypesParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listInstancesParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listInstancesParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listIpv4PoolsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listIpv4PoolsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listOperationLogsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listOperationLogsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listPeeringsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listPeeringsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listPortsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listPortsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listPrivateNetworksParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listPrivateNetworksParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listRegionsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listRegionsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listRoutesParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listRoutesParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listSecurityGroupRulesParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listSecurityGroupRulesParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listSecurityGroupsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listSecurityGroupsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listSnapshotsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listSnapshotsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/listSubnetsParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/listSubnetsParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/money.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/money.zod.js +2 -2
- package/dist/compute/v1/generated/validators/newBootDisk.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/newBootDisk.zod.js +2 -2
- package/dist/compute/v1/generated/validators/newCompute.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/newCompute.zod.js +2 -2
- package/dist/compute/v1/generated/validators/newFloatingIP.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/newFloatingIP.zod.js +2 -2
- package/dist/compute/v1/generated/validators/nextFreeCidrResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/nextFreeCidrResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/offsetPagination.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/offsetPagination.zod.js +2 -2
- package/dist/compute/v1/generated/validators/operationLogListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/operationLogListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/operationLogResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/operationLogResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/peeringListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/peeringListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/peeringOperation.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/peeringOperation.zod.js +2 -2
- package/dist/compute/v1/generated/validators/peeringResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/peeringResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/placedOrder.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/placedOrder.zod.js +2 -2
- package/dist/compute/v1/generated/validators/portAddress.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/portAddress.zod.js +2 -2
- package/dist/compute/v1/generated/validators/portAttachment.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/portAttachment.zod.js +2 -2
- package/dist/compute/v1/generated/validators/portAttachmentList.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/portAttachmentList.zod.js +2 -2
- package/dist/compute/v1/generated/validators/portListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/portListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/portOperation.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/portOperation.zod.js +2 -2
- package/dist/compute/v1/generated/validators/portResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/portResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/powerRequest.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/powerRequest.zod.js +2 -2
- package/dist/compute/v1/generated/validators/pricing.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/pricing.zod.js +2 -2
- package/dist/compute/v1/generated/validators/pricingOption.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/pricingOption.zod.js +12 -10
- package/dist/compute/v1/generated/validators/privateNetworkListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/privateNetworkListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/privateNetworkResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/privateNetworkResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/quote.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/quote.zod.js +2 -2
- package/dist/compute/v1/generated/validators/quoteItem.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/quoteItem.zod.js +2 -2
- package/dist/compute/v1/generated/validators/rebootInstanceRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/rebootInstanceRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/rebuildInstanceRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/rebuildInstanceRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/rebuildInstanceResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/rebuildInstanceResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/regionListResponseBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/regionListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/regionResource.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/regionResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/releaseResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/releaseResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/releaseSetItem.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/releaseSetItem.zod.js +2 -2
- package/dist/compute/v1/generated/validators/renameBackupRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/renameBackupRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/renameDiskRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/renameDiskRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/renameImageRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/renameImageRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/renameInstanceRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/renameInstanceRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/renamePrivateNetworkRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/renamePrivateNetworkRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/renameSecurityGroupRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/renameSecurityGroupRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/renameSnapshotRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/renameSnapshotRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/resetPasswordRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/resetPasswordRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/resetPasswordResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/resetPasswordResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/resizeDiskQuoteRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/resizeDiskQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/resizeDiskRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/resizeDiskRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/resizeDiskResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/resizeDiskResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/resizeInstanceQuoteRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/resizeInstanceQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/resizeInstanceRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/resizeInstanceRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/resizeInstanceResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/resizeInstanceResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/restoreBackupQuoteRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/restoreBackupQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/restoreBackupRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/restoreBackupRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/revertDiskRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/revertDiskRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/routeListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/routeListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/routeResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/routeResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/runCommandRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/runCommandRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/securityGroupListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/securityGroupListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/securityGroupResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/securityGroupResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/securityRuleListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/securityRuleListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/securityRuleResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/securityRuleResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/setFloatingIPBandwidthQuoteRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/setFloatingIPBandwidthQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/setFloatingIPBandwidthRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/setFloatingIPBandwidthRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/setFloatingIPBandwidthResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/setFloatingIPBandwidthResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/setInstanceLabelsRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/setInstanceLabelsRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/setInstanceNotesRequestBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/setInstanceNotesRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/setSnapshotQuotaQuoteRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/setSnapshotQuotaQuoteRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/setSnapshotQuotaRequestBody.zod.d.ts +5 -5
- package/dist/compute/v1/generated/validators/setSnapshotQuotaRequestBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/setSnapshotQuotaResponseBody.zod.d.ts +8 -8
- package/dist/compute/v1/generated/validators/setSnapshotQuotaResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/snapshotListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/snapshotListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/snapshotOperation.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/snapshotOperation.zod.js +2 -2
- package/dist/compute/v1/generated/validators/snapshotQuota.zod.d.ts +8 -8
- package/dist/compute/v1/generated/validators/snapshotQuota.zod.js +2 -2
- package/dist/compute/v1/generated/validators/snapshotResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/snapshotResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/subnetListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/subnetListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/subnetResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/subnetResource.zod.js +2 -2
- package/dist/compute/v1/generated/validators/suggestSubnetCidrParams.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/suggestSubnetCidrParams.zod.js +2 -2
- package/dist/compute/v1/generated/validators/terminationPolicy.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/terminationPolicy.zod.js +2 -2
- package/dist/compute/v1/generated/validators/zoneListResponseBody.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/zoneListResponseBody.zod.js +2 -2
- package/dist/compute/v1/generated/validators/zoneResource.zod.d.ts +2 -2
- package/dist/compute/v1/generated/validators/zoneResource.zod.js +2 -2
- package/dist/membership/v1/generated/models.d.ts +379 -779
- package/dist/membership/v1/generated/models.js +12 -44
- package/dist/membership/v1/generated/validators/accountBalance.zod.d.ts +22 -11
- package/dist/membership/v1/generated/validators/accountBalance.zod.js +8 -8
- package/dist/membership/v1/generated/validators/activeResource.zod.js +8 -5
- package/dist/membership/v1/generated/validators/allowance.zod.js +3 -3
- package/dist/membership/v1/generated/validators/applicability.zod.d.ts +22 -11
- package/dist/membership/v1/generated/validators/applicability.zod.js +12 -3
- package/dist/membership/v1/generated/validators/applicablePlan.zod.js +1 -1
- package/dist/membership/v1/generated/validators/billingAccount.zod.js +5 -5
- package/dist/membership/v1/generated/validators/billingAccountUpdate.zod.js +1 -1
- package/dist/membership/v1/generated/validators/billingScheme.zod.d.ts +14 -0
- package/dist/membership/v1/generated/validators/billingScheme.zod.js +11 -0
- package/dist/membership/v1/generated/validators/cancellation.zod.d.ts +6 -3
- package/dist/membership/v1/generated/validators/cancellation.zod.js +4 -4
- package/dist/membership/v1/generated/validators/cancellationCreate.zod.js +3 -3
- package/dist/membership/v1/generated/validators/cancellationItem.zod.d.ts +6 -3
- package/dist/membership/v1/generated/validators/cancellationItem.zod.js +6 -5
- package/dist/membership/v1/generated/validators/cancellationList.zod.d.ts +6 -3
- package/dist/membership/v1/generated/validators/cancellationRefundPreview.zod.d.ts +6 -3
- package/dist/membership/v1/generated/validators/cancellationRefundPreview.zod.js +1 -1
- package/dist/membership/v1/generated/validators/cancellationRefundPreviewItem.zod.d.ts +6 -3
- package/dist/membership/v1/generated/validators/cancellationRefundPreviewItem.zod.js +7 -4
- package/dist/membership/v1/generated/validators/contact.zod.js +2 -2
- package/dist/membership/v1/generated/validators/creditGrant.zod.d.ts +22 -11
- package/dist/membership/v1/generated/validators/creditGrantList.zod.d.ts +22 -11
- package/dist/membership/v1/generated/validators/creditGroup.zod.d.ts +22 -11
- package/dist/membership/v1/generated/validators/creditGroup.zod.js +1 -1
- package/dist/membership/v1/generated/validators/creditNote.zod.js +4 -4
- package/dist/membership/v1/generated/validators/currency6ff0ec7.zod.js +1 -1
- package/dist/membership/v1/generated/validators/discount.zod.d.ts +23 -12
- package/dist/membership/v1/generated/validators/discount.zod.js +4 -4
- package/dist/membership/v1/generated/validators/discountList.zod.d.ts +23 -12
- package/dist/membership/v1/generated/validators/entitlement.zod.js +1 -1
- package/dist/membership/v1/generated/validators/funds.zod.js +4 -4
- package/dist/membership/v1/generated/validators/invoice.zod.d.ts +0 -1
- package/dist/membership/v1/generated/validators/invoice.zod.js +8 -8
- package/dist/membership/v1/generated/validators/invoiceItem.zod.d.ts +2 -0
- package/dist/membership/v1/generated/validators/invoiceItem.zod.js +10 -4
- package/dist/membership/v1/generated/validators/invoiceItemList.zod.d.ts +2 -0
- package/dist/membership/v1/generated/validators/invoiceItemProration.zod.js +1 -3
- package/dist/membership/v1/generated/validators/invoiceList.zod.d.ts +0 -1
- package/dist/membership/v1/generated/validators/invoiceStatus.zod.d.ts +0 -1
- package/dist/membership/v1/generated/validators/invoiceStatus.zod.js +2 -2
- package/dist/membership/v1/generated/validators/invoiceSummary.zod.d.ts +0 -1
- package/dist/membership/v1/generated/validators/invoiceSummary.zod.js +3 -3
- package/dist/membership/v1/generated/validators/membershipPurchase.zod.d.ts +0 -1
- package/dist/membership/v1/generated/validators/monthlyStatement.zod.js +2 -2
- package/dist/membership/v1/generated/validators/objectIdentity.zod.js +1 -1
- package/dist/membership/v1/generated/validators/order.zod.d.ts +7 -4
- package/dist/membership/v1/generated/validators/order.zod.js +10 -12
- package/dist/membership/v1/generated/validators/orderItem.zod.d.ts +7 -3
- package/dist/membership/v1/generated/validators/orderItem.zod.js +16 -14
- package/dist/membership/v1/generated/validators/orderItemList.zod.d.ts +7 -3
- package/dist/membership/v1/generated/validators/orderItemStatus.zod.js +1 -1
- package/dist/membership/v1/generated/validators/orderList.zod.d.ts +7 -4
- package/dist/membership/v1/generated/validators/orderRefundQuote.zod.js +1 -1
- package/dist/membership/v1/generated/validators/orderRefundQuoteInput.zod.js +1 -1
- package/dist/membership/v1/generated/validators/orderStatus.zod.js +1 -1
- package/dist/membership/v1/generated/validators/paidWith.zod.js +1 -1
- package/dist/membership/v1/generated/validators/payInvoiceRequest.zod.js +6 -6
- package/dist/membership/v1/generated/validators/payTogetherRequest.zod.js +2 -2
- package/dist/membership/v1/generated/validators/paymentAction.zod.js +4 -4
- package/dist/membership/v1/generated/validators/paymentCancellationReason.zod.js +1 -1
- package/dist/membership/v1/generated/validators/paymentMethodSetupResult.zod.js +2 -4
- package/dist/membership/v1/generated/validators/paymentOption.zod.js +1 -1
- package/dist/membership/v1/generated/validators/paymentOptionMethod.zod.js +1 -1
- package/dist/membership/v1/generated/validators/paymentPreview.zod.js +4 -4
- package/dist/membership/v1/generated/validators/paymentResult.zod.js +5 -8
- package/dist/membership/v1/generated/validators/paymentStatus.zod.js +1 -1
- package/dist/membership/v1/generated/validators/placedOrder.zod.d.ts +0 -1
- package/dist/membership/v1/generated/validators/price.zod.d.ts +7 -5
- package/dist/membership/v1/generated/validators/price.zod.js +14 -11
- package/dist/membership/v1/generated/validators/priceList.zod.d.ts +7 -5
- package/dist/membership/v1/generated/validators/priceOption.zod.d.ts +7 -5
- package/dist/membership/v1/generated/validators/priceOption.zod.js +7 -3
- package/dist/membership/v1/generated/validators/priceType.zod.d.ts +14 -0
- package/dist/membership/v1/generated/validators/priceType.zod.js +11 -0
- package/dist/membership/v1/generated/validators/productID.zod.js +1 -1
- package/dist/membership/v1/generated/validators/projectAssignment.zod.js +2 -2
- package/dist/membership/v1/generated/validators/purchaseOperation.zod.js +1 -1
- package/dist/membership/v1/generated/validators/quote.zod.d.ts +6 -3
- package/dist/membership/v1/generated/validators/quote.zod.js +4 -4
- package/dist/membership/v1/generated/validators/quoteCancellation.zod.js +2 -2
- package/dist/membership/v1/generated/validators/quoteItem.zod.js +4 -4
- package/dist/membership/v1/generated/validators/quoteItemInput.zod.d.ts +5 -2
- package/dist/membership/v1/generated/validators/quoteItemInput.zod.js +8 -8
- package/dist/membership/v1/generated/validators/quoteRenewal.zod.js +1 -1
- package/dist/membership/v1/generated/validators/quoteRenewalResult.zod.js +2 -2
- package/dist/membership/v1/generated/validators/quoteRequest.zod.d.ts +5 -2
- package/dist/membership/v1/generated/validators/quoteRequest.zod.js +5 -5
- package/dist/membership/v1/generated/validators/quotedDiscount.zod.js +1 -1
- package/dist/membership/v1/generated/validators/rate.zod.d.ts +11 -0
- package/dist/membership/v1/generated/validators/rate.zod.js +14 -6
- package/dist/membership/v1/generated/validators/rateList.zod.d.ts +11 -0
- package/dist/membership/v1/generated/validators/refund.zod.js +3 -3
- package/dist/membership/v1/generated/validators/refundPolicy.zod.js +1 -1
- package/dist/membership/v1/generated/validators/refundReason.zod.js +1 -1
- package/dist/membership/v1/generated/validators/renewRequest.zod.js +2 -2
- package/dist/membership/v1/generated/validators/renewalOrderRequest.zod.js +2 -2
- package/dist/membership/v1/generated/validators/renewalPrice.zod.js +1 -1
- package/dist/membership/v1/generated/validators/scheduledChange.zod.js +2 -2
- package/dist/membership/v1/generated/validators/spendRow.zod.d.ts +8 -0
- package/dist/membership/v1/generated/validators/spendRow.zod.js +11 -0
- package/dist/membership/v1/generated/validators/spendRowList.zod.d.ts +8 -0
- package/dist/membership/v1/generated/validators/spendRowList.zod.js +1 -1
- package/dist/membership/v1/generated/validators/statement.zod.js +2 -2
- package/dist/membership/v1/generated/validators/statementItem.zod.d.ts +1 -0
- package/dist/membership/v1/generated/validators/statementItem.zod.js +4 -0
- package/dist/membership/v1/generated/validators/statementSummary.zod.d.ts +1 -0
- package/dist/membership/v1/generated/validators/statementType.zod.js +1 -1
- package/dist/membership/v1/generated/validators/subscription.zod.d.ts +7 -3
- package/dist/membership/v1/generated/validators/subscription.zod.js +20 -14
- package/dist/membership/v1/generated/validators/subscriptionCancellation.zod.js +2 -2
- package/dist/membership/v1/generated/validators/subscriptionList.zod.d.ts +7 -3
- package/dist/membership/v1/generated/validators/subscriptionRestriction.zod.js +1 -1
- package/dist/membership/v1/generated/validators/terminationPolicy.zod.js +1 -1
- package/dist/membership/v1/generated/validators/tier.zod.js +1 -1
- package/dist/membership/v1/generated/validators/topUp.zod.js +8 -8
- package/dist/membership/v1/generated/validators/topUpCreate.zod.js +4 -4
- package/dist/membership/v1/generated/validators/transaction.zod.js +6 -6
- package/dist/membership/v1/generated/validators/usageCharge.zod.d.ts +1 -0
- package/dist/membership/v1/generated/validators/usageCharge.zod.js +8 -7
- package/dist/membership/v1/generated/validators/usageChargeList.zod.d.ts +1 -0
- package/dist/membership/v1/generated/validators/usageType.zod.d.ts +14 -0
- package/dist/membership/v1/generated/validators/usageType.zod.js +11 -0
- package/dist/membership/v1/generated/validators/withdrawal.zod.js +2 -2
- package/dist/membership/v1/generated/validators/withdrawalItem.zod.js +2 -2
- package/dist/membership/v1/generated/validators/withdrawalSource.zod.js +1 -1
- package/dist/routes.d.ts +4 -4
- package/dist/routes.js +4 -4
- package/package.json +1 -1
|
@@ -6,12 +6,7 @@
|
|
|
6
6
|
* OpenAPI spec version: v1
|
|
7
7
|
*/
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
10
|
-
* the discount is applied and it is issued; other drafts are private to administrators.
|
|
11
|
-
* An issued invoice is open until settled; a zero-total issued invoice is immediately paid.
|
|
12
|
-
* Unbilled usage remains separate from invoices until it is invoiced.
|
|
13
|
-
* A refund does not change the status: a paid invoice stays paid, with the refunded part in
|
|
14
|
-
* amount_refunded. void means collection has stopped and any funds received have been returned.
|
|
9
|
+
* `draft`: not yet issued; an order's draft invoice shows base prices until it is paid, when the discount is applied and it is issued. Other drafts are visible only to operators. `open`: issued and not yet settled; a zero-total invoice is paid at once. `paid` stays paid after a refund, with the refunded part in amount_refunded. `void`: collection has stopped and any funds received have been returned. Usage not yet invoiced is not on any invoice.
|
|
15
10
|
*/
|
|
16
11
|
export type InvoiceStatus = (typeof InvoiceStatus)[keyof typeof InvoiceStatus];
|
|
17
12
|
export declare const InvoiceStatus: {
|
|
@@ -19,7 +14,6 @@ export declare const InvoiceStatus: {
|
|
|
19
14
|
readonly open: "open";
|
|
20
15
|
readonly paid: "paid";
|
|
21
16
|
readonly void: "void";
|
|
22
|
-
readonly uncollectible: "uncollectible";
|
|
23
17
|
};
|
|
24
18
|
/**
|
|
25
19
|
* A decimal string, in the currency stated alongside it.
|
|
@@ -34,10 +28,7 @@ export declare const InvoiceStatus: {
|
|
|
34
28
|
*/
|
|
35
29
|
export type Money = string;
|
|
36
30
|
/**
|
|
37
|
-
*
|
|
38
|
-
* has an invoice from placement. A draft shows base prices until it is paid, when the discount is
|
|
39
|
-
* applied and it is issued; a zero-total invoice is issued and paid at placement whatever the
|
|
40
|
-
* checkout mode. Neither establishes acceptance or delivery.
|
|
31
|
+
* An order's invoice amounts, without contact details or payment methods. A draft shows base prices until it is paid, when the discount is applied and it is issued; a zero-total invoice is issued and paid at placement.
|
|
41
32
|
*/
|
|
42
33
|
export interface InvoiceSummary {
|
|
43
34
|
id: string;
|
|
@@ -55,9 +46,9 @@ export interface InvoiceSummary {
|
|
|
55
46
|
tax_amount: string;
|
|
56
47
|
total: string;
|
|
57
48
|
amount_paid: string;
|
|
58
|
-
/** Issued
|
|
49
|
+
/** Issued credit notes that reduced unpaid receivables; the original invoice total is unchanged. */
|
|
59
50
|
pre_payment_credit_notes_amount: Money;
|
|
60
|
-
/** Issued credit notes against payments already received
|
|
51
|
+
/** Issued credit notes against payments already received; their refunds may not have completed. */
|
|
61
52
|
post_payment_credit_notes_amount: Money;
|
|
62
53
|
/**
|
|
63
54
|
* What is still collectible after unpaid credit notes and successful payments; never below zero.
|
|
@@ -120,7 +111,7 @@ export declare const WithdrawalItemStatus: {
|
|
|
120
111
|
readonly reversed: "reversed";
|
|
121
112
|
};
|
|
122
113
|
/**
|
|
123
|
-
* The original top-up and its refund
|
|
114
|
+
* The original top-up and where its refund goes. Card details are included when the original payment method was saved.
|
|
124
115
|
*/
|
|
125
116
|
export interface WithdrawalSource {
|
|
126
117
|
/** @pattern ^[0-9]{1,15}([.][0-9]{1,10})?$ */
|
|
@@ -138,7 +129,7 @@ export interface WithdrawalSource {
|
|
|
138
129
|
card_last4?: string;
|
|
139
130
|
}
|
|
140
131
|
/**
|
|
141
|
-
*
|
|
132
|
+
* For one original top-up: the principal deducted, the withdrawal fee and the amount refunded, through its own refund. payment_gateway and method_type identify the original route.
|
|
142
133
|
*/
|
|
143
134
|
export interface WithdrawalItem {
|
|
144
135
|
source_transaction_id: string;
|
|
@@ -163,7 +154,7 @@ export interface WithdrawalItem {
|
|
|
163
154
|
payment_gateway: string;
|
|
164
155
|
method_type: string;
|
|
165
156
|
source: WithdrawalSource;
|
|
166
|
-
/** The
|
|
157
|
+
/** The gateway's failure code when a refund failed, or `refund_reversed` when a completed refund was reversed. Absent while pending or successful. */
|
|
167
158
|
failure_code?: string;
|
|
168
159
|
}
|
|
169
160
|
export type WithdrawalStatus = (typeof WithdrawalStatus)[keyof typeof WithdrawalStatus];
|
|
@@ -176,7 +167,7 @@ export declare const WithdrawalStatus: {
|
|
|
176
167
|
readonly reversed: "reversed";
|
|
177
168
|
};
|
|
178
169
|
/**
|
|
179
|
-
*
|
|
170
|
+
* A withdrawal of account balance to the original payment methods of its unused top-ups. Accepted amounts are fixed. deducted_amount, settled_amount and charged_fee_amount cover completed items. A failed item releases its principal and fee; successful items stand when another item fails.
|
|
180
171
|
*/
|
|
181
172
|
export interface Withdrawal {
|
|
182
173
|
id: string;
|
|
@@ -201,7 +192,7 @@ export interface Withdrawal {
|
|
|
201
192
|
status: WithdrawalStatus;
|
|
202
193
|
created_at: string;
|
|
203
194
|
completed_at?: string;
|
|
204
|
-
/**
|
|
195
|
+
/** Who submitted the withdrawal; may differ from the account owner. */
|
|
205
196
|
created_by?: string;
|
|
206
197
|
}
|
|
207
198
|
export interface WithdrawalPreviewItem {
|
|
@@ -259,7 +250,7 @@ export interface WithdrawalItemList {
|
|
|
259
250
|
pagination: OffsetPagination;
|
|
260
251
|
}
|
|
261
252
|
/**
|
|
262
|
-
* Whether a
|
|
253
|
+
* Whether a delivered purchase may end immediately or only at the end of its paid term; refunds follow the refund policy. When absent, no termination terms were agreed.
|
|
263
254
|
*/
|
|
264
255
|
export type TerminationPolicy = (typeof TerminationPolicy)[keyof typeof TerminationPolicy];
|
|
265
256
|
export declare const TerminationPolicy: {
|
|
@@ -267,16 +258,7 @@ export declare const TerminationPolicy: {
|
|
|
267
258
|
readonly period_end: "period_end";
|
|
268
259
|
};
|
|
269
260
|
/**
|
|
270
|
-
* none refunds nothing. prorated refunds the amount paid for the current period minus the value of
|
|
271
|
-
* the time used, never below zero and never more than what remains unrefunded. The time used runs
|
|
272
|
-
* from the period start to the effective cancellation time and is valued at the plan's
|
|
273
|
-
* shorter-period prices in the same currency, frozen at purchase as the order item's
|
|
274
|
-
* refund_monthly_amount and refund_hourly_amount: each full calendar month at the one-month prepaid
|
|
275
|
-
* price, the remainder at the postpaid hourly price or, without one, at the one-month price by the
|
|
276
|
-
* second. When the plan has no prepaid period shorter than the one bought, the time used is valued
|
|
277
|
-
* at the price paid, pro rata by the second. Discounts are not refunded, as they were never paid,
|
|
278
|
-
* and setup fees are excluded. The refunded part returns to the payment sources it came from. Tax
|
|
279
|
-
* paid is refunded in the same proportion as the amount it was paid on.
|
|
261
|
+
* `none` refunds nothing. `prorated` refunds the amount paid for the current period minus the value of the time used, never below zero or above what remains unrefunded. Time used runs from the period start to the effective cancellation and is valued at prices frozen on the order item: each full calendar month at `refund_monthly_amount`, the rest at `refund_hourly_amount` or, without it, at the monthly price by the second. When the plan has no licensed period shorter than the one bought, time used is valued pro rata at the price paid. Discounts and setup fees are not refunded. Refunds return to the original payment sources, with tax refunded in proportion.
|
|
280
262
|
*/
|
|
281
263
|
export type RefundPolicy = (typeof RefundPolicy)[keyof typeof RefundPolicy];
|
|
282
264
|
export declare const RefundPolicy: {
|
|
@@ -298,7 +280,7 @@ export declare const QuoteRenewalInterval: {
|
|
|
298
280
|
readonly year: "year";
|
|
299
281
|
};
|
|
300
282
|
/**
|
|
301
|
-
* Price renewing a
|
|
283
|
+
* Price renewing a licensed subscription. Give `price_id`, or `interval` with
|
|
302
284
|
* `interval_count`, to renew for another term at the price currently sold for it. Naming
|
|
303
285
|
* the current term, or giving neither, renews at the agreed amount. A term sold at several
|
|
304
286
|
* prices that differ in termination policy is refused with 409
|
|
@@ -326,9 +308,7 @@ export declare const QuoteRenewalResultInterval: {
|
|
|
326
308
|
readonly year: "year";
|
|
327
309
|
};
|
|
328
310
|
/**
|
|
329
|
-
* What renewing would charge. Renewing the same subscription for the same term and
|
|
330
|
-
* of periods charges exactly `total`, unless prices or the discounts the account holds
|
|
331
|
-
* change in between.
|
|
311
|
+
* What renewing would charge. Renewing the same subscription for the same term and periods charges exactly `total` unless prices or the account's discounts change first.
|
|
332
312
|
*/
|
|
333
313
|
export interface QuoteRenewalResult {
|
|
334
314
|
/** Which renewal of the request this answers. */
|
|
@@ -339,11 +319,7 @@ export interface QuoteRenewalResult {
|
|
|
339
319
|
interval: QuoteRenewalResultInterval;
|
|
340
320
|
interval_count: number;
|
|
341
321
|
periods: number;
|
|
342
|
-
/**
|
|
343
|
-
* The price of the periods before the discounts the account holds. A discount the
|
|
344
|
-
* subscription already carries is reflected here. Contains tax only where the price
|
|
345
|
-
* itself includes it.
|
|
346
|
-
*/
|
|
322
|
+
/** The price of the periods before the account's discounts, with any discount the subscription carries already reflected; includes tax only where the price does. */
|
|
347
323
|
amount: Money;
|
|
348
324
|
/** The reduction from a discount the account holds. */
|
|
349
325
|
discount_amount: Money;
|
|
@@ -358,25 +334,25 @@ export interface QuoteRenewalResult {
|
|
|
358
334
|
total: Money;
|
|
359
335
|
}
|
|
360
336
|
/**
|
|
361
|
-
* One fully calculated purchase, estimated
|
|
337
|
+
* One fully calculated purchase, estimated metered usage or recorded order item. Amounts use the
|
|
362
338
|
* billing-account currency. An item with no immediate charge has zero checkout amounts.
|
|
363
339
|
*/
|
|
364
340
|
export interface QuoteItem {
|
|
365
341
|
tax_amount: Money;
|
|
366
342
|
tax_included_amount: Money;
|
|
367
343
|
/**
|
|
368
|
-
*
|
|
344
|
+
* The zero-based request line index, or the recorded order item's position for an order quote.
|
|
369
345
|
* @minimum 0
|
|
370
346
|
*/
|
|
371
347
|
index: number;
|
|
372
348
|
/** Present for an existing order quote; identifies the recorded item being priced. */
|
|
373
349
|
order_item_id?: string;
|
|
374
|
-
/** The selected price,
|
|
350
|
+
/** The selected price, also when the request identified it indirectly. */
|
|
375
351
|
price_id: string;
|
|
376
352
|
plan_name: string;
|
|
377
353
|
/** Unit price before discounts. Null when no single unit price applies, such as tiered or multiple-rate pricing. */
|
|
378
354
|
unit_amount: Money | null;
|
|
379
|
-
/** The quantity priced
|
|
355
|
+
/** The quantity priced; with duration_seconds, quantity times the duration. */
|
|
380
356
|
quantity: string;
|
|
381
357
|
/** Amount before discounts and including any setup charge. For requested future usage this is an estimate, not a collectible checkout amount. */
|
|
382
358
|
amount: Money;
|
|
@@ -387,16 +363,16 @@ export interface QuoteItem {
|
|
|
387
363
|
/**
|
|
388
364
|
* Account funding for this purchase, calculated by Billing. Amounts use the enclosing response currency.
|
|
389
365
|
* Credit eligibility and all purchase requirements are already evaluated. Nothing is charged or reserved.
|
|
390
|
-
* A
|
|
366
|
+
* A licensed purchase may instead be paid with an online payment method.
|
|
391
367
|
*/
|
|
392
368
|
export interface Funds {
|
|
393
369
|
/** Spendable balance after pending returns. */
|
|
394
370
|
available_balance_amount: Money;
|
|
395
|
-
/** Currently effective credits eligible for the quoted purchases or
|
|
371
|
+
/** Currently effective credits eligible for the quoted purchases or metered usage. Each grant is counted once. */
|
|
396
372
|
usable_credit_amount: Money;
|
|
397
|
-
/** Currently effective credits that cannot fund any quoted purchase or
|
|
373
|
+
/** Currently effective credits that cannot fund any quoted purchase or metered target. Unused eligible credits are not restricted. */
|
|
398
374
|
restricted_credit_amount: Money;
|
|
399
|
-
/** Minimum spendable balance needed after eligible credits, covering immediate charges and every new
|
|
375
|
+
/** Minimum spendable balance needed after eligible credits, covering immediate charges and every new metered purchase's admission requirement. */
|
|
400
376
|
required_balance_amount: Money;
|
|
401
377
|
/** Additional balance needed now. Zero means account funds satisfy this quote. No funds are reserved. */
|
|
402
378
|
balance_shortfall_amount: Money;
|
|
@@ -409,8 +385,7 @@ export declare const QuotedDiscountType: {
|
|
|
409
385
|
readonly account_discount: "account_discount";
|
|
410
386
|
};
|
|
411
387
|
/**
|
|
412
|
-
* The discount selected for this calculation.
|
|
413
|
-
* reserve a redemption. Discount amounts are reported on the quote and its lines.
|
|
388
|
+
* The discount selected for this calculation, not applied and not reserved. Amounts are on the quote and its lines.
|
|
414
389
|
*/
|
|
415
390
|
export interface QuotedDiscount {
|
|
416
391
|
type: QuotedDiscountType;
|
|
@@ -438,30 +413,35 @@ export interface NamedIdentity {
|
|
|
438
413
|
/** @maxLength 255 */
|
|
439
414
|
name: string;
|
|
440
415
|
}
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
416
|
+
/**
|
|
417
|
+
* `one_time` charges once when bought. `recurring` charges again for every period, or for usage as it is settled.
|
|
418
|
+
*/
|
|
419
|
+
export type PriceType = (typeof PriceType)[keyof typeof PriceType];
|
|
420
|
+
export declare const PriceType: {
|
|
445
421
|
readonly one_time: "one_time";
|
|
422
|
+
readonly recurring: "recurring";
|
|
446
423
|
};
|
|
447
424
|
/**
|
|
448
|
-
*
|
|
425
|
+
* `licensed` charges for the quantity bought, each period paid before it starts. `metered` charges for the usage
|
|
426
|
+
* reported, after it is settled; a metered subscription lasts until it is canceled. A one-time price is licensed.
|
|
427
|
+
*/
|
|
428
|
+
export type UsageType = (typeof UsageType)[keyof typeof UsageType];
|
|
429
|
+
export declare const UsageType: {
|
|
430
|
+
readonly licensed: "licensed";
|
|
431
|
+
readonly metered: "metered";
|
|
432
|
+
};
|
|
433
|
+
/**
|
|
434
|
+
* One subscription of the quoted cancellation.
|
|
449
435
|
*/
|
|
450
436
|
export interface CancellationRefundPreviewItem {
|
|
451
437
|
subscription_id: string;
|
|
452
438
|
plan_id: string;
|
|
453
439
|
plan_name: string;
|
|
454
|
-
/**
|
|
455
|
-
* The project and its current name, for display. Absent for a purchase at account level, and when the
|
|
456
|
-
* project details cannot be read at the moment.
|
|
457
|
-
*/
|
|
440
|
+
/** The project and its current name. Absent for an account-level purchase or when the project cannot be read. */
|
|
458
441
|
project?: NamedIdentity | null;
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
* cancellation does not turn it back on for a prepaid subscription; a postpaid subscription continues
|
|
463
|
-
* until it is canceled and turns it back on.
|
|
464
|
-
*/
|
|
442
|
+
type: PriceType;
|
|
443
|
+
usage_type: UsageType;
|
|
444
|
+
/** Whether automatic renewal is on now. Creating the cancellation turns it off; withdrawing it turns it back on for a metered subscription but not for a licensed one. */
|
|
465
445
|
auto_renew: boolean;
|
|
466
446
|
unused_amount: Money;
|
|
467
447
|
refundable_amount: Money;
|
|
@@ -471,19 +451,19 @@ export interface CancellationRefundPreviewItem {
|
|
|
471
451
|
forfeited_amount: Money;
|
|
472
452
|
}
|
|
473
453
|
/**
|
|
474
|
-
* What the cancellation would return,
|
|
475
|
-
* `
|
|
454
|
+
* What the cancellation would return, per subscription and in total, as of now. Give `proration_date` and
|
|
455
|
+
* `refundable_amount` when creating the cancellation.
|
|
476
456
|
*
|
|
477
|
-
* - `unused_amount`: before tax, the amount paid for the current periods minus the value of the
|
|
478
|
-
*
|
|
479
|
-
* - `refundable_amount`: what is returned the way it was paid,
|
|
480
|
-
* `
|
|
481
|
-
* - `refund_amount`: the part returned to the balance or
|
|
457
|
+
* - `unused_amount`: before tax, the amount paid for the current periods minus the value of the time used,
|
|
458
|
+
* valued as refund policy `prorated` describes, whatever the refund terms say.
|
|
459
|
+
* - `refundable_amount`: what is returned the way it was paid, tax included; `refund_amount` plus
|
|
460
|
+
* `credit_amount`.
|
|
461
|
+
* - `refund_amount`: the part returned to the balance or the payment method.
|
|
482
462
|
* - `credit_amount`: the part restored to the credit grants that paid.
|
|
483
463
|
* - `tax_amount`: the tax included in `refundable_amount`.
|
|
484
464
|
* - `forfeited_amount`: before tax, the part of `unused_amount` the refund terms do not return.
|
|
485
465
|
*
|
|
486
|
-
*
|
|
466
|
+
* Metered and one-time subscriptions show zero; their usage until release is charged as usual.
|
|
487
467
|
*/
|
|
488
468
|
export interface CancellationRefundPreview {
|
|
489
469
|
mode: TerminationPolicy;
|
|
@@ -501,11 +481,7 @@ export interface CancellationRefundPreview {
|
|
|
501
481
|
items: CancellationRefundPreviewItem[];
|
|
502
482
|
}
|
|
503
483
|
/**
|
|
504
|
-
* An estimated refund to original payment sources. Before acceptance, cancellation returns the
|
|
505
|
-
* collected amount. For delivered service, only value funded by this order is included; renewals
|
|
506
|
-
* are evaluated under their own orders and the agreed termination terms apply. An unknown
|
|
507
|
-
* delivery outcome is not evidence that a refund is eligible. This calculation does not create
|
|
508
|
-
* a refund; the amount returned is determined when cancellation or termination is confirmed.
|
|
484
|
+
* An estimated refund to the original payment sources. Before acceptance, cancellation returns the collected amount. For delivered service, only value paid by this order is included; renewals are evaluated with their own orders under the agreed termination terms. Nothing is refunded by the quote; the amount is fixed when cancellation or termination is confirmed.
|
|
509
485
|
*/
|
|
510
486
|
export interface OrderRefundQuote {
|
|
511
487
|
order_id: string;
|
|
@@ -515,21 +491,15 @@ export interface OrderRefundQuote {
|
|
|
515
491
|
currency: string;
|
|
516
492
|
}
|
|
517
493
|
/**
|
|
518
|
-
* A complete calculation in
|
|
519
|
-
* redemptions. The request fails if any item cannot be priced. Requested future usage estimates are
|
|
520
|
-
* included in totals for reporting and are not collectible at checkout. Only an existing-order quote
|
|
521
|
-
* provides that order's checkout amount.
|
|
494
|
+
* A complete calculation in the billing account's currency; nothing is saved or reserved. The request fails if any item cannot be priced. Usage estimates are included in totals but are not collected at checkout; only an existing-order quote gives that order's checkout amount.
|
|
522
495
|
*/
|
|
523
496
|
export interface Quote {
|
|
524
|
-
/** Account
|
|
497
|
+
/** Account funds for an existing-order checkout quote. Absent for usage estimates, refunds and cancellations. */
|
|
525
498
|
funds?: Funds;
|
|
526
499
|
subtotal: Money;
|
|
527
500
|
discount_amount: Money;
|
|
528
501
|
tax_amount: Money;
|
|
529
|
-
/**
|
|
530
|
-
* The discount evaluated for a purchase or order, without applying it. Null when none is selected or
|
|
531
|
-
* when quoting renewals or a cancellation. A confirmed order reports its recorded discount.
|
|
532
|
-
*/
|
|
502
|
+
/** The discount a purchase or order would get, not yet applied. Null when there is none, and for renewals and cancellations. A confirmed order reports its recorded discount. */
|
|
533
503
|
discount: QuotedDiscount | null;
|
|
534
504
|
items: QuoteItem[];
|
|
535
505
|
renewals: QuoteRenewalResult[];
|
|
@@ -537,20 +507,15 @@ export interface Quote {
|
|
|
537
507
|
cancellation?: CancellationRefundPreview;
|
|
538
508
|
total: Money;
|
|
539
509
|
currency: string;
|
|
540
|
-
/** Present
|
|
510
|
+
/** Present when an order refund was requested. */
|
|
541
511
|
refund?: OrderRefundQuote;
|
|
542
512
|
}
|
|
543
513
|
/**
|
|
544
|
-
* A cancellation to quote: what ending these subscriptions together would return
|
|
545
|
-
* request; to compare, quote `immediate` and `period_end` separately.
|
|
546
|
-
*
|
|
547
|
-
* Refused with 409 `BILLING_SUBSCRIPTION_OPERATION_PENDING` when a subscription is already being
|
|
548
|
-
* canceled (`meta.cancellation_id`), is being reclaimed (`meta.reason` `reclaim_requested`) or has a
|
|
549
|
-
* paid change still waiting to switch (`meta.order_id`).
|
|
514
|
+
* A cancellation to quote: what ending these subscriptions together would return, for one mode; quote `immediate` and `period_end` separately to compare. Refused with 409 `BILLING_SUBSCRIPTION_OPERATION_PENDING` when a subscription is already being canceled (`meta.cancellation_id`), is being reclaimed (`meta.reason` `reclaim_requested`) or has a paid change waiting to switch (`meta.order_id`).
|
|
550
515
|
*/
|
|
551
516
|
export interface QuoteCancellation {
|
|
552
517
|
/**
|
|
553
|
-
* The subscriptions to end together, all of one service
|
|
518
|
+
* The subscriptions to end together, all of one service, including every subscription released with a resource.
|
|
554
519
|
* @minItems 1
|
|
555
520
|
* @maxItems 50
|
|
556
521
|
*/
|
|
@@ -565,15 +530,12 @@ export interface CancellationCreate {
|
|
|
565
530
|
*/
|
|
566
531
|
subscription_ids: string[];
|
|
567
532
|
mode: TerminationPolicy;
|
|
568
|
-
/**
|
|
569
|
-
* For `immediate`, the `proration_date` of the quote: a whole second, not in the future and
|
|
570
|
-
* at most ten minutes old. The refund is computed as of it. Now when omitted.
|
|
571
|
-
*/
|
|
533
|
+
/** For `immediate`, the quote's `proration_date`: a whole second, not in the future and at most ten minutes old; the refund is computed as of it. Now when omitted. */
|
|
572
534
|
proration_date?: string;
|
|
573
|
-
/** The `refundable_amount
|
|
535
|
+
/** The quote's `refundable_amount`; the cancellation is refused when the refund differs. */
|
|
574
536
|
expected_refundable_amount: Money & string;
|
|
575
537
|
/**
|
|
576
|
-
* A note from the account holder
|
|
538
|
+
* A note from the account holder, kept with the cancellation.
|
|
577
539
|
* @maxLength 1024
|
|
578
540
|
*/
|
|
579
541
|
reason?: string;
|
|
@@ -588,7 +550,7 @@ export declare const CancellationStatus: {
|
|
|
588
550
|
readonly failed: "failed";
|
|
589
551
|
};
|
|
590
552
|
/**
|
|
591
|
-
* Who
|
|
553
|
+
* Who requested it; `project_deletion` means the project was deleted.
|
|
592
554
|
*/
|
|
593
555
|
export type CancellationOrigin = (typeof CancellationOrigin)[keyof typeof CancellationOrigin];
|
|
594
556
|
export declare const CancellationOrigin: {
|
|
@@ -596,17 +558,6 @@ export declare const CancellationOrigin: {
|
|
|
596
558
|
readonly operator: "operator";
|
|
597
559
|
readonly project_deletion: "project_deletion";
|
|
598
560
|
};
|
|
599
|
-
/**
|
|
600
|
-
* How the subscription is charged. Creating the cancellation turned automatic renewal off;
|
|
601
|
-
* withdrawing it turns renewal back on for a `postpaid` subscription and leaves it off for a
|
|
602
|
-
* `prepaid` one.
|
|
603
|
-
*/
|
|
604
|
-
export type CancellationItemChargeType = (typeof CancellationItemChargeType)[keyof typeof CancellationItemChargeType];
|
|
605
|
-
export declare const CancellationItemChargeType: {
|
|
606
|
-
readonly postpaid: "postpaid";
|
|
607
|
-
readonly prepaid: "prepaid";
|
|
608
|
-
readonly one_time: "one_time";
|
|
609
|
-
};
|
|
610
561
|
export type CancellationItemStatus = (typeof CancellationItemStatus)[keyof typeof CancellationItemStatus];
|
|
611
562
|
export declare const CancellationItemStatus: {
|
|
612
563
|
readonly requested: "requested";
|
|
@@ -620,19 +571,19 @@ export declare const CancellationItemStatus: {
|
|
|
620
571
|
* One subscription of the cancellation.
|
|
621
572
|
*/
|
|
622
573
|
export interface CancellationItem {
|
|
623
|
-
/** The cancellation item
|
|
574
|
+
/** The subscription's cancellation item, the same as `Subscription.cancellation.id`. */
|
|
624
575
|
id: string;
|
|
625
576
|
subscription_id: string;
|
|
626
577
|
plan_id: string;
|
|
627
578
|
plan_name: string;
|
|
579
|
+
type: PriceType;
|
|
628
580
|
/**
|
|
629
|
-
*
|
|
630
|
-
*
|
|
631
|
-
* `prepaid` one.
|
|
581
|
+
* Creating the cancellation turned automatic renewal off; withdrawing it turns renewal back on
|
|
582
|
+
* for a `metered` subscription and leaves it off for a `licensed` one.
|
|
632
583
|
*/
|
|
633
|
-
|
|
584
|
+
usage_type: UsageType;
|
|
634
585
|
status: CancellationItemStatus;
|
|
635
|
-
/**
|
|
586
|
+
/** The release stopped or its result is unknown; present while the release needs resolution. */
|
|
636
587
|
failure_code?: string;
|
|
637
588
|
release_started_at?: string;
|
|
638
589
|
/** When the service ended, as confirmed by the service that provides it. */
|
|
@@ -662,20 +613,14 @@ export interface Cancellation {
|
|
|
662
613
|
scheduled_at?: string;
|
|
663
614
|
/** For `immediate`, the second the refund is computed as of. */
|
|
664
615
|
proration_date?: string;
|
|
665
|
-
/** Who
|
|
616
|
+
/** Who requested it; `project_deletion` means the project was deleted. */
|
|
666
617
|
origin: CancellationOrigin;
|
|
667
|
-
/**
|
|
668
|
-
* The billing account that paid for these subscriptions when the cancellation was created: the
|
|
669
|
-
* account of an account-level purchase, or the account the project was linked to.
|
|
670
|
-
*/
|
|
618
|
+
/** The billing account paying for these subscriptions when the cancellation was created: the purchasing account of an account-level purchase, or the project's linked account. */
|
|
671
619
|
billing_account_id: number;
|
|
672
620
|
currency: string;
|
|
673
|
-
/** The refund confirmed when
|
|
621
|
+
/** The refund confirmed when the cancellation was created. Absent when the platform created it. */
|
|
674
622
|
expected_refundable_amount?: Money;
|
|
675
|
-
/**
|
|
676
|
-
* Present with `failed`. A code of the service that provides the resources, such as a disk
|
|
677
|
-
* that can only be released with its server. Clients map it to their own wording.
|
|
678
|
-
*/
|
|
623
|
+
/** Present with `failed`: the owning service's code, such as for a disk that can only be released with its server. */
|
|
679
624
|
failure_code?: string;
|
|
680
625
|
requested_at: string;
|
|
681
626
|
completed_at?: string;
|
|
@@ -701,13 +646,11 @@ export declare const SubscriptionCancellationMode: {
|
|
|
701
646
|
readonly period_end: "period_end";
|
|
702
647
|
};
|
|
703
648
|
/**
|
|
704
|
-
* The latest cancellation
|
|
705
|
-
* item; `cancellation_id` is the cancellation. scheduled_at is the intended time; effective_at is the
|
|
706
|
-
* confirmed end of service. A cancellation alone does not stop metering or issue a refund.
|
|
649
|
+
* The latest cancellation including the subscription, with this subscription's item: `id` is the item and `cancellation_id` the cancellation. scheduled_at is the intended time and effective_at the confirmed end of service.
|
|
707
650
|
*/
|
|
708
651
|
export interface SubscriptionCancellation {
|
|
709
652
|
reason?: string;
|
|
710
|
-
/** The cancellation this
|
|
653
|
+
/** The cancellation this item belongs to, with the other subscriptions released together. */
|
|
711
654
|
cancellation_id?: string;
|
|
712
655
|
id: string;
|
|
713
656
|
subscription_id: string;
|
|
@@ -741,7 +684,7 @@ export interface Error {
|
|
|
741
684
|
status: number;
|
|
742
685
|
}
|
|
743
686
|
/**
|
|
744
|
-
*
|
|
687
|
+
* The platform service's fixed identifier, such as compute, canopy or assistant.
|
|
745
688
|
* @minLength 1
|
|
746
689
|
* @maxLength 64
|
|
747
690
|
* @pattern ^[a-z][a-z0-9]*(-[a-z0-9]+)*$
|
|
@@ -760,29 +703,22 @@ export declare const BillingAccountStatus: {
|
|
|
760
703
|
};
|
|
761
704
|
export interface BillingAccount {
|
|
762
705
|
/**
|
|
763
|
-
* The active contact used for
|
|
706
|
+
* The active contact used for invoices, of this account; null clears it.
|
|
764
707
|
* @nullable
|
|
765
708
|
*/
|
|
766
709
|
invoice_contact_id?: string | null;
|
|
767
710
|
id: number;
|
|
768
|
-
/**
|
|
711
|
+
/** Your name for the account. */
|
|
769
712
|
name?: string;
|
|
770
713
|
/** Fixed when the account was opened. */
|
|
771
714
|
currency: string;
|
|
772
715
|
status: BillingAccountStatus;
|
|
773
|
-
/**
|
|
774
|
-
* How far past the suspension threshold this account may go before its resources are
|
|
775
|
-
* suspended. "0" means none: the account is suspended as soon as it crosses the threshold.
|
|
776
|
-
*/
|
|
716
|
+
/** How far past the suspension threshold the account may go before its resources are suspended; `0` means none. */
|
|
777
717
|
grace_amount?: string;
|
|
778
|
-
/**
|
|
779
|
-
* How long this account has to top up after crossing the suspension threshold.
|
|
780
|
-
* 0 means none. Whichever runs out first — this or grace_amount — ends the grace.
|
|
781
|
-
*/
|
|
718
|
+
/** How long the account has to top up after crossing the suspension threshold, in seconds; `0` means none. Grace ends when this or grace_amount runs out. */
|
|
782
719
|
grace_period_seconds?: number;
|
|
783
720
|
/**
|
|
784
|
-
*
|
|
785
|
-
* Null or absent if the account is not closed or its historical close time is unknown.
|
|
721
|
+
* When the account was closed. Null if it is not closed or the time is unknown.
|
|
786
722
|
* @nullable
|
|
787
723
|
*/
|
|
788
724
|
readonly closed_at?: string | null;
|
|
@@ -799,7 +735,7 @@ export interface Currency {
|
|
|
799
735
|
*/
|
|
800
736
|
code: string;
|
|
801
737
|
/**
|
|
802
|
-
* Decimal places of the
|
|
738
|
+
* Decimal places of the ISO 4217 minor unit.
|
|
803
739
|
* @minimum 0
|
|
804
740
|
* @maximum 4
|
|
805
741
|
*/
|
|
@@ -826,7 +762,7 @@ export interface BillingAccountCreate {
|
|
|
826
762
|
}
|
|
827
763
|
export interface BillingAccountUpdate {
|
|
828
764
|
/**
|
|
829
|
-
* The active contact used for
|
|
765
|
+
* The active contact used for invoices, of this account; null clears it.
|
|
830
766
|
* @nullable
|
|
831
767
|
*/
|
|
832
768
|
invoice_contact_id?: string | null;
|
|
@@ -838,7 +774,7 @@ export interface BillingAccountList {
|
|
|
838
774
|
pagination: OffsetPagination;
|
|
839
775
|
}
|
|
840
776
|
/**
|
|
841
|
-
* A plan
|
|
777
|
+
* A plan referenced by an applicability; active is false once it is archived, and the reference still applies.
|
|
842
778
|
*/
|
|
843
779
|
export interface ApplicablePlan {
|
|
844
780
|
id: string;
|
|
@@ -846,24 +782,20 @@ export interface ApplicablePlan {
|
|
|
846
782
|
active: boolean;
|
|
847
783
|
}
|
|
848
784
|
/**
|
|
849
|
-
* A catalog object inlined for display.
|
|
785
|
+
* A catalog object, inlined for display.
|
|
850
786
|
*/
|
|
851
787
|
export interface ObjectIdentity {
|
|
852
788
|
lookup_key?: string;
|
|
853
789
|
id: string;
|
|
854
790
|
name: string;
|
|
855
791
|
}
|
|
856
|
-
|
|
857
|
-
|
|
792
|
+
/**
|
|
793
|
+
* `per_unit` multiplies a unit amount; `tiered` walks a ladder.
|
|
794
|
+
*/
|
|
795
|
+
export type BillingScheme = (typeof BillingScheme)[keyof typeof BillingScheme];
|
|
796
|
+
export declare const BillingScheme: {
|
|
858
797
|
readonly per_unit: "per_unit";
|
|
859
798
|
readonly tiered: "tiered";
|
|
860
|
-
readonly rated: "rated";
|
|
861
|
-
};
|
|
862
|
-
export type PriceOptionType = (typeof PriceOptionType)[keyof typeof PriceOptionType];
|
|
863
|
-
export declare const PriceOptionType: {
|
|
864
|
-
readonly postpaid: "postpaid";
|
|
865
|
-
readonly prepaid: "prepaid";
|
|
866
|
-
readonly one_time: "one_time";
|
|
867
799
|
};
|
|
868
800
|
export type PriceOptionInterval = (typeof PriceOptionInterval)[keyof typeof PriceOptionInterval];
|
|
869
801
|
export declare const PriceOptionInterval: {
|
|
@@ -873,16 +805,18 @@ export declare const PriceOptionInterval: {
|
|
|
873
805
|
readonly year: "year";
|
|
874
806
|
};
|
|
875
807
|
/**
|
|
876
|
-
* A price's display terms, including archived prices referenced by an applicability
|
|
808
|
+
* A price's display terms, including archived prices referenced by an applicability.
|
|
877
809
|
*/
|
|
878
810
|
export interface PriceOption {
|
|
879
811
|
product: Product;
|
|
880
812
|
plan: ObjectIdentity;
|
|
881
|
-
|
|
813
|
+
/** Absent when the price delegates to a rate card. */
|
|
814
|
+
billing_scheme?: BillingScheme;
|
|
882
815
|
unit_quantity: string;
|
|
883
816
|
id: string;
|
|
884
817
|
currency: string;
|
|
885
|
-
type:
|
|
818
|
+
type: PriceType;
|
|
819
|
+
usage_type: UsageType;
|
|
886
820
|
interval: PriceOptionInterval;
|
|
887
821
|
/** How many periods one purchase covers. */
|
|
888
822
|
interval_count?: number;
|
|
@@ -891,11 +825,7 @@ export interface PriceOption {
|
|
|
891
825
|
active: boolean;
|
|
892
826
|
}
|
|
893
827
|
/**
|
|
894
|
-
*
|
|
895
|
-
* zero-charge purchases. It does not mean the account's first purchase; use
|
|
896
|
-
* `first_purchase_only` for that restriction. `renew` covers renewals. `modify` covers
|
|
897
|
-
* configuration or billing-term changes, including changes that increase or decrease
|
|
898
|
-
* the amount due and changes with no additional charge or refund.
|
|
828
|
+
* The purchase operation covered. `new`: every new purchase, including zero-charge ones; it does not mean the account's first purchase, which `first_purchase_only` restricts. `renew`: renewals. `modify`: configuration or billing-term changes, whether they charge, refund or neither.
|
|
899
829
|
*/
|
|
900
830
|
export type PurchaseOperation = (typeof PurchaseOperation)[keyof typeof PurchaseOperation];
|
|
901
831
|
export declare const PurchaseOperation: {
|
|
@@ -904,20 +834,18 @@ export declare const PurchaseOperation: {
|
|
|
904
834
|
readonly modify: "modify";
|
|
905
835
|
};
|
|
906
836
|
/**
|
|
907
|
-
*
|
|
908
|
-
* given, subject to the charge type, operation and term conditions. Entries always include their
|
|
909
|
-
* display fields; archived plans and prices stay listed with active set to false.
|
|
837
|
+
* Covers anything not excluded that matches an inclusion, or anything not excluded when no inclusion is given, subject to the price type, usage type, operation and term conditions. Archived plans and prices stay listed with active false.
|
|
910
838
|
*/
|
|
911
839
|
export interface Applicability {
|
|
912
840
|
products?: Product[];
|
|
913
841
|
plans?: ApplicablePlan[];
|
|
914
842
|
prices?: PriceOption[];
|
|
915
|
-
|
|
843
|
+
/** The price types covered; empty covers both. */
|
|
844
|
+
price_types?: PriceType[];
|
|
845
|
+
/** The usage types covered; empty covers both. */
|
|
846
|
+
usage_types?: UsageType[];
|
|
916
847
|
operations?: PurchaseOperation[];
|
|
917
|
-
/**
|
|
918
|
-
* The shortest term a purchase may have, in months. A purchase with no term, such as
|
|
919
|
-
* metered usage, never qualifies while this is set.
|
|
920
|
-
*/
|
|
848
|
+
/** The shortest term a purchase may have, in months. Purchases without a term, such as metered usage, do not qualify while this is set. */
|
|
921
849
|
min_term_months?: number;
|
|
922
850
|
/** The longest term a purchase may have, in months. */
|
|
923
851
|
max_term_months?: number;
|
|
@@ -926,56 +854,42 @@ export interface Applicability {
|
|
|
926
854
|
excluded_prices?: PriceOption[];
|
|
927
855
|
}
|
|
928
856
|
export interface CreditGroup {
|
|
929
|
-
/** What the credit in this group may pay for
|
|
857
|
+
/** What the credit in this group may pay for; no restrictions means anything on the account. */
|
|
930
858
|
applies_to: Applicability;
|
|
931
859
|
/** Restricted to your first purchase of anything it applies to. */
|
|
932
860
|
first_purchase_only?: boolean;
|
|
933
861
|
amount: Money;
|
|
934
862
|
}
|
|
935
863
|
/**
|
|
936
|
-
*
|
|
864
|
+
* Balance, credits and unpaid charges, each reported separately.
|
|
937
865
|
*/
|
|
938
866
|
export interface AccountBalance {
|
|
939
867
|
/** Balance minus pending balance returns and the part of unbilled_amount and due that estimated_credit_applied does not cover. Negative only when the balance and applicable credit fall short of what the account owes. */
|
|
940
868
|
available_credit: Money;
|
|
941
|
-
/** Credit expected to pay unbilled_amount and due
|
|
869
|
+
/** Credit expected to pay unbilled_amount and due, matching each charge to the grants whose scope, validity and conditions it meets, in the order credit is applied at payment. Nothing is deducted until an invoice is paid, so credits still includes this amount. */
|
|
942
870
|
estimated_credit_applied: Money;
|
|
943
|
-
/** Current estimate of
|
|
871
|
+
/** Current estimate of priced usage that has not been invoiced. Final pricing and tax are fixed at issuance. */
|
|
944
872
|
unbilled_amount: Money;
|
|
945
873
|
billing_account_id: number;
|
|
946
874
|
currency: string;
|
|
947
|
-
/**
|
|
948
|
-
* Prepaid funds in the account currency, excluding credits. May be negative after a payment
|
|
949
|
-
* dispute. Outstanding charges are reported separately in due; this value is not a withdrawal quote.
|
|
950
|
-
*/
|
|
875
|
+
/** Topped-up funds in the account's currency, excluding credits. May be negative after a payment dispute. Amounts owed are reported in due; this is not a withdrawable amount. */
|
|
951
876
|
balance: Money;
|
|
952
|
-
/**
|
|
953
|
-
* The recorded remaining credit, including restricted grants. It is not withdrawable
|
|
954
|
-
* and is not part of balance. credit_groups describes currently valid credit by permitted use; a positive
|
|
955
|
-
* credits balance does not imply that due is zero.
|
|
956
|
-
*/
|
|
877
|
+
/** Remaining credit, including restricted grants; not withdrawable and not part of balance. credit_groups shows currently valid credit by permitted use; positive credits do not mean due is zero. */
|
|
957
878
|
credits: Money;
|
|
958
|
-
/** Currently valid credit
|
|
879
|
+
/** Currently valid credit restricted to certain products, operations or conditions; part of credits, not of balance. */
|
|
959
880
|
restricted_credits: Money;
|
|
960
|
-
/**
|
|
961
|
-
* Currently valid, unspent credit grouped by permitted use. Restrictions and
|
|
962
|
-
* validity dates determine which charges a group can cover, so these groups are not a general
|
|
963
|
-
* spendable balance and may differ from the recorded credits total.
|
|
964
|
-
*/
|
|
881
|
+
/** Currently valid unspent credit grouped by permitted use. Each group covers only the charges its restrictions and validity allow, and the groups may differ from the recorded credits total. */
|
|
965
882
|
credit_groups: CreditGroup[];
|
|
966
|
-
/** Amount still payable on issued invoices. The invoice of an order not yet accepted is
|
|
883
|
+
/** Amount still payable on issued invoices. The invoice of an order not yet accepted is excluded, here and from available_credit. Usage not yet invoiced is reported separately. */
|
|
967
884
|
due: Money;
|
|
968
885
|
pending_returns_amount: Money;
|
|
969
886
|
}
|
|
970
887
|
/**
|
|
971
|
-
* A project's assignment to a billing account
|
|
888
|
+
* A project's assignment to a billing account from effective_from until effective_to; an open assignment has no end.
|
|
972
889
|
*/
|
|
973
890
|
export interface ProjectAssignment {
|
|
974
891
|
project_id: string;
|
|
975
|
-
/**
|
|
976
|
-
* The project and its current name, for display. Absent when the project no longer exists or its
|
|
977
|
-
* details cannot be read at the moment; `project_id` still identifies it.
|
|
978
|
-
*/
|
|
892
|
+
/** The project and its current name. Absent when the project cannot be read; `project_id` still identifies it. */
|
|
979
893
|
project?: NamedIdentity | null;
|
|
980
894
|
billing_account_id: number;
|
|
981
895
|
account_name?: string;
|
|
@@ -992,16 +906,7 @@ export interface SetProjectAssignmentRequest {
|
|
|
992
906
|
billing_account_id: number;
|
|
993
907
|
}
|
|
994
908
|
/**
|
|
995
|
-
* `pending` until the payment gateway reaches a result
|
|
996
|
-
*
|
|
997
|
-
* `failed` means the gateway declined the payment. A declined attempt ends the top-up at once
|
|
998
|
-
* and the payment is withdrawn at the gateway; to pay another way, create a new top-up.
|
|
999
|
-
* `canceled` means the attempt was withdrawn without collecting money; `cancellation_reason`
|
|
1000
|
-
* says why. Unknown gateway outcomes remain `pending`, and a browser redirect is not proof of
|
|
1001
|
-
* payment.
|
|
1002
|
-
*
|
|
1003
|
-
* `failed` and `canceled` are final. If the gateway nevertheless collects payment for such an
|
|
1004
|
-
* attempt, the amount is credited as a separate `succeeded` top-up.
|
|
909
|
+
* `pending` until the payment gateway reaches a result; the balance increases on `succeeded`. `failed`: the gateway declined the payment, which is withdrawn at the gateway; create a new top-up to pay another way. `canceled`: withdrawn without collecting money, for the reason in `cancellation_reason`. Unknown gateway outcomes stay `pending`; a browser redirect is not proof of payment. `failed` and `canceled` are final; a payment the gateway collects afterwards is credited as a separate `succeeded` top-up.
|
|
1005
910
|
*/
|
|
1006
911
|
export type TopUpStatus = (typeof TopUpStatus)[keyof typeof TopUpStatus];
|
|
1007
912
|
export declare const TopUpStatus: {
|
|
@@ -1016,8 +921,7 @@ export interface AccountIdentity {
|
|
|
1016
921
|
currency: string;
|
|
1017
922
|
}
|
|
1018
923
|
/**
|
|
1019
|
-
* Why a gateway payment was withdrawn
|
|
1020
|
-
* allowed for payment. `requested_by_customer` means the customer canceled it.
|
|
924
|
+
* Why a gateway payment was withdrawn: `abandoned` when the customer did not complete it in time, `requested_by_customer` when the customer canceled it.
|
|
1021
925
|
*/
|
|
1022
926
|
export type PaymentCancellationReason = (typeof PaymentCancellationReason)[keyof typeof PaymentCancellationReason];
|
|
1023
927
|
export declare const PaymentCancellationReason: {
|
|
@@ -1031,83 +935,55 @@ export declare const PaymentActionType: {
|
|
|
1031
935
|
readonly sdk: "sdk";
|
|
1032
936
|
};
|
|
1033
937
|
/**
|
|
1034
|
-
* The customer's next
|
|
938
|
+
* The customer's next step; the payment outcome is reported separately.
|
|
1035
939
|
*/
|
|
1036
940
|
export interface PaymentAction {
|
|
1037
941
|
type: PaymentActionType;
|
|
1038
|
-
/**
|
|
942
|
+
/** The browser adapter for the action, for example stripe. */
|
|
1039
943
|
provider?: string;
|
|
1040
944
|
url?: string;
|
|
1041
|
-
/** QR content to render
|
|
945
|
+
/** QR content to render, not an image URL. */
|
|
1042
946
|
qr_code?: string;
|
|
1043
|
-
/** Short-lived client credential for this payment
|
|
947
|
+
/** Short-lived client credential for confirming this payment in the browser. */
|
|
1044
948
|
client_secret?: string;
|
|
1045
949
|
public_key?: string;
|
|
1046
950
|
}
|
|
1047
951
|
/**
|
|
1048
|
-
* A top-up attempt and its outcome. A successful top-up adds
|
|
952
|
+
* A top-up attempt and its outcome. A successful top-up adds to the balance; it is not a credit grant and has no invoice.
|
|
1049
953
|
*/
|
|
1050
954
|
export interface TopUp {
|
|
1051
955
|
id: string;
|
|
1052
956
|
billing_account_id: number;
|
|
1053
957
|
account: AccountIdentity;
|
|
1054
|
-
/** What is credited to the account, in
|
|
958
|
+
/** What is credited to the account, in its currency. */
|
|
1055
959
|
amount: Money;
|
|
1056
960
|
currency: string;
|
|
1057
|
-
/**
|
|
1058
|
-
* The part of this top-up still held in the balance. Pending refunds can temporarily
|
|
1059
|
-
* reserve part of it; it is not a promise that the whole amount is immediately withdrawable.
|
|
1060
|
-
*/
|
|
961
|
+
/** The part of this top-up still in the balance. Pending refunds may hold part of it, so not all of it is necessarily withdrawable. */
|
|
1061
962
|
remaining_amount?: Money;
|
|
1062
|
-
/**
|
|
1063
|
-
* `pending` until the payment gateway reaches a result. The balance increases on `succeeded`.
|
|
1064
|
-
*
|
|
1065
|
-
* `failed` means the gateway declined the payment. A declined attempt ends the top-up at once
|
|
1066
|
-
* and the payment is withdrawn at the gateway; to pay another way, create a new top-up.
|
|
1067
|
-
* `canceled` means the attempt was withdrawn without collecting money; `cancellation_reason`
|
|
1068
|
-
* says why. Unknown gateway outcomes remain `pending`, and a browser redirect is not proof of
|
|
1069
|
-
* payment.
|
|
1070
|
-
*
|
|
1071
|
-
* `failed` and `canceled` are final. If the gateway nevertheless collects payment for such an
|
|
1072
|
-
* attempt, the amount is credited as a separate `succeeded` top-up.
|
|
1073
|
-
*/
|
|
963
|
+
/** `pending` until the payment gateway reaches a result; the balance increases on `succeeded`. `failed`: the gateway declined the payment, which is withdrawn at the gateway; create a new top-up to pay another way. `canceled`: withdrawn without collecting money, for the reason in `cancellation_reason`. Unknown gateway outcomes stay `pending`; a browser redirect is not proof of payment. `failed` and `canceled` are final; a payment the gateway collects afterwards is credited as a separate `succeeded` top-up. */
|
|
1074
964
|
status: TopUpStatus;
|
|
1075
965
|
cancellation_reason?: PaymentCancellationReason;
|
|
1076
966
|
/** Which payment gateway collected it. */
|
|
1077
967
|
payment_gateway?: string;
|
|
1078
968
|
/** The selected payment method, such as card, wechat_pay or alipay. */
|
|
1079
969
|
method_type?: string;
|
|
1080
|
-
/**
|
|
1081
|
-
* The currency the customer was actually charged in, when the checkout page collected a
|
|
1082
|
-
* local one. Absent when it was the same as the account's.
|
|
1083
|
-
*/
|
|
970
|
+
/** The currency the customer was charged in when the checkout collected a local currency; absent when it is the account's. */
|
|
1084
971
|
presentment_currency?: string;
|
|
1085
|
-
/**
|
|
1086
|
-
* What was charged, in `presentment_currency`. It will not equal `amount`, and it is
|
|
1087
|
-
* the figure that appears on the customer's card or wallet statement.
|
|
1088
|
-
*/
|
|
972
|
+
/** The amount charged in `presentment_currency`, as shown on the customer's statement. */
|
|
1089
973
|
presentment_amount?: Money;
|
|
1090
|
-
/**
|
|
1091
|
-
* Why the gateway declined it. Present with `failed`. The value is the gateway's own code,
|
|
1092
|
-
* passed on unchanged: the card issuer's decline code when there is one (Stripe's decline_code,
|
|
1093
|
-
* such as insufficient_funds or lost_card), otherwise the gateway's error code (Stripe's code,
|
|
1094
|
-
* such as card_declined, expired_card or payment_intent_authentication_failure). Clients map it
|
|
1095
|
-
* to their own wording and treat an unknown value as a generic decline.
|
|
1096
|
-
*/
|
|
974
|
+
/** Why the gateway declined it; present with `failed`. The gateway's code unchanged: the issuer's decline code when there is one (Stripe decline_code, such as insufficient_funds), otherwise the gateway's error code (Stripe code, such as card_declined). Treat an unknown value as a generic decline. */
|
|
1097
975
|
failure_reason?: string;
|
|
1098
976
|
action?: PaymentAction;
|
|
1099
977
|
created_at: string;
|
|
1100
978
|
/**
|
|
1101
|
-
* When the funds arrived
|
|
1102
|
-
* reconciling against a statement uses this rather than the moment it was started.
|
|
1103
|
-
* Absent until the payment completes.
|
|
979
|
+
* When the funds arrived, possibly days after `created_at`. Absent until the payment completes.
|
|
1104
980
|
* @nullable
|
|
1105
981
|
*/
|
|
1106
982
|
settled_at?: string | null;
|
|
1107
983
|
}
|
|
1108
984
|
export interface TopUpCreate {
|
|
1109
985
|
/**
|
|
1110
|
-
* The gateway
|
|
986
|
+
* The gateway selected from the available payment options.
|
|
1111
987
|
* @minLength 1
|
|
1112
988
|
* @maxLength 32
|
|
1113
989
|
*/
|
|
@@ -1118,21 +994,12 @@ export interface TopUpCreate {
|
|
|
1118
994
|
* @maxLength 64
|
|
1119
995
|
*/
|
|
1120
996
|
method_type: string;
|
|
1121
|
-
/** The
|
|
997
|
+
/** The top-up ID, chosen by the caller. Read it after an uncertain response. */
|
|
1122
998
|
id: string;
|
|
1123
999
|
billing_account_id: number;
|
|
1124
|
-
/**
|
|
1125
|
-
* In the account's currency, and no finer than that currency's smallest unit:
|
|
1126
|
-
* two decimals for most, none for the yen. A finer amount is refused here rather
|
|
1127
|
-
* than at the checkout page, where the customer would see the gateway's own wording
|
|
1128
|
-
* instead of an explanation.
|
|
1129
|
-
*
|
|
1130
|
-
* There is a minimum, which differs by currency. Below it the gateway's fee
|
|
1131
|
-
* exceeds the top-up itself, so such a payment costs more to accept than it brings.
|
|
1132
|
-
* The minimum in force is returned with the rejection.
|
|
1133
|
-
*/
|
|
1000
|
+
/** In the account's currency, no finer than its smallest unit (two decimals for most currencies, none for JPY). An amount below the currency's minimum top-up is refused, and the minimum is returned with the error. */
|
|
1134
1001
|
amount: Money & string;
|
|
1135
|
-
/** Charge a saved method instead of opening a checkout page. */
|
|
1002
|
+
/** Charge a saved payment method instead of opening a checkout page. */
|
|
1136
1003
|
payment_method_id?: string;
|
|
1137
1004
|
/** Where to send the customer after checkout. */
|
|
1138
1005
|
return_url?: string;
|
|
@@ -1144,14 +1011,11 @@ export interface TopUpList {
|
|
|
1144
1011
|
export interface PaymentOptionMethod {
|
|
1145
1012
|
/** The value to send as `method_type`, such as card, wechat_pay or alipay. */
|
|
1146
1013
|
method_type: string;
|
|
1147
|
-
/**
|
|
1148
|
-
* Whether a method of this type can be saved with create-payment-method-setup and charged later
|
|
1149
|
-
* without the customer present. Methods that are not reusable are paid anew each time.
|
|
1150
|
-
*/
|
|
1014
|
+
/** Whether this method type can be saved with create-payment-method-setup and charged later without the customer. */
|
|
1151
1015
|
reusable: boolean;
|
|
1152
1016
|
}
|
|
1153
1017
|
/**
|
|
1154
|
-
* A
|
|
1018
|
+
* A gateway accepting the account's currency, with its payment methods.
|
|
1155
1019
|
*/
|
|
1156
1020
|
export interface PaymentOption {
|
|
1157
1021
|
/** The value to send as `payment_gateway`. */
|
|
@@ -1195,15 +1059,10 @@ export interface PaymentMethodSetup {
|
|
|
1195
1059
|
billing_account_id: number;
|
|
1196
1060
|
}
|
|
1197
1061
|
/**
|
|
1198
|
-
* What the payment gateway's browser library needs
|
|
1199
|
-
* no address to redirect to: the form is rendered in the page, and the card goes straight
|
|
1200
|
-
* from the browser to the gateway.
|
|
1062
|
+
* What the payment gateway's browser library needs to collect a card in the page; the card goes from the browser straight to the gateway.
|
|
1201
1063
|
*/
|
|
1202
1064
|
export interface PaymentMethodSetupResult {
|
|
1203
|
-
/**
|
|
1204
|
-
* The gateway's identifier for this attempt. Use it to tell a reloaded page apart
|
|
1205
|
-
* from a second attempt.
|
|
1206
|
-
*/
|
|
1065
|
+
/** The gateway's identifier for this attempt. */
|
|
1207
1066
|
setup_id: string;
|
|
1208
1067
|
payment_gateway: string;
|
|
1209
1068
|
action: PaymentAction;
|
|
@@ -1219,7 +1078,7 @@ export interface PaymentMethodSetupResult {
|
|
|
1219
1078
|
*/
|
|
1220
1079
|
export interface PayInvoiceRequest {
|
|
1221
1080
|
/**
|
|
1222
|
-
* Required to collect an online remainder. An existing attempt keeps its
|
|
1081
|
+
* Required to collect an online remainder. An existing attempt keeps its gateway.
|
|
1223
1082
|
* @minLength 1
|
|
1224
1083
|
* @maxLength 32
|
|
1225
1084
|
*/
|
|
@@ -1230,51 +1089,35 @@ export interface PayInvoiceRequest {
|
|
|
1230
1089
|
* @maxLength 64
|
|
1231
1090
|
*/
|
|
1232
1091
|
method_type?: string;
|
|
1233
|
-
/**
|
|
1092
|
+
/** A saved card of this billing account at the selected gateway. Omit to pay interactively. */
|
|
1234
1093
|
payment_method_id?: string;
|
|
1235
|
-
/** Whether to apply the
|
|
1094
|
+
/** Whether to apply the balance; credit grants are controlled by use_credits. */
|
|
1236
1095
|
use_balance?: boolean;
|
|
1237
|
-
/** Apply eligible, unexpired credit grants before
|
|
1096
|
+
/** Apply eligible, unexpired credit grants before the balance. Grants are never converted into balance. */
|
|
1238
1097
|
use_credits?: boolean;
|
|
1239
1098
|
return_url?: string;
|
|
1240
1099
|
/**
|
|
1241
|
-
* The code to apply while the order's terms are not
|
|
1242
|
-
* account discount, or to keep the discount already recorded.
|
|
1100
|
+
* The code to apply while the order's terms are not fixed. Omit to apply the best applicable account discount, or to keep the discount already recorded.
|
|
1243
1101
|
* @minLength 1
|
|
1244
1102
|
* @maxLength 64
|
|
1245
1103
|
*/
|
|
1246
1104
|
promotion_code?: string;
|
|
1247
|
-
/**
|
|
1248
|
-
* The invoice total to expect, after discounts and tax and before credit grants or balance, as the
|
|
1249
|
-
* payment preview or an order quote gave it. A different total fails with BILLING_AMOUNT_CHANGED
|
|
1250
|
-
* and nothing is charged. Omit to skip the comparison; an explicit zero is compared.
|
|
1251
|
-
*/
|
|
1105
|
+
/** The invoice total to expect, after discounts and tax and before credit grants or balance, as the payment preview or an order quote gave it. A different total fails with `BILLING_AMOUNT_CHANGED` and nothing is charged. Omit to skip the check; zero is checked. */
|
|
1252
1106
|
expected_amount?: Money & string;
|
|
1253
1107
|
}
|
|
1254
1108
|
/**
|
|
1255
|
-
* Name at least one invoice or order.
|
|
1256
|
-
* its currency; anything else is refused rather than partly paid.
|
|
1109
|
+
* Name at least one invoice or order. All must belong to one account in its currency.
|
|
1257
1110
|
*/
|
|
1258
1111
|
export interface PayTogetherRequest {
|
|
1259
1112
|
/** @maxItems 100 */
|
|
1260
1113
|
invoice_ids?: string[];
|
|
1261
1114
|
/** @maxItems 100 */
|
|
1262
1115
|
order_ids?: string[];
|
|
1263
|
-
/**
|
|
1264
|
-
* The amount due to expect across all of them, before credit grants or balance, as preview-pay-together
|
|
1265
|
-
* gave it. A different amount fails with BILLING_AMOUNT_CHANGED and nothing is charged. Omit to skip
|
|
1266
|
-
* the comparison.
|
|
1267
|
-
*/
|
|
1116
|
+
/** The amount due across all invoices, before credit grants or balance, as preview-pay-together gave it. A different amount fails with `BILLING_AMOUNT_CHANGED` and nothing is charged. Omit to skip the check. */
|
|
1268
1117
|
expected_amount?: Money & string;
|
|
1269
1118
|
}
|
|
1270
1119
|
/**
|
|
1271
|
-
*
|
|
1272
|
-
*
|
|
1273
|
-
* succeeded means payment is complete. processing means confirmation is pending; poll the invoice or
|
|
1274
|
-
* order rather than submitting another payment. requires_action means the customer must complete the
|
|
1275
|
-
* supplied action. failed means the attempt did not succeed and failure_reason explains the outcome; a
|
|
1276
|
-
* declined gateway payment is withdrawn at the gateway, and paying again starts a new payment with the
|
|
1277
|
-
* same or another method.
|
|
1120
|
+
* `succeeded`: paid. `processing`: confirmation is pending; poll the invoice or order instead of paying again. `requires_action`: the customer must complete the returned action. `failed`: the attempt did not succeed, for the reason in failure_reason; a declined gateway payment is withdrawn, and paying again starts a new payment.
|
|
1278
1121
|
*/
|
|
1279
1122
|
export type PaymentStatus = (typeof PaymentStatus)[keyof typeof PaymentStatus];
|
|
1280
1123
|
export declare const PaymentStatus: {
|
|
@@ -1300,7 +1143,7 @@ export interface PaymentPreviewInvoice {
|
|
|
1300
1143
|
balance_applied: Money;
|
|
1301
1144
|
}
|
|
1302
1145
|
/**
|
|
1303
|
-
* What paying would take,
|
|
1146
|
+
* What paying would take, calculated as paying does. Nothing is charged or reserved.
|
|
1304
1147
|
*/
|
|
1305
1148
|
export interface PaymentPreview {
|
|
1306
1149
|
funds?: Funds;
|
|
@@ -1309,23 +1152,19 @@ export interface PaymentPreview {
|
|
|
1309
1152
|
amount_due: Money;
|
|
1310
1153
|
/** What credit grants would pay. Grants restricted to other purchases pay nothing here. */
|
|
1311
1154
|
credit_applied: Money;
|
|
1312
|
-
/** The credit grants that would pay, in the order
|
|
1155
|
+
/** The credit grants that would pay, in the order used. */
|
|
1313
1156
|
credit_grants: AppliedCredit[];
|
|
1314
1157
|
/** What the balance would pay. */
|
|
1315
1158
|
balance_applied: Money;
|
|
1316
|
-
/** What would remain to
|
|
1159
|
+
/** What would remain to pay online. Paying without a gateway is refused with `BILLING_INSUFFICIENT_FUNDS` while this is above zero. */
|
|
1317
1160
|
gateway_amount: Money;
|
|
1318
1161
|
/** The available balance after paying. */
|
|
1319
1162
|
balance_after: Money;
|
|
1320
|
-
/** Paying together only
|
|
1163
|
+
/** Paying together only: each invoice, in payment order. */
|
|
1321
1164
|
invoices?: PaymentPreviewInvoice[];
|
|
1322
1165
|
}
|
|
1323
1166
|
/**
|
|
1324
|
-
* Present on refunds
|
|
1325
|
-
*
|
|
1326
|
-
* - `balance`: back to the account balance.
|
|
1327
|
-
* - `credit`: back to the credit grant that paid, which keeps its original expiry.
|
|
1328
|
-
* - `gateway`: back to the payment method it was paid with.
|
|
1167
|
+
* Present on refunds: where this part goes. `balance`: the account balance. `credit`: the credit grant that paid, keeping its original expiry. `gateway`: the payment method it was paid with.
|
|
1329
1168
|
*/
|
|
1330
1169
|
export type TransactionRefundDestination = (typeof TransactionRefundDestination)[keyof typeof TransactionRefundDestination];
|
|
1331
1170
|
export declare const TransactionRefundDestination: {
|
|
@@ -1334,9 +1173,7 @@ export declare const TransactionRefundDestination: {
|
|
|
1334
1173
|
readonly gateway: "gateway";
|
|
1335
1174
|
};
|
|
1336
1175
|
/**
|
|
1337
|
-
* `failed
|
|
1338
|
-
* it. `canceled` means a gateway payment was withdrawn without collecting money. After either,
|
|
1339
|
-
* an invoice the payment was meant to pay remains open for another payment.
|
|
1176
|
+
* `failed`: the operation did not succeed; for a gateway payment, the gateway declined it. `canceled`: a gateway payment was withdrawn without collecting money. Either way, the invoice it was for stays open.
|
|
1340
1177
|
*/
|
|
1341
1178
|
export type TransactionStatus = (typeof TransactionStatus)[keyof typeof TransactionStatus];
|
|
1342
1179
|
export declare const TransactionStatus: {
|
|
@@ -1357,7 +1194,7 @@ export declare const TransactionType: {
|
|
|
1357
1194
|
readonly fee: "fee";
|
|
1358
1195
|
};
|
|
1359
1196
|
/**
|
|
1360
|
-
* A funds
|
|
1197
|
+
* A funds movement with one source. Refunds name the original transaction. Unknown gateway results stay pending.
|
|
1361
1198
|
*/
|
|
1362
1199
|
export interface Transaction {
|
|
1363
1200
|
invoice_id?: string;
|
|
@@ -1366,47 +1203,22 @@ export interface Transaction {
|
|
|
1366
1203
|
credit_grant_id?: string;
|
|
1367
1204
|
credit_grant?: ObjectIdentity;
|
|
1368
1205
|
refund_id?: string;
|
|
1369
|
-
/**
|
|
1370
|
-
* Present on refunds. Where this part of the refund goes.
|
|
1371
|
-
*
|
|
1372
|
-
* - `balance`: back to the account balance.
|
|
1373
|
-
* - `credit`: back to the credit grant that paid, which keeps its original expiry.
|
|
1374
|
-
* - `gateway`: back to the payment method it was paid with.
|
|
1375
|
-
*/
|
|
1206
|
+
/** Present on refunds: where this part goes. `balance`: the account balance. `credit`: the credit grant that paid, keeping its original expiry. `gateway`: the payment method it was paid with. */
|
|
1376
1207
|
refund_destination?: TransactionRefundDestination;
|
|
1377
|
-
/**
|
|
1378
|
-
* `failed` means the operation did not succeed; for a gateway payment, that the gateway declined
|
|
1379
|
-
* it. `canceled` means a gateway payment was withdrawn without collecting money. After either,
|
|
1380
|
-
* an invoice the payment was meant to pay remains open for another payment.
|
|
1381
|
-
*/
|
|
1208
|
+
/** `failed`: the operation did not succeed; for a gateway payment, the gateway declined it. `canceled`: a gateway payment was withdrawn without collecting money. Either way, the invoice it was for stays open. */
|
|
1382
1209
|
status?: TransactionStatus;
|
|
1383
1210
|
cancellation_reason?: PaymentCancellationReason;
|
|
1384
1211
|
payment_gateway?: string;
|
|
1385
1212
|
method_type?: string;
|
|
1386
|
-
/**
|
|
1387
|
-
* Why it failed. Present with `failed`. For a declined gateway payment the value is the
|
|
1388
|
-
* gateway's own code, passed on unchanged: the card issuer's decline code when there is one
|
|
1389
|
-
* (Stripe's decline_code, such as insufficient_funds or lost_card), otherwise the gateway's
|
|
1390
|
-
* error code (Stripe's code, such as card_declined, expired_card or
|
|
1391
|
-
* payment_intent_authentication_failure). Clients map it to their own wording and treat an
|
|
1392
|
-
* unknown value as a generic decline.
|
|
1393
|
-
*/
|
|
1213
|
+
/** Why it failed; present with `failed`. For a declined gateway payment, the gateway's code unchanged: the issuer's decline code when there is one (Stripe decline_code, such as insufficient_funds), otherwise the gateway's error code (Stripe code, such as card_declined). Treat an unknown value as a generic decline. */
|
|
1394
1214
|
failure_reason?: string;
|
|
1395
1215
|
settled_at?: string;
|
|
1396
1216
|
id: string;
|
|
1397
1217
|
billing_account_id?: number;
|
|
1398
1218
|
type: TransactionType;
|
|
1399
|
-
/**
|
|
1400
|
-
* Signed by type: positive for `topup` and `payment`, negative for `refund`.
|
|
1401
|
-
* An `adjustment` is positive when it adds to the balance and negative when it takes from
|
|
1402
|
-
* it. For the other types the sign does not tell the effect on the balance: a payment from
|
|
1403
|
-
* the balance lowers it, while a payment by gateway or by credit leaves it unchanged.
|
|
1404
|
-
*/
|
|
1219
|
+
/** Signed by type: positive for `topup` and `payment`, negative for `refund`. An `adjustment` is positive when it adds to the balance and negative when it takes from it. For other types the sign does not show the effect on the balance: a payment from balance lowers it, a payment by gateway or credit does not. */
|
|
1405
1220
|
amount: Money;
|
|
1406
|
-
/**
|
|
1407
|
-
* How much of this transaction is still available in the balance. Only top-ups, positive
|
|
1408
|
-
* adjustments and gateway payments later returned to the balance can be non-zero.
|
|
1409
|
-
*/
|
|
1221
|
+
/** How much of this transaction is still in the balance. Only top-ups, positive adjustments and gateway payments returned to the balance can be non-zero. */
|
|
1410
1222
|
remaining_amount: Money;
|
|
1411
1223
|
currency: string;
|
|
1412
1224
|
reason?: string;
|
|
@@ -1414,49 +1226,31 @@ export interface Transaction {
|
|
|
1414
1226
|
}
|
|
1415
1227
|
export interface PaymentResult {
|
|
1416
1228
|
transactions: Transaction[];
|
|
1417
|
-
/** The gateway transaction, when one is involved.
|
|
1229
|
+
/** The gateway transaction, when one is involved. */
|
|
1418
1230
|
transaction_id?: string;
|
|
1419
1231
|
status: PaymentStatus;
|
|
1420
1232
|
amount_paid: Money;
|
|
1421
|
-
/**
|
|
1422
|
-
* What is still outstanding. Zero once the payment succeeds. Unchanged while
|
|
1423
|
-
* `processing`: nothing is collected until the gateway confirms it.
|
|
1424
|
-
*/
|
|
1233
|
+
/** What is still outstanding: zero once the payment succeeds, unchanged while `processing`. */
|
|
1425
1234
|
amount_due: Money;
|
|
1426
1235
|
currency: string;
|
|
1427
1236
|
credit_applied?: Money;
|
|
1428
1237
|
gateway_amount?: Money;
|
|
1429
1238
|
payment_gateway?: string;
|
|
1430
1239
|
method_type?: string;
|
|
1431
|
-
/**
|
|
1432
|
-
* The amount already paid from the account's balance toward this invoice. Retrying an online remainder
|
|
1433
|
-
* does not debit it again. A canceled purchase returns funds through its refund process.
|
|
1434
|
-
*/
|
|
1240
|
+
/** The amount already paid from balance toward this invoice; retrying the online remainder does not debit it again. */
|
|
1435
1241
|
balance_applied?: Money;
|
|
1436
1242
|
action?: PaymentAction;
|
|
1437
|
-
/**
|
|
1438
|
-
* Whether paying again is worth attempting. False for a refusal that will keep
|
|
1439
|
-
* happening — a closed account, an amount over a limit — so that a client does not
|
|
1440
|
-
* retry in a loop.
|
|
1441
|
-
*/
|
|
1243
|
+
/** Whether paying again can succeed. False for a refusal that will repeat, such as a closed account or an amount over a limit. */
|
|
1442
1244
|
retriable?: boolean;
|
|
1443
1245
|
/** @nullable */
|
|
1444
1246
|
invoice_id?: string | null;
|
|
1445
1247
|
/** @nullable */
|
|
1446
1248
|
order_id?: string | null;
|
|
1447
|
-
/**
|
|
1448
|
-
* Why the payment did not go through. Present with `failed`. For a declined gateway payment the
|
|
1449
|
-
* value is the gateway's own code, passed on unchanged: the card issuer's decline code when
|
|
1450
|
-
* there is one (Stripe's decline_code, such as insufficient_funds or lost_card), otherwise the
|
|
1451
|
-
* gateway's error code (Stripe's code, such as card_declined, expired_card or
|
|
1452
|
-
* payment_intent_authentication_failure). Clients map it to their own wording and treat an
|
|
1453
|
-
* unknown value as a generic decline.
|
|
1454
|
-
*/
|
|
1249
|
+
/** Why the payment failed; present with `failed`. For a declined gateway payment, the gateway's code unchanged: the issuer's decline code when there is one (Stripe decline_code, such as insufficient_funds), otherwise the gateway's error code (Stripe code, such as card_declined). Treat an unknown value as a generic decline. */
|
|
1455
1250
|
failure_reason?: string;
|
|
1456
1251
|
}
|
|
1457
1252
|
/**
|
|
1458
|
-
* How tax applied to the customer when the invoice was issued
|
|
1459
|
-
* charged because the customer accounts for it under the reverse-charge mechanism.
|
|
1253
|
+
* How tax applied to the customer when the invoice was issued; `reverse` means no tax was charged under the reverse-charge mechanism.
|
|
1460
1254
|
*/
|
|
1461
1255
|
export type InvoiceCustomerTaxExempt = (typeof InvoiceCustomerTaxExempt)[keyof typeof InvoiceCustomerTaxExempt];
|
|
1462
1256
|
export declare const InvoiceCustomerTaxExempt: {
|
|
@@ -1479,7 +1273,7 @@ export interface TaxItem {
|
|
|
1479
1273
|
currency: string;
|
|
1480
1274
|
}
|
|
1481
1275
|
export interface Invoice {
|
|
1482
|
-
/** Collection has
|
|
1276
|
+
/** Collection has stopped; accepted return obligations are completed. */
|
|
1483
1277
|
void_requested_at?: string;
|
|
1484
1278
|
due_at?: string;
|
|
1485
1279
|
amount_refunded?: string;
|
|
@@ -1499,16 +1293,16 @@ export interface Invoice {
|
|
|
1499
1293
|
/** Sum of the line discounts, taken off before tax. */
|
|
1500
1294
|
discount_amount?: Money;
|
|
1501
1295
|
tax_amount?: Money;
|
|
1502
|
-
/** Successful credit-grant payments included in amount_paid
|
|
1296
|
+
/** Successful credit-grant payments, included in amount_paid; they do not reduce the receivable or tax base. */
|
|
1503
1297
|
credit_applied?: Money;
|
|
1504
|
-
/** Subtotal less discount plus tax. Balance and credit grants
|
|
1298
|
+
/** Subtotal less discount plus tax. Balance and credit grants pay it; they do not reduce it. */
|
|
1505
1299
|
total: Money;
|
|
1506
1300
|
amount_paid?: Money;
|
|
1507
|
-
/** Issued
|
|
1301
|
+
/** Issued credit notes that reduced unpaid receivables; the original invoice total is unchanged. */
|
|
1508
1302
|
pre_payment_credit_notes_amount: Money;
|
|
1509
|
-
/** Issued credit notes against payments already received
|
|
1303
|
+
/** Issued credit notes against payments already received; their refunds may not have completed. */
|
|
1510
1304
|
post_payment_credit_notes_amount: Money;
|
|
1511
|
-
/** What is still collectible after unpaid credit notes and successful payments; never below zero.
|
|
1305
|
+
/** What is still collectible after unpaid credit notes and successful payments; never below zero. Zero for a draft, whose total is the base price, and for a paid or void invoice. */
|
|
1512
1306
|
amount_due: Money;
|
|
1513
1307
|
/** @nullable */
|
|
1514
1308
|
period_start?: string | null;
|
|
@@ -1517,17 +1311,11 @@ export interface Invoice {
|
|
|
1517
1311
|
* @nullable
|
|
1518
1312
|
*/
|
|
1519
1313
|
period_end?: string | null;
|
|
1520
|
-
/**
|
|
1521
|
-
* Who this was billed to, as recorded when the invoice was issued. Later changes to
|
|
1522
|
-
* the account do not alter it.
|
|
1523
|
-
*/
|
|
1314
|
+
/** The billing details recorded when the invoice was issued. */
|
|
1524
1315
|
customer_name?: string;
|
|
1525
1316
|
customer_email?: string;
|
|
1526
1317
|
customer_tax_id?: string;
|
|
1527
|
-
/**
|
|
1528
|
-
* How tax applied to the customer when the invoice was issued. `reverse` means no tax was
|
|
1529
|
-
* charged because the customer accounts for it under the reverse-charge mechanism.
|
|
1530
|
-
*/
|
|
1318
|
+
/** How tax applied to the customer when the invoice was issued; `reverse` means no tax was charged under the reverse-charge mechanism. */
|
|
1531
1319
|
customer_tax_exempt?: InvoiceCustomerTaxExempt;
|
|
1532
1320
|
customer_address_line1?: string;
|
|
1533
1321
|
customer_address_line2?: string;
|
|
@@ -1550,13 +1338,19 @@ export declare const InvoiceItemType: {
|
|
|
1550
1338
|
readonly setup: "setup";
|
|
1551
1339
|
readonly adjustment: "adjustment";
|
|
1552
1340
|
};
|
|
1341
|
+
/**
|
|
1342
|
+
* For a usage line, the values of its meter's presentation dimensions, such as the model and token kind. Empty for other lines.
|
|
1343
|
+
*/
|
|
1344
|
+
export type InvoiceItemDimensions = {
|
|
1345
|
+
[key: string]: string;
|
|
1346
|
+
};
|
|
1553
1347
|
/**
|
|
1554
1348
|
* The value of one paid period moved to the new configuration of a subscription.
|
|
1555
1349
|
*/
|
|
1556
1350
|
export interface InvoiceItemProration {
|
|
1557
1351
|
/** The earlier invoice line that paid for the period. */
|
|
1558
1352
|
credited_invoice_item_id: string;
|
|
1559
|
-
/** The
|
|
1353
|
+
/** The earlier invoice line's wording as recorded. */
|
|
1560
1354
|
description: string;
|
|
1561
1355
|
period_start: string;
|
|
1562
1356
|
/** Exclusive. */
|
|
@@ -1588,29 +1382,26 @@ export interface InvoiceItem {
|
|
|
1588
1382
|
type?: InvoiceItemType;
|
|
1589
1383
|
/** @nullable */
|
|
1590
1384
|
project_id?: string | null;
|
|
1591
|
-
/**
|
|
1592
|
-
* The project the charge was for and its current name, for display. Absent when the line is
|
|
1593
|
-
* not for a project, and when the project no longer exists or its details cannot be read at
|
|
1594
|
-
* the moment; `project_id` still identifies it then.
|
|
1595
|
-
*/
|
|
1385
|
+
/** The project the charge was for and its current name. Absent when the line has no project or the project cannot be read; `project_id` still identifies it. */
|
|
1596
1386
|
project?: NamedIdentity | null;
|
|
1597
1387
|
resource_id?: string;
|
|
1598
|
-
/**
|
|
1599
|
-
* The wording as recorded when the invoice was issued. It is not re-translated
|
|
1600
|
-
* afterwards, so that an invoice continues to read as it did when it was sent.
|
|
1601
|
-
*/
|
|
1388
|
+
/** The line's wording as recorded when the invoice was issued. */
|
|
1602
1389
|
description: string;
|
|
1603
1390
|
unit?: string;
|
|
1604
1391
|
quantity?: string;
|
|
1605
1392
|
/** The part covered by an included allowance, and therefore not charged. */
|
|
1606
1393
|
deducted_quantity?: string;
|
|
1607
1394
|
unit_amount?: Money;
|
|
1395
|
+
/** The quantity `unit_amount` prices, such as 1000000 tokens or 3600 seconds: `amount` is `quantity` × `unit_amount` ÷ `unit_quantity`. Present together with `unit_amount`. */
|
|
1396
|
+
unit_quantity?: string;
|
|
1608
1397
|
amount: Money;
|
|
1609
1398
|
currency: string;
|
|
1610
1399
|
/** @nullable */
|
|
1611
1400
|
period_start?: string | null;
|
|
1612
1401
|
/** @nullable */
|
|
1613
1402
|
period_end?: string | null;
|
|
1403
|
+
/** For a usage line, the values of its meter's presentation dimensions, such as the model and token kind. Empty for other lines. */
|
|
1404
|
+
dimensions?: InvoiceItemDimensions;
|
|
1614
1405
|
/**
|
|
1615
1406
|
* Present on a line that changes a subscription immediately, one entry for each paid period it
|
|
1616
1407
|
* covers. `amount` is the sum of `remaining_amount` minus `credited_amount` over the entries.
|
|
@@ -1659,9 +1450,7 @@ export declare const CreditNoteStatus: {
|
|
|
1659
1450
|
readonly void: "void";
|
|
1660
1451
|
};
|
|
1661
1452
|
/**
|
|
1662
|
-
* Why the note was issued. Notes
|
|
1663
|
-
* `usage_true_up` returns a tier price reduction settled after the original invoice; `operator` is
|
|
1664
|
-
* issued by Leaflow on request.
|
|
1453
|
+
* Why the note was issued. Notes for canceled, expired or failed orders carry the order's reason; `usage_true_up` returns a tier price reduction settled after the original invoice; `operator` was issued on request.
|
|
1665
1454
|
*/
|
|
1666
1455
|
export type CreditNoteReason = (typeof CreditNoteReason)[keyof typeof CreditNoteReason];
|
|
1667
1456
|
export declare const CreditNoteReason: {
|
|
@@ -1675,7 +1464,7 @@ export declare const CreditNoteReason: {
|
|
|
1675
1464
|
readonly operator: "operator";
|
|
1676
1465
|
};
|
|
1677
1466
|
/**
|
|
1678
|
-
*
|
|
1467
|
+
* A reduction of an issued invoice; the original invoice amounts do not change. The credited amount is pre_payment_amount plus post_payment_amount. A paid part creates a refund, identified by refund_id, whose outcome may still be pending.
|
|
1679
1468
|
*/
|
|
1680
1469
|
export interface CreditNote {
|
|
1681
1470
|
id: string;
|
|
@@ -1690,18 +1479,14 @@ export interface CreditNote {
|
|
|
1690
1479
|
voided_at: string | null;
|
|
1691
1480
|
/** The reduction of unpaid receivables. A void note no longer reduces what is due. */
|
|
1692
1481
|
pre_payment_amount: Money;
|
|
1693
|
-
/** The credited part of payments already received
|
|
1482
|
+
/** The credited part of payments already received; its refund may not have completed. */
|
|
1694
1483
|
post_payment_amount: Money;
|
|
1695
1484
|
/**
|
|
1696
|
-
* The refund to the original payment sources
|
|
1485
|
+
* The refund to the original payment sources; null when no paid amount was credited.
|
|
1697
1486
|
* @nullable
|
|
1698
1487
|
*/
|
|
1699
1488
|
refund_id: string | null;
|
|
1700
|
-
/**
|
|
1701
|
-
* Why the note was issued. Notes from canceled, expired or failed orders carry the order's reason;
|
|
1702
|
-
* `usage_true_up` returns a tier price reduction settled after the original invoice; `operator` is
|
|
1703
|
-
* issued by Leaflow on request.
|
|
1704
|
-
*/
|
|
1489
|
+
/** Why the note was issued. Notes for canceled, expired or failed orders carry the order's reason; `usage_true_up` returns a tier price reduction settled after the original invoice; `operator` was issued on request. */
|
|
1705
1490
|
reason: CreditNoteReason;
|
|
1706
1491
|
}
|
|
1707
1492
|
export interface CreditNoteItem {
|
|
@@ -1720,7 +1505,7 @@ export interface CreditNoteItemList {
|
|
|
1720
1505
|
pagination: OffsetPagination;
|
|
1721
1506
|
}
|
|
1722
1507
|
/**
|
|
1723
|
-
* Use balance_amount, credit_amount and gateway_amount, which also show a refund split between
|
|
1508
|
+
* Use balance_amount, credit_amount and gateway_amount, which also show a refund split between destinations.
|
|
1724
1509
|
* @deprecated
|
|
1725
1510
|
*/
|
|
1726
1511
|
export type RefundDestination = (typeof RefundDestination)[keyof typeof RefundDestination];
|
|
@@ -1748,22 +1533,19 @@ export declare const RefundStatus: {
|
|
|
1748
1533
|
readonly failed: "failed";
|
|
1749
1534
|
};
|
|
1750
1535
|
/**
|
|
1751
|
-
* Why the refund was made.
|
|
1752
|
-
* treat an unknown code as a refund without a stated reason.
|
|
1536
|
+
* Why the refund was made. New codes may be added; treat an unknown code as unspecified.
|
|
1753
1537
|
*
|
|
1754
1538
|
* - `provisioning_failed`: the purchase could not be delivered.
|
|
1755
|
-
* - `order_expired`: the order expired after part of it
|
|
1756
|
-
* - `order_canceled`: the
|
|
1757
|
-
* - `change_canceled`: a scheduled change was withdrawn after part of it
|
|
1758
|
-
* - `change_expired`: a scheduled change could not take effect
|
|
1759
|
-
* - `subscription_canceled`: the
|
|
1760
|
-
*
|
|
1761
|
-
* - `
|
|
1762
|
-
*
|
|
1763
|
-
*
|
|
1764
|
-
*
|
|
1765
|
-
* zero or less.
|
|
1766
|
-
* - `usage_true_up`: usage priced again over the whole month cost less than was charged.
|
|
1539
|
+
* - `order_expired`: the order expired after part of it was paid.
|
|
1540
|
+
* - `order_canceled`: the order was canceled after part of it was paid.
|
|
1541
|
+
* - `change_canceled`: a scheduled change was withdrawn after part of it was paid.
|
|
1542
|
+
* - `change_expired`: a scheduled change could not take effect in time.
|
|
1543
|
+
* - `subscription_canceled`: the unused value of a canceled subscription, under its refund terms.
|
|
1544
|
+
* - `future_period_canceled`: a renewal that had not started was withdrawn.
|
|
1545
|
+
* - `downgrade_difference`: after a downgrade, the remaining paid value, valued as refund policy `prorated`
|
|
1546
|
+
* describes, minus the new configuration's cost for the remaining time at the change item's
|
|
1547
|
+
* `refund_monthly_amount` and `refund_hourly_amount`.
|
|
1548
|
+
* - `usage_true_up`: usage priced over the whole month cost less than was charged.
|
|
1767
1549
|
* - `payment_not_applied`: a payment arrived after its invoice could no longer be paid.
|
|
1768
1550
|
* - `operator`: made by the platform operator.
|
|
1769
1551
|
*/
|
|
@@ -1784,15 +1566,14 @@ export declare const RefundReason: {
|
|
|
1784
1566
|
export interface Refund {
|
|
1785
1567
|
transaction_id?: string;
|
|
1786
1568
|
cancellation_item_id?: string;
|
|
1787
|
-
/**
|
|
1569
|
+
/** The refund split by original payment source, with each result. Unknown gateway results stay pending. */
|
|
1788
1570
|
transactions: Transaction[];
|
|
1789
1571
|
id: string;
|
|
1790
1572
|
billing_account_id?: number;
|
|
1791
1573
|
/** @nullable */
|
|
1792
1574
|
invoice_id?: string | null;
|
|
1793
1575
|
/**
|
|
1794
|
-
* The order the refund belongs to: the order that caused it, such as a downgrade, otherwise
|
|
1795
|
-
* the order of the refunded invoice. Null for refunds of top-ups and of usage invoices.
|
|
1576
|
+
* The order the refund belongs to: the order that caused it, such as a downgrade, otherwise the order of the refunded invoice. Null for refunds of top-ups and usage invoices.
|
|
1796
1577
|
* @nullable
|
|
1797
1578
|
*/
|
|
1798
1579
|
order_id?: string | null;
|
|
@@ -1808,7 +1589,7 @@ export interface Refund {
|
|
|
1808
1589
|
settled_amount?: Money;
|
|
1809
1590
|
currency: string;
|
|
1810
1591
|
/**
|
|
1811
|
-
* Use balance_amount, credit_amount and gateway_amount, which also show a refund split between
|
|
1592
|
+
* Use balance_amount, credit_amount and gateway_amount, which also show a refund split between destinations.
|
|
1812
1593
|
* @deprecated
|
|
1813
1594
|
*/
|
|
1814
1595
|
destination?: RefundDestination;
|
|
@@ -1835,7 +1616,7 @@ export interface RefundList {
|
|
|
1835
1616
|
pagination: OffsetPagination;
|
|
1836
1617
|
}
|
|
1837
1618
|
/**
|
|
1838
|
-
* The
|
|
1619
|
+
* The dimension values the rate was matched by, such as region and machine type.
|
|
1839
1620
|
*/
|
|
1840
1621
|
export type UsageChargeDimensions = {
|
|
1841
1622
|
[key: string]: string;
|
|
@@ -1844,28 +1625,27 @@ export interface UsageCharge {
|
|
|
1844
1625
|
subscription_id: string;
|
|
1845
1626
|
id: string;
|
|
1846
1627
|
project_id?: string;
|
|
1847
|
-
/**
|
|
1848
|
-
* The project and its current name, for display. Absent when the project no longer exists or its
|
|
1849
|
-
* details cannot be read at the moment; `project_id` still identifies it.
|
|
1850
|
-
*/
|
|
1628
|
+
/** The project and its current name. Absent when the project cannot be read; `project_id` still identifies it. */
|
|
1851
1629
|
project?: NamedIdentity | null;
|
|
1852
1630
|
product: Product;
|
|
1853
1631
|
/** Which resource this was charged for. Empty for charges not tied to one. */
|
|
1854
1632
|
resource_id?: string;
|
|
1855
1633
|
meter: ObjectIdentity;
|
|
1856
1634
|
unit?: string;
|
|
1857
|
-
/** The
|
|
1635
|
+
/** The dimension values the rate was matched by, such as region and machine type. */
|
|
1858
1636
|
dimensions?: UsageChargeDimensions;
|
|
1859
1637
|
window_start: string;
|
|
1860
1638
|
/** Exclusive. */
|
|
1861
1639
|
window_end: string;
|
|
1862
|
-
/**
|
|
1640
|
+
/** Quantity used before allowances. */
|
|
1863
1641
|
gross_quantity?: string;
|
|
1864
1642
|
/** How much of that was covered by an allowance. */
|
|
1865
1643
|
deducted_quantity?: string;
|
|
1866
|
-
/**
|
|
1644
|
+
/** The quantity charged: gross quantity less the part covered by allowances. */
|
|
1867
1645
|
quantity: string;
|
|
1868
1646
|
unit_amount?: Money;
|
|
1647
|
+
/** The quantity `unit_amount` prices, such as 1000000 tokens or 3600 seconds: `amount` is `quantity` × `unit_amount` ÷ `unit_quantity`. */
|
|
1648
|
+
unit_quantity?: string;
|
|
1869
1649
|
amount: Money;
|
|
1870
1650
|
currency: string;
|
|
1871
1651
|
/**
|
|
@@ -1885,12 +1665,6 @@ export interface UsageChargeList {
|
|
|
1885
1665
|
items: UsageCharge[];
|
|
1886
1666
|
pagination: OffsetPagination;
|
|
1887
1667
|
}
|
|
1888
|
-
export type SubscriptionChargeType = (typeof SubscriptionChargeType)[keyof typeof SubscriptionChargeType];
|
|
1889
|
-
export declare const SubscriptionChargeType: {
|
|
1890
|
-
readonly postpaid: "postpaid";
|
|
1891
|
-
readonly prepaid: "prepaid";
|
|
1892
|
-
readonly one_time: "one_time";
|
|
1893
|
-
};
|
|
1894
1668
|
export type SubscriptionInterval = (typeof SubscriptionInterval)[keyof typeof SubscriptionInterval];
|
|
1895
1669
|
export declare const SubscriptionInterval: {
|
|
1896
1670
|
readonly none: "none";
|
|
@@ -1899,7 +1673,7 @@ export declare const SubscriptionInterval: {
|
|
|
1899
1673
|
readonly year: "year";
|
|
1900
1674
|
};
|
|
1901
1675
|
/**
|
|
1902
|
-
* An operation
|
|
1676
|
+
* An operation prevented on the subscription. `billing.subscriptions.use` stops the service. `renew` prevents renewal and paying a renewal order. `modify` prevents placing a change order. `cancel` prevents cancellation. `terminate` prevents immediate termination.
|
|
1903
1677
|
*/
|
|
1904
1678
|
export type SubscriptionRestriction = (typeof SubscriptionRestriction)[keyof typeof SubscriptionRestriction];
|
|
1905
1679
|
export declare const SubscriptionRestriction: {
|
|
@@ -1910,13 +1684,7 @@ export declare const SubscriptionRestriction: {
|
|
|
1910
1684
|
readonly billingsubscriptionsterminate: "billing.subscriptions.terminate";
|
|
1911
1685
|
};
|
|
1912
1686
|
/**
|
|
1913
|
-
* Follows the items. `pending
|
|
1914
|
-
* whether payment is still needed, and it can expire or be canceled. `accepted` is accepted with items still
|
|
1915
|
-
* being set up. `completed` means every item was set up. `partially_completed` means some items were set up
|
|
1916
|
-
* and the others failed or were canceled and were refunded to their original payment sources. `failed` means
|
|
1917
|
-
* no item was delivered and at least one failed; collected amounts for the undelivered items are refunded.
|
|
1918
|
-
* `canceled` means every item was withdrawn without delivery; collected amounts are returned to their original
|
|
1919
|
-
* payment sources. No status establishes service delivery by itself.
|
|
1687
|
+
* Follows the items. `pending`: not yet accepted, paid or unpaid; its invoice shows whether payment is needed, and it can expire or be canceled. `accepted`: items are being set up. `completed`: every item was set up. `partially_completed`: some items were set up and the others failed or were canceled and refunded to their original payment sources. `failed`: no item was delivered and at least one failed; amounts collected for undelivered items are refunded. `canceled`: every item was withdrawn without delivery; collected amounts are returned to their original payment sources. No status by itself means the service was delivered.
|
|
1920
1688
|
*/
|
|
1921
1689
|
export type OrderStatus = (typeof OrderStatus)[keyof typeof OrderStatus];
|
|
1922
1690
|
export declare const OrderStatus: {
|
|
@@ -1934,7 +1702,7 @@ export declare const ScheduledChangeInterval: {
|
|
|
1934
1702
|
readonly year: "year";
|
|
1935
1703
|
};
|
|
1936
1704
|
/**
|
|
1937
|
-
* The next accepted period-end change
|
|
1705
|
+
* The next accepted period-end change of the subscription: the target terms, applied at effective_at.
|
|
1938
1706
|
*/
|
|
1939
1707
|
export interface ScheduledChange {
|
|
1940
1708
|
order_id: string;
|
|
@@ -1945,7 +1713,7 @@ export interface ScheduledChange {
|
|
|
1945
1713
|
plan_name: string;
|
|
1946
1714
|
price_id: string;
|
|
1947
1715
|
quantity: string;
|
|
1948
|
-
/** The target
|
|
1716
|
+
/** The target licensed renewal amount before tax. */
|
|
1949
1717
|
recurring_amount: string;
|
|
1950
1718
|
currency: string;
|
|
1951
1719
|
interval: ScheduledChangeInterval;
|
|
@@ -1953,11 +1721,7 @@ export interface ScheduledChange {
|
|
|
1953
1721
|
interval_count: number;
|
|
1954
1722
|
}
|
|
1955
1723
|
/**
|
|
1956
|
-
* pending
|
|
1957
|
-
* provisioning means the service accepted the order and is delivering. For a service-owned
|
|
1958
|
-
* purchase, only confirmed delivery moves it to active; paying alone does not.
|
|
1959
|
-
* canceled means cancellation completed, or an unfulfilled purchase was canceled or failed without delivery.
|
|
1960
|
-
* terminated means an administrator or the owning service immediately ended the commercial relationship.
|
|
1724
|
+
* `pending`: the order has not been accepted. `provisioning`: the owning service accepted the order and is delivering. `active`: delivery was confirmed; payment alone does not make a subscription active. `suspended`: service is stopped while a lien restricts its use. `canceled`: cancellation completed, or an undelivered purchase was canceled or failed. `terminated`: an operator or the owning service ended it immediately.
|
|
1961
1725
|
*/
|
|
1962
1726
|
export type SubscriptionStatus = (typeof SubscriptionStatus)[keyof typeof SubscriptionStatus];
|
|
1963
1727
|
export declare const SubscriptionStatus: {
|
|
@@ -1969,42 +1733,37 @@ export declare const SubscriptionStatus: {
|
|
|
1969
1733
|
readonly terminated: "terminated";
|
|
1970
1734
|
};
|
|
1971
1735
|
/**
|
|
1972
|
-
*
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
*
|
|
1979
|
-
*
|
|
1980
|
-
*
|
|
1981
|
-
* then; postpaid usage starts only when the service reports actual delivery and metering.
|
|
1736
|
+
* The dimension values of what was bought, such as region and instance type. Empty when the purchase gave none.
|
|
1737
|
+
*/
|
|
1738
|
+
export type SubscriptionDimensions = {
|
|
1739
|
+
[key: string]: string;
|
|
1740
|
+
};
|
|
1741
|
+
/**
|
|
1742
|
+
* A purchase that is billed, renewed and changed on its own, separate from the owning service's resource. A new
|
|
1743
|
+
* recurring purchase creates a pending subscription for each order line; its ID is returned on the order item
|
|
1744
|
+
* and stays the same through checkout, delivery, renewals and changes. A one-time purchase may create none.
|
|
1982
1745
|
*
|
|
1983
|
-
*
|
|
1984
|
-
*
|
|
1985
|
-
*
|
|
1986
|
-
*
|
|
1987
|
-
*
|
|
1988
|
-
* original value. Technical state belongs to the owning service.
|
|
1746
|
+
* Pending and provisioning subscriptions grant no service. A subscription becomes provisioning when the owning
|
|
1747
|
+
* service accepts the order, and active when the service confirms delivery, which sets started_at; payment
|
|
1748
|
+
* changes neither. Licensed service periods start at delivery, and metered usage is charged as the service
|
|
1749
|
+
* reports it. Canceling or failing an undelivered purchase cancels its subscriptions without starting a period.
|
|
1750
|
+
* Renewals use recurring_amount and the agreed interval; paid periods keep their value.
|
|
1989
1751
|
*
|
|
1990
|
-
* A
|
|
1991
|
-
*
|
|
1992
|
-
* Creating or deleting snapshots within it does not create, activate or terminate more subscriptions;
|
|
1993
|
-
* the owning service enforces current holdings against the purchased count.
|
|
1752
|
+
* A shared capacity limit, such as a regional snapshot quota, has one subscription for the purchased quantity
|
|
1753
|
+
* rather than one per item.
|
|
1994
1754
|
*/
|
|
1995
1755
|
export interface Subscription {
|
|
1996
1756
|
/** Whether new account discounts may apply to future renewals. A fixed operator renewal agreement disables automatic discounts; catalog repricing or a newly selected purchase agreement enables them. */
|
|
1997
1757
|
renewal_discounts_enabled?: boolean;
|
|
1998
1758
|
currency: string;
|
|
1999
|
-
|
|
1759
|
+
type: PriceType;
|
|
1760
|
+
usage_type: UsageType;
|
|
1761
|
+
/** The dimension values of what was bought, such as region and instance type. Empty when the purchase gave none. */
|
|
1762
|
+
dimensions: SubscriptionDimensions;
|
|
2000
1763
|
interval: SubscriptionInterval;
|
|
2001
1764
|
/** @minimum 1 */
|
|
2002
1765
|
interval_count?: number;
|
|
2003
|
-
/**
|
|
2004
|
-
* Whole-subscription prepaid renewal amount, after continuing discounts and before tax.
|
|
2005
|
-
* Pending subscriptions show base terms until paying the order fixes any new continuing discount.
|
|
2006
|
-
* Absent for other charge types.
|
|
2007
|
-
*/
|
|
1766
|
+
/** The whole licensed subscription's renewal amount, after continuing discounts and before tax. A pending subscription shows base terms until paying the order fixes any new discount. Absent for metered and one-time subscriptions. */
|
|
2008
1767
|
recurring_amount?: string;
|
|
2009
1768
|
termination_policy?: TerminationPolicy;
|
|
2010
1769
|
refund_policy?: RefundPolicy;
|
|
@@ -2013,17 +1772,14 @@ export interface Subscription {
|
|
|
2013
1772
|
coupon?: ObjectIdentity;
|
|
2014
1773
|
/** @minimum 0 */
|
|
2015
1774
|
discounted_renewals_remaining?: number;
|
|
2016
|
-
/** The operations currently prevented on the subscription, sorted
|
|
1775
|
+
/** The operations currently prevented on the subscription, sorted; it is suspended while this contains `billing.subscriptions.use`. */
|
|
2017
1776
|
restrictions?: SubscriptionRestriction[];
|
|
2018
1777
|
billing_cycle_anchor?: string;
|
|
2019
1778
|
cancellation?: SubscriptionCancellation;
|
|
2020
|
-
/** The accepted period-end change
|
|
1779
|
+
/** The accepted period-end change scheduled for this subscription; null when there is none. */
|
|
2021
1780
|
scheduled_change?: ScheduledChange | null;
|
|
2022
1781
|
/**
|
|
2023
|
-
* The saved payment method automatic renewal charges after the account's
|
|
2024
|
-
* before the account's default payment method. Set when the purchase, a renewal or a change is paid with a
|
|
2025
|
-
* saved payment method; paying any other way leaves it unchanged. It is used only while it belongs to the
|
|
2026
|
-
* account that pays the renewal.
|
|
1782
|
+
* The saved payment method automatic renewal charges after balance and credits, before the account's default payment method. Set when a purchase, renewal or change is paid with a saved payment method. Used only while it belongs to the account paying the renewal.
|
|
2027
1783
|
* @nullable
|
|
2028
1784
|
*/
|
|
2029
1785
|
default_payment_method_id?: string | null;
|
|
@@ -2034,16 +1790,11 @@ export interface Subscription {
|
|
|
2034
1790
|
account: AccountIdentity;
|
|
2035
1791
|
product_id: ProductID;
|
|
2036
1792
|
/**
|
|
2037
|
-
*
|
|
2038
|
-
* membership, which belongs to no single project.
|
|
1793
|
+
* The project it is for. Absent for an account-level purchase, such as a membership.
|
|
2039
1794
|
* @nullable
|
|
2040
1795
|
*/
|
|
2041
1796
|
project_id?: string | null;
|
|
2042
|
-
/**
|
|
2043
|
-
* The project and its current name, for display. Absent for a purchase at account level,
|
|
2044
|
-
* and when the project no longer exists or its details cannot be read at the moment;
|
|
2045
|
-
* `project_id` still identifies it then.
|
|
2046
|
-
*/
|
|
1797
|
+
/** The project and its current name. Absent for an account-level purchase or when the project cannot be read; `project_id` still identifies it. */
|
|
2047
1798
|
project?: NamedIdentity | null;
|
|
2048
1799
|
product: Product;
|
|
2049
1800
|
plan_id: string;
|
|
@@ -2051,35 +1802,26 @@ export interface Subscription {
|
|
|
2051
1802
|
price_id: string;
|
|
2052
1803
|
quantity: string;
|
|
2053
1804
|
/**
|
|
2054
|
-
* When a
|
|
2055
|
-
* Renewing several periods in advance moves it. Null until a new subscription becomes active, even when
|
|
2056
|
-
* its purchase has been paid, and for postpaid subscriptions.
|
|
1805
|
+
* When a licensed subscription renews or expires: the end of the last period bought, moved by renewing in advance. Null until the subscription becomes active, even when its purchase has been paid, and for metered subscriptions.
|
|
2057
1806
|
* @nullable
|
|
2058
1807
|
*/
|
|
2059
1808
|
current_term_end?: string | null;
|
|
2060
1809
|
/**
|
|
2061
|
-
* Start of the service period in effect now. Null when none is, including for
|
|
1810
|
+
* Start of the service period in effect now. Null when none is, including for metered subscriptions.
|
|
2062
1811
|
* @nullable
|
|
2063
1812
|
*/
|
|
2064
1813
|
current_period_start?: string | null;
|
|
2065
1814
|
/**
|
|
2066
|
-
* End of the service period in effect now
|
|
2067
|
-
* this. Null when no period is in effect, including for postpaid subscriptions.
|
|
1815
|
+
* End of the service period in effect now; renewing in advance moves `current_term_end`, not this. Null when no period is in effect, including for metered subscriptions.
|
|
2068
1816
|
* @nullable
|
|
2069
1817
|
*/
|
|
2070
1818
|
current_period_end?: string | null;
|
|
2071
|
-
/**
|
|
1819
|
+
/** Whether a licensed subscription renews automatically. A metered subscription continues until it is canceled; for it this is true until a cancellation is requested, and cannot be set. */
|
|
2072
1820
|
auto_renew: boolean;
|
|
2073
|
-
/**
|
|
2074
|
-
* pending means the purchase relationship exists but its order has not been accepted.
|
|
2075
|
-
* provisioning means the service accepted the order and is delivering. For a service-owned
|
|
2076
|
-
* purchase, only confirmed delivery moves it to active; paying alone does not.
|
|
2077
|
-
* canceled means cancellation completed, or an unfulfilled purchase was canceled or failed without delivery.
|
|
2078
|
-
* terminated means an administrator or the owning service immediately ended the commercial relationship.
|
|
2079
|
-
*/
|
|
1821
|
+
/** `pending`: the order has not been accepted. `provisioning`: the owning service accepted the order and is delivering. `active`: delivery was confirmed; payment alone does not make a subscription active. `suspended`: service is stopped while a lien restricts its use. `canceled`: cancellation completed, or an undelivered purchase was canceled or failed. `terminated`: an operator or the owning service ended it immediately. */
|
|
2080
1822
|
status: SubscriptionStatus;
|
|
2081
1823
|
/**
|
|
2082
|
-
*
|
|
1824
|
+
* When service started. Null until a new subscription becomes active, also after payment.
|
|
2083
1825
|
* @nullable
|
|
2084
1826
|
*/
|
|
2085
1827
|
started_at?: string | null;
|
|
@@ -2106,10 +1848,7 @@ export interface RenewalPrice {
|
|
|
2106
1848
|
/** What renewing for this term costs, for the quantity held. */
|
|
2107
1849
|
amount?: Money;
|
|
2108
1850
|
currency?: string;
|
|
2109
|
-
/**
|
|
2110
|
-
* The term this item already bills at. Renewing for it uses the price bought
|
|
2111
|
-
* originally, so a later price change does not affect it.
|
|
2112
|
-
*/
|
|
1851
|
+
/** The term the subscription renews at now; renewing for it keeps the agreed price. */
|
|
2113
1852
|
current: boolean;
|
|
2114
1853
|
}
|
|
2115
1854
|
export interface RenewalPriceList {
|
|
@@ -2126,14 +1865,10 @@ export declare const RenewRequestInterval: {
|
|
|
2126
1865
|
readonly year: "year";
|
|
2127
1866
|
};
|
|
2128
1867
|
export interface RenewRequest {
|
|
2129
|
-
/**
|
|
1868
|
+
/** The order ID, chosen by the caller. Creating it again conflicts; read the order after an unknown outcome. */
|
|
2130
1869
|
order_id: string;
|
|
2131
1870
|
/**
|
|
2132
|
-
* How many further periods to buy, each at the price
|
|
2133
|
-
*
|
|
2134
|
-
* Buying twelve monthly periods is not the same as buying one yearly term: a longer
|
|
2135
|
-
* term is usually sold at a lower price, and that price is only reached by naming the
|
|
2136
|
-
* interval. Use `interval_count` and `interval` for that.
|
|
1871
|
+
* How many further periods to buy, each at the price the subscription already renews at. To buy a longer term at its own price, give `interval` and `interval_count` instead.
|
|
2137
1872
|
* @minimum 1
|
|
2138
1873
|
*/
|
|
2139
1874
|
periods?: number;
|
|
@@ -2172,10 +1907,10 @@ export declare const RenewalOrderRequestInterval: {
|
|
|
2172
1907
|
readonly year: "year";
|
|
2173
1908
|
};
|
|
2174
1909
|
/**
|
|
2175
|
-
* The periods and price
|
|
1910
|
+
* The renewal's periods and price, chosen as in renewing.
|
|
2176
1911
|
*/
|
|
2177
1912
|
export interface RenewalOrderRequest {
|
|
2178
|
-
/**
|
|
1913
|
+
/** The order ID, chosen by the caller. Creating it again conflicts; read the order after an unknown outcome. */
|
|
2179
1914
|
order_id: string;
|
|
2180
1915
|
/**
|
|
2181
1916
|
* As in renewing.
|
|
@@ -2196,10 +1931,7 @@ export interface AutoRenewSet {
|
|
|
2196
1931
|
auto_renew: boolean;
|
|
2197
1932
|
}
|
|
2198
1933
|
/**
|
|
2199
|
-
* `pending
|
|
2200
|
-
* `failed` was not set up and its amount was refunded to the original payment sources.
|
|
2201
|
-
* `canceled` was confirmed withdrawn without delivery; any collected amount is returned. A completed item is ended by canceling
|
|
2202
|
-
* its subscription.
|
|
1934
|
+
* `pending`: waiting to be set up. `completed`: set up, as confirmed by the service. `failed`: not set up; its amount was refunded to the original payment sources. `canceled`: withdrawn without delivery; any collected amount is returned. A completed item ends when its subscription is canceled.
|
|
2203
1935
|
*/
|
|
2204
1936
|
export type OrderItemStatus = (typeof OrderItemStatus)[keyof typeof OrderItemStatus];
|
|
2205
1937
|
export declare const OrderItemStatus: {
|
|
@@ -2209,7 +1941,7 @@ export declare const OrderItemStatus: {
|
|
|
2209
1941
|
readonly canceled: "canceled";
|
|
2210
1942
|
};
|
|
2211
1943
|
/**
|
|
2212
|
-
* `new` buys, `renew` extends a
|
|
1944
|
+
* `new` buys, `renew` extends a licensed subscription, `modify` changes a subscription's configuration or billing terms.
|
|
2213
1945
|
*/
|
|
2214
1946
|
export type OrderType = (typeof OrderType)[keyof typeof OrderType];
|
|
2215
1947
|
export declare const OrderType: {
|
|
@@ -2218,12 +1950,7 @@ export declare const OrderType: {
|
|
|
2218
1950
|
readonly modify: "modify";
|
|
2219
1951
|
};
|
|
2220
1952
|
/**
|
|
2221
|
-
* When a plan change takes effect
|
|
2222
|
-
*
|
|
2223
|
-
* `period_end` orders stay pending until the first period at the new price is paid. That period
|
|
2224
|
-
* is invoiced shortly before the current paid period ends and starts when it ends; if the
|
|
2225
|
-
* invoice is still unpaid by then, the order is canceled and the subscription renews or ends as
|
|
2226
|
-
* usual. Renewing in the meantime moves all of this along with it.
|
|
1953
|
+
* When a plan change takes effect; `none` for anything that is not a change. A `period_end` order stays pending until the first period at the new price is paid. That period is invoiced shortly before the current paid period ends and starts when it ends; if the invoice is unpaid by then, the order is canceled and the subscription renews or ends as usual. A renewal in the meantime moves the change to the end of the renewed period.
|
|
2227
1954
|
*/
|
|
2228
1955
|
export type OrderChangeEffective = (typeof OrderChangeEffective)[keyof typeof OrderChangeEffective];
|
|
2229
1956
|
export declare const OrderChangeEffective: {
|
|
@@ -2232,8 +1959,7 @@ export declare const OrderChangeEffective: {
|
|
|
2232
1959
|
readonly period_end: "period_end";
|
|
2233
1960
|
};
|
|
2234
1961
|
/**
|
|
2235
|
-
* How it was paid.
|
|
2236
|
-
* then names a removed payment method.
|
|
1962
|
+
* How it was paid. `payment_method_id` still names the payment method after it is removed.
|
|
2237
1963
|
*/
|
|
2238
1964
|
export interface PaidWith {
|
|
2239
1965
|
/**
|
|
@@ -2255,22 +1981,17 @@ export declare const OrderItemInterval: {
|
|
|
2255
1981
|
readonly month: "month";
|
|
2256
1982
|
readonly year: "year";
|
|
2257
1983
|
};
|
|
2258
|
-
/**
|
|
2259
|
-
* The payment timing of the selected price.
|
|
2260
|
-
*/
|
|
2261
|
-
export type OrderItemChargeType = (typeof OrderItemChargeType)[keyof typeof OrderItemChargeType];
|
|
2262
|
-
export declare const OrderItemChargeType: {
|
|
2263
|
-
readonly postpaid: "postpaid";
|
|
2264
|
-
readonly prepaid: "prepaid";
|
|
2265
|
-
readonly one_time: "one_time";
|
|
2266
|
-
};
|
|
2267
1984
|
export type OrderItemConfiguration = {
|
|
2268
1985
|
[key: string]: unknown;
|
|
2269
1986
|
};
|
|
2270
1987
|
/**
|
|
2271
|
-
*
|
|
2272
|
-
|
|
2273
|
-
|
|
1988
|
+
* The dimension values the line was bought with, such as region and instance type. Empty when the purchase gave none.
|
|
1989
|
+
*/
|
|
1990
|
+
export type OrderItemDimensions = {
|
|
1991
|
+
[key: string]: string;
|
|
1992
|
+
};
|
|
1993
|
+
/**
|
|
1994
|
+
* The purchase terms frozen at placement. Monetary fields come from the order's invoice lines and are zero without an immediate charge, such as for a metered purchase. Later catalog changes do not reprice the line. A new service purchase has its pending subscription from placement.
|
|
2274
1995
|
*/
|
|
2275
1996
|
export interface OrderItem {
|
|
2276
1997
|
/** Whether new account discounts may apply to future renewals. A fixed operator renewal agreement disables automatic discounts; catalog repricing or a newly selected purchase agreement enables them. */
|
|
@@ -2280,11 +2001,7 @@ export interface OrderItem {
|
|
|
2280
2001
|
/** @minimum 0 */
|
|
2281
2002
|
position?: number;
|
|
2282
2003
|
configuration?: OrderItemConfiguration;
|
|
2283
|
-
/**
|
|
2284
|
-
* Stable Billing subscription ID. A new prepaid or postpaid service purchase returns the
|
|
2285
|
-
* pending subscription here; renewals and changes reference the existing subscription, which
|
|
2286
|
-
* keeps its ID. Absent for delivery without a subscription. This is not a business resource ID.
|
|
2287
|
-
*/
|
|
2004
|
+
/** The Billing subscription: the new pending subscription of a recurring purchase, or the existing one renewed or changed, which keeps its ID. Absent for a purchase without a subscription. */
|
|
2288
2005
|
subscription_id?: string;
|
|
2289
2006
|
interval: OrderItemInterval;
|
|
2290
2007
|
/** @minimum 1 */
|
|
@@ -2292,22 +2009,21 @@ export interface OrderItem {
|
|
|
2292
2009
|
termination_policy?: TerminationPolicy;
|
|
2293
2010
|
refund_policy?: RefundPolicy;
|
|
2294
2011
|
/**
|
|
2295
|
-
*
|
|
2296
|
-
* at purchase, used to value time used under a prorated refund or a downgrade. Null when the plan has
|
|
2297
|
-
* no prepaid period shorter than the one bought.
|
|
2012
|
+
* Recurring licensed items only: the plan's one-month licensed price for this item's quantity, before tax and frozen at purchase, used to value time under a prorated refund or a downgrade. Null when the plan has no licensed period shorter than the one bought.
|
|
2298
2013
|
* @nullable
|
|
2299
2014
|
*/
|
|
2300
2015
|
refund_monthly_amount?: string | null;
|
|
2301
2016
|
/**
|
|
2302
|
-
*
|
|
2303
|
-
* purchase, used for time used short of a full month. Null when the plan has no postpaid price.
|
|
2017
|
+
* Recurring licensed items only, the plan's metered hourly price for this item's quantity before tax, frozen at purchase, used for time used short of a full month. Null when the licensed price has no meter.
|
|
2304
2018
|
* @nullable
|
|
2305
2019
|
*/
|
|
2306
2020
|
refund_hourly_amount?: string | null;
|
|
2307
2021
|
recurring_amount?: string;
|
|
2308
2022
|
setup_amount?: string;
|
|
2309
|
-
|
|
2310
|
-
|
|
2023
|
+
type: PriceType;
|
|
2024
|
+
usage_type: UsageType;
|
|
2025
|
+
/** The dimension values the line was bought with, such as region and instance type. Empty when the purchase gave none. */
|
|
2026
|
+
dimensions: OrderItemDimensions;
|
|
2311
2027
|
/** Total tax after discounts, including any tax already included in the price. */
|
|
2312
2028
|
tax_amount?: string;
|
|
2313
2029
|
/** The part of tax_amount already included in gross_amount; it is not charged again. */
|
|
@@ -2319,45 +2035,28 @@ export interface OrderItem {
|
|
|
2319
2035
|
product?: Product;
|
|
2320
2036
|
/** Which plan was bought. */
|
|
2321
2037
|
plan_id: string;
|
|
2322
|
-
/**
|
|
2323
|
-
* What it was called when bought. It does not follow later catalogue renames and is
|
|
2324
|
-
* not translated.
|
|
2325
|
-
*/
|
|
2038
|
+
/** The name when bought. */
|
|
2326
2039
|
plan_name: string;
|
|
2327
2040
|
quantity: string;
|
|
2328
|
-
/**
|
|
2329
|
-
* The unit amount of the price this line is charged under. Absent for a tiered price, which has no
|
|
2330
|
-
* single unit amount, and for a change that takes effect at once, which is charged as `gross_amount`
|
|
2331
|
-
* describes.
|
|
2332
|
-
*/
|
|
2041
|
+
/** The unit amount of the price the line is charged under. Absent for a tiered price, and for an immediate change, which is charged as `gross_amount` describes. */
|
|
2333
2042
|
unit_amount?: Money;
|
|
2334
2043
|
/**
|
|
2335
|
-
* Before discounts: the price applied to the quantity,
|
|
2336
|
-
*
|
|
2337
|
-
* the
|
|
2338
|
-
*
|
|
2339
|
-
* difference instead. A change between equal period prices charges and refunds nothing. The setup fee is not part of it; see `setup_amount`.
|
|
2044
|
+
* Before discounts and setup fees: the price applied to the quantity, `unit_amount` times `quantity` for a per-
|
|
2045
|
+
* unit price, raised by any minimum charge. For an immediate upgrade it is the new price for the rest of the
|
|
2046
|
+
* paid period minus the amount paid for that time; a downgrade, or a change between equal period prices, charges
|
|
2047
|
+
* nothing.
|
|
2340
2048
|
*
|
|
2341
|
-
* Under an inclusive tax rate it includes tax,
|
|
2342
|
-
*
|
|
2343
|
-
* tax, and tax is added to it.
|
|
2049
|
+
* Under an inclusive tax rate it includes tax, shown in `tax_included_amount`, except for a renewal at agreed
|
|
2050
|
+
* terms, whose amount excludes tax.
|
|
2344
2051
|
*/
|
|
2345
2052
|
gross_amount?: Money;
|
|
2346
|
-
/**
|
|
2347
|
-
* The reduction on this line: from the coupon the order uses and, for a renewal at the agreed terms,
|
|
2348
|
-
* from the discount the subscription carries.
|
|
2349
|
-
*
|
|
2350
|
-
* A carried discount is part of the agreed amount. It is listed here, and `gross_amount` is then
|
|
2351
|
-
* `unit_amount` times `quantity`, except in two cases where `gross_amount` is the agreed amount and
|
|
2352
|
-
* the carried discount is already reflected in it: the renewal order also uses a coupon the account
|
|
2353
|
-
* holds, or the account's tax rate is inclusive.
|
|
2354
|
-
*/
|
|
2053
|
+
/** The reduction on this line, from the order's coupon and, for a renewal at agreed terms, from the subscription's carried discount. With a carried discount, `gross_amount` is `unit_amount` times `quantity`, except when the renewal order also uses an account coupon or the tax rate is inclusive: then `gross_amount` is the agreed amount, which already reflects the carried discount. */
|
|
2355
2054
|
discount_amount?: Money;
|
|
2356
2055
|
/** `gross_amount` less `discount_amount`. */
|
|
2357
2056
|
amount?: Money;
|
|
2358
2057
|
currency: string;
|
|
2359
2058
|
/**
|
|
2360
|
-
* The start of the service period this line paid for.
|
|
2059
|
+
* The start of the service period this line paid for. Fixed at placement for renewals and period-end changes, and for a licensed line of a new purchase when its invoice is paid. Absent for metered and one-time lines.
|
|
2361
2060
|
* @nullable
|
|
2362
2061
|
*/
|
|
2363
2062
|
period_start?: string | null;
|
|
@@ -2369,17 +2068,13 @@ export interface OrderItem {
|
|
|
2369
2068
|
status: OrderItemStatus;
|
|
2370
2069
|
}
|
|
2371
2070
|
/**
|
|
2372
|
-
* A recorded purchase with its invoice from placement; a zero-total invoice, such as for
|
|
2373
|
-
* admission, is issued and paid at placement whatever the checkout mode. Until checkout_confirmed_at is set, the
|
|
2374
|
-
* invoice is a draft at base prices: paying it fixes the discount and amount, issues it and collects it, and the
|
|
2375
|
-
* order cannot be accepted before then. Coupon fields describe the discount fixed at that point and are absent
|
|
2376
|
-
* before it; a quote never populates them. Payment and acceptance remain separate from resource delivery.
|
|
2071
|
+
* A recorded purchase with its invoice from placement; a zero-total invoice, such as for a metered purchase, is issued and paid at placement in either checkout mode. Until checkout_confirmed_at is set, the invoice is a draft at base prices: paying it fixes the discount and amount, issues it and collects it, and the order cannot be accepted before then. Coupon fields describe the discount fixed then and are absent before. Payment and acceptance do not mean the resources were delivered.
|
|
2377
2072
|
*/
|
|
2378
2073
|
export interface Order {
|
|
2379
2074
|
coupon_id?: string;
|
|
2380
2075
|
coupon?: ObjectIdentity;
|
|
2381
2076
|
promotion_code_id?: string;
|
|
2382
|
-
/**
|
|
2077
|
+
/** The promotion code applied. Absent for an account discount. */
|
|
2383
2078
|
promotion_code?: string;
|
|
2384
2079
|
/** The order's invoice, the same as invoice.id. */
|
|
2385
2080
|
invoice_id: string;
|
|
@@ -2390,53 +2085,32 @@ export interface Order {
|
|
|
2390
2085
|
change_effective_at?: string;
|
|
2391
2086
|
id: string;
|
|
2392
2087
|
/**
|
|
2393
|
-
*
|
|
2394
|
-
* as a membership.
|
|
2088
|
+
* The project it was bought for. Absent for an account-level purchase, such as a membership.
|
|
2395
2089
|
* @nullable
|
|
2396
2090
|
*/
|
|
2397
2091
|
project_id?: string | null;
|
|
2398
|
-
/**
|
|
2399
|
-
* The project and its current name, for display. Absent for a purchase at account level,
|
|
2400
|
-
* and when the project no longer exists or its details cannot be read at the moment;
|
|
2401
|
-
* `project_id` still identifies it then.
|
|
2402
|
-
*/
|
|
2092
|
+
/** The project and its current name. Absent for an account-level purchase or when the project cannot be read; `project_id` still identifies it. */
|
|
2403
2093
|
project?: NamedIdentity | null;
|
|
2404
|
-
/**
|
|
2405
|
-
* The billing account the order was placed with. It does not change when the project is later
|
|
2406
|
-
* linked to another billing account. While this account is suspended or closed the order cannot
|
|
2407
|
-
* be accepted, and the invoice of a change scheduled for the end of a period is not issued and the change is called off
|
|
2408
|
-
* when the current period ends; such requests fail with BILLING_ACCOUNT_UNAVAILABLE.
|
|
2409
|
-
*/
|
|
2094
|
+
/** The billing account the order was placed with, unchanged when the project is later linked to another account. While it is suspended or closed, the order cannot be accepted, and a period-end change's invoice is not issued and the change is called off when the current period ends; such requests fail with `BILLING_ACCOUNT_UNAVAILABLE`. */
|
|
2410
2095
|
billing_account_id?: number;
|
|
2411
2096
|
currency: string;
|
|
2412
|
-
/** `new` buys, `renew` extends a
|
|
2097
|
+
/** `new` buys, `renew` extends a licensed subscription, `modify` changes a subscription's configuration or billing terms. */
|
|
2413
2098
|
type: OrderType;
|
|
2414
2099
|
status: OrderStatus;
|
|
2415
|
-
/**
|
|
2416
|
-
* When a plan change takes effect. `none` on anything that is not a change.
|
|
2417
|
-
*
|
|
2418
|
-
* `period_end` orders stay pending until the first period at the new price is paid. That period
|
|
2419
|
-
* is invoiced shortly before the current paid period ends and starts when it ends; if the
|
|
2420
|
-
* invoice is still unpaid by then, the order is canceled and the subscription renews or ends as
|
|
2421
|
-
* usual. Renewing in the meantime moves all of this along with it.
|
|
2422
|
-
*/
|
|
2100
|
+
/** When a plan change takes effect; `none` for anything that is not a change. A `period_end` order stays pending until the first period at the new price is paid. That period is invoiced shortly before the current paid period ends and starts when it ends; if the invoice is unpaid by then, the order is canceled and the subscription renews or ends as usual. A renewal in the meantime moves the change to the end of the renewed period. */
|
|
2423
2101
|
change_effective?: OrderChangeEffective;
|
|
2424
2102
|
/**
|
|
2425
|
-
* Acceptance deadline
|
|
2103
|
+
* Acceptance deadline; a pending order expires after it.
|
|
2426
2104
|
* @nullable
|
|
2427
2105
|
*/
|
|
2428
2106
|
expires_at?: string | null;
|
|
2429
2107
|
/**
|
|
2430
|
-
* When the discount and amount were fixed: at placement for automatic checkout
|
|
2431
|
-
* zero total, otherwise when the invoice was first paid. Null while a deferred order awaits payment.
|
|
2108
|
+
* When the discount and amount were fixed: at placement for automatic checkout or a zero total, otherwise when the invoice was first paid. Null while a deferred order awaits payment.
|
|
2432
2109
|
* @nullable
|
|
2433
2110
|
*/
|
|
2434
2111
|
checkout_confirmed_at?: string | null;
|
|
2435
2112
|
created_at: string;
|
|
2436
|
-
/**
|
|
2437
|
-
* What was bought. Present on a single order and on every order in a list, so a list
|
|
2438
|
-
* can be rendered without a further request per row.
|
|
2439
|
-
*/
|
|
2113
|
+
/** What was bought. */
|
|
2440
2114
|
items: OrderItem[];
|
|
2441
2115
|
}
|
|
2442
2116
|
export interface OrderList {
|
|
@@ -2444,8 +2118,7 @@ export interface OrderList {
|
|
|
2444
2118
|
pagination: OffsetPagination;
|
|
2445
2119
|
}
|
|
2446
2120
|
/**
|
|
2447
|
-
* `scheduled` before valid_from, `active` within the validity, `expired` after valid_until, or
|
|
2448
|
-
* `voided` once Leaflow withdrew it.
|
|
2121
|
+
* `scheduled` before valid_from, `active` within the validity, `expired` after valid_until, or `voided` once withdrawn.
|
|
2449
2122
|
*/
|
|
2450
2123
|
export type DiscountStatus = (typeof DiscountStatus)[keyof typeof DiscountStatus];
|
|
2451
2124
|
export declare const DiscountStatus: {
|
|
@@ -2462,9 +2135,7 @@ export declare const DiscountType: {
|
|
|
2462
2135
|
readonly free_setup: "free_setup";
|
|
2463
2136
|
};
|
|
2464
2137
|
/**
|
|
2465
|
-
* Whether the discount continues on renewals
|
|
2466
|
-
* purchase or renewal that uses the coupon, `recurring` continues for `frequency_duration` billing
|
|
2467
|
-
* periods including the first, and `forever` continues on every renewal.
|
|
2138
|
+
* Whether the discount continues on renewals: `once` applies only to the purchase or renewal using the coupon, `recurring` for `frequency_duration` periods including the first, `forever` on every renewal.
|
|
2468
2139
|
*/
|
|
2469
2140
|
export type DiscountFrequency = (typeof DiscountFrequency)[keyof typeof DiscountFrequency];
|
|
2470
2141
|
export declare const DiscountFrequency: {
|
|
@@ -2473,26 +2144,18 @@ export declare const DiscountFrequency: {
|
|
|
2473
2144
|
readonly forever: "forever";
|
|
2474
2145
|
};
|
|
2475
2146
|
/**
|
|
2476
|
-
* A coupon held
|
|
2477
|
-
* to metered usage that the coupon covers.
|
|
2147
|
+
* A coupon held by the account for a period, applying without a code to the purchases and metered usage it covers.
|
|
2478
2148
|
*/
|
|
2479
2149
|
export interface Discount {
|
|
2480
2150
|
min_amount?: string;
|
|
2481
2151
|
billing_account_id?: number;
|
|
2482
2152
|
coupon_id: string;
|
|
2483
2153
|
promotion_code_id?: string;
|
|
2484
|
-
/**
|
|
2485
|
-
* `scheduled` before valid_from, `active` within the validity, `expired` after valid_until, or
|
|
2486
|
-
* `voided` once Leaflow withdrew it.
|
|
2487
|
-
*/
|
|
2154
|
+
/** `scheduled` before valid_from, `active` within the validity, `expired` after valid_until, or `voided` once withdrawn. */
|
|
2488
2155
|
status: DiscountStatus;
|
|
2489
2156
|
voided_at?: string;
|
|
2490
2157
|
type: DiscountType;
|
|
2491
|
-
/**
|
|
2492
|
-
* Whether the discount continues on renewals of the purchased item. `once` applies only to the
|
|
2493
|
-
* purchase or renewal that uses the coupon, `recurring` continues for `frequency_duration` billing
|
|
2494
|
-
* periods including the first, and `forever` continues on every renewal.
|
|
2495
|
-
*/
|
|
2158
|
+
/** Whether the discount continues on renewals: `once` applies only to the purchase or renewal using the coupon, `recurring` for `frequency_duration` periods including the first, `forever` on every renewal. */
|
|
2496
2159
|
frequency?: DiscountFrequency;
|
|
2497
2160
|
/** @minimum 1 */
|
|
2498
2161
|
frequency_duration?: number;
|
|
@@ -2504,10 +2167,7 @@ export interface Discount {
|
|
|
2504
2167
|
/** Caps a percentage discount. */
|
|
2505
2168
|
max_discount?: Money;
|
|
2506
2169
|
currency?: string;
|
|
2507
|
-
/**
|
|
2508
|
-
* What it may be used for. Absent means it applies to anything on the account,
|
|
2509
|
-
* including setup fees and traffic.
|
|
2510
|
-
*/
|
|
2170
|
+
/** What it may pay for. Absent means anything on the account, including setup fees and usage. */
|
|
2511
2171
|
applies_to: Applicability;
|
|
2512
2172
|
/** Restricted to your first purchase of anything it applies to. */
|
|
2513
2173
|
first_purchase_only?: boolean;
|
|
@@ -2527,7 +2187,7 @@ export interface OrderItemList {
|
|
|
2527
2187
|
pagination: OffsetPagination;
|
|
2528
2188
|
}
|
|
2529
2189
|
/**
|
|
2530
|
-
* Whether the quantity was paid for or granted free
|
|
2190
|
+
* Whether the quantity was paid for or granted free; both are consumed the same way.
|
|
2531
2191
|
*/
|
|
2532
2192
|
export type AllowanceCategory = (typeof AllowanceCategory)[keyof typeof AllowanceCategory];
|
|
2533
2193
|
export declare const AllowanceCategory: {
|
|
@@ -2558,7 +2218,7 @@ export interface Allowance {
|
|
|
2558
2218
|
meter: ObjectIdentity;
|
|
2559
2219
|
/** The unit it is counted in, such as `MiB`. */
|
|
2560
2220
|
unit?: string;
|
|
2561
|
-
/** Whether the quantity was paid for or granted free
|
|
2221
|
+
/** Whether the quantity was paid for or granted free; both are consumed the same way. */
|
|
2562
2222
|
category: AllowanceCategory;
|
|
2563
2223
|
/**
|
|
2564
2224
|
* Exact values for a subset of the meter's dimensions. Only usage with these values is deducted;
|
|
@@ -2570,16 +2230,12 @@ export interface Allowance {
|
|
|
2570
2230
|
quantity: string;
|
|
2571
2231
|
/** How much is left. */
|
|
2572
2232
|
remaining_quantity: string;
|
|
2573
|
-
/**
|
|
2574
|
-
* Lower values are consumed first. At equal priority, earlier expiry and then earlier issuance take
|
|
2575
|
-
* precedence.
|
|
2576
|
-
*/
|
|
2233
|
+
/** Lower values are consumed first; at equal priority, earlier expiry and then earlier issuance. */
|
|
2577
2234
|
priority?: number;
|
|
2578
2235
|
status: AllowanceStatus;
|
|
2579
2236
|
valid_from: string;
|
|
2580
2237
|
/**
|
|
2581
|
-
* When
|
|
2582
|
-
* not carry over. Absent when it does not expire on its own.
|
|
2238
|
+
* When the allowance lapses; unused quantity is lost. Absent when it does not expire.
|
|
2583
2239
|
* @nullable
|
|
2584
2240
|
*/
|
|
2585
2241
|
valid_until?: string | null;
|
|
@@ -2622,8 +2278,7 @@ export interface Entitlement {
|
|
|
2622
2278
|
name?: string;
|
|
2623
2279
|
enabled: boolean;
|
|
2624
2280
|
/**
|
|
2625
|
-
* When the
|
|
2626
|
-
* has no end date.
|
|
2281
|
+
* When the providing subscription ends. Absent for a metered subscription.
|
|
2627
2282
|
* @nullable
|
|
2628
2283
|
*/
|
|
2629
2284
|
expires_at?: string | null;
|
|
@@ -2656,30 +2311,7 @@ export interface PlanList {
|
|
|
2656
2311
|
pagination: OffsetPagination;
|
|
2657
2312
|
}
|
|
2658
2313
|
/**
|
|
2659
|
-
* `
|
|
2660
|
-
* charges once.
|
|
2661
|
-
*/
|
|
2662
|
-
export type PriceType = (typeof PriceType)[keyof typeof PriceType];
|
|
2663
|
-
export declare const PriceType: {
|
|
2664
|
-
readonly postpaid: "postpaid";
|
|
2665
|
-
readonly prepaid: "prepaid";
|
|
2666
|
-
readonly one_time: "one_time";
|
|
2667
|
-
};
|
|
2668
|
-
/**
|
|
2669
|
-
* How the amount is arrived at. `rated` means the rate depends on attributes such as
|
|
2670
|
-
* region or machine type, and is looked up on a price list.
|
|
2671
|
-
*/
|
|
2672
|
-
export type PriceBillingScheme = (typeof PriceBillingScheme)[keyof typeof PriceBillingScheme];
|
|
2673
|
-
export declare const PriceBillingScheme: {
|
|
2674
|
-
readonly per_unit: "per_unit";
|
|
2675
|
-
readonly tiered: "tiered";
|
|
2676
|
-
readonly rated: "rated";
|
|
2677
|
-
};
|
|
2678
|
-
/**
|
|
2679
|
-
* `none` for a price that is not tiered, which is most of them.
|
|
2680
|
-
*
|
|
2681
|
-
* Otherwise `graduated` charges each band at its own rate, and `volume` charges
|
|
2682
|
-
* everything at the rate of the band the total falls in.
|
|
2314
|
+
* How a ladder is walked: `graduated` charges each band at its own rate, `volume` charges everything at the rate of the band the total falls in. `none` when not tiered.
|
|
2683
2315
|
*/
|
|
2684
2316
|
export type PriceTiersMode = (typeof PriceTiersMode)[keyof typeof PriceTiersMode];
|
|
2685
2317
|
export declare const PriceTiersMode: {
|
|
@@ -2696,7 +2328,7 @@ export declare const PriceInterval: {
|
|
|
2696
2328
|
};
|
|
2697
2329
|
export interface Tier {
|
|
2698
2330
|
/**
|
|
2699
|
-
* The upper bound
|
|
2331
|
+
* The band's inclusive upper bound; null for the last band.
|
|
2700
2332
|
* @nullable
|
|
2701
2333
|
*/
|
|
2702
2334
|
up_to?: string | null;
|
|
@@ -2709,6 +2341,7 @@ export interface Price {
|
|
|
2709
2341
|
lookup_key?: string;
|
|
2710
2342
|
product: Product;
|
|
2711
2343
|
plan: ObjectIdentity;
|
|
2344
|
+
/** For a metered price with its own amounts, the meter it charges. For a licensed price, the meter its quantity is held on. Absent otherwise. */
|
|
2712
2345
|
meter_id?: string;
|
|
2713
2346
|
meter?: ObjectIdentity;
|
|
2714
2347
|
unit_quantity: string;
|
|
@@ -2720,39 +2353,25 @@ export interface Price {
|
|
|
2720
2353
|
id: string;
|
|
2721
2354
|
plan_id: string;
|
|
2722
2355
|
currency: string;
|
|
2723
|
-
/**
|
|
2724
|
-
* `postpaid` charges for what is used, `prepaid` buys a period in advance, `one_time`
|
|
2725
|
-
* charges once.
|
|
2726
|
-
*/
|
|
2727
2356
|
type: PriceType;
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
*/
|
|
2732
|
-
billing_scheme: PriceBillingScheme;
|
|
2357
|
+
usage_type: UsageType;
|
|
2358
|
+
/** Absent when the price delegates to a rate card, where the rate depends on attributes such as region or machine type. */
|
|
2359
|
+
billing_scheme?: BillingScheme;
|
|
2733
2360
|
/** Present for `per_unit`. */
|
|
2734
2361
|
unit_amount?: Money;
|
|
2735
|
-
/**
|
|
2736
|
-
* `none` for a price that is not tiered, which is most of them.
|
|
2737
|
-
*
|
|
2738
|
-
* Otherwise `graduated` charges each band at its own rate, and `volume` charges
|
|
2739
|
-
* everything at the rate of the band the total falls in.
|
|
2740
|
-
*/
|
|
2362
|
+
/** How a ladder is walked: `graduated` charges each band at its own rate, `volume` charges everything at the rate of the band the total falls in. `none` when not tiered. */
|
|
2741
2363
|
tiers_mode?: PriceTiersMode;
|
|
2742
2364
|
/** Present for `tiered`, in ascending order. */
|
|
2743
2365
|
tiers?: Tier[];
|
|
2744
|
-
/**
|
|
2366
|
+
/** Present when the price delegates to a rate card, the price list its rates are read from. */
|
|
2745
2367
|
rate_card_id?: string;
|
|
2746
2368
|
/** The smallest quantity that can be bought. Absent means no lower bound. */
|
|
2747
2369
|
min_quantity?: string;
|
|
2748
|
-
/**
|
|
2749
|
-
* The largest purchasable quantity. Omitted when no maximum applies. A quantity above this limit is
|
|
2750
|
-
* rejected with BILLING_PRICE_INVALID and field=max_quantity.
|
|
2751
|
-
*/
|
|
2370
|
+
/** The largest quantity that may be bought; absent when there is no limit. A larger quantity is refused with `BILLING_PRICE_INVALID` and `field` `max_quantity`. */
|
|
2752
2371
|
max_quantity?: string;
|
|
2753
2372
|
/** Quantities must be a multiple of this. Absent means any quantity within the bounds. */
|
|
2754
2373
|
quantity_step?: string;
|
|
2755
|
-
/** For
|
|
2374
|
+
/** For recurring licensed prices, how many interval units one period covers. */
|
|
2756
2375
|
interval_count?: number;
|
|
2757
2376
|
interval: PriceInterval;
|
|
2758
2377
|
setup_fee?: Money;
|
|
@@ -2762,18 +2381,20 @@ export interface PriceList {
|
|
|
2762
2381
|
pagination: OffsetPagination;
|
|
2763
2382
|
}
|
|
2764
2383
|
/**
|
|
2765
|
-
* The
|
|
2384
|
+
* The dimension values this rate applies to, such as region and machine type.
|
|
2766
2385
|
*/
|
|
2767
2386
|
export type RateDimensions = {
|
|
2768
2387
|
[key: string]: string;
|
|
2769
2388
|
};
|
|
2770
2389
|
/**
|
|
2771
|
-
*
|
|
2390
|
+
* Licensed rates only, the period the amount buys; `none` for metered rates.
|
|
2772
2391
|
*/
|
|
2773
|
-
export type
|
|
2774
|
-
export declare const
|
|
2775
|
-
readonly
|
|
2776
|
-
readonly
|
|
2392
|
+
export type RateInterval = (typeof RateInterval)[keyof typeof RateInterval];
|
|
2393
|
+
export declare const RateInterval: {
|
|
2394
|
+
readonly none: "none";
|
|
2395
|
+
readonly day: "day";
|
|
2396
|
+
readonly month: "month";
|
|
2397
|
+
readonly year: "year";
|
|
2777
2398
|
};
|
|
2778
2399
|
/**
|
|
2779
2400
|
* `graduated` charges each band at its own rate; `volume` charges everything at the rate of the band the total lands in. `none` for a `per_unit` rate.
|
|
@@ -2786,22 +2407,24 @@ export declare const RateTiersMode: {
|
|
|
2786
2407
|
};
|
|
2787
2408
|
export interface Rate {
|
|
2788
2409
|
meter: ObjectIdentity;
|
|
2789
|
-
/** The unit readings
|
|
2410
|
+
/** The unit readings are reported in, such as `core-second`. */
|
|
2790
2411
|
unit?: string;
|
|
2791
|
-
/** The
|
|
2412
|
+
/** The dimension values this rate applies to, such as region and machine type. */
|
|
2792
2413
|
dimensions: RateDimensions;
|
|
2793
|
-
|
|
2794
|
-
|
|
2414
|
+
billing_scheme: BillingScheme;
|
|
2415
|
+
/** `metered` prices usage; `licensed` prices holding a quantity for one period. */
|
|
2416
|
+
usage_type: UsageType;
|
|
2417
|
+
/** Licensed rates only, the period the amount buys; `none` for metered rates. */
|
|
2418
|
+
interval: RateInterval;
|
|
2419
|
+
/** @nullable */
|
|
2420
|
+
interval_count?: number | null;
|
|
2795
2421
|
/** `graduated` charges each band at its own rate; `volume` charges everything at the rate of the band the total lands in. `none` for a `per_unit` rate. */
|
|
2796
2422
|
tiers_mode: RateTiersMode;
|
|
2797
2423
|
/** Present for `per_unit`. Tiered rates carry their amounts on the tiers. */
|
|
2798
2424
|
unit_amount?: Money;
|
|
2799
2425
|
/** Present for a tiered rate, in ascending order. */
|
|
2800
2426
|
tiers?: Tier[];
|
|
2801
|
-
/**
|
|
2802
|
-
* How many measured units one amount covers. An hourly rate on a per-second meter is
|
|
2803
|
-
* `"3600"`.
|
|
2804
|
-
*/
|
|
2427
|
+
/** How many measured units one amount covers; an hourly rate on a per-second meter is `"3600"`. */
|
|
2805
2428
|
unit_quantity?: string;
|
|
2806
2429
|
currency: string;
|
|
2807
2430
|
effective_from: string;
|
|
@@ -2812,15 +2435,6 @@ export interface RateList {
|
|
|
2812
2435
|
items: Rate[];
|
|
2813
2436
|
pagination: OffsetPagination;
|
|
2814
2437
|
}
|
|
2815
|
-
/**
|
|
2816
|
-
* Narrows the selection when a plan offers more than one charge type.
|
|
2817
|
-
*/
|
|
2818
|
-
export type QuoteItemInputPriceType = (typeof QuoteItemInputPriceType)[keyof typeof QuoteItemInputPriceType];
|
|
2819
|
-
export declare const QuoteItemInputPriceType: {
|
|
2820
|
-
readonly postpaid: "postpaid";
|
|
2821
|
-
readonly prepaid: "prepaid";
|
|
2822
|
-
readonly one_time: "one_time";
|
|
2823
|
-
};
|
|
2824
2438
|
export type QuoteItemInputInterval = (typeof QuoteItemInputInterval)[keyof typeof QuoteItemInputInterval];
|
|
2825
2439
|
export declare const QuoteItemInputInterval: {
|
|
2826
2440
|
readonly none: "none";
|
|
@@ -2829,23 +2443,13 @@ export declare const QuoteItemInputInterval: {
|
|
|
2829
2443
|
readonly year: "year";
|
|
2830
2444
|
};
|
|
2831
2445
|
/**
|
|
2832
|
-
* The
|
|
2833
|
-
*
|
|
2834
|
-
* Required when the price draws its rates from a price list, which is how anything
|
|
2835
|
-
* sold by region or by machine type is priced. A price that carries a single unit
|
|
2836
|
-
* amount, or a ladder, has no attributes to give and takes none.
|
|
2837
|
-
*
|
|
2838
|
-
* Every attribute the meter declares must be present. A combination with no rate
|
|
2839
|
-
* covering it is refused rather than priced at zero.
|
|
2446
|
+
* The dimension values the rate depends on, such as region, instance type or token kind: those of the usage for a metered estimate, and those of what is bought for a licensed price on a rate card. Required whenever the price uses a rate card; prices with their own amounts ignore them. Every key the meter declares must be given. A combination no rate covers is refused rather than priced at zero.
|
|
2840
2447
|
*/
|
|
2841
2448
|
export type QuoteItemInputDimensions = {
|
|
2842
2449
|
[key: string]: string;
|
|
2843
2450
|
};
|
|
2844
2451
|
/**
|
|
2845
|
-
* Identify a price
|
|
2846
|
-
* key, never both. Lookup keys require product_id. Meter, dimensions or duration_seconds request a
|
|
2847
|
-
* postpaid usage estimate. Such an estimate cannot be combined with a promotion code or treated as a
|
|
2848
|
-
* checkout amount. Without a usage estimate, a postpaid item includes only any setup charge.
|
|
2452
|
+
* Identify a price, or select one for a plan; give each resource's ID or lookup key, never both, and product_id with lookup keys. For a metered price, a meter or duration_seconds requests a usage estimate, which cannot be combined with a promotion code and is not a checkout amount. Without one, a metered item includes only any setup charge.
|
|
2849
2453
|
*/
|
|
2850
2454
|
export interface QuoteItemInput {
|
|
2851
2455
|
/**
|
|
@@ -2861,12 +2465,14 @@ export interface QuoteItemInput {
|
|
|
2861
2465
|
price_id?: string;
|
|
2862
2466
|
product_id?: ProductID;
|
|
2863
2467
|
plan_id?: string;
|
|
2864
|
-
/** Narrows the selection when a plan offers more than one
|
|
2865
|
-
price_type?:
|
|
2468
|
+
/** Narrows the selection when a plan offers more than one price type. */
|
|
2469
|
+
price_type?: PriceType;
|
|
2470
|
+
/** Narrows the selection when a plan offers more than one usage type. */
|
|
2471
|
+
usage_type?: UsageType;
|
|
2866
2472
|
interval?: QuoteItemInputInterval;
|
|
2867
2473
|
/** @minimum 1 */
|
|
2868
2474
|
interval_count?: number;
|
|
2869
|
-
/** Selects among
|
|
2475
|
+
/** Selects among licensed prices with otherwise identical billing terms. Ambiguous terms are refused instead of choosing a price arbitrarily. */
|
|
2870
2476
|
termination_policy?: TerminationPolicy;
|
|
2871
2477
|
/** @pattern ^(?:(?:[1-9][0-9]{0,27}|0(?:[1-9][0-9]{0,26}|0(?:[1-9][0-9]{0,25}|0(?:[1-9][0-9]{0,24}|0(?:[1-9][0-9]{0,23}|0(?:[1-9][0-9]{0,22}|0(?:[1-9][0-9]{0,21}|0(?:[1-9][0-9]{0,20}|0(?:[1-9][0-9]{0,19}|0(?:[1-9][0-9]{0,18}|0(?:[1-9][0-9]{0,17}|0(?:[1-9][0-9]{0,16}|0(?:[1-9][0-9]{0,15}|0(?:[1-9][0-9]{0,14}|0(?:[1-9][0-9]{0,13}|0(?:[1-9][0-9]{0,12}|0(?:[1-9][0-9]{0,11}|0(?:[1-9][0-9]{0,10}|0(?:[1-9][0-9]{0,9}|0(?:[1-9][0-9]{0,8}|0(?:[1-9][0-9]{0,7}|0(?:[1-9][0-9]{0,6}|0(?:[1-9][0-9]{0,5}|0(?:[1-9][0-9]{0,4}|0(?:[1-9][0-9]{0,3}|0(?:[1-9][0-9]{0,2}|0(?:[1-9][0-9]{0,1}|0[1-9])))))))))))))))))))))))))))([.][0-9]{1,10})?|0{1,28}[.](?:[1-9][0-9]{0,9}|0(?:[1-9][0-9]{0,8}|0(?:[1-9][0-9]{0,7}|0(?:[1-9][0-9]{0,6}|0(?:[1-9][0-9]{0,5}|0(?:[1-9][0-9]{0,4}|0(?:[1-9][0-9]{0,3}|0(?:[1-9][0-9]{0,2}|0(?:[1-9][0-9]{0,1}|0[1-9]))))))))))$ */
|
|
2872
2478
|
quantity: string;
|
|
@@ -2876,36 +2482,37 @@ export interface QuoteItemInput {
|
|
|
2876
2482
|
* @maxLength 128
|
|
2877
2483
|
*/
|
|
2878
2484
|
meter_lookup_key?: string;
|
|
2879
|
-
/**
|
|
2880
|
-
* The attributes the price depends on — region, instance type, token class.
|
|
2881
|
-
*
|
|
2882
|
-
* Required when the price draws its rates from a price list, which is how anything
|
|
2883
|
-
* sold by region or by machine type is priced. A price that carries a single unit
|
|
2884
|
-
* amount, or a ladder, has no attributes to give and takes none.
|
|
2885
|
-
*
|
|
2886
|
-
* Every attribute the meter declares must be present. A combination with no rate
|
|
2887
|
-
* covering it is refused rather than priced at zero.
|
|
2888
|
-
*/
|
|
2485
|
+
/** The dimension values the rate depends on, such as region, instance type or token kind: those of the usage for a metered estimate, and those of what is bought for a licensed price on a rate card. Required whenever the price uses a rate card; prices with their own amounts ignore them. Every key the meter declares must be given. A combination no rate covers is refused rather than priced at zero. */
|
|
2889
2486
|
dimensions?: QuoteItemInputDimensions;
|
|
2890
|
-
/**
|
|
2891
|
-
* For metered items, how long to price for. This allows an estimate such as "about
|
|
2892
|
-
* this much per month" to be shown before anything exists. The priced quantity is
|
|
2893
|
-
* `quantity` multiplied by this duration.
|
|
2894
|
-
*/
|
|
2487
|
+
/** For a metered estimate, how long to price for, in seconds; the priced quantity is `quantity` times this duration. */
|
|
2895
2488
|
duration_seconds?: number;
|
|
2896
2489
|
}
|
|
2490
|
+
/**
|
|
2491
|
+
* The values of the meter's presentation dimensions, present only when grouped by meter.
|
|
2492
|
+
*/
|
|
2493
|
+
export type SpendRowDimensions = {
|
|
2494
|
+
[key: string]: string;
|
|
2495
|
+
};
|
|
2897
2496
|
export interface SpendRow {
|
|
2898
2497
|
product?: Product;
|
|
2899
2498
|
plan_id?: string;
|
|
2900
2499
|
plan_name?: string;
|
|
2901
2500
|
/** Present only when grouped by resource. */
|
|
2902
2501
|
resource_id?: string;
|
|
2502
|
+
/** Present only when grouped by meter. */
|
|
2503
|
+
meter?: ObjectIdentity;
|
|
2504
|
+
/** Present only when grouped by meter. */
|
|
2505
|
+
unit?: string;
|
|
2506
|
+
/** Net usage quantity, present only when grouped by meter. */
|
|
2507
|
+
quantity?: string;
|
|
2508
|
+
/** The values of the meter's presentation dimensions, present only when grouped by meter. */
|
|
2509
|
+
dimensions?: SpendRowDimensions;
|
|
2903
2510
|
amount: Money;
|
|
2904
2511
|
currency: string;
|
|
2905
2512
|
}
|
|
2906
2513
|
export interface SpendRowList {
|
|
2907
2514
|
items: SpendRow[];
|
|
2908
|
-
/** The
|
|
2515
|
+
/** The total over all matching groups, not only the page returned. */
|
|
2909
2516
|
total: Money;
|
|
2910
2517
|
currency: string;
|
|
2911
2518
|
pagination: OffsetPagination;
|
|
@@ -2921,28 +2528,28 @@ export declare const ActiveResourceStatus: {
|
|
|
2921
2528
|
readonly closed: "closed";
|
|
2922
2529
|
};
|
|
2923
2530
|
/**
|
|
2924
|
-
* A resource
|
|
2531
|
+
* A resource charged continuously by the second.
|
|
2925
2532
|
*/
|
|
2926
2533
|
export interface ActiveResource {
|
|
2927
2534
|
id: string;
|
|
2928
2535
|
ended_at?: string;
|
|
2929
2536
|
suspended_at?: string;
|
|
2930
2537
|
state_changed_at?: string;
|
|
2931
|
-
/** The
|
|
2538
|
+
/** The metered subscription charged for this metering record. */
|
|
2932
2539
|
subscription_id: string;
|
|
2933
2540
|
resource_id: string;
|
|
2934
2541
|
product: Product;
|
|
2935
|
-
/**
|
|
2542
|
+
/** The resource type, as the owning service names it. */
|
|
2936
2543
|
resource_type?: string;
|
|
2937
2544
|
meter: ObjectIdentity;
|
|
2938
2545
|
unit?: string;
|
|
2939
|
-
/** How much is held
|
|
2546
|
+
/** How much is held, such as cores, MiB or cards; not how much was used. */
|
|
2940
2547
|
quantity: string;
|
|
2941
2548
|
dimensions?: ActiveResourceDimensions;
|
|
2942
2549
|
status: ActiveResourceStatus;
|
|
2943
2550
|
started_at: string;
|
|
2944
2551
|
project_id?: string;
|
|
2945
|
-
/** Usage has been generated up to this boundary; it
|
|
2552
|
+
/** Usage has been generated up to this boundary; it says nothing about invoicing or payment. */
|
|
2946
2553
|
usage_generated_until: string;
|
|
2947
2554
|
}
|
|
2948
2555
|
export interface ActiveResourceList {
|
|
@@ -2950,7 +2557,7 @@ export interface ActiveResourceList {
|
|
|
2950
2557
|
pagination: OffsetPagination;
|
|
2951
2558
|
}
|
|
2952
2559
|
/**
|
|
2953
|
-
* An estimate of the refundable value of
|
|
2560
|
+
* An estimate of the refundable value of an order or selected items; nothing is canceled or refunded.
|
|
2954
2561
|
*/
|
|
2955
2562
|
export interface OrderRefundQuoteInput {
|
|
2956
2563
|
order_id: string;
|
|
@@ -2962,33 +2569,24 @@ export interface OrderRefundQuoteInput {
|
|
|
2962
2569
|
order_item_ids?: string[];
|
|
2963
2570
|
}
|
|
2964
2571
|
/**
|
|
2965
|
-
*
|
|
2966
|
-
* refund. All targets use the specified billing account. Nothing is saved, charged, reserved or
|
|
2967
|
-
* canceled. Promotion codes apply only to a purchase basket or an existing order. An invalid
|
|
2968
|
-
* combination returns BILLING_PURCHASE_INVALID with the offending field."
|
|
2572
|
+
* Quote exactly one target for the billing account: proposed items, an existing order, renewals, a cancellation or an order refund. Promotion codes apply only to proposed items or an existing order. An invalid combination fails with `BILLING_PURCHASE_INVALID` and the field.
|
|
2969
2573
|
*/
|
|
2970
2574
|
export interface QuoteRequest {
|
|
2971
2575
|
/**
|
|
2972
|
-
* The billing account to price for
|
|
2973
|
-
* with this account; renewals and cancellations must currently be paid for by it.
|
|
2576
|
+
* The billing account to price for; it must be yours. Existing orders must have been placed with it, and renewals and cancellations must currently be paid by it.
|
|
2974
2577
|
* @minimum 1
|
|
2975
2578
|
*/
|
|
2976
2579
|
billing_account_id: number;
|
|
2977
2580
|
/**
|
|
2978
|
-
* A proposed purchase priced in the account currency. Metered items may
|
|
2979
|
-
* quantities; those estimates are not amounts collectible at checkout.
|
|
2581
|
+
* A proposed purchase priced in the account's currency. Metered items may include usage estimates, which are not checkout amounts.
|
|
2980
2582
|
* @minItems 1
|
|
2981
2583
|
* @maxItems 100
|
|
2982
2584
|
*/
|
|
2983
2585
|
items?: QuoteItemInput[];
|
|
2984
|
-
/**
|
|
2985
|
-
* Preview paying this existing order. Its recorded purchase terms supply every line, and an order
|
|
2986
|
-
* whose terms are fixed returns its recorded amounts. A preview does not change the order.
|
|
2987
|
-
*/
|
|
2586
|
+
/** Preview paying this order. Its recorded terms supply every line, and an order whose terms are fixed returns its recorded amounts. The order does not change. */
|
|
2988
2587
|
order_id?: string;
|
|
2989
2588
|
/**
|
|
2990
|
-
* Preview renewing these subscriptions, each at most once
|
|
2991
|
-
* renewal order. To preview a new promotion code, create a renewal order and quote it by order_id.
|
|
2589
|
+
* Preview renewing these subscriptions, each at most once; each entry is a separate renewal order. To preview a promotion code, create a renewal order and quote it by order_id.
|
|
2992
2590
|
* @minItems 1
|
|
2993
2591
|
* @maxItems 100
|
|
2994
2592
|
*/
|
|
@@ -3002,9 +2600,7 @@ export interface QuoteRequest {
|
|
|
3002
2600
|
refund?: OrderRefundQuoteInput;
|
|
3003
2601
|
}
|
|
3004
2602
|
/**
|
|
3005
|
-
* How tax applies to the customer, as in Stripe
|
|
3006
|
-
* `reverse` charges no tax and leaves it to the customer under the reverse-charge mechanism;
|
|
3007
|
-
* invoices state this. Only operators change it.
|
|
2603
|
+
* How tax applies to the customer, as in Stripe: `none` taxes normally, `exempt` charges no tax, `reverse` charges no tax under the reverse-charge mechanism, stated on invoices. Only operators change it.
|
|
3008
2604
|
*/
|
|
3009
2605
|
export type ContactTaxExempt = (typeof ContactTaxExempt)[keyof typeof ContactTaxExempt];
|
|
3010
2606
|
export declare const ContactTaxExempt: {
|
|
@@ -3013,7 +2609,7 @@ export declare const ContactTaxExempt: {
|
|
|
3013
2609
|
readonly reverse: "reverse";
|
|
3014
2610
|
};
|
|
3015
2611
|
/**
|
|
3016
|
-
* A billing
|
|
2612
|
+
* A contact of a billing account with one address. An account can hold several; a contact is not a login.
|
|
3017
2613
|
*/
|
|
3018
2614
|
export interface Contact {
|
|
3019
2615
|
id: string;
|
|
@@ -3041,11 +2637,7 @@ export interface Contact {
|
|
|
3041
2637
|
address_postal_code?: string;
|
|
3042
2638
|
/** @pattern ^([A-Z]{2})?$ */
|
|
3043
2639
|
address_country?: string;
|
|
3044
|
-
/**
|
|
3045
|
-
* How tax applies to the customer, as in Stripe. `none` taxes normally. `exempt` charges no tax.
|
|
3046
|
-
* `reverse` charges no tax and leaves it to the customer under the reverse-charge mechanism;
|
|
3047
|
-
* invoices state this. Only operators change it.
|
|
3048
|
-
*/
|
|
2640
|
+
/** How tax applies to the customer, as in Stripe: `none` taxes normally, `exempt` charges no tax, `reverse` charges no tax under the reverse-charge mechanism, stated on invoices. Only operators change it. */
|
|
3049
2641
|
tax_exempt: ContactTaxExempt;
|
|
3050
2642
|
active: boolean;
|
|
3051
2643
|
created_at: string;
|
|
@@ -3121,14 +2713,14 @@ export interface StatementAmounts {
|
|
|
3121
2713
|
total: Money;
|
|
3122
2714
|
}
|
|
3123
2715
|
/**
|
|
3124
|
-
* One billing account's usage billing for one UTC calendar month, summed over
|
|
2716
|
+
* One billing account's usage billing for one UTC calendar month, summed over its statements. Not payable itself; each statement's invoice is collected on its own.
|
|
3125
2717
|
*/
|
|
3126
2718
|
export interface MonthlyStatement {
|
|
3127
2719
|
billing_account_id: number;
|
|
3128
2720
|
currency: string;
|
|
3129
2721
|
period_start: string;
|
|
3130
2722
|
period_end: string;
|
|
3131
|
-
/** True after the period's final closing, which applies minimum charges
|
|
2723
|
+
/** True after the period's final closing, which applies the month's minimum charges. Usage priced later is billed in supplement statements and added here. */
|
|
3132
2724
|
finalized: boolean;
|
|
3133
2725
|
finalized_at?: string;
|
|
3134
2726
|
/** Statements of the period, including the open one. */
|
|
@@ -3151,7 +2743,7 @@ export declare const StatementStatus: {
|
|
|
3151
2743
|
readonly closed: "closed";
|
|
3152
2744
|
};
|
|
3153
2745
|
/**
|
|
3154
|
-
* interim
|
|
2746
|
+
* `interim`: a closing before the period's usage is final, without minimum charges. `final`: the first closing after the period ended and its late usage was settled, applying the period's minimum charges. `supplement`: a closing after the final one, for usage priced late. An open statement is interim.
|
|
3155
2747
|
*/
|
|
3156
2748
|
export type StatementType = (typeof StatementType)[keyof typeof StatementType];
|
|
3157
2749
|
export declare const StatementType: {
|
|
@@ -3160,7 +2752,7 @@ export declare const StatementType: {
|
|
|
3160
2752
|
readonly supplement: "supplement";
|
|
3161
2753
|
};
|
|
3162
2754
|
/**
|
|
3163
|
-
* An account's consumption for one billing period
|
|
2755
|
+
* An account's consumption for one billing period up to one closing. Usage is invoiced after every settlement run, about hourly: each closing issues an invoice for the usage priced since the previous one and collects it from credits and balance, and later usage goes into the next statement of the same period. A closed statement does not change. The period's consumption is the sum of its statements.
|
|
3164
2756
|
*/
|
|
3165
2757
|
export interface Statement {
|
|
3166
2758
|
id: string;
|
|
@@ -3172,7 +2764,7 @@ export interface Statement {
|
|
|
3172
2764
|
sequence: number;
|
|
3173
2765
|
status: StatementStatus;
|
|
3174
2766
|
type: StatementType;
|
|
3175
|
-
/** True while the statement is open. The estimate
|
|
2767
|
+
/** True while the statement is open. The estimate prices the period's usage so far at tier prices and adds tax for the current invoice contact. Minimum charges are added at the period's final closing, and a tier reduction larger than this statement's charges is credited to the period's earlier invoices at closing. */
|
|
3176
2768
|
estimated: boolean;
|
|
3177
2769
|
amounts: StatementAmounts;
|
|
3178
2770
|
closed_at?: string;
|
|
@@ -3186,11 +2778,19 @@ export interface StatementList {
|
|
|
3186
2778
|
items: Statement[];
|
|
3187
2779
|
pagination: OffsetPagination;
|
|
3188
2780
|
}
|
|
2781
|
+
/**
|
|
2782
|
+
* The values of the meter's presentation dimensions, such as the model and token kind. Included only when grouping by meter, which splits each meter by these values.
|
|
2783
|
+
*/
|
|
2784
|
+
export type StatementItemDimensions = {
|
|
2785
|
+
[key: string]: string;
|
|
2786
|
+
};
|
|
3189
2787
|
export interface StatementItem {
|
|
3190
2788
|
project_id?: string;
|
|
3191
2789
|
product_id?: string;
|
|
3192
2790
|
meter_id?: string;
|
|
3193
2791
|
unit?: string;
|
|
2792
|
+
/** The values of the meter's presentation dimensions, such as the model and token kind. Included only when grouping by meter, which splits each meter by these values. */
|
|
2793
|
+
dimensions?: StatementItemDimensions;
|
|
3194
2794
|
/** Net usage quantity. Included only when grouping by meter. */
|
|
3195
2795
|
quantity?: string;
|
|
3196
2796
|
deducted_quantity?: string;
|