Payment Preferences
November 13, 2025 ยท View on GitHub
The payment preferences for a subscription.
Structure
PaymentPreferences
Fields
| Name | Type | Tags | Description | Getter | Setter |
|---|---|---|---|---|---|
AutoBillOutstanding | Boolean | Optional | Indicates whether to automatically bill the outstanding amount in the next billing cycle. Default: true | Boolean getAutoBillOutstanding() | setAutoBillOutstanding(Boolean autoBillOutstanding) |
SetupFee | Money | Optional | The currency and amount for a financial transaction, such as a balance or payment due. | Money getSetupFee() | setSetupFee(Money setupFee) |
SetupFeeFailureAction | SetupFeeFailureAction | Optional | The action to take on the subscription if the initial payment for the setup fails. Default: SetupFeeFailureAction.CANCELConstraints: Minimum Length: 1, Maximum Length: 24, Pattern: ^[A-Z_]+$ | SetupFeeFailureAction getSetupFeeFailureAction() | setSetupFeeFailureAction(SetupFeeFailureAction setupFeeFailureAction) |
PaymentFailureThreshold | Integer | Optional | The maximum number of payment failures before a subscription is suspended. For example, if payment_failure_threshold is 2, the subscription automatically updates to the SUSPEND state if two consecutive payments fail.Default: 0Constraints: >= 0, <= 999 | Integer getPaymentFailureThreshold() | setPaymentFailureThreshold(Integer paymentFailureThreshold) |
Example (as JSON)
{
"auto_bill_outstanding": true,
"setup_fee_failure_action": "CANCEL",
"payment_failure_threshold": 0,
"setup_fee": {
"currency_code": "currency_code8",
"value": "value4"
}
}