This repository was archived by the owner on Apr 23, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 25
/
Copy pathV1TransactionsApiTest.java
243 lines (213 loc) · 8.71 KB
/
V1TransactionsApiTest.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
/*
* Square Connect API
* Client library for accessing the Square Connect APIs
*
* OpenAPI spec version: 2.0
* Contact: [email protected]
*
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*/
package com.squareup.connect.api;
import com.squareup.connect.ApiException;
import com.squareup.connect.models.V1Refund;
import com.squareup.connect.models.V1CreateRefundRequest;
import com.squareup.connect.models.V1BankAccount;
import com.squareup.connect.models.V1Order;
import com.squareup.connect.models.V1Payment;
import com.squareup.connect.models.V1Settlement;
import com.squareup.connect.models.V1UpdateOrderRequest;
import org.junit.Test;
import org.junit.Ignore;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* API tests for VTransactionsApi
*/
@Ignore
public class V1TransactionsApiTest {
private final V1TransactionsApi api = new V1TransactionsApi();
/**
* Issues a refund for a previously processed payment. You must issue a refund within 60 days of the associated payment.
*
* Issues a refund for a previously processed payment. You must issue a refund within 60 days of the associated payment.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void createRefundTest() throws ApiException {
String locationId = null;
V1CreateRefundRequest body = null;
V1Refund response = api.createRefund(locationId, body);
// TODO: test validations
}
/**
* Provides non-confidential details for all of a location's associated bank accounts. This endpoint does not provide full bank account numbers, and there is no way to obtain a full bank account number with the Connect API.
*
* Provides non-confidential details for all of a location's associated bank accounts. This endpoint does not provide full bank account numbers, and there is no way to obtain a full bank account number with the Connect API.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void listBankAccountsTest() throws ApiException {
String locationId = null;
List<V1BankAccount> response = api.listBankAccounts(locationId);
// TODO: test validations
}
/**
* Provides summary information for a merchant's online store orders.
*
* Provides summary information for a merchant's online store orders.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void listOrdersTest() throws ApiException {
String locationId = null;
String order = null;
Integer limit = null;
String batchToken = null;
List<V1Order> response = api.listOrders(locationId, order, limit, batchToken);
// TODO: test validations
}
/**
* Provides summary information for all payments taken by a merchant or any of the merchant's mobile staff during a date range. Date ranges cannot exceed one year in length. See Date ranges for details of inclusive and exclusive dates.
*
* Provides summary information for all payments taken by a merchant or any of the merchant's mobile staff during a date range. Date ranges cannot exceed one year in length. See Date ranges for details of inclusive and exclusive dates.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void listPaymentsTest() throws ApiException {
String locationId = null;
String order = null;
String beginTime = null;
String endTime = null;
Integer limit = null;
String batchToken = null;
List<V1Payment> response = api.listPayments(locationId, order, beginTime, endTime, limit, batchToken, true);
// TODO: test validations
}
/**
* Provides the details for all refunds initiated by a merchant or any of the merchant's mobile staff during a date range. Date ranges cannot exceed one year in length.
*
* Provides the details for all refunds initiated by a merchant or any of the merchant's mobile staff during a date range. Date ranges cannot exceed one year in length.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void listRefundsTest() throws ApiException {
String locationId = null;
String order = null;
String beginTime = null;
String endTime = null;
Integer limit = null;
String batchToken = null;
List<V1Refund> response = api.listRefunds(locationId, order, beginTime, endTime, limit, batchToken);
// TODO: test validations
}
/**
* Provides summary information for all deposits and withdrawals initiated by Square to a merchant's bank account during a date range. Date ranges cannot exceed one year in length.
*
* Provides summary information for all deposits and withdrawals initiated by Square to a merchant's bank account during a date range. Date ranges cannot exceed one year in length.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void listSettlementsTest() throws ApiException {
String locationId = null;
String order = null;
String beginTime = null;
String endTime = null;
Integer limit = null;
String status = null;
String batchToken = null;
List<V1Settlement> response = api.listSettlements(locationId, order, beginTime, endTime, limit, status, batchToken);
// TODO: test validations
}
/**
* Provides non-confidential details for a merchant's associated bank account. This endpoint does not provide full bank account numbers, and there is no way to obtain a full bank account number with the Connect API.
*
* Provides non-confidential details for a merchant's associated bank account. This endpoint does not provide full bank account numbers, and there is no way to obtain a full bank account number with the Connect API.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void retrieveBankAccountTest() throws ApiException {
String locationId = null;
String bankAccountId = null;
V1BankAccount response = api.retrieveBankAccount(locationId, bankAccountId);
// TODO: test validations
}
/**
* Provides comprehensive information for a single online store order, including the order's history.
*
* Provides comprehensive information for a single online store order, including the order's history.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void retrieveOrderTest() throws ApiException {
String locationId = null;
String orderId = null;
V1Order response = api.retrieveOrder(locationId, orderId);
// TODO: test validations
}
/**
* Provides comprehensive information for a single payment.
*
* Provides comprehensive information for a single payment.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void retrievePaymentTest() throws ApiException {
String locationId = null;
String paymentId = null;
V1Payment response = api.retrievePayment(locationId, paymentId);
// TODO: test validations
}
/**
* Provides comprehensive information for a single settlement, including the entries that contribute to the settlement's total.
*
* Provides comprehensive information for a single settlement, including the entries that contribute to the settlement's total.
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void retrieveSettlementTest() throws ApiException {
String locationId = null;
String settlementId = null;
V1Settlement response = api.retrieveSettlement(locationId, settlementId);
// TODO: test validations
}
/**
* Updates the details of an online store order. Every update you perform on an order corresponds to one of three actions:
*
* Updates the details of an online store order. Every update you perform on an order corresponds to one of three actions:
*
* @throws ApiException
* if the Api call fails
*/
@Test
public void updateOrderTest() throws ApiException {
String locationId = null;
String orderId = null;
V1UpdateOrderRequest body = null;
V1Order response = api.updateOrder(locationId, orderId, body);
// TODO: test validations
}
}