Skip to content

Commit

Permalink
Changes generated by 279d3ccd1fb2912f796065da92fd9940899470c1
Browse files Browse the repository at this point in the history
This commit was automatically created from gocardless/gocardless-pro-java-template@279d3cc
by the `push-files` action.

Workflow run: https://github.com/gocardless/gocardless-pro-java-template/actions/runs/9992013048
  • Loading branch information
gocardless-ci-robot[bot] committed Jul 18, 2024
1 parent f6f7d34 commit 45d3b29
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 5 deletions.
4 changes: 3 additions & 1 deletion src/main/java/com/gocardless/resources/Event.java
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ public Map<String, Object> getResourceMetadata() {
* <ul>
* <li>`billing_requests`</li>
* <li>`creditors`</li>
* <li>`exports`</li>
* <li>`instalment_schedules`</li>
* <li>`mandates`</li>
* <li>`payer_authorisations`</li>
Expand All @@ -111,7 +112,8 @@ public ResourceType getResourceType() {
public enum ResourceType {
@SerializedName("billing_requests")
BILLING_REQUESTS, @SerializedName("creditors")
CREDITORS, @SerializedName("instalment_schedules")
CREDITORS, @SerializedName("exports")
EXPORTS, @SerializedName("instalment_schedules")
INSTALMENT_SCHEDULES, @SerializedName("mandates")
MANDATES, @SerializedName("organisations")
ORGANISATIONS, @SerializedName("payer_authorisations")
Expand Down
22 changes: 18 additions & 4 deletions src/main/java/com/gocardless/services/EventService.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ public static final class EventListRequest<S> extends ListRequest<S, Event> {
private String billingRequest;
private CreatedAt createdAt;
private String creditor;
private String export;
private Include include;
private String instalmentSchedule;
private String mandate;
Expand Down Expand Up @@ -159,6 +160,14 @@ public EventListRequest<S> withCreditor(String creditor) {
return this;
}

/**
* ID of an export. If specified, this endpoint will return all events for the given export.
*/
public EventListRequest<S> withExport(String export) {
this.export = export;
return this;
}

/**
* Includes linked resources in the response. Must be used with the `resource_type`
* parameter specified. The include should be one of:
Expand Down Expand Up @@ -252,12 +261,13 @@ public EventListRequest<S> withRefund(String refund) {

/**
* Type of resource that you'd like to get all events for. Cannot be used together with the
* `billing_request`, `creditor`, `instalment_schedule`, `mandate`, `payer_authorisation`,
* `payment`, `payout`, `refund`, `scheme_identifier` or `subscription` parameters. The type
* can be one of:
* `billing_request`, `creditor`, `export`,`instalment_schedule`, `mandate`,
* `payer_authorisation`, `payment`, `payout`, `refund`, `scheme_identifier` or
* `subscription` parameters. The type can be one of:
* <ul>
* <li>`billing_requests`</li>
* <li>`creditors`</li>
* <li>`exports`</li>
* <li>`instalment_schedules`</li>
* <li>`mandates`</li>
* <li>`payer_authorisations`</li>
Expand Down Expand Up @@ -316,6 +326,9 @@ protected Map<String, Object> getQueryParams() {
if (creditor != null) {
params.put("creditor", creditor);
}
if (export != null) {
params.put("export", export);
}
if (include != null) {
params.put("include", include);
}
Expand Down Expand Up @@ -390,7 +403,8 @@ public String toString() {
public enum ResourceType {
@SerializedName("billing_requests")
BILLING_REQUESTS, @SerializedName("creditors")
CREDITORS, @SerializedName("instalment_schedules")
CREDITORS, @SerializedName("exports")
EXPORTS, @SerializedName("instalment_schedules")
INSTALMENT_SCHEDULES, @SerializedName("mandates")
MANDATES, @SerializedName("organisations")
ORGANISATIONS, @SerializedName("payer_authorisations")
Expand Down

0 comments on commit 45d3b29

Please sign in to comment.