@amazon-sp-api-release/amazon-sp-api-sdk-js 1.1.0 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (144) hide show
  1. package/README.md +2 -3
  2. package/helper/DefaultRateLimitMap.mjs +14 -1
  3. package/index.js +2 -0
  4. package/package.json +1 -1
  5. package/src/apluscontent_v2020_11_01/ApiClient.js +5 -1
  6. package/src/appintegrations_v2024_04_01/ApiClient.js +5 -1
  7. package/src/applications_v2023_11_30/ApiClient.js +5 -1
  8. package/src/awd_v2024_05_09/ApiClient.js +5 -1
  9. package/src/catalogitems_v2022_04_01/ApiClient.js +5 -1
  10. package/src/datakiosk_v2023_11_15/ApiClient.js +5 -1
  11. package/src/easyship_v2022_03_23/ApiClient.js +5 -1
  12. package/src/fbaeligibility_v1/ApiClient.js +5 -1
  13. package/src/fbainventory_v1/ApiClient.js +5 -1
  14. package/src/feeds_v2021_06_30/ApiClient.js +5 -1
  15. package/src/finances_2024_06_19/ApiClient.js +827 -0
  16. package/src/finances_2024_06_19/api/DefaultApi.js +125 -0
  17. package/src/finances_2024_06_19/index.js +168 -0
  18. package/src/finances_2024_06_19/model/AmazonPayContext.js +76 -0
  19. package/src/finances_2024_06_19/model/Breakdown.js +76 -0
  20. package/src/finances_2024_06_19/model/BusinessContext.js +76 -0
  21. package/src/finances_2024_06_19/model/Context.js +308 -0
  22. package/src/finances_2024_06_19/model/Currency.js +69 -0
  23. package/src/finances_2024_06_19/model/DeferredContext.js +69 -0
  24. package/src/finances_2024_06_19/model/Error.js +80 -0
  25. package/src/finances_2024_06_19/model/ErrorList.js +65 -0
  26. package/src/finances_2024_06_19/model/Item.js +93 -0
  27. package/src/finances_2024_06_19/model/ItemRelatedIdentifier.js +101 -0
  28. package/src/finances_2024_06_19/model/ListTransactionsResponse.js +62 -0
  29. package/src/finances_2024_06_19/model/MarketplaceDetails.js +69 -0
  30. package/src/finances_2024_06_19/model/PaymentsContext.js +83 -0
  31. package/src/finances_2024_06_19/model/ProductContext.js +83 -0
  32. package/src/finances_2024_06_19/model/RelatedIdentifier.js +137 -0
  33. package/src/finances_2024_06_19/model/SellingPartnerMetadata.js +76 -0
  34. package/src/finances_2024_06_19/model/TimeRangeContext.js +69 -0
  35. package/src/finances_2024_06_19/model/Transaction.js +143 -0
  36. package/src/finances_2024_06_19/model/TransactionsPayload.js +70 -0
  37. package/src/finances_v0/ApiClient.js +5 -1
  38. package/src/fulfillmentinbound_v0/ApiClient.js +5 -1
  39. package/src/fulfillmentinbound_v2024_03_20/ApiClient.js +5 -1
  40. package/src/fulfillmentoutbound_v2020_07_01/ApiClient.js +5 -1
  41. package/src/invoices_v2024_06_19/ApiClient.js +5 -1
  42. package/src/invoicing_v0/ApiClient.js +5 -1
  43. package/src/listingsitems_v2021_08_01/ApiClient.js +5 -1
  44. package/src/listingsitems_v2021_08_01/api/ListingsApi.js +6 -6
  45. package/src/listingsitems_v2021_08_01/model/FulfillmentAvailability.js +2 -2
  46. package/src/listingsitems_v2021_08_01/model/Issue.js +2 -2
  47. package/src/listingsitems_v2021_08_01/model/IssueExemption.js +1 -1
  48. package/src/listingsitems_v2021_08_01/model/ItemRelationship.js +1 -1
  49. package/src/listingsitems_v2021_08_01/model/ItemSearchResults.js +2 -2
  50. package/src/listingsitems_v2021_08_01/model/Pagination.js +1 -1
  51. package/src/listingsitems_v2021_08_01/model/PatchOperation.js +9 -3
  52. package/src/listingsrestrictions_v2021_08_01/ApiClient.js +5 -1
  53. package/src/merchantfulfillment_v0/ApiClient.js +5 -1
  54. package/src/messaging_v1/ApiClient.js +5 -1
  55. package/src/notifications_v1/ApiClient.js +5 -1
  56. package/src/orders_v0/ApiClient.js +5 -1
  57. package/src/orders_v0/api/OrdersV0Api.js +26 -26
  58. package/src/orders_v0/api/ShipmentApi.js +2 -2
  59. package/src/orders_v0/index.js +0 -7
  60. package/src/orders_v0/model/AmazonPrograms.js +3 -3
  61. package/src/orders_v0/model/OrderItem.js +0 -7
  62. package/src/orders_v0/model/OrdersList.js +1 -1
  63. package/src/orders_v0/model/PackageDetail.js +1 -1
  64. package/src/pricing_v0/ApiClient.js +5 -1
  65. package/src/pricing_v2022_05_01/ApiClient.js +5 -1
  66. package/src/pricing_v2022_05_01/model/CompetitiveSummaryRequest.js +2 -2
  67. package/src/pricing_v2022_05_01/model/CompetitiveSummaryResponseBody.js +2 -2
  68. package/src/pricing_v2022_05_01/model/FeaturedOfferExpectedPriceRequest.js +3 -3
  69. package/src/pricing_v2022_05_01/model/FeaturedOfferExpectedPriceRequestParams.js +2 -2
  70. package/src/pricing_v2022_05_01/model/FeaturedOfferSegment.js +7 -1
  71. package/src/pricing_v2022_05_01/model/LowestPricedOffersInput.js +2 -2
  72. package/src/pricing_v2022_05_01/model/OfferIdentifier.js +2 -2
  73. package/src/pricing_v2022_05_01/model/ReferencePrice.js +2 -2
  74. package/src/productfees_v0/ApiClient.js +5 -1
  75. package/src/producttypedefinitions_v2020_09_01/ApiClient.js +5 -1
  76. package/src/replenishment_v2022_11_07/ApiClient.js +5 -1
  77. package/src/reports_v2021_06_30/ApiClient.js +5 -1
  78. package/src/sales_v1/ApiClient.js +5 -1
  79. package/src/sales_v1/api/SalesApi.js +4 -1
  80. package/src/sellerWallet_2024_03_01/ApiClient.js +827 -0
  81. package/src/sellerWallet_2024_03_01/api/AccountsApi.js +212 -0
  82. package/src/sellerWallet_2024_03_01/api/TransactionsApi.js +233 -0
  83. package/src/sellerWallet_2024_03_01/api/TransferPreviewApi.js +144 -0
  84. package/src/sellerWallet_2024_03_01/api/TransferScheduleApi.js +347 -0
  85. package/src/sellerWallet_2024_03_01/index.js +322 -0
  86. package/src/sellerWallet_2024_03_01/model/AccountHolderAddress.js +114 -0
  87. package/src/sellerWallet_2024_03_01/model/Balance.js +98 -0
  88. package/src/sellerWallet_2024_03_01/model/BalanceListing.js +63 -0
  89. package/src/sellerWallet_2024_03_01/model/BalanceType.js +54 -0
  90. package/src/sellerWallet_2024_03_01/model/BankAccount.js +148 -0
  91. package/src/sellerWallet_2024_03_01/model/BankAccountHolderStatus.js +54 -0
  92. package/src/sellerWallet_2024_03_01/model/BankAccountListing.js +65 -0
  93. package/src/sellerWallet_2024_03_01/model/BankAccountNumberFormat.js +42 -0
  94. package/src/sellerWallet_2024_03_01/model/BankAccountOwnershipType.js +48 -0
  95. package/src/sellerWallet_2024_03_01/model/BankNumberFormat.js +42 -0
  96. package/src/sellerWallet_2024_03_01/model/Currency.js +69 -0
  97. package/src/sellerWallet_2024_03_01/model/DeleteTransferSchedule.js +80 -0
  98. package/src/sellerWallet_2024_03_01/model/Error.js +80 -0
  99. package/src/sellerWallet_2024_03_01/model/ErrorList.js +65 -0
  100. package/src/sellerWallet_2024_03_01/model/Fee.js +91 -0
  101. package/src/sellerWallet_2024_03_01/model/FeeType.js +48 -0
  102. package/src/sellerWallet_2024_03_01/model/FxRateDetails.js +91 -0
  103. package/src/sellerWallet_2024_03_01/model/PaymentPreference.js +73 -0
  104. package/src/sellerWallet_2024_03_01/model/PaymentPreferencePaymentType.js +42 -0
  105. package/src/sellerWallet_2024_03_01/model/RateDirection.js +42 -0
  106. package/src/sellerWallet_2024_03_01/model/RecurringFrequency.js +54 -0
  107. package/src/sellerWallet_2024_03_01/model/ScheduleExpression.js +71 -0
  108. package/src/sellerWallet_2024_03_01/model/ScheduleExpressionType.js +42 -0
  109. package/src/sellerWallet_2024_03_01/model/ScheduleTransferType.js +36 -0
  110. package/src/sellerWallet_2024_03_01/model/Transaction.js +187 -0
  111. package/src/sellerWallet_2024_03_01/model/TransactionAccount.js +112 -0
  112. package/src/sellerWallet_2024_03_01/model/TransactionInitiationRequest.js +121 -0
  113. package/src/sellerWallet_2024_03_01/model/TransactionInstrumentDetails.js +73 -0
  114. package/src/sellerWallet_2024_03_01/model/TransactionListing.js +72 -0
  115. package/src/sellerWallet_2024_03_01/model/TransactionStatus.js +66 -0
  116. package/src/sellerWallet_2024_03_01/model/TransactionType.js +42 -0
  117. package/src/sellerWallet_2024_03_01/model/TransferRatePreview.js +91 -0
  118. package/src/sellerWallet_2024_03_01/model/TransferSchedule.js +123 -0
  119. package/src/sellerWallet_2024_03_01/model/TransferScheduleFailures.js +73 -0
  120. package/src/sellerWallet_2024_03_01/model/TransferScheduleInformation.js +83 -0
  121. package/src/sellerWallet_2024_03_01/model/TransferScheduleListing.js +72 -0
  122. package/src/sellerWallet_2024_03_01/model/TransferScheduleRequest.js +125 -0
  123. package/src/sellerWallet_2024_03_01/model/TransferScheduleStatus.js +54 -0
  124. package/src/sellers_v1/ApiClient.js +5 -1
  125. package/src/services_v1/ApiClient.js +5 -1
  126. package/src/shipping_v2/ApiClient.js +5 -1
  127. package/src/solicitations_v1/ApiClient.js +5 -1
  128. package/src/supplysources_v2020_07_01/ApiClient.js +5 -1
  129. package/src/tokens_v2021_03_01/ApiClient.js +5 -1
  130. package/src/transfers_v2024_06_01/ApiClient.js +5 -1
  131. package/src/uploads_v2020_11_01/ApiClient.js +5 -1
  132. package/src/vehicles_v2024_11_01/ApiClient.js +5 -1
  133. package/src/vendordfinventory_v1/ApiClient.js +5 -1
  134. package/src/vendordforders_v2021_12_28/ApiClient.js +5 -1
  135. package/src/vendordfpayments_v1/ApiClient.js +5 -1
  136. package/src/vendordfshipping_v2021_12_28/ApiClient.js +5 -1
  137. package/src/vendordftransactions_v2021_12_28/ApiClient.js +5 -1
  138. package/src/vendorinvoices_v1/ApiClient.js +5 -1
  139. package/src/vendororders_v1/ApiClient.js +5 -1
  140. package/src/vendorshipments_v1/ApiClient.js +5 -1
  141. package/src/vendorshipments_v1/api/VendorShippingApi.js +2 -2
  142. package/src/vendorshipments_v1/model/Shipment.js +3 -3
  143. package/src/vendortransactionstatus_v1/ApiClient.js +5 -1
  144. package/src/orders_v0/model/ExportInfo.js +0 -69
@@ -0,0 +1,347 @@
1
+ /**
2
+ * The Selling Partner API for Amazon Seller Wallet Open Banking API
3
+ * The Selling Partner API for Seller Wallet (Seller Wallet API) provides financial information that is relevant to a seller's Seller Wallet account. You can obtain financial events, balances, and transfer schedules for Seller Wallet accounts. You can also schedule and initiate transactions.
4
+ *
5
+ * The version of the OpenAPI document: 2024-03-01
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ *
12
+ */
13
+
14
+ import { ApiClient } from '../ApiClient.js'
15
+ import { DeleteTransferSchedule } from '../model/DeleteTransferSchedule.js'
16
+ import { ErrorList } from '../model/ErrorList.js'
17
+ import { TransferSchedule } from '../model/TransferSchedule.js'
18
+ import { TransferScheduleListing } from '../model/TransferScheduleListing.js'
19
+ import { TransferScheduleRequest } from '../model/TransferScheduleRequest.js'
20
+ import { SuperagentRateLimiter } from '../../../helper/SuperagentRateLimiter.mjs'
21
+ import { DefaultRateLimitFetcher } from '../../../helper/DefaultRateLimitFetcher.mjs'
22
+
23
+ /**
24
+ * TransferSchedule service.
25
+ * @module sellerWallet_2024_03_01/api/TransferScheduleApi
26
+ * @version 2024-03-01
27
+ */
28
+ export class TransferScheduleApi {
29
+ // Private memeber stores the default rate limiters
30
+ #defaultRateLimiterMap
31
+
32
+ /**
33
+ * Constructs a new TransferScheduleApi.
34
+ * @alias module:sellerWallet_2024_03_01/api/TransferScheduleApi
35
+ * @class
36
+ * @param {module:sellerWallet_2024_03_01/ApiClient} [apiClient] Optional API client implementation to use,
37
+ * default to {@link module:sellerWallet_2024_03_01/ApiClient#instance} if unspecified.
38
+ */
39
+ constructor (apiClient) {
40
+ this.apiClient = apiClient || ApiClient.instance
41
+ this.initializeDefaultRateLimiterMap()
42
+ }
43
+
44
+ /**
45
+ * Initialize rate limiters for API operations
46
+ */
47
+ initializeDefaultRateLimiterMap () {
48
+ this.#defaultRateLimiterMap = new Map()
49
+ const defaultRateLimitFetcher = new DefaultRateLimitFetcher()
50
+ const operations = [
51
+ 'TransferScheduleApi-createTransferSchedule',
52
+ 'TransferScheduleApi-deleteScheduleTransaction',
53
+ 'TransferScheduleApi-getTransferSchedule',
54
+ 'TransferScheduleApi-listTransferSchedules',
55
+ 'TransferScheduleApi-updateTransferSchedule'
56
+ ]
57
+
58
+ for (const operation of operations) {
59
+ const config = defaultRateLimitFetcher.getLimit(operation)
60
+ this.#defaultRateLimiterMap.set(operation, new SuperagentRateLimiter(config))
61
+ }
62
+ }
63
+
64
+ /**
65
+ * Get rate limiter for a specific operation
66
+ * @param {String} operation name
67
+ */
68
+ getRateLimiter (operation) {
69
+ return this.#defaultRateLimiterMap.get(operation)
70
+ }
71
+
72
+ /**
73
+ * Create a transfer schedule request from Amazon Seller Wallet account to another customer-provided account
74
+ * Create a transfer schedule request from an Amazon Seller Wallet account to another customer-provided account.
75
+ * @param {String} destAccountDigitalSignature Digital signature for the destination bank account details.
76
+ * @param {String} amountDigitalSignature Digital signature for the source currency transaction amount.
77
+ * @param {module:sellerWallet_2024_03_01/model/TransferScheduleRequest} body The payload of the request.
78
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:sellerWallet_2024_03_01/model/TransferSchedule} and HTTP response
79
+ */
80
+ createTransferScheduleWithHttpInfo (destAccountDigitalSignature, amountDigitalSignature, body) {
81
+ const postBody = body
82
+
83
+ // verify the required parameter 'destAccountDigitalSignature' is set
84
+ if (destAccountDigitalSignature === undefined || destAccountDigitalSignature === null) {
85
+ throw new Error("Missing the required parameter 'destAccountDigitalSignature' when calling createTransferSchedule")
86
+ }
87
+
88
+ // verify the required parameter 'amountDigitalSignature' is set
89
+ if (amountDigitalSignature === undefined || amountDigitalSignature === null) {
90
+ throw new Error("Missing the required parameter 'amountDigitalSignature' when calling createTransferSchedule")
91
+ }
92
+
93
+ // verify the required parameter 'body' is set
94
+ if (body === undefined || body === null) {
95
+ throw new Error("Missing the required parameter 'body' when calling createTransferSchedule")
96
+ }
97
+
98
+ const pathParams = {
99
+ }
100
+ const queryParams = {
101
+ }
102
+ const headerParams = {
103
+ destAccountDigitalSignature,
104
+ amountDigitalSignature
105
+ }
106
+ const formParams = {
107
+ }
108
+
109
+ const contentTypes = ['application/json']
110
+ const accepts = ['application/json']
111
+ const returnType = TransferSchedule
112
+
113
+ return this.apiClient.callApi('TransferScheduleApi-createTransferSchedule',
114
+ '/finances/transfers/wallet/2024-03-01/transferSchedules', 'POST',
115
+ pathParams, queryParams, headerParams, formParams, postBody,
116
+ contentTypes, accepts, returnType, this.getRateLimiter('TransferScheduleApi-createTransferSchedule')
117
+ )
118
+ }
119
+
120
+ /**
121
+ * Create a transfer schedule request from Amazon Seller Wallet account to another customer-provided account
122
+ * Create a transfer schedule request from an Amazon Seller Wallet account to another customer-provided account.
123
+ * @param {String} destAccountDigitalSignature Digital signature for the destination bank account details.
124
+ * @param {String} amountDigitalSignature Digital signature for the source currency transaction amount.
125
+ * @param {module:sellerWallet_2024_03_01/model/TransferScheduleRequest} body The payload of the request.
126
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:sellerWallet_2024_03_01/model/TransferSchedule}
127
+ */
128
+ createTransferSchedule (destAccountDigitalSignature, amountDigitalSignature, body) {
129
+ return this.createTransferScheduleWithHttpInfo(destAccountDigitalSignature, amountDigitalSignature, body)
130
+ .then(function (response_and_data) {
131
+ return response_and_data.data
132
+ })
133
+ }
134
+
135
+ /**
136
+ * Delete a transaction request that is scheduled from Amazon Seller Wallet account to another customer-provided account
137
+ * Delete a transaction request that is scheduled from Amazon Seller Wallet account to another customer-provided account.
138
+ * @param {String} transferScheduleId A unique reference ID for a scheduled transfer.
139
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:sellerWallet_2024_03_01/model/DeleteTransferSchedule} and HTTP response
140
+ */
141
+ deleteScheduleTransactionWithHttpInfo (transferScheduleId) {
142
+ const postBody = null
143
+
144
+ // verify the required parameter 'transferScheduleId' is set
145
+ if (transferScheduleId === undefined || transferScheduleId === null) {
146
+ throw new Error("Missing the required parameter 'transferScheduleId' when calling deleteScheduleTransaction")
147
+ }
148
+
149
+ const pathParams = {
150
+ transferScheduleId
151
+ }
152
+ const queryParams = {
153
+ }
154
+ const headerParams = {
155
+ }
156
+ const formParams = {
157
+ }
158
+
159
+ const contentTypes = []
160
+ const accepts = ['application/json']
161
+ const returnType = DeleteTransferSchedule
162
+
163
+ return this.apiClient.callApi('TransferScheduleApi-deleteScheduleTransaction',
164
+ '/finances/transfers/wallet/2024-03-01/transferSchedules/{transferScheduleId}', 'DELETE',
165
+ pathParams, queryParams, headerParams, formParams, postBody,
166
+ contentTypes, accepts, returnType, this.getRateLimiter('TransferScheduleApi-deleteScheduleTransaction')
167
+ )
168
+ }
169
+
170
+ /**
171
+ * Delete a transaction request that is scheduled from Amazon Seller Wallet account to another customer-provided account
172
+ * Delete a transaction request that is scheduled from Amazon Seller Wallet account to another customer-provided account.
173
+ * @param {String} transferScheduleId A unique reference ID for a scheduled transfer.
174
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:sellerWallet_2024_03_01/model/DeleteTransferSchedule}
175
+ */
176
+ deleteScheduleTransaction (transferScheduleId) {
177
+ return this.deleteScheduleTransactionWithHttpInfo(transferScheduleId)
178
+ .then(function (response_and_data) {
179
+ return response_and_data.data
180
+ })
181
+ }
182
+
183
+ /**
184
+ * Find particular Amazon Seller Wallet account transfer schedule by Amazon transfer schedule identifier
185
+ * Find a particular Amazon Seller Wallet account transfer schedule.
186
+ * @param {String} transferScheduleId The schedule ID of the Amazon Seller Wallet transfer.
187
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:sellerWallet_2024_03_01/model/TransferSchedule} and HTTP response
188
+ */
189
+ getTransferScheduleWithHttpInfo (transferScheduleId) {
190
+ const postBody = null
191
+
192
+ // verify the required parameter 'transferScheduleId' is set
193
+ if (transferScheduleId === undefined || transferScheduleId === null) {
194
+ throw new Error("Missing the required parameter 'transferScheduleId' when calling getTransferSchedule")
195
+ }
196
+
197
+ const pathParams = {
198
+ transferScheduleId
199
+ }
200
+ const queryParams = {
201
+ }
202
+ const headerParams = {
203
+ }
204
+ const formParams = {
205
+ }
206
+
207
+ const contentTypes = []
208
+ const accepts = ['application/json']
209
+ const returnType = TransferSchedule
210
+
211
+ return this.apiClient.callApi('TransferScheduleApi-getTransferSchedule',
212
+ '/finances/transfers/wallet/2024-03-01/transferSchedules/{transferScheduleId}', 'GET',
213
+ pathParams, queryParams, headerParams, formParams, postBody,
214
+ contentTypes, accepts, returnType, this.getRateLimiter('TransferScheduleApi-getTransferSchedule')
215
+ )
216
+ }
217
+
218
+ /**
219
+ * Find particular Amazon Seller Wallet account transfer schedule by Amazon transfer schedule identifier
220
+ * Find a particular Amazon Seller Wallet account transfer schedule.
221
+ * @param {String} transferScheduleId The schedule ID of the Amazon Seller Wallet transfer.
222
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:sellerWallet_2024_03_01/model/TransferSchedule}
223
+ */
224
+ getTransferSchedule (transferScheduleId) {
225
+ return this.getTransferScheduleWithHttpInfo(transferScheduleId)
226
+ .then(function (response_and_data) {
227
+ return response_and_data.data
228
+ })
229
+ }
230
+
231
+ /**
232
+ * The API will return all the transfer schedules for a given Amazon Seller Wallet account
233
+ * Returns all transfer schedules of a given Amazon Seller Wallet bank account with the schedule ID in response if present.
234
+ * @param {String} accountId The ID of the Amazon Seller Wallet account.
235
+ * @param {Object} opts Optional parameters
236
+ * @param {String} opts.nextPageToken A token that you use to retrieve the next page of results. The response includes `nextPageToken` when the number of results exceeds the specified `pageSize` value. To get the next page of results, call the operation with this token and include the same arguments as the call that produced the token. To get a complete list, call this operation until `nextPageToken` is null. Note that this operation can return empty pages.
237
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:sellerWallet_2024_03_01/model/TransferScheduleListing} and HTTP response
238
+ */
239
+ listTransferSchedulesWithHttpInfo (accountId, opts) {
240
+ opts = opts || {}
241
+ const postBody = null
242
+
243
+ // verify the required parameter 'accountId' is set
244
+ if (accountId === undefined || accountId === null) {
245
+ throw new Error("Missing the required parameter 'accountId' when calling listTransferSchedules")
246
+ }
247
+
248
+ const pathParams = {
249
+ }
250
+ const queryParams = {
251
+ accountId,
252
+ nextPageToken: opts.nextPageToken
253
+ }
254
+ const headerParams = {
255
+ }
256
+ const formParams = {
257
+ }
258
+
259
+ const contentTypes = []
260
+ const accepts = ['application/json']
261
+ const returnType = TransferScheduleListing
262
+
263
+ return this.apiClient.callApi('TransferScheduleApi-listTransferSchedules',
264
+ '/finances/transfers/wallet/2024-03-01/transferSchedules', 'GET',
265
+ pathParams, queryParams, headerParams, formParams, postBody,
266
+ contentTypes, accepts, returnType, this.getRateLimiter('TransferScheduleApi-listTransferSchedules')
267
+ )
268
+ }
269
+
270
+ /**
271
+ * The API will return all the transfer schedules for a given Amazon Seller Wallet account
272
+ * Returns all transfer schedules of a given Amazon Seller Wallet bank account with the schedule ID in response if present.
273
+ * @param {String} accountId The ID of the Amazon Seller Wallet account.
274
+ * @param {Object} opts Optional parameters
275
+ * @param {String} opts.nextPageToken A token that you use to retrieve the next page of results. The response includes `nextPageToken` when the number of results exceeds the specified `pageSize` value. To get the next page of results, call the operation with this token and include the same arguments as the call that produced the token. To get a complete list, call this operation until `nextPageToken` is null. Note that this operation can return empty pages.
276
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:sellerWallet_2024_03_01/model/TransferScheduleListing}
277
+ */
278
+ listTransferSchedules (accountId, opts) {
279
+ return this.listTransferSchedulesWithHttpInfo(accountId, opts)
280
+ .then(function (response_and_data) {
281
+ return response_and_data.data
282
+ })
283
+ }
284
+
285
+ /**
286
+ * Update a transfer schedule information. Only fields (i.e; transferScheduleInformation, paymentPreference, transferScheduleStatus) in the request body can be updated.
287
+ * Update transfer schedule information. Returns a transfer belonging to the updated scheduled transfer request.
288
+ * @param {String} destAccountDigitalSignature Digital signature for the destination bank account details.
289
+ * @param {String} amountDigitalSignature Digital signature for the source currency transaction amount.
290
+ * @param {module:sellerWallet_2024_03_01/model/TransferSchedule} body The payload of the scheduled transfer request that is to be updated.
291
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:sellerWallet_2024_03_01/model/TransferSchedule} and HTTP response
292
+ */
293
+ updateTransferScheduleWithHttpInfo (destAccountDigitalSignature, amountDigitalSignature, body) {
294
+ const postBody = body
295
+
296
+ // verify the required parameter 'destAccountDigitalSignature' is set
297
+ if (destAccountDigitalSignature === undefined || destAccountDigitalSignature === null) {
298
+ throw new Error("Missing the required parameter 'destAccountDigitalSignature' when calling updateTransferSchedule")
299
+ }
300
+
301
+ // verify the required parameter 'amountDigitalSignature' is set
302
+ if (amountDigitalSignature === undefined || amountDigitalSignature === null) {
303
+ throw new Error("Missing the required parameter 'amountDigitalSignature' when calling updateTransferSchedule")
304
+ }
305
+
306
+ // verify the required parameter 'body' is set
307
+ if (body === undefined || body === null) {
308
+ throw new Error("Missing the required parameter 'body' when calling updateTransferSchedule")
309
+ }
310
+
311
+ const pathParams = {
312
+ }
313
+ const queryParams = {
314
+ }
315
+ const headerParams = {
316
+ destAccountDigitalSignature,
317
+ amountDigitalSignature
318
+ }
319
+ const formParams = {
320
+ }
321
+
322
+ const contentTypes = ['application/json']
323
+ const accepts = ['application/json']
324
+ const returnType = TransferSchedule
325
+
326
+ return this.apiClient.callApi('TransferScheduleApi-updateTransferSchedule',
327
+ '/finances/transfers/wallet/2024-03-01/transferSchedules', 'PUT',
328
+ pathParams, queryParams, headerParams, formParams, postBody,
329
+ contentTypes, accepts, returnType, this.getRateLimiter('TransferScheduleApi-updateTransferSchedule')
330
+ )
331
+ }
332
+
333
+ /**
334
+ * Update a transfer schedule information. Only fields (i.e; transferScheduleInformation, paymentPreference, transferScheduleStatus) in the request body can be updated.
335
+ * Update transfer schedule information. Returns a transfer belonging to the updated scheduled transfer request.
336
+ * @param {String} destAccountDigitalSignature Digital signature for the destination bank account details.
337
+ * @param {String} amountDigitalSignature Digital signature for the source currency transaction amount.
338
+ * @param {module:sellerWallet_2024_03_01/model/TransferSchedule} body The payload of the scheduled transfer request that is to be updated.
339
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:sellerWallet_2024_03_01/model/TransferSchedule}
340
+ */
341
+ updateTransferSchedule (destAccountDigitalSignature, amountDigitalSignature, body) {
342
+ return this.updateTransferScheduleWithHttpInfo(destAccountDigitalSignature, amountDigitalSignature, body)
343
+ .then(function (response_and_data) {
344
+ return response_and_data.data
345
+ })
346
+ }
347
+ }
@@ -0,0 +1,322 @@
1
+ /**
2
+ * The Selling Partner API for Amazon Seller Wallet Open Banking API
3
+ * The Selling Partner API for Seller Wallet (Seller Wallet API) provides financial information that is relevant to a seller's Seller Wallet account. You can obtain financial events, balances, and transfer schedules for Seller Wallet accounts. You can also schedule and initiate transactions.
4
+ *
5
+ * The version of the OpenAPI document: 2024-03-01
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ *
12
+ */
13
+
14
+ import { ApiClient } from './ApiClient.js'
15
+ import { AccountHolderAddress } from './model/AccountHolderAddress.js'
16
+ import { Balance } from './model/Balance.js'
17
+ import { BalanceListing } from './model/BalanceListing.js'
18
+ import { BalanceType } from './model/BalanceType.js'
19
+ import { BankAccount } from './model/BankAccount.js'
20
+ import { BankAccountHolderStatus } from './model/BankAccountHolderStatus.js'
21
+ import { BankAccountListing } from './model/BankAccountListing.js'
22
+ import { BankAccountNumberFormat } from './model/BankAccountNumberFormat.js'
23
+ import { BankAccountOwnershipType } from './model/BankAccountOwnershipType.js'
24
+ import { BankNumberFormat } from './model/BankNumberFormat.js'
25
+ import { Currency } from './model/Currency.js'
26
+ import { DeleteTransferSchedule } from './model/DeleteTransferSchedule.js'
27
+ import { Error } from './model/Error.js'
28
+ import { ErrorList } from './model/ErrorList.js'
29
+ import { Fee } from './model/Fee.js'
30
+ import { FeeType } from './model/FeeType.js'
31
+ import { FxRateDetails } from './model/FxRateDetails.js'
32
+ import { PaymentPreference } from './model/PaymentPreference.js'
33
+ import { PaymentPreferencePaymentType } from './model/PaymentPreferencePaymentType.js'
34
+ import { RateDirection } from './model/RateDirection.js'
35
+ import { RecurringFrequency } from './model/RecurringFrequency.js'
36
+ import { ScheduleExpression } from './model/ScheduleExpression.js'
37
+ import { ScheduleExpressionType } from './model/ScheduleExpressionType.js'
38
+ import { ScheduleTransferType } from './model/ScheduleTransferType.js'
39
+ import { Transaction } from './model/Transaction.js'
40
+ import { TransactionAccount } from './model/TransactionAccount.js'
41
+ import { TransactionInitiationRequest } from './model/TransactionInitiationRequest.js'
42
+ import { TransactionInstrumentDetails } from './model/TransactionInstrumentDetails.js'
43
+ import { TransactionListing } from './model/TransactionListing.js'
44
+ import { TransactionStatus } from './model/TransactionStatus.js'
45
+ import { TransactionType } from './model/TransactionType.js'
46
+ import { TransferRatePreview } from './model/TransferRatePreview.js'
47
+ import { TransferSchedule } from './model/TransferSchedule.js'
48
+ import { TransferScheduleFailures } from './model/TransferScheduleFailures.js'
49
+ import { TransferScheduleInformation } from './model/TransferScheduleInformation.js'
50
+ import { TransferScheduleListing } from './model/TransferScheduleListing.js'
51
+ import { TransferScheduleRequest } from './model/TransferScheduleRequest.js'
52
+ import { TransferScheduleStatus } from './model/TransferScheduleStatus.js'
53
+ import { AccountsApi } from './api/AccountsApi.js'
54
+ import { TransactionsApi } from './api/TransactionsApi.js'
55
+ import { TransferPreviewApi } from './api/TransferPreviewApi.js'
56
+ import { TransferScheduleApi } from './api/TransferScheduleApi.js'
57
+
58
+ /**
59
+ * The Selling Partner API for Seller Wallet (Seller Wallet API) provides financial information that is relevant to a seller&#39;s Seller Wallet account. You can obtain financial events, balances, and transfer schedules for Seller Wallet accounts. You can also schedule and initiate transactions..<br>
60
+ * The <code>index</code> module provides access to constructors for all the classes which comprise the public API.
61
+ * @module sellerWallet_2024_03_01/index
62
+ * @version 2024-03-01
63
+ */
64
+ export {
65
+ /**
66
+ * The ApiClient constructor.
67
+ * @property {module:sellerWallet_2024_03_01/ApiClient}
68
+ */
69
+ ApiClient,
70
+
71
+ /**
72
+ * The AccountHolderAddress model constructor.
73
+ * @property {module:sellerWallet_2024_03_01/model/AccountHolderAddress}
74
+ */
75
+ AccountHolderAddress,
76
+
77
+ /**
78
+ * The Balance model constructor.
79
+ * @property {module:sellerWallet_2024_03_01/model/Balance}
80
+ */
81
+ Balance,
82
+
83
+ /**
84
+ * The BalanceListing model constructor.
85
+ * @property {module:sellerWallet_2024_03_01/model/BalanceListing}
86
+ */
87
+ BalanceListing,
88
+
89
+ /**
90
+ * The BalanceType model constructor.
91
+ * @property {module:sellerWallet_2024_03_01/model/BalanceType}
92
+ */
93
+ BalanceType,
94
+
95
+ /**
96
+ * The BankAccount model constructor.
97
+ * @property {module:sellerWallet_2024_03_01/model/BankAccount}
98
+ */
99
+ BankAccount,
100
+
101
+ /**
102
+ * The BankAccountHolderStatus model constructor.
103
+ * @property {module:sellerWallet_2024_03_01/model/BankAccountHolderStatus}
104
+ */
105
+ BankAccountHolderStatus,
106
+
107
+ /**
108
+ * The BankAccountListing model constructor.
109
+ * @property {module:sellerWallet_2024_03_01/model/BankAccountListing}
110
+ */
111
+ BankAccountListing,
112
+
113
+ /**
114
+ * The BankAccountNumberFormat model constructor.
115
+ * @property {module:sellerWallet_2024_03_01/model/BankAccountNumberFormat}
116
+ */
117
+ BankAccountNumberFormat,
118
+
119
+ /**
120
+ * The BankAccountOwnershipType model constructor.
121
+ * @property {module:sellerWallet_2024_03_01/model/BankAccountOwnershipType}
122
+ */
123
+ BankAccountOwnershipType,
124
+
125
+ /**
126
+ * The BankNumberFormat model constructor.
127
+ * @property {module:sellerWallet_2024_03_01/model/BankNumberFormat}
128
+ */
129
+ BankNumberFormat,
130
+
131
+ /**
132
+ * The Currency model constructor.
133
+ * @property {module:sellerWallet_2024_03_01/model/Currency}
134
+ */
135
+ Currency,
136
+
137
+ /**
138
+ * The DeleteTransferSchedule model constructor.
139
+ * @property {module:sellerWallet_2024_03_01/model/DeleteTransferSchedule}
140
+ */
141
+ DeleteTransferSchedule,
142
+
143
+ /**
144
+ * The Error model constructor.
145
+ * @property {module:sellerWallet_2024_03_01/model/Error}
146
+ */
147
+ Error,
148
+
149
+ /**
150
+ * The ErrorList model constructor.
151
+ * @property {module:sellerWallet_2024_03_01/model/ErrorList}
152
+ */
153
+ ErrorList,
154
+
155
+ /**
156
+ * The Fee model constructor.
157
+ * @property {module:sellerWallet_2024_03_01/model/Fee}
158
+ */
159
+ Fee,
160
+
161
+ /**
162
+ * The FeeType model constructor.
163
+ * @property {module:sellerWallet_2024_03_01/model/FeeType}
164
+ */
165
+ FeeType,
166
+
167
+ /**
168
+ * The FxRateDetails model constructor.
169
+ * @property {module:sellerWallet_2024_03_01/model/FxRateDetails}
170
+ */
171
+ FxRateDetails,
172
+
173
+ /**
174
+ * The PaymentPreference model constructor.
175
+ * @property {module:sellerWallet_2024_03_01/model/PaymentPreference}
176
+ */
177
+ PaymentPreference,
178
+
179
+ /**
180
+ * The PaymentPreferencePaymentType model constructor.
181
+ * @property {module:sellerWallet_2024_03_01/model/PaymentPreferencePaymentType}
182
+ */
183
+ PaymentPreferencePaymentType,
184
+
185
+ /**
186
+ * The RateDirection model constructor.
187
+ * @property {module:sellerWallet_2024_03_01/model/RateDirection}
188
+ */
189
+ RateDirection,
190
+
191
+ /**
192
+ * The RecurringFrequency model constructor.
193
+ * @property {module:sellerWallet_2024_03_01/model/RecurringFrequency}
194
+ */
195
+ RecurringFrequency,
196
+
197
+ /**
198
+ * The ScheduleExpression model constructor.
199
+ * @property {module:sellerWallet_2024_03_01/model/ScheduleExpression}
200
+ */
201
+ ScheduleExpression,
202
+
203
+ /**
204
+ * The ScheduleExpressionType model constructor.
205
+ * @property {module:sellerWallet_2024_03_01/model/ScheduleExpressionType}
206
+ */
207
+ ScheduleExpressionType,
208
+
209
+ /**
210
+ * The ScheduleTransferType model constructor.
211
+ * @property {module:sellerWallet_2024_03_01/model/ScheduleTransferType}
212
+ */
213
+ ScheduleTransferType,
214
+
215
+ /**
216
+ * The Transaction model constructor.
217
+ * @property {module:sellerWallet_2024_03_01/model/Transaction}
218
+ */
219
+ Transaction,
220
+
221
+ /**
222
+ * The TransactionAccount model constructor.
223
+ * @property {module:sellerWallet_2024_03_01/model/TransactionAccount}
224
+ */
225
+ TransactionAccount,
226
+
227
+ /**
228
+ * The TransactionInitiationRequest model constructor.
229
+ * @property {module:sellerWallet_2024_03_01/model/TransactionInitiationRequest}
230
+ */
231
+ TransactionInitiationRequest,
232
+
233
+ /**
234
+ * The TransactionInstrumentDetails model constructor.
235
+ * @property {module:sellerWallet_2024_03_01/model/TransactionInstrumentDetails}
236
+ */
237
+ TransactionInstrumentDetails,
238
+
239
+ /**
240
+ * The TransactionListing model constructor.
241
+ * @property {module:sellerWallet_2024_03_01/model/TransactionListing}
242
+ */
243
+ TransactionListing,
244
+
245
+ /**
246
+ * The TransactionStatus model constructor.
247
+ * @property {module:sellerWallet_2024_03_01/model/TransactionStatus}
248
+ */
249
+ TransactionStatus,
250
+
251
+ /**
252
+ * The TransactionType model constructor.
253
+ * @property {module:sellerWallet_2024_03_01/model/TransactionType}
254
+ */
255
+ TransactionType,
256
+
257
+ /**
258
+ * The TransferRatePreview model constructor.
259
+ * @property {module:sellerWallet_2024_03_01/model/TransferRatePreview}
260
+ */
261
+ TransferRatePreview,
262
+
263
+ /**
264
+ * The TransferSchedule model constructor.
265
+ * @property {module:sellerWallet_2024_03_01/model/TransferSchedule}
266
+ */
267
+ TransferSchedule,
268
+
269
+ /**
270
+ * The TransferScheduleFailures model constructor.
271
+ * @property {module:sellerWallet_2024_03_01/model/TransferScheduleFailures}
272
+ */
273
+ TransferScheduleFailures,
274
+
275
+ /**
276
+ * The TransferScheduleInformation model constructor.
277
+ * @property {module:sellerWallet_2024_03_01/model/TransferScheduleInformation}
278
+ */
279
+ TransferScheduleInformation,
280
+
281
+ /**
282
+ * The TransferScheduleListing model constructor.
283
+ * @property {module:sellerWallet_2024_03_01/model/TransferScheduleListing}
284
+ */
285
+ TransferScheduleListing,
286
+
287
+ /**
288
+ * The TransferScheduleRequest model constructor.
289
+ * @property {module:sellerWallet_2024_03_01/model/TransferScheduleRequest}
290
+ */
291
+ TransferScheduleRequest,
292
+
293
+ /**
294
+ * The TransferScheduleStatus model constructor.
295
+ * @property {module:sellerWallet_2024_03_01/model/TransferScheduleStatus}
296
+ */
297
+ TransferScheduleStatus,
298
+
299
+ /**
300
+ * The AccountsApi service constructor.
301
+ * @property {module:sellerWallet_2024_03_01/api/AccountsApi}
302
+ */
303
+ AccountsApi,
304
+
305
+ /**
306
+ * The TransactionsApi service constructor.
307
+ * @property {module:sellerWallet_2024_03_01/api/TransactionsApi}
308
+ */
309
+ TransactionsApi,
310
+
311
+ /**
312
+ * The TransferPreviewApi service constructor.
313
+ * @property {module:sellerWallet_2024_03_01/api/TransferPreviewApi}
314
+ */
315
+ TransferPreviewApi,
316
+
317
+ /**
318
+ * The TransferScheduleApi service constructor.
319
+ * @property {module:sellerWallet_2024_03_01/api/TransferScheduleApi}
320
+ */
321
+ TransferScheduleApi
322
+ }