Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 17 additions & 4 deletions src/main/java/com/gocardless/services/InstitutionService.java
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ public static final class InstitutionListRequest<S> extends ListRequest<S, Insti
private String branchCode;
private String countryCode;
private String feature;
private Boolean includeDisabled;
private String scheme;

/**
Expand All @@ -86,19 +87,28 @@ public InstitutionListRequest<S> withCountryCode(String countryCode) {

/**
* The feature that institutions support. The available options include <code>pis</code>,
* and <code>vrp_sweeping</code>. If nothing is provided, institutions supporting 'pis' are
* returned by default.
* <code>vrp_sweeping</code>, and <code>vrp_commercial</code>. If nothing is provided,
* institutions supporting 'pis' are returned by default.
*/
public InstitutionListRequest<S> withFeature(String feature) {
this.feature = feature;
return this;
}

/**
* Indicates whether to include temporarily disabled institutions in the response. If not
* provided or set to false, only enabled institutions will be returned.
*/
public InstitutionListRequest<S> withIncludeDisabled(Boolean includeDisabled) {
this.includeDisabled = includeDisabled;
return this;
}

/**
* The scheme that institutions support. The available options include
* <code>faster_payments</code>, <code>sepa_credit_transfer</code>, and
* <code>sepa_instant_credit_transfer</code>. If nothing is provided, institutions
* supporting 'faster_payments' are returned by default.
* <code>sepa_instant_credit_transfer</code>. If nothing is provided, no scheme filter is
* applied to the returned institutions.
*/
public InstitutionListRequest<S> withScheme(String scheme) {
this.scheme = scheme;
Expand Down Expand Up @@ -128,6 +138,9 @@ protected Map<String, Object> getQueryParams() {
if (feature != null) {
params.put("feature", feature);
}
if (includeDisabled != null) {
params.put("include_disabled", includeDisabled);
}
if (scheme != null) {
params.put("scheme", scheme);
}
Expand Down
Loading