Skip to content
Open
Show file tree
Hide file tree
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
2,051 changes: 589 additions & 1,462 deletions openapi.json

Large diffs are not rendered by default.

12 changes: 0 additions & 12 deletions src/main/java/com/sumup/sdk/SumUpAsyncClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
import com.sumup.sdk.clients.ReadersAsyncClient;
import com.sumup.sdk.clients.ReceiptsAsyncClient;
import com.sumup.sdk.clients.RolesAsyncClient;
import com.sumup.sdk.clients.SubaccountsAsyncClient;
import com.sumup.sdk.clients.TransactionsAsyncClient;
import com.sumup.sdk.core.ApiClient;
import java.net.http.HttpClient;
Expand All @@ -32,7 +31,6 @@ public final class SumUpAsyncClient {
private final ReadersAsyncClient readers;
private final ReceiptsAsyncClient receipts;
private final RolesAsyncClient roles;
private final SubaccountsAsyncClient subaccounts;
private final TransactionsAsyncClient transactions;

/** Creates a SumUpAsyncClient using the API key from the SUMUP_API_KEY environment variable. */
Expand Down Expand Up @@ -73,7 +71,6 @@ private SumUpAsyncClient(ApiClient apiClient) {
this.readers = new ReadersAsyncClient(this.apiClient);
this.receipts = new ReceiptsAsyncClient(this.apiClient);
this.roles = new RolesAsyncClient(this.apiClient);
this.subaccounts = new SubaccountsAsyncClient(this.apiClient);
this.transactions = new TransactionsAsyncClient(this.apiClient);
}

Expand Down Expand Up @@ -176,15 +173,6 @@ public RolesAsyncClient roles() {
return roles;
}

/**
* Returns the SubaccountsAsyncClient client for the "Subaccounts" API group.
*
* @return Client for the associated API group.
*/
public SubaccountsAsyncClient subaccounts() {
return subaccounts;
}

/**
* Returns the TransactionsAsyncClient client for the "Transactions" API group.
*
Expand Down
12 changes: 0 additions & 12 deletions src/main/java/com/sumup/sdk/SumUpClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
import com.sumup.sdk.clients.ReadersClient;
import com.sumup.sdk.clients.ReceiptsClient;
import com.sumup.sdk.clients.RolesClient;
import com.sumup.sdk.clients.SubaccountsClient;
import com.sumup.sdk.clients.TransactionsClient;
import com.sumup.sdk.core.ApiClient;
import java.net.http.HttpClient;
Expand All @@ -32,7 +31,6 @@ public final class SumUpClient {
private final ReadersClient readers;
private final ReceiptsClient receipts;
private final RolesClient roles;
private final SubaccountsClient subaccounts;
private final TransactionsClient transactions;

/** Creates a SumUpClient using the API key from the SUMUP_API_KEY environment variable. */
Expand Down Expand Up @@ -73,7 +71,6 @@ private SumUpClient(ApiClient apiClient) {
this.readers = new ReadersClient(this.apiClient);
this.receipts = new ReceiptsClient(this.apiClient);
this.roles = new RolesClient(this.apiClient);
this.subaccounts = new SubaccountsClient(this.apiClient);
this.transactions = new TransactionsClient(this.apiClient);
}

Expand Down Expand Up @@ -176,15 +173,6 @@ public RolesClient roles() {
return roles;
}

/**
* Returns the SubaccountsClient client for the "Subaccounts" API group.
*
* @return Client for the associated API group.
*/
public SubaccountsClient subaccounts() {
return subaccounts;
}

/**
* Returns the TransactionsClient client for the "Transactions" API group.
*
Expand Down
166 changes: 27 additions & 139 deletions src/main/java/com/sumup/sdk/clients/PayoutsAsyncClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,19 @@ public PayoutsAsyncClient(ApiClient apiClient) {
/**
* List payouts
*
* <p>Lists ordered payouts for the merchant account.
* <p>Lists payout and payout-deduction records for the specified merchant account within the
* requested date range. The response can include: - regular payouts (`type = PAYOUT`) - deduction
* records for refunds, chargebacks, direct debit returns, or balance adjustments Results are
* sorted by payout date in the requested `order`.
*
* <p>Operation ID: ListPayoutsV1
*
* @param merchantCode Merchant code of the account whose payouts should be listed.
* @param endDate End date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param startDate Start date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param endDate End date of the payout period filter, inclusive, in
* [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) `date` format (`YYYY-MM-DD`). Must be
* greater than or equal to `start_date`.
* @param startDate Start date of the payout period filter, inclusive, in
* [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) `date` format (`YYYY-MM-DD`).
* <p>Call the overload that accepts optional parameter objects or RequestOptions to customize
* headers, authorization, query values, or timeouts.
* @return CompletableFuture resolved with com.sumup.sdk.models.FinancialPayouts parsed response.
Expand All @@ -54,13 +60,19 @@ public CompletableFuture<com.sumup.sdk.models.FinancialPayouts> list(
/**
* List payouts
*
* <p>Lists ordered payouts for the merchant account.
* <p>Lists payout and payout-deduction records for the specified merchant account within the
* requested date range. The response can include: - regular payouts (`type = PAYOUT`) - deduction
* records for refunds, chargebacks, direct debit returns, or balance adjustments Results are
* sorted by payout date in the requested `order`.
*
* <p>Operation ID: ListPayoutsV1
*
* @param merchantCode Merchant code of the account whose payouts should be listed.
* @param endDate End date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param startDate Start date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param endDate End date of the payout period filter, inclusive, in
* [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) `date` format (`YYYY-MM-DD`). Must be
* greater than or equal to `start_date`.
* @param startDate Start date of the payout period filter, inclusive, in
* [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) `date` format (`YYYY-MM-DD`).
* @param listPayoutsV1 Optional query parameters for this request.
* <p>Call the overload that accepts RequestOptions to customize headers, authorization, or
* request timeout.
Expand All @@ -79,13 +91,19 @@ public CompletableFuture<com.sumup.sdk.models.FinancialPayouts> list(
/**
* List payouts
*
* <p>Lists ordered payouts for the merchant account.
* <p>Lists payout and payout-deduction records for the specified merchant account within the
* requested date range. The response can include: - regular payouts (`type = PAYOUT`) - deduction
* records for refunds, chargebacks, direct debit returns, or balance adjustments Results are
* sorted by payout date in the requested `order`.
*
* <p>Operation ID: ListPayoutsV1
*
* @param merchantCode Merchant code of the account whose payouts should be listed.
* @param endDate End date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param startDate Start date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param endDate End date of the payout period filter, inclusive, in
* [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) `date` format (`YYYY-MM-DD`). Must be
* greater than or equal to `start_date`.
* @param startDate Start date of the payout period filter, inclusive, in
* [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) `date` format (`YYYY-MM-DD`).
* @param listPayoutsV1 Optional query parameters for this request.
* @param requestOptions Request-specific overrides (headers, authorization, or timeout). Pass
* {@code null} to use client defaults.
Expand Down Expand Up @@ -123,89 +141,6 @@ public CompletableFuture<com.sumup.sdk.models.FinancialPayouts> list(
requestOptions);
}

/**
* List payouts
*
* <p>Lists ordered payouts for the merchant account.
*
* <p>Operation ID: ListPayouts
*
* @param endDate End date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param startDate Start date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* <p>Call the overload that accepts optional parameter objects or RequestOptions to customize
* headers, authorization, query values, or timeouts.
* @return CompletableFuture resolved with com.sumup.sdk.models.FinancialPayouts parsed response.
* @throws ApiException if the SumUp API returns an error.
*/
public CompletableFuture<com.sumup.sdk.models.FinancialPayouts> listDeprecated(
java.time.LocalDate endDate, java.time.LocalDate startDate) throws ApiException {
return listDeprecated(endDate, startDate, null);
}

/**
* List payouts
*
* <p>Lists ordered payouts for the merchant account.
*
* <p>Operation ID: ListPayouts
*
* @param endDate End date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param startDate Start date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param listPayouts Optional query parameters for this request.
* <p>Call the overload that accepts RequestOptions to customize headers, authorization, or
* request timeout.
* @return CompletableFuture resolved with com.sumup.sdk.models.FinancialPayouts parsed response.
* @throws ApiException if the SumUp API returns an error.
*/
public CompletableFuture<com.sumup.sdk.models.FinancialPayouts> listDeprecated(
java.time.LocalDate endDate,
java.time.LocalDate startDate,
ListPayoutsQueryParams listPayouts)
throws ApiException {
return listDeprecated(endDate, startDate, listPayouts, null);
}

/**
* List payouts
*
* <p>Lists ordered payouts for the merchant account.
*
* <p>Operation ID: ListPayouts
*
* @param endDate End date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param startDate Start date (in [ISO8601](https://en.wikipedia.org/wiki/ISO_8601) format).
* @param listPayouts Optional query parameters for this request.
* @param requestOptions Request-specific overrides (headers, authorization, or timeout). Pass
* {@code null} to use client defaults.
* @return CompletableFuture resolved with com.sumup.sdk.models.FinancialPayouts parsed response.
* @throws ApiException if the SumUp API returns an error.
*/
public CompletableFuture<com.sumup.sdk.models.FinancialPayouts> listDeprecated(
java.time.LocalDate endDate,
java.time.LocalDate startDate,
ListPayoutsQueryParams listPayouts,
RequestOptions requestOptions)
throws ApiException {
Objects.requireNonNull(endDate, "endDate");
Objects.requireNonNull(startDate, "startDate");
String path = "/v0.1/me/financials/payouts";
Map<String, Object> queryParams = new LinkedHashMap<>();
queryParams.put("end_date", endDate);
queryParams.put("start_date", startDate);
if (listPayouts != null) {
queryParams.putAll(listPayouts.toMap());
}

return this.apiClient.sendAsync(
HttpMethod.GET,
path,
queryParams,
null,
null,
new TypeReference<com.sumup.sdk.models.FinancialPayouts>() {},
requestOptions);
}

/** Optional query parameters for this request. */
public static final class ListPayoutsV1QueryParams {
private final Map<String, Object> values = new LinkedHashMap<>();
Expand Down Expand Up @@ -252,51 +187,4 @@ Map<String, Object> toMap() {
return values;
}
}

/** Optional query parameters for this request. */
public static final class ListPayoutsQueryParams {
private final Map<String, Object> values = new LinkedHashMap<>();

/**
* Sets the format query parameter.
*
* @param value Response format for the payout list.
* @return This ListPayoutsQueryParams instance.
*/
public ListPayoutsQueryParams format(com.sumup.sdk.models.ListPayoutsFormat value) {
this.values.put("format", Objects.requireNonNull(value, "format"));
return this;
}

/**
* Sets the limit query parameter.
*
* @param value Maximum number of payout records to return.
* @return This ListPayoutsQueryParams instance.
*/
public ListPayoutsQueryParams limit(Long value) {
this.values.put("limit", Objects.requireNonNull(value, "limit"));
return this;
}

/**
* Sets the order query parameter.
*
* @param value Sort direction for the returned payouts.
* @return This ListPayoutsQueryParams instance.
*/
public ListPayoutsQueryParams order(com.sumup.sdk.models.ListPayoutsOrder value) {
this.values.put("order", Objects.requireNonNull(value, "order"));
return this;
}

/**
* Converts query parameters to a map understood by ApiClient.
*
* @return Collected query parameters keyed by API name.
*/
Map<String, Object> toMap() {
return values;
}
}
}
Loading
Loading