Skip to content

Commit ed4ef34

Browse files
author
autobot
committed
Generated PR for Release: 31.0.0.20230720
1 parent 21fff2c commit ed4ef34

File tree

379 files changed

+2525
-2139
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

379 files changed

+2525
-2139
lines changed

doc/api/customers.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ CompletableFuture<ListCustomersResponse> listCustomersAsync(
3535
final String cursor,
3636
final Integer limit,
3737
final String sortField,
38-
final String sortOrder)
38+
final String sortOrder,
39+
final Boolean count)
3940
```
4041

4142
## Parameters
@@ -46,6 +47,7 @@ CompletableFuture<ListCustomersResponse> listCustomersAsync(
4647
| `limit` | `Integer` | Query, Optional | The maximum number of results to return in a single page. This limit is advisory. The response might contain more or fewer results.<br>If the specified limit is less than 1 or greater than 100, Square returns a `400 VALUE_TOO_LOW` or `400 VALUE_TOO_HIGH` error. The default value is 100.<br><br>For more information, see [Pagination](https://developer.squareup.com/docs/build-basics/common-api-patterns/pagination). |
4748
| `sortField` | [`String`](../../doc/models/customer-sort-field.md) | Query, Optional | Indicates how customers should be sorted.<br><br>The default value is `DEFAULT`. |
4849
| `sortOrder` | [`String`](../../doc/models/sort-order.md) | Query, Optional | Indicates whether customers should be sorted in ascending (`ASC`) or<br>descending (`DESC`) order.<br><br>The default value is `ASC`. |
50+
| `count` | `Boolean` | Query, Optional | Indicates whether to return the total count of customers in the `count` field of the response.<br><br>The default value is `false`.<br>**Default**: `false` |
4951

5052
## Response Type
5153

@@ -54,7 +56,9 @@ CompletableFuture<ListCustomersResponse> listCustomersAsync(
5456
## Example Usage
5557

5658
```java
57-
customersApi.listCustomersAsync(null, null, null, null).thenAccept(result -> {
59+
Boolean count = false;
60+
61+
customersApi.listCustomersAsync(null, null, null, null, count).thenAccept(result -> {
5862
// TODO success callback handler
5963
System.out.println(result);
6064
}).exceptionally(exception -> {

doc/api/invoices.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ CreateInvoiceRequest body = new CreateInvoiceRequest.Builder(
118118
.squareGiftCard(false)
119119
.bankAccount(false)
120120
.buyNowPayLater(false)
121+
.cashAppPay(false)
121122
.build())
122123
.customFields(Arrays.asList(
123124
new InvoiceCustomField.Builder()

doc/api/refunds.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ CompletableFuture<ListPaymentRefundsResponse> listPaymentRefundsAsync(
4040

4141
| Parameter | Type | Tags | Description |
4242
| --- | --- | --- | --- |
43-
| `beginTime` | `String` | Query, Optional | Indicates the start of the time range to retrieve each PaymentRefund`for, in RFC 3339 format. The range is determined using the`created_at`field for each`PaymentRefund`.<br><br>Default: The current time minus one year. |
43+
| `beginTime` | `String` | Query, Optional | Indicates the start of the time range to retrieve each `PaymentRefund` for, in RFC 3339<br>format. The range is determined using the `created_at` field for each `PaymentRefund`.<br><br>Default: The current time minus one year. |
4444
| `endTime` | `String` | Query, Optional | Indicates the end of the time range to retrieve each `PaymentRefund` for, in RFC 3339<br>format. The range is determined using the `created_at` field for each `PaymentRefund`.<br><br>Default: The current time. |
4545
| `sortOrder` | `String` | Query, Optional | The order in which results are listed by `PaymentRefund.created_at`:<br><br>- `ASC` - Oldest to newest.<br>- `DESC` - Newest to oldest (default). |
4646
| `cursor` | `String` | Query, Optional | A pagination cursor returned by a previous call to this endpoint.<br>Provide this cursor to retrieve the next set of results for the original query.<br><br>For more information, see [Pagination](https://developer.squareup.com/docs/build-basics/common-api-patterns/pagination). |

doc/api/subscriptions.md

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -56,18 +56,19 @@ CreateSubscriptionRequest body = new CreateSubscriptionRequest.Builder(
5656
"CHFGVKYY8RSV93M5KCYTG4PN0G"
5757
)
5858
.idempotencyKey("8193148c-9586-11e6-99f9-28cfe92138cf")
59-
.planId("6JHXF3B2CW3YKHDV4XEM674H")
60-
.startDate("2021-10-20")
61-
.taxPercentage("5")
62-
.priceOverrideMoney(new Money.Builder()
63-
.amount(100L)
64-
.currency("USD")
65-
.build())
59+
.planVariationId("6JHXF3B2CW3YKHDV4XEM674H")
60+
.startDate("2023-06-20")
6661
.cardId("ccof:qy5x8hHGYsgLrp4Q4GB")
6762
.timezone("America/Los_Angeles")
6863
.source(new SubscriptionSource.Builder()
69-
.name("My App")
64+
.name("My Application")
7065
.build())
66+
.phases(Arrays.asList(
67+
new Phase.Builder()
68+
.ordinal(0)
69+
.orderTemplateId("U2NaowWxzXwpsZU697x7ZHOAnCNZY")
70+
.build()
71+
))
7172
.build();
7273

7374
subscriptionsApi.createSubscriptionAsync(body).thenAccept(result -> {
@@ -441,6 +442,14 @@ CompletableFuture<SwapPlanResponse> swapPlanAsync(
441442
```java
442443
String subscriptionId = "subscription_id0";
443444
SwapPlanRequest body = new SwapPlanRequest.Builder()
445+
.newPlanVariationId("FQ7CDXXWSLUJRPM3GFJSJGZ7")
446+
.phases(Arrays.asList(
447+
new PhaseInput.Builder(
448+
0
449+
)
450+
.orderTemplateId("uhhnjH9osVv3shUADwaC0b3hNxQZY")
451+
.build()
452+
))
444453
.build();
445454

446455
subscriptionsApi.swapPlanAsync(subscriptionId, body).thenAccept(result -> {

doc/client.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ The following parameters are configurable for the API Client:
55

66
| Parameter | Type | Description |
77
| --- | --- | --- |
8-
| `squareVersion` | `String` | Square Connect API versions<br>*Default*: `"2023-06-08"` |
8+
| `squareVersion` | `String` | Square Connect API versions<br>*Default*: `"2023-07-20"` |
99
| `customUrl` | `String` | Sets the base URL requests are made to. Defaults to `https://connect.squareup.com`<br>*Default*: `"https://connect.squareup.com"` |
1010
| `environment` | `string` | The API environment. <br> **Default: `production`** |
1111
| `httpClientConfig` | [`ReadonlyHttpClientConfiguration`](http-client-configuration.md) | Http Client Configuration instance. |
@@ -19,7 +19,7 @@ The API client can be initialized as follows:
1919
SquareClient client = new SquareClient.Builder()
2020
.httpClientConfig(configBuilder -> configBuilder
2121
.timeout(0))
22-
.squareVersion("2023-06-08")
22+
.squareVersion("2023-07-20")
2323
.accessToken("AccessToken")
2424
.environment(Environment.PRODUCTION)
2525
.customUrl("https://connect.squareup.com")
@@ -40,7 +40,7 @@ public class Program {
4040
SquareClient client = new SquareClient.Builder()
4141
.httpClientConfig(configBuilder -> configBuilder
4242
.timeout(0))
43-
.squareVersion("2023-06-08")
43+
.squareVersion("2023-07-20")
4444
.accessToken("AccessToken")
4545
.build();
4646

doc/models/accept-dispute-response.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,20 +41,20 @@ Defines the fields in an `AcceptDispute` response.
4141
},
4242
"errors": [
4343
{
44-
"category": "AUTHENTICATION_ERROR",
45-
"code": "REFUND_ALREADY_PENDING",
44+
"category": "REFUND_ERROR",
45+
"code": "MERCHANT_SUBSCRIPTION_NOT_FOUND",
4646
"detail": "detail1",
4747
"field": "field9"
4848
},
4949
{
50-
"category": "INVALID_REQUEST_ERROR",
51-
"code": "PAYMENT_NOT_REFUNDABLE",
50+
"category": "MERCHANT_SUBSCRIPTION_ERROR",
51+
"code": "BAD_REQUEST",
5252
"detail": "detail2",
5353
"field": "field0"
5454
},
5555
{
56-
"category": "RATE_LIMIT_ERROR",
57-
"code": "REFUND_DECLINED",
56+
"category": "EXTERNAL_VENDOR_ERROR",
57+
"code": "MISSING_REQUIRED_PARAMETER",
5858
"detail": "detail3",
5959
"field": "field1"
6060
}

doc/models/accumulate-loyalty-points-response.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -56,20 +56,20 @@ Represents an [AccumulateLoyaltyPoints](../../doc/api/loyalty.md#accumulate-loya
5656
],
5757
"errors": [
5858
{
59-
"category": "AUTHENTICATION_ERROR",
60-
"code": "REFUND_ALREADY_PENDING",
59+
"category": "REFUND_ERROR",
60+
"code": "MERCHANT_SUBSCRIPTION_NOT_FOUND",
6161
"detail": "detail1",
6262
"field": "field9"
6363
},
6464
{
65-
"category": "INVALID_REQUEST_ERROR",
66-
"code": "PAYMENT_NOT_REFUNDABLE",
65+
"category": "MERCHANT_SUBSCRIPTION_ERROR",
66+
"code": "BAD_REQUEST",
6767
"detail": "detail2",
6868
"field": "field0"
6969
},
7070
{
71-
"category": "RATE_LIMIT_ERROR",
72-
"code": "REFUND_DECLINED",
71+
"category": "EXTERNAL_VENDOR_ERROR",
72+
"code": "MISSING_REQUIRED_PARAMETER",
7373
"detail": "detail3",
7474
"field": "field1"
7575
}

doc/models/add-group-to-customer-response.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,20 +20,20 @@ a request to the [AddGroupToCustomer](../../doc/api/customers.md#add-group-to-cu
2020
{
2121
"errors": [
2222
{
23-
"category": "AUTHENTICATION_ERROR",
24-
"code": "REFUND_ALREADY_PENDING",
23+
"category": "REFUND_ERROR",
24+
"code": "MERCHANT_SUBSCRIPTION_NOT_FOUND",
2525
"detail": "detail1",
2626
"field": "field9"
2727
},
2828
{
29-
"category": "INVALID_REQUEST_ERROR",
30-
"code": "PAYMENT_NOT_REFUNDABLE",
29+
"category": "MERCHANT_SUBSCRIPTION_ERROR",
30+
"code": "BAD_REQUEST",
3131
"detail": "detail2",
3232
"field": "field0"
3333
},
3434
{
35-
"category": "RATE_LIMIT_ERROR",
36-
"code": "REFUND_DECLINED",
35+
"category": "EXTERNAL_VENDOR_ERROR",
36+
"code": "MISSING_REQUIRED_PARAMETER",
3737
"detail": "detail3",
3838
"field": "field1"
3939
}

doc/models/additional-recipient.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Represents an additional recipient (other than the merchant) receiving a portion
2424
"description": "description0",
2525
"amount_money": {
2626
"amount": 186,
27-
"currency": "NGN"
27+
"currency": "TZS"
2828
},
2929
"receivable_id": "receivable_id0"
3030
}

doc/models/adjust-loyalty-points-response.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -52,20 +52,20 @@ Represents an [AdjustLoyaltyPoints](../../doc/api/loyalty.md#adjust-loyalty-poin
5252
},
5353
"errors": [
5454
{
55-
"category": "AUTHENTICATION_ERROR",
56-
"code": "REFUND_ALREADY_PENDING",
55+
"category": "REFUND_ERROR",
56+
"code": "MERCHANT_SUBSCRIPTION_NOT_FOUND",
5757
"detail": "detail1",
5858
"field": "field9"
5959
},
6060
{
61-
"category": "INVALID_REQUEST_ERROR",
62-
"code": "PAYMENT_NOT_REFUNDABLE",
61+
"category": "MERCHANT_SUBSCRIPTION_ERROR",
62+
"code": "BAD_REQUEST",
6363
"detail": "detail2",
6464
"field": "field0"
6565
},
6666
{
67-
"category": "RATE_LIMIT_ERROR",
68-
"code": "REFUND_DECLINED",
67+
"category": "EXTERNAL_VENDOR_ERROR",
68+
"code": "MISSING_REQUIRED_PARAMETER",
6969
"detail": "detail3",
7070
"field": "field1"
7171
}

0 commit comments

Comments
 (0)