From ff91f8825c7086e7e14992a0e31b3b6468de737a Mon Sep 17 00:00:00 2001 From: "gocardless-ci-robot[bot]" <123969075+gocardless-ci-robot[bot]@users.noreply.github.com> Date: Mon, 12 Oct 2026 11:46:59 +0000 Subject: [PATCH] Changes generated by 2e29891ff133813749feeb56b58b682d8d6fa8b5 This commit was automatically created from gocardless/client-library-templates@2e29891ff133813749feeb56b58b682d8d6fa8b5 by the `push-files` action. Workflow run: https://github.com/gocardless/client-library-templates/actions/runs/38244474469 --- .../gocardless/services/MandateService.java | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/src/main/java/com/gocardless/services/MandateService.java b/src/main/java/com/gocardless/services/MandateService.java index a535a148..d15d554d 100644 --- a/src/main/java/com/gocardless/services/MandateService.java +++ b/src/main/java/com/gocardless/services/MandateService.java @@ -302,6 +302,7 @@ public static final class MandateListRequest extends ListRequest private String creditor; private String customer; private String customerBankAccount; + private List include; private String mandateType; private String reference; private List scheme; @@ -406,6 +407,27 @@ public MandateListRequest withCustomerBankAccount(String customerBankAccount) return this; } + /** + * Includes linked resources in the response. Use customer to embed customer + * details, or bank_account to embed bank account details. + */ + public MandateListRequest withInclude(List include) { + this.include = include; + return this; + } + + /** + * Includes linked resources in the response. Use customer to embed customer + * details, or bank_account to embed bank account details. + */ + public MandateListRequest withInclude(String include) { + if (this.include == null) { + this.include = new ArrayList<>(); + } + this.include.add(include); + return this; + } + /** * Number of records to return. */ @@ -497,6 +519,9 @@ protected Map getQueryParams() { if (customerBankAccount != null) { params.put("customer_bank_account", customerBankAccount); } + if (include != null) { + params.put("include", Joiner.on(",").join(include)); + } if (mandateType != null) { params.put("mandate_type", mandateType); }