From e56ea2295b838950811a1bf591d860565111a24e Mon Sep 17 00:00:00 2001 From: "gocardless-ci-robot[bot]" <123969075+gocardless-ci-robot[bot]@users.noreply.github.com> Date: Tue, 16 Jun 2026 13:12:24 +0000 Subject: [PATCH 1/5] Changes generated by c1a246cf193597d4a75b4787fe464fa9d5cbf101 This commit was automatically created from gocardless/client-library-templates@c1a246cf193597d4a75b4787fe464fa9d5cbf101 by the `push-files` action. Workflow run: https://github.com/gocardless/client-library-templates/actions/runs/27619830131 --- .../resources/BillingRequestTemplate.java | 35 +------- .../BillingRequestTemplateService.java | 80 ++----------------- 2 files changed, 9 insertions(+), 106 deletions(-) diff --git a/src/main/java/com/gocardless/resources/BillingRequestTemplate.java b/src/main/java/com/gocardless/resources/BillingRequestTemplate.java index 0dd9d044..332dd013 100644 --- a/src/main/java/com/gocardless/resources/BillingRequestTemplate.java +++ b/src/main/java/com/gocardless/resources/BillingRequestTemplate.java @@ -31,7 +31,7 @@ private BillingRequestTemplate() { private String mandateRequestDescription; private Map mandateRequestMetadata; private String mandateRequestScheme; - private MandateRequestVerify mandateRequestVerify; + private String mandateRequestVerify; private Map metadata; private String name; private String paymentRequestAmount; @@ -108,29 +108,9 @@ public String getMandateRequestScheme() { } /** - * Verification preference for the mandate. One of: - * - * - * By default, all Billing Requests use the `recommended` verification preference. It uses - * GoCardless payment intelligence solution to determine if a payer is fraudulent or not. The - * verification mechanism is based on the response and the payer may be asked to verify - * themselves. If the feature is not available, `recommended` behaves like `minimum`. - * - * If you never wish to take advantage of our reduced risk products and Verified Mandates as - * they are released in new schemes, please use the `minimum` verification preference. - * - * See [Billing Requests: Creating Verified - * Mandates](https://developer.gocardless.com/getting-started/billing-requests/verified-mandates/) - * for more information. + * Verification preference for the mandate. */ - public MandateRequestVerify getMandateRequestVerify() { + public String getMandateRequestVerify() { return mandateRequestVerify; } @@ -210,15 +190,6 @@ public String getUpdatedAt() { return updatedAt; } - public enum MandateRequestVerify { - @SerializedName("minimum") - MINIMUM, @SerializedName("recommended") - RECOMMENDED, @SerializedName("when_available") - WHEN_AVAILABLE, @SerializedName("always") - ALWAYS, @SerializedName("unknown") - UNKNOWN - } - /** * Represents a mandate request constraint resource returned from the API. * diff --git a/src/main/java/com/gocardless/services/BillingRequestTemplateService.java b/src/main/java/com/gocardless/services/BillingRequestTemplateService.java index a30383cb..3f2ecef8 100644 --- a/src/main/java/com/gocardless/services/BillingRequestTemplateService.java +++ b/src/main/java/com/gocardless/services/BillingRequestTemplateService.java @@ -211,7 +211,7 @@ public static final class BillingRequestTemplateCreateRequest private String mandateRequestDescription; private Map mandateRequestMetadata; private String mandateRequestScheme; - private MandateRequestVerify mandateRequestVerify; + private String mandateRequestVerify; private Map metadata; private String name; private String paymentRequestAmount; @@ -377,30 +377,10 @@ public BillingRequestTemplateCreateRequest withMandateRequestScheme( } /** - * Verification preference for the mandate. One of: - *
    - *
  • `minimum`: only verify if absolutely required, such as when part of scheme rules
  • - *
  • `recommended`: in addition to `minimum`, use the GoCardless payment intelligence - * solution to decide if a payer should be verified
  • - *
  • `when_available`: if verification mechanisms are available, use them
  • - *
  • `always`: as `when_available`, but fail to create the Billing Request if a mechanism - * isn't available
  • - *
- * - * By default, all Billing Requests use the `recommended` verification preference. It uses - * GoCardless payment intelligence solution to determine if a payer is fraudulent or not. - * The verification mechanism is based on the response and the payer may be asked to verify - * themselves. If the feature is not available, `recommended` behaves like `minimum`. - * - * If you never wish to take advantage of our reduced risk products and Verified Mandates as - * they are released in new schemes, please use the `minimum` verification preference. - * - * See [Billing Requests: Creating Verified - * Mandates](https://developer.gocardless.com/getting-started/billing-requests/verified-mandates/) - * for more information. + * Verification preference for the mandate. */ public BillingRequestTemplateCreateRequest withMandateRequestVerify( - MandateRequestVerify mandateRequestVerify) { + String mandateRequestVerify) { this.mandateRequestVerify = mandateRequestVerify; return this; } @@ -558,20 +538,6 @@ protected boolean hasBody() { return true; } - public enum MandateRequestVerify { - @SerializedName("minimum") - MINIMUM, @SerializedName("recommended") - RECOMMENDED, @SerializedName("when_available") - WHEN_AVAILABLE, @SerializedName("always") - ALWAYS, @SerializedName("unknown") - UNKNOWN; - - @Override - public String toString() { - return name().toLowerCase(); - } - } - public static class Links { private String creditor; @@ -759,7 +725,7 @@ public static final class BillingRequestTemplateUpdateRequest private String mandateRequestDescription; private Map mandateRequestMetadata; private String mandateRequestScheme; - private MandateRequestVerify mandateRequestVerify; + private String mandateRequestVerify; private Map metadata; private String name; private String paymentRequestAmount; @@ -908,30 +874,10 @@ public BillingRequestTemplateUpdateRequest withMandateRequestScheme( } /** - * Verification preference for the mandate. One of: - *
    - *
  • `minimum`: only verify if absolutely required, such as when part of scheme rules
  • - *
  • `recommended`: in addition to `minimum`, use the GoCardless payment intelligence - * solution to decide if a payer should be verified
  • - *
  • `when_available`: if verification mechanisms are available, use them
  • - *
  • `always`: as `when_available`, but fail to create the Billing Request if a mechanism - * isn't available
  • - *
- * - * By default, all Billing Requests use the `recommended` verification preference. It uses - * GoCardless payment intelligence solution to determine if a payer is fraudulent or not. - * The verification mechanism is based on the response and the payer may be asked to verify - * themselves. If the feature is not available, `recommended` behaves like `minimum`. - * - * If you never wish to take advantage of our reduced risk products and Verified Mandates as - * they are released in new schemes, please use the `minimum` verification preference. - * - * See [Billing Requests: Creating Verified - * Mandates](https://developer.gocardless.com/getting-started/billing-requests/verified-mandates/) - * for more information. + * Verification preference for the mandate. */ public BillingRequestTemplateUpdateRequest withMandateRequestVerify( - MandateRequestVerify mandateRequestVerify) { + String mandateRequestVerify) { this.mandateRequestVerify = mandateRequestVerify; return this; } @@ -1081,20 +1027,6 @@ protected boolean hasBody() { return true; } - public enum MandateRequestVerify { - @SerializedName("minimum") - MINIMUM, @SerializedName("recommended") - RECOMMENDED, @SerializedName("when_available") - WHEN_AVAILABLE, @SerializedName("always") - ALWAYS, @SerializedName("unknown") - UNKNOWN; - - @Override - public String toString() { - return name().toLowerCase(); - } - } - public static class PeriodicLimits { private Alignment alignment; private Integer maxPayments; From 004f405d0ab4ff91cdc961c92ad5da1182c4bb67 Mon Sep 17 00:00:00 2001 From: "gocardless-ci-robot[bot]" <123969075+gocardless-ci-robot[bot]@users.noreply.github.com> Date: Mon, 22 Jun 2026 09:19:28 +0000 Subject: [PATCH 2/5] Changes generated by 893a370c1e1fa2eb153215ac032eb19dbcae5641 This commit was automatically created from gocardless/client-library-templates@893a370c1e1fa2eb153215ac032eb19dbcae5641 by the `push-files` action. Workflow run: https://github.com/gocardless/client-library-templates/actions/runs/27942291534 --- src/main/java/com/gocardless/resources/Export.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/gocardless/resources/Export.java b/src/main/java/com/gocardless/resources/Export.java index fea0bb16..72bcd52c 100644 --- a/src/main/java/com/gocardless/resources/Export.java +++ b/src/main/java/com/gocardless/resources/Export.java @@ -85,7 +85,8 @@ public enum ExportType { GC_INVALID_AUTHORISATION_REQUESTS, @SerializedName("partner_fees") PARTNER_FEES, @SerializedName("payments_import_template") PAYMENTS_IMPORT_TEMPLATE, @SerializedName("payment_account_statement") - PAYMENT_ACCOUNT_STATEMENT, @SerializedName("unknown") + PAYMENT_ACCOUNT_STATEMENT, @SerializedName("outbound_payments_index") + OUTBOUND_PAYMENTS_INDEX, @SerializedName("unknown") UNKNOWN } } From 6c0072c927e8d14b39c71314807591219d4a0a2c Mon Sep 17 00:00:00 2001 From: "gocardless-ci-robot[bot]" <123969075+gocardless-ci-robot[bot]@users.noreply.github.com> Date: Fri, 26 Jun 2026 10:49:35 +0000 Subject: [PATCH 3/5] Changes generated by d97c5f53b394eaa852733dc030b77590b491794c This commit was automatically created from gocardless/client-library-templates@d97c5f53b394eaa852733dc030b77590b491794c by the `push-files` action. Workflow run: https://github.com/gocardless/client-library-templates/actions/runs/28233224258 --- .../gocardless/resources/VerificationDetail.java | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/main/java/com/gocardless/resources/VerificationDetail.java b/src/main/java/com/gocardless/resources/VerificationDetail.java index d0538d52..ff077ed9 100644 --- a/src/main/java/com/gocardless/resources/VerificationDetail.java +++ b/src/main/java/com/gocardless/resources/VerificationDetail.java @@ -23,11 +23,13 @@ private VerificationDetail() { private String addressLine3; private String city; private String companyNumber; + private String countryCode; private String description; private List directors; private Links links; private String name; private String postalCode; + private String region; /** * The first line of the company's address. @@ -64,6 +66,13 @@ public String getCompanyNumber() { return companyNumber; } + /** + * The country code of the company's address. + */ + public String getCountryCode() { + return countryCode; + } + /** * A summary describing what the company does. */ @@ -96,6 +105,13 @@ public String getPostalCode() { return postalCode; } + /** + * The region of the company's address. + */ + public String getRegion() { + return region; + } + /** * Represents a director resource returned from the API. * From d9e2cfe0337863b009a626c2023f9a6304e30994 Mon Sep 17 00:00:00 2001 From: "gocardless-ci-robot[bot]" <123969075+gocardless-ci-robot[bot]@users.noreply.github.com> Date: Tue, 7 Jul 2026 10:45:58 +0000 Subject: [PATCH 4/5] Changes generated by 5bc32e9481786eea9c3d32e230fdacc4a3d47f50 This commit was automatically created from gocardless/client-library-templates@5bc32e9481786eea9c3d32e230fdacc4a3d47f50 by the `push-files` action. Workflow run: https://github.com/gocardless/client-library-templates/actions/runs/28860199162 --- .../gocardless/resources/BillingRequest.java | 52 +++++-- .../resources/BillingRequestTemplate.java | 50 +++++-- .../resources/BillingRequestWithAction.java | 53 +++++-- .../com/gocardless/resources/Payment.java | 3 + .../services/BillingRequestService.java | 55 +++++--- .../BillingRequestTemplateService.java | 132 +++++++++++++----- .../BillingRequestWithActionService.java | 52 ++++--- .../services/InstalmentScheduleService.java | 3 + .../gocardless/services/PaymentService.java | 3 + 9 files changed, 289 insertions(+), 114 deletions(-) diff --git a/src/main/java/com/gocardless/resources/BillingRequest.java b/src/main/java/com/gocardless/resources/BillingRequest.java index ab8bd6a6..7ab9c5ee 100644 --- a/src/main/java/com/gocardless/resources/BillingRequest.java +++ b/src/main/java/com/gocardless/resources/BillingRequest.java @@ -588,6 +588,9 @@ private InstalmentsWithDate() { /** * Amount, in the lowest denomination for the currency (e.g. pence in GBP, cents in * EUR). + * + * For Variable Recurring Payments (VRP), this must not exceed the mandate's + * `max_amount_per_payment` constraint. */ public Integer getAmount() { return amount; @@ -1045,8 +1048,9 @@ public String getEndDate() { } /** - * The maximum amount that can be charged for a single payment. Required for PayTo and - * VRP. + * The maximum amount that can be charged for a single payment in the lowest + * denomination for the currency (e.g. pence in GBP, cents in EUR). _Note:_ Required for + * PayTo and VRP. */ public Integer getMaxAmountPerPayment() { return maxAmountPerPayment; @@ -1054,7 +1058,8 @@ public Integer getMaxAmountPerPayment() { /** * A constraint where you can specify info (free text string) about how payments are - * calculated. _Note:_ This is only supported for ACH and PAD schemes. + * calculated. For use when payments vary and cannot be expressed as a fixed amount and + * frequency. _Note:_ This is only supported for ACH and PAD schemes. * */ public String getPaymentMethod() { @@ -1062,7 +1067,13 @@ public String getPaymentMethod() { } /** - * List of periodic limits and constraints which apply to them + * Caps on the total amount and/or number of payments that can be collected within a + * repeating period (e.g. no more than a set amount per month), as opposed to + * `max_amount_per_payment` which caps a single payment. + * + * _Note:_ Required for VRP, where exactly one periodic limit must be provided. Optional + * for PayTo. + * */ public List getPeriodicLimits() { return periodicLimits; @@ -1095,14 +1106,21 @@ private PeriodicLimit() { private Period period; /** - * The alignment of the period. + * The alignment of the period. Defaults to `creation_date` if not specified. + * + * `calendar` - the period follows fixed calendar boundaries, the same for every + * mandate: `week` runs Monday to Sunday, `month` runs from the 1st to the last day + * of the calendar month, and `year` runs from 1 January to 31 December. If the + * mandate starts partway through a period, the limit for that first period is + * reduced proportionally to the days remaining (e.g. a monthly limit starting on + * the 15th gives roughly half the limit for that first month). * - * `calendar` - this will finish on the end of the current period. For example this - * will expire on the Monday for the current week or the January for the next year. + * `creation_date` - the period follows the mandate's own start date rather than the + * calendar. For example, if the mandate starts on the 15th, each monthly period + * runs from the 15th to the 14th of the following month. The first period is a full + * period, not reduced proportionally. * - * `creation_date` - this will finish on the next instance of the current period. - * For example Monthly it will expire on the same day of the next month, or yearly - * the same day of the next year. + * _Note:_ Has no effect when period is `flexible`. * */ public Alignment getAlignment() { @@ -1111,7 +1129,8 @@ public Alignment getAlignment() { /** * The maximum number of payments that can be collected in this periodic limit. - * _Note:_ This is only supported for the PayTo scheme, where it is required. + * + * _Note:_ Only supported for the PayTo scheme, where it is optional. * */ public Integer getMaxPayments() { @@ -1120,7 +1139,10 @@ public Integer getMaxPayments() { /** * The maximum total amount that can be charged for all payments in this periodic - * limit. Required for VRP. + * limit, in the lowest denomination for the currency (e.g. pence in GBP, cents in + * EUR). + * + * _Note:_ Required for VRP. This is not permitted for the PayTo scheme. * */ public Integer getMaxTotalAmount() { @@ -1128,8 +1150,10 @@ public Integer getMaxTotalAmount() { } /** - * The repeating period for this mandate. Defaults to flexible for PayTo if not - * specified. + * The repeating period for this mandate. Required whenever a periodic limit is + * provided (for both VRP and PayTo). If periodic_limits is omitted entirely for + * PayTo, this defaults to flexible. + * */ public Period getPeriod() { return period; diff --git a/src/main/java/com/gocardless/resources/BillingRequestTemplate.java b/src/main/java/com/gocardless/resources/BillingRequestTemplate.java index 332dd013..453b9c71 100644 --- a/src/main/java/com/gocardless/resources/BillingRequestTemplate.java +++ b/src/main/java/com/gocardless/resources/BillingRequestTemplate.java @@ -220,7 +220,8 @@ public String getEndDate() { } /** - * The maximum amount that can be charged for a single payment. Required for PayTo and VRP. + * The maximum amount that can be charged for a single payment in the lowest denomination + * for the currency (e.g. pence in GBP, cents in EUR). _Note:_ Required for PayTo and VRP. */ public Integer getMaxAmountPerPayment() { return maxAmountPerPayment; @@ -228,7 +229,8 @@ public Integer getMaxAmountPerPayment() { /** * A constraint where you can specify info (free text string) about how payments are - * calculated. _Note:_ This is only supported for ACH and PAD schemes. + * calculated. For use when payments vary and cannot be expressed as a fixed amount and + * frequency. _Note:_ This is only supported for ACH and PAD schemes. * */ public String getPaymentMethod() { @@ -236,7 +238,13 @@ public String getPaymentMethod() { } /** - * List of periodic limits and constraints which apply to them + * Caps on the total amount and/or number of payments that can be collected within a + * repeating period (e.g. no more than a set amount per month), as opposed to + * `max_amount_per_payment` which caps a single payment. + * + * _Note:_ Required for VRP, where exactly one periodic limit must be provided. Optional for + * PayTo. + * */ public List getPeriodicLimits() { return periodicLimits; @@ -269,14 +277,21 @@ private PeriodicLimit() { private Period period; /** - * The alignment of the period. + * The alignment of the period. Defaults to `creation_date` if not specified. + * + * `calendar` - the period follows fixed calendar boundaries, the same for every + * mandate: `week` runs Monday to Sunday, `month` runs from the 1st to the last day of + * the calendar month, and `year` runs from 1 January to 31 December. If the mandate + * starts partway through a period, the limit for that first period is reduced + * proportionally to the days remaining (e.g. a monthly limit starting on the 15th gives + * roughly half the limit for that first month). * - * `calendar` - this will finish on the end of the current period. For example this will - * expire on the Monday for the current week or the January for the next year. + * `creation_date` - the period follows the mandate's own start date rather than the + * calendar. For example, if the mandate starts on the 15th, each monthly period runs + * from the 15th to the 14th of the following month. The first period is a full period, + * not reduced proportionally. * - * `creation_date` - this will finish on the next instance of the current period. For - * example Monthly it will expire on the same day of the next month, or yearly the same - * day of the next year. + * _Note:_ Has no effect when period is `flexible`. * */ public Alignment getAlignment() { @@ -284,8 +299,9 @@ public Alignment getAlignment() { } /** - * The maximum number of payments that can be collected in this periodic limit. _Note:_ - * This is only supported for the PayTo scheme, where it is required. + * The maximum number of payments that can be collected in this periodic limit. + * + * _Note:_ Only supported for the PayTo scheme, where it is optional. * */ public Integer getMaxPayments() { @@ -293,8 +309,10 @@ public Integer getMaxPayments() { } /** - * The maximum total amount that can be charged for all payments in this periodic limit. - * Required for VRP. + * The maximum total amount that can be charged for all payments in this periodic limit, + * in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR). + * + * _Note:_ Required for VRP. This is not permitted for the PayTo scheme. * */ public Integer getMaxTotalAmount() { @@ -302,8 +320,10 @@ public Integer getMaxTotalAmount() { } /** - * The repeating period for this mandate. Defaults to flexible for PayTo if not - * specified. + * The repeating period for this mandate. Required whenever a periodic limit is provided + * (for both VRP and PayTo). If periodic_limits is omitted entirely for PayTo, this + * defaults to flexible. + * */ public Period getPeriod() { return period; diff --git a/src/main/java/com/gocardless/resources/BillingRequestWithAction.java b/src/main/java/com/gocardless/resources/BillingRequestWithAction.java index c7068523..8a961938 100644 --- a/src/main/java/com/gocardless/resources/BillingRequestWithAction.java +++ b/src/main/java/com/gocardless/resources/BillingRequestWithAction.java @@ -790,6 +790,9 @@ private InstalmentsWithDate() { /** * Amount, in the lowest denomination for the currency (e.g. pence in GBP, cents in * EUR). + * + * For Variable Recurring Payments (VRP), this must not exceed the mandate's + * `max_amount_per_payment` constraint. */ public Integer getAmount() { return amount; @@ -1253,8 +1256,9 @@ public String getEndDate() { } /** - * The maximum amount that can be charged for a single payment. Required for PayTo - * and VRP. + * The maximum amount that can be charged for a single payment in the lowest + * denomination for the currency (e.g. pence in GBP, cents in EUR). _Note:_ Required + * for PayTo and VRP. */ public Integer getMaxAmountPerPayment() { return maxAmountPerPayment; @@ -1262,7 +1266,8 @@ public Integer getMaxAmountPerPayment() { /** * A constraint where you can specify info (free text string) about how payments are - * calculated. _Note:_ This is only supported for ACH and PAD schemes. + * calculated. For use when payments vary and cannot be expressed as a fixed amount + * and frequency. _Note:_ This is only supported for ACH and PAD schemes. * */ public String getPaymentMethod() { @@ -1270,7 +1275,13 @@ public String getPaymentMethod() { } /** - * List of periodic limits and constraints which apply to them + * Caps on the total amount and/or number of payments that can be collected within a + * repeating period (e.g. no more than a set amount per month), as opposed to + * `max_amount_per_payment` which caps a single payment. + * + * _Note:_ Required for VRP, where exactly one periodic limit must be provided. + * Optional for PayTo. + * */ public List getPeriodicLimits() { return periodicLimits; @@ -1303,15 +1314,21 @@ private PeriodicLimit() { private Period period; /** - * The alignment of the period. + * The alignment of the period. Defaults to `creation_date` if not specified. + * + * `calendar` - the period follows fixed calendar boundaries, the same for every + * mandate: `week` runs Monday to Sunday, `month` runs from the 1st to the last + * day of the calendar month, and `year` runs from 1 January to 31 December. If + * the mandate starts partway through a period, the limit for that first period + * is reduced proportionally to the days remaining (e.g. a monthly limit + * starting on the 15th gives roughly half the limit for that first month). * - * `calendar` - this will finish on the end of the current period. For example - * this will expire on the Monday for the current week or the January for the - * next year. + * `creation_date` - the period follows the mandate's own start date rather than + * the calendar. For example, if the mandate starts on the 15th, each monthly + * period runs from the 15th to the 14th of the following month. The first + * period is a full period, not reduced proportionally. * - * `creation_date` - this will finish on the next instance of the current - * period. For example Monthly it will expire on the same day of the next month, - * or yearly the same day of the next year. + * _Note:_ Has no effect when period is `flexible`. * */ public Alignment getAlignment() { @@ -1320,7 +1337,8 @@ public Alignment getAlignment() { /** * The maximum number of payments that can be collected in this periodic limit. - * _Note:_ This is only supported for the PayTo scheme, where it is required. + * + * _Note:_ Only supported for the PayTo scheme, where it is optional. * */ public Integer getMaxPayments() { @@ -1329,7 +1347,10 @@ public Integer getMaxPayments() { /** * The maximum total amount that can be charged for all payments in this - * periodic limit. Required for VRP. + * periodic limit, in the lowest denomination for the currency (e.g. pence in + * GBP, cents in EUR). + * + * _Note:_ Required for VRP. This is not permitted for the PayTo scheme. * */ public Integer getMaxTotalAmount() { @@ -1337,8 +1358,10 @@ public Integer getMaxTotalAmount() { } /** - * The repeating period for this mandate. Defaults to flexible for PayTo if not - * specified. + * The repeating period for this mandate. Required whenever a periodic limit is + * provided (for both VRP and PayTo). If periodic_limits is omitted entirely for + * PayTo, this defaults to flexible. + * */ public Period getPeriod() { return period; diff --git a/src/main/java/com/gocardless/resources/Payment.java b/src/main/java/com/gocardless/resources/Payment.java index dc9ea978..0b402a73 100644 --- a/src/main/java/com/gocardless/resources/Payment.java +++ b/src/main/java/com/gocardless/resources/Payment.java @@ -36,6 +36,9 @@ private Payment() { /** * Amount, in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR). + * + * For Variable Recurring Payments (VRP), this must not exceed the mandate's + * `max_amount_per_payment` constraint. */ public Integer getAmount() { return amount; diff --git a/src/main/java/com/gocardless/services/BillingRequestService.java b/src/main/java/com/gocardless/services/BillingRequestService.java index c3ae4839..cfca1b4d 100644 --- a/src/main/java/com/gocardless/services/BillingRequestService.java +++ b/src/main/java/com/gocardless/services/BillingRequestService.java @@ -1041,6 +1041,9 @@ public static class InstalmentsWithDates { /** * Amount, in the lowest denomination for the currency (e.g. pence in GBP, cents in * EUR). + * + * For Variable Recurring Payments (VRP), this must not exceed the mandate's + * `max_amount_per_payment` constraint. */ public InstalmentsWithDates withAmount(Integer amount) { this.amount = amount; @@ -1307,14 +1310,21 @@ public static class PeriodicLimits { private Period period; /** - * The alignment of the period. + * The alignment of the period. Defaults to `creation_date` if not specified. + * + * `calendar` - the period follows fixed calendar boundaries, the same for every + * mandate: `week` runs Monday to Sunday, `month` runs from the 1st to the last day of + * the calendar month, and `year` runs from 1 January to 31 December. If the mandate + * starts partway through a period, the limit for that first period is reduced + * proportionally to the days remaining (e.g. a monthly limit starting on the 15th gives + * roughly half the limit for that first month). * - * `calendar` - this will finish on the end of the current period. For example this will - * expire on the Monday for the current week or the January for the next year. + * `creation_date` - the period follows the mandate's own start date rather than the + * calendar. For example, if the mandate starts on the 15th, each monthly period runs + * from the 15th to the 14th of the following month. The first period is a full period, + * not reduced proportionally. * - * `creation_date` - this will finish on the next instance of the current period. For - * example Monthly it will expire on the same day of the next month, or yearly the same - * day of the next year. + * _Note:_ Has no effect when period is `flexible`. * */ public PeriodicLimits withAlignment(Alignment alignment) { @@ -1323,8 +1333,9 @@ public PeriodicLimits withAlignment(Alignment alignment) { } /** - * The maximum number of payments that can be collected in this periodic limit. _Note:_ - * This is only supported for the PayTo scheme, where it is required. + * The maximum number of payments that can be collected in this periodic limit. + * + * _Note:_ Only supported for the PayTo scheme, where it is optional. * */ public PeriodicLimits withMaxPayments(Integer maxPayments) { @@ -1333,8 +1344,10 @@ public PeriodicLimits withMaxPayments(Integer maxPayments) { } /** - * The maximum total amount that can be charged for all payments in this periodic limit. - * Required for VRP. + * The maximum total amount that can be charged for all payments in this periodic limit, + * in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR). + * + * _Note:_ Required for VRP. This is not permitted for the PayTo scheme. * */ public PeriodicLimits withMaxTotalAmount(Integer maxTotalAmount) { @@ -1343,8 +1356,10 @@ public PeriodicLimits withMaxTotalAmount(Integer maxTotalAmount) { } /** - * The repeating period for this mandate. Defaults to flexible for PayTo if not - * specified. + * The repeating period for this mandate. Required whenever a periodic limit is provided + * (for both VRP and PayTo). If periodic_limits is omitted entirely for PayTo, this + * defaults to flexible. + * */ public PeriodicLimits withPeriod(Period period) { this.period = period; @@ -1418,8 +1433,9 @@ public Constraints withEndDate(String endDate) { } /** - * The maximum amount that can be charged for a single payment. Required for PayTo and - * VRP. + * The maximum amount that can be charged for a single payment in the lowest + * denomination for the currency (e.g. pence in GBP, cents in EUR). _Note:_ Required for + * PayTo and VRP. */ public Constraints withMaxAmountPerPayment(Integer maxAmountPerPayment) { this.maxAmountPerPayment = maxAmountPerPayment; @@ -1428,7 +1444,8 @@ public Constraints withMaxAmountPerPayment(Integer maxAmountPerPayment) { /** * A constraint where you can specify info (free text string) about how payments are - * calculated. _Note:_ This is only supported for ACH and PAD schemes. + * calculated. For use when payments vary and cannot be expressed as a fixed amount and + * frequency. _Note:_ This is only supported for ACH and PAD schemes. * */ public Constraints withPaymentMethod(String paymentMethod) { @@ -1437,7 +1454,13 @@ public Constraints withPaymentMethod(String paymentMethod) { } /** - * List of periodic limits and constraints which apply to them + * Caps on the total amount and/or number of payments that can be collected within a + * repeating period (e.g. no more than a set amount per month), as opposed to + * `max_amount_per_payment` which caps a single payment. + * + * _Note:_ Required for VRP, where exactly one periodic limit must be provided. Optional + * for PayTo. + * */ public Constraints withPeriodicLimits(List periodicLimits) { this.periodicLimits = periodicLimits; diff --git a/src/main/java/com/gocardless/services/BillingRequestTemplateService.java b/src/main/java/com/gocardless/services/BillingRequestTemplateService.java index 3f2ecef8..85d22816 100644 --- a/src/main/java/com/gocardless/services/BillingRequestTemplateService.java +++ b/src/main/java/com/gocardless/services/BillingRequestTemplateService.java @@ -266,7 +266,8 @@ public BillingRequestTemplateCreateRequest withMandateRequestConstraintsEndDate( } /** - * The maximum amount that can be charged for a single payment. Required for PayTo and VRP. + * The maximum amount that can be charged for a single payment in the lowest denomination + * for the currency (e.g. pence in GBP, cents in EUR). _Note:_ Required for PayTo and VRP. */ public BillingRequestTemplateCreateRequest withMandateRequestConstraintsMaxAmountPerPayment( Integer maxAmountPerPayment) { @@ -279,7 +280,8 @@ public BillingRequestTemplateCreateRequest withMandateRequestConstraintsMaxAmoun /** * A constraint where you can specify info (free text string) about how payments are - * calculated. _Note:_ This is only supported for ACH and PAD schemes. + * calculated. For use when payments vary and cannot be expressed as a fixed amount and + * frequency. _Note:_ This is only supported for ACH and PAD schemes. * */ public BillingRequestTemplateCreateRequest withMandateRequestConstraintsPaymentMethod( @@ -292,7 +294,13 @@ public BillingRequestTemplateCreateRequest withMandateRequestConstraintsPaymentM } /** - * List of periodic limits and constraints which apply to them + * Caps on the total amount and/or number of payments that can be collected within a + * repeating period (e.g. no more than a set amount per month), as opposed to + * `max_amount_per_payment` which caps a single payment. + * + * _Note:_ Required for VRP, where exactly one periodic limit must be provided. Optional for + * PayTo. + * */ public BillingRequestTemplateCreateRequest withMandateRequestConstraintsPeriodicLimits( List periodicLimits) { @@ -558,14 +566,21 @@ public static class PeriodicLimits { private Period period; /** - * The alignment of the period. + * The alignment of the period. Defaults to `creation_date` if not specified. * - * `calendar` - this will finish on the end of the current period. For example this will - * expire on the Monday for the current week or the January for the next year. + * `calendar` - the period follows fixed calendar boundaries, the same for every + * mandate: `week` runs Monday to Sunday, `month` runs from the 1st to the last day of + * the calendar month, and `year` runs from 1 January to 31 December. If the mandate + * starts partway through a period, the limit for that first period is reduced + * proportionally to the days remaining (e.g. a monthly limit starting on the 15th gives + * roughly half the limit for that first month). * - * `creation_date` - this will finish on the next instance of the current period. For - * example Monthly it will expire on the same day of the next month, or yearly the same - * day of the next year. + * `creation_date` - the period follows the mandate's own start date rather than the + * calendar. For example, if the mandate starts on the 15th, each monthly period runs + * from the 15th to the 14th of the following month. The first period is a full period, + * not reduced proportionally. + * + * _Note:_ Has no effect when period is `flexible`. * */ public PeriodicLimits withAlignment(Alignment alignment) { @@ -574,8 +589,9 @@ public PeriodicLimits withAlignment(Alignment alignment) { } /** - * The maximum number of payments that can be collected in this periodic limit. _Note:_ - * This is only supported for the PayTo scheme, where it is required. + * The maximum number of payments that can be collected in this periodic limit. + * + * _Note:_ Only supported for the PayTo scheme, where it is optional. * */ public PeriodicLimits withMaxPayments(Integer maxPayments) { @@ -584,8 +600,10 @@ public PeriodicLimits withMaxPayments(Integer maxPayments) { } /** - * The maximum total amount that can be charged for all payments in this periodic limit. - * Required for VRP. + * The maximum total amount that can be charged for all payments in this periodic limit, + * in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR). + * + * _Note:_ Required for VRP. This is not permitted for the PayTo scheme. * */ public PeriodicLimits withMaxTotalAmount(Integer maxTotalAmount) { @@ -594,8 +612,10 @@ public PeriodicLimits withMaxTotalAmount(Integer maxTotalAmount) { } /** - * The repeating period for this mandate. Defaults to flexible for PayTo if not - * specified. + * The repeating period for this mandate. Required whenever a periodic limit is provided + * (for both VRP and PayTo). If periodic_limits is omitted entirely for PayTo, this + * defaults to flexible. + * */ public PeriodicLimits withPeriod(Period period) { this.period = period; @@ -669,8 +689,9 @@ public MandateRequestConstraints withEndDate(String endDate) { } /** - * The maximum amount that can be charged for a single payment. Required for PayTo and - * VRP. + * The maximum amount that can be charged for a single payment in the lowest + * denomination for the currency (e.g. pence in GBP, cents in EUR). _Note:_ Required for + * PayTo and VRP. */ public MandateRequestConstraints withMaxAmountPerPayment(Integer maxAmountPerPayment) { this.maxAmountPerPayment = maxAmountPerPayment; @@ -679,7 +700,8 @@ public MandateRequestConstraints withMaxAmountPerPayment(Integer maxAmountPerPay /** * A constraint where you can specify info (free text string) about how payments are - * calculated. _Note:_ This is only supported for ACH and PAD schemes. + * calculated. For use when payments vary and cannot be expressed as a fixed amount and + * frequency. _Note:_ This is only supported for ACH and PAD schemes. * */ public MandateRequestConstraints withPaymentMethod(String paymentMethod) { @@ -688,7 +710,13 @@ public MandateRequestConstraints withPaymentMethod(String paymentMethod) { } /** - * List of periodic limits and constraints which apply to them + * Caps on the total amount and/or number of payments that can be collected within a + * repeating period (e.g. no more than a set amount per month), as opposed to + * `max_amount_per_payment` which caps a single payment. + * + * _Note:_ Required for VRP, where exactly one periodic limit must be provided. Optional + * for PayTo. + * */ public MandateRequestConstraints withPeriodicLimits( List periodicLimits) { @@ -763,7 +791,8 @@ public BillingRequestTemplateUpdateRequest withMandateRequestConstraintsEndDate( } /** - * The maximum amount that can be charged for a single payment. Required for PayTo and VRP. + * The maximum amount that can be charged for a single payment in the lowest denomination + * for the currency (e.g. pence in GBP, cents in EUR). _Note:_ Required for PayTo and VRP. */ public BillingRequestTemplateUpdateRequest withMandateRequestConstraintsMaxAmountPerPayment( Integer maxAmountPerPayment) { @@ -776,7 +805,8 @@ public BillingRequestTemplateUpdateRequest withMandateRequestConstraintsMaxAmoun /** * A constraint where you can specify info (free text string) about how payments are - * calculated. _Note:_ This is only supported for ACH and PAD schemes. + * calculated. For use when payments vary and cannot be expressed as a fixed amount and + * frequency. _Note:_ This is only supported for ACH and PAD schemes. * */ public BillingRequestTemplateUpdateRequest withMandateRequestConstraintsPaymentMethod( @@ -789,7 +819,13 @@ public BillingRequestTemplateUpdateRequest withMandateRequestConstraintsPaymentM } /** - * List of periodic limits and constraints which apply to them + * Caps on the total amount and/or number of payments that can be collected within a + * repeating period (e.g. no more than a set amount per month), as opposed to + * `max_amount_per_payment` which caps a single payment. + * + * _Note:_ Required for VRP, where exactly one periodic limit must be provided. Optional for + * PayTo. + * */ public BillingRequestTemplateUpdateRequest withMandateRequestConstraintsPeriodicLimits( List periodicLimits) { @@ -1034,14 +1070,21 @@ public static class PeriodicLimits { private Period period; /** - * The alignment of the period. + * The alignment of the period. Defaults to `creation_date` if not specified. * - * `calendar` - this will finish on the end of the current period. For example this will - * expire on the Monday for the current week or the January for the next year. + * `calendar` - the period follows fixed calendar boundaries, the same for every + * mandate: `week` runs Monday to Sunday, `month` runs from the 1st to the last day of + * the calendar month, and `year` runs from 1 January to 31 December. If the mandate + * starts partway through a period, the limit for that first period is reduced + * proportionally to the days remaining (e.g. a monthly limit starting on the 15th gives + * roughly half the limit for that first month). * - * `creation_date` - this will finish on the next instance of the current period. For - * example Monthly it will expire on the same day of the next month, or yearly the same - * day of the next year. + * `creation_date` - the period follows the mandate's own start date rather than the + * calendar. For example, if the mandate starts on the 15th, each monthly period runs + * from the 15th to the 14th of the following month. The first period is a full period, + * not reduced proportionally. + * + * _Note:_ Has no effect when period is `flexible`. * */ public PeriodicLimits withAlignment(Alignment alignment) { @@ -1050,8 +1093,9 @@ public PeriodicLimits withAlignment(Alignment alignment) { } /** - * The maximum number of payments that can be collected in this periodic limit. _Note:_ - * This is only supported for the PayTo scheme, where it is required. + * The maximum number of payments that can be collected in this periodic limit. + * + * _Note:_ Only supported for the PayTo scheme, where it is optional. * */ public PeriodicLimits withMaxPayments(Integer maxPayments) { @@ -1060,8 +1104,10 @@ public PeriodicLimits withMaxPayments(Integer maxPayments) { } /** - * The maximum total amount that can be charged for all payments in this periodic limit. - * Required for VRP. + * The maximum total amount that can be charged for all payments in this periodic limit, + * in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR). + * + * _Note:_ Required for VRP. This is not permitted for the PayTo scheme. * */ public PeriodicLimits withMaxTotalAmount(Integer maxTotalAmount) { @@ -1070,8 +1116,10 @@ public PeriodicLimits withMaxTotalAmount(Integer maxTotalAmount) { } /** - * The repeating period for this mandate. Defaults to flexible for PayTo if not - * specified. + * The repeating period for this mandate. Required whenever a periodic limit is provided + * (for both VRP and PayTo). If periodic_limits is omitted entirely for PayTo, this + * defaults to flexible. + * */ public PeriodicLimits withPeriod(Period period) { this.period = period; @@ -1145,8 +1193,9 @@ public MandateRequestConstraints withEndDate(String endDate) { } /** - * The maximum amount that can be charged for a single payment. Required for PayTo and - * VRP. + * The maximum amount that can be charged for a single payment in the lowest + * denomination for the currency (e.g. pence in GBP, cents in EUR). _Note:_ Required for + * PayTo and VRP. */ public MandateRequestConstraints withMaxAmountPerPayment(Integer maxAmountPerPayment) { this.maxAmountPerPayment = maxAmountPerPayment; @@ -1155,7 +1204,8 @@ public MandateRequestConstraints withMaxAmountPerPayment(Integer maxAmountPerPay /** * A constraint where you can specify info (free text string) about how payments are - * calculated. _Note:_ This is only supported for ACH and PAD schemes. + * calculated. For use when payments vary and cannot be expressed as a fixed amount and + * frequency. _Note:_ This is only supported for ACH and PAD schemes. * */ public MandateRequestConstraints withPaymentMethod(String paymentMethod) { @@ -1164,7 +1214,13 @@ public MandateRequestConstraints withPaymentMethod(String paymentMethod) { } /** - * List of periodic limits and constraints which apply to them + * Caps on the total amount and/or number of payments that can be collected within a + * repeating period (e.g. no more than a set amount per month), as opposed to + * `max_amount_per_payment` which caps a single payment. + * + * _Note:_ Required for VRP, where exactly one periodic limit must be provided. Optional + * for PayTo. + * */ public MandateRequestConstraints withPeriodicLimits( List periodicLimits) { diff --git a/src/main/java/com/gocardless/services/BillingRequestWithActionService.java b/src/main/java/com/gocardless/services/BillingRequestWithActionService.java index dee9a2d7..9be09a4d 100644 --- a/src/main/java/com/gocardless/services/BillingRequestWithActionService.java +++ b/src/main/java/com/gocardless/services/BillingRequestWithActionService.java @@ -1272,14 +1272,21 @@ public static class PeriodicLimits { private Period period; /** - * The alignment of the period. + * The alignment of the period. Defaults to `creation_date` if not specified. * - * `calendar` - this will finish on the end of the current period. For example this will - * expire on the Monday for the current week or the January for the next year. + * `calendar` - the period follows fixed calendar boundaries, the same for every + * mandate: `week` runs Monday to Sunday, `month` runs from the 1st to the last day of + * the calendar month, and `year` runs from 1 January to 31 December. If the mandate + * starts partway through a period, the limit for that first period is reduced + * proportionally to the days remaining (e.g. a monthly limit starting on the 15th gives + * roughly half the limit for that first month). * - * `creation_date` - this will finish on the next instance of the current period. For - * example Monthly it will expire on the same day of the next month, or yearly the same - * day of the next year. + * `creation_date` - the period follows the mandate's own start date rather than the + * calendar. For example, if the mandate starts on the 15th, each monthly period runs + * from the 15th to the 14th of the following month. The first period is a full period, + * not reduced proportionally. + * + * _Note:_ Has no effect when period is `flexible`. * */ public PeriodicLimits withAlignment(Alignment alignment) { @@ -1288,8 +1295,9 @@ public PeriodicLimits withAlignment(Alignment alignment) { } /** - * The maximum number of payments that can be collected in this periodic limit. _Note:_ - * This is only supported for the PayTo scheme, where it is required. + * The maximum number of payments that can be collected in this periodic limit. + * + * _Note:_ Only supported for the PayTo scheme, where it is optional. * */ public PeriodicLimits withMaxPayments(Integer maxPayments) { @@ -1298,8 +1306,10 @@ public PeriodicLimits withMaxPayments(Integer maxPayments) { } /** - * The maximum total amount that can be charged for all payments in this periodic limit. - * Required for VRP. + * The maximum total amount that can be charged for all payments in this periodic limit, + * in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR). + * + * _Note:_ Required for VRP. This is not permitted for the PayTo scheme. * */ public PeriodicLimits withMaxTotalAmount(Integer maxTotalAmount) { @@ -1308,8 +1318,10 @@ public PeriodicLimits withMaxTotalAmount(Integer maxTotalAmount) { } /** - * The repeating period for this mandate. Defaults to flexible for PayTo if not - * specified. + * The repeating period for this mandate. Required whenever a periodic limit is provided + * (for both VRP and PayTo). If periodic_limits is omitted entirely for PayTo, this + * defaults to flexible. + * */ public PeriodicLimits withPeriod(Period period) { this.period = period; @@ -1383,8 +1395,9 @@ public Constraints withEndDate(String endDate) { } /** - * The maximum amount that can be charged for a single payment. Required for PayTo and - * VRP. + * The maximum amount that can be charged for a single payment in the lowest + * denomination for the currency (e.g. pence in GBP, cents in EUR). _Note:_ Required for + * PayTo and VRP. */ public Constraints withMaxAmountPerPayment(Integer maxAmountPerPayment) { this.maxAmountPerPayment = maxAmountPerPayment; @@ -1393,7 +1406,8 @@ public Constraints withMaxAmountPerPayment(Integer maxAmountPerPayment) { /** * A constraint where you can specify info (free text string) about how payments are - * calculated. _Note:_ This is only supported for ACH and PAD schemes. + * calculated. For use when payments vary and cannot be expressed as a fixed amount and + * frequency. _Note:_ This is only supported for ACH and PAD schemes. * */ public Constraints withPaymentMethod(String paymentMethod) { @@ -1402,7 +1416,13 @@ public Constraints withPaymentMethod(String paymentMethod) { } /** - * List of periodic limits and constraints which apply to them + * Caps on the total amount and/or number of payments that can be collected within a + * repeating period (e.g. no more than a set amount per month), as opposed to + * `max_amount_per_payment` which caps a single payment. + * + * _Note:_ Required for VRP, where exactly one periodic limit must be provided. Optional + * for PayTo. + * */ public Constraints withPeriodicLimits(List periodicLimits) { this.periodicLimits = periodicLimits; diff --git a/src/main/java/com/gocardless/services/InstalmentScheduleService.java b/src/main/java/com/gocardless/services/InstalmentScheduleService.java index 7139fb23..b8fcc7b3 100644 --- a/src/main/java/com/gocardless/services/InstalmentScheduleService.java +++ b/src/main/java/com/gocardless/services/InstalmentScheduleService.java @@ -345,6 +345,9 @@ public static class Instalments { /** * Amount, in the lowest denomination for the currency (e.g. pence in GBP, cents in * EUR). + * + * For Variable Recurring Payments (VRP), this must not exceed the mandate's + * `max_amount_per_payment` constraint. */ public Instalments withAmount(Integer amount) { this.amount = amount; diff --git a/src/main/java/com/gocardless/services/PaymentService.java b/src/main/java/com/gocardless/services/PaymentService.java index 7c841939..8c7a5a3d 100644 --- a/src/main/java/com/gocardless/services/PaymentService.java +++ b/src/main/java/com/gocardless/services/PaymentService.java @@ -118,6 +118,9 @@ public static final class PaymentCreateRequest extends IdempotentPostRequest Date: Tue, 14 Jul 2026 17:47:29 +0000 Subject: [PATCH 5/5] Changes generated by 0e52fa170fb1e7a538fd16be889f703d99a3870e This commit was automatically created from gocardless/client-library-templates@0e52fa170fb1e7a538fd16be889f703d99a3870e by the `push-files` action. Workflow run: https://github.com/gocardless/client-library-templates/actions/runs/29354977793 --- .../java/com/gocardless/resources/Event.java | 6 ++++++ .../com/gocardless/services/EventService.java | 16 ++++++++++++++++ 2 files changed, 22 insertions(+) diff --git a/src/main/java/com/gocardless/resources/Event.java b/src/main/java/com/gocardless/resources/Event.java index bba52e8f..41da0cb2 100644 --- a/src/main/java/com/gocardless/resources/Event.java +++ b/src/main/java/com/gocardless/resources/Event.java @@ -12,6 +12,12 @@ * creation is an asynchronous process, so it can take some time between an action occurring and its * corresponding event getting included in API responses. See [here](#event-types) for a complete * list of event types. + *

+ * Important: Events older than 18 months will be archived and no longer accessible + * via the API or exports. Archival will begin no sooner than 1 August 2026 in sandbox environments, + * and no sooner than 1 October 2026 in live environments. Events within the 18-month window are + * unaffected. If you need archived data, contact GoCardless support. + *

*/ public class Event { private Event() { diff --git a/src/main/java/com/gocardless/services/EventService.java b/src/main/java/com/gocardless/services/EventService.java index 77330865..da13e586 100644 --- a/src/main/java/com/gocardless/services/EventService.java +++ b/src/main/java/com/gocardless/services/EventService.java @@ -16,6 +16,12 @@ * creation is an asynchronous process, so it can take some time between an action occurring and its * corresponding event getting included in API responses. See [here](#event-types) for a complete * list of event types. + *

+ * Important: Events older than 18 months will be archived and no longer accessible + * via the API or exports. Archival will begin no sooner than 1 August 2026 in sandbox environments, + * and no sooner than 1 October 2026 in live environments. Events within the 18-month window are + * unaffected. If you need archived data, contact GoCardless support. + *

*/ public class EventService { private final HttpClient httpClient; @@ -30,6 +36,11 @@ public EventService(HttpClient httpClient) { /** * Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your events. + *

+ * Important: This endpoint will no longer return events older than 18 months, + * including when filtering by resource. This takes effect no sooner than 1 August 2026 in + * sandbox environments, and no sooner than 1 October 2026 in live environments. + *

*/ public EventListRequest> list() { return new EventListRequest<>(httpClient, ListRequest.pagingExecutor()); @@ -50,6 +61,11 @@ public EventGetRequest get(String identity) { * Request class for {@link EventService#list }. * * Returns a [cursor-paginated](#api-usage-cursor-pagination) list of your events. + *

+ * Important: This endpoint will no longer return events older than 18 months, + * including when filtering by resource. This takes effect no sooner than 1 August 2026 in + * sandbox environments, and no sooner than 1 October 2026 in live environments. + *

*/ public static final class EventListRequest extends ListRequest { private String action;