@cobo/cobo-waas2 1.21.0 → 1.22.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 (170) hide show
  1. package/README.md +52 -2
  2. package/dist/ApiClient.js +1 -1
  3. package/dist/PreRequestScript.js +2 -4
  4. package/dist/api/AutoSweepApi.js +289 -0
  5. package/dist/api/PaymentApi.js +231 -18
  6. package/dist/api/TokenizationApi.js +1024 -0
  7. package/dist/api/TransactionsApi.js +101 -0
  8. package/dist/index.js +154 -0
  9. package/dist/model/ApprovalDetail.js +7 -7
  10. package/dist/model/AutoSweepTask.js +198 -0
  11. package/dist/model/AutoSweepTaskStatus.js +61 -0
  12. package/dist/model/CreateAutoSweepTask.js +126 -0
  13. package/dist/model/CreateCryptoAddressRequest.js +5 -5
  14. package/dist/model/CreateCustodialWalletParams.js +9 -0
  15. package/dist/model/CreateExchangeWalletParams.js +14 -0
  16. package/dist/model/CreateMpcWalletParams.js +14 -0
  17. package/dist/model/CreateSafeWalletParams.js +9 -0
  18. package/dist/model/CreateSettlement.js +27 -4
  19. package/dist/model/CreateSmartContractWalletParams.js +6 -0
  20. package/dist/model/CreateSweepToAddress.js +126 -0
  21. package/dist/model/CreateWalletParams.js +6 -0
  22. package/dist/model/CreatedWalletInfo.js +6 -0
  23. package/dist/model/CustodialWalletInfo.js +9 -0
  24. package/dist/model/DeleteCryptoAddress201Response.js +2 -2
  25. package/dist/model/ExchangeWalletInfo.js +14 -0
  26. package/dist/model/GetTokenizationAllowlistActivation200Response.js +107 -0
  27. package/dist/model/ListAutoSweepTask200Response.js +123 -0
  28. package/dist/model/ListMerchantBalances200Response.js +107 -0
  29. package/dist/model/ListPaymentWalletBalances200Response.js +107 -0
  30. package/dist/model/ListTokenizationBlocklistAddresses200Response.js +145 -0
  31. package/dist/model/ListWalletSweepToAddresses200Response.js +107 -0
  32. package/dist/model/MPCWalletInfo.js +14 -0
  33. package/dist/model/MerchantBalance.js +201 -0
  34. package/dist/model/PaymentWalletBalance.js +177 -0
  35. package/dist/model/PspBalance.js +175 -0
  36. package/dist/model/ReceivedAmountPerAddress.js +126 -0
  37. package/dist/model/SafeWallet.js +9 -0
  38. package/dist/model/SettlementDetail.js +1 -1
  39. package/dist/model/SmartContractWalletInfo.js +6 -0
  40. package/dist/model/SweepToAddress.js +135 -0
  41. package/dist/model/SweepToAddressStatus.js +61 -0
  42. package/dist/model/TokenizationActivityInfo.js +8 -4
  43. package/dist/model/TokenizationAllowlistActivationRequest.js +13 -0
  44. package/dist/model/TokenizationAllowlistAddressNote.js +4 -4
  45. package/dist/model/TokenizationAllowlistAddressesResponse.js +145 -0
  46. package/dist/model/TokenizationBlocklistAddressNote.js +4 -4
  47. package/dist/model/TokenizationBurnEstimateFeeParams.js +13 -0
  48. package/dist/model/TokenizationBurnTokenParamsBurnsInner.js +4 -4
  49. package/dist/model/TokenizationBurnTokenRequest.js +13 -0
  50. package/dist/model/TokenizationContractCallEstimateFeeParams.js +13 -0
  51. package/dist/model/TokenizationContractCallParamsData.js +43 -9
  52. package/dist/model/TokenizationContractCallRequest.js +13 -0
  53. package/dist/model/TokenizationContractCallType.js +5 -0
  54. package/dist/model/TokenizationERC20TokenParams.js +4 -4
  55. package/dist/model/TokenizationEstimateFeeRequestOperationParams.js +6 -0
  56. package/dist/model/TokenizationEvmContractCallParams.js +2 -2
  57. package/dist/model/TokenizationIssueEstimateFeeParams.js +13 -0
  58. package/dist/model/TokenizationIssueTokenParamsTokenParams.js +40 -12
  59. package/dist/model/TokenizationIssuedTokenRequest.js +14 -1
  60. package/dist/model/TokenizationMintEstimateFeeParams.js +13 -0
  61. package/dist/model/TokenizationMintTokenRequest.js +13 -0
  62. package/dist/model/TokenizationMpcOperationSource.js +2 -2
  63. package/dist/model/TokenizationPauseEstimateFeeParams.js +13 -0
  64. package/dist/model/TokenizationPauseTokenRequest.js +13 -0
  65. package/dist/model/TokenizationSOLTokenParams.js +173 -0
  66. package/dist/model/TokenizationSolContractCallParams.js +137 -0
  67. package/dist/model/TokenizationSolTokenPermissionParams.js +140 -0
  68. package/dist/model/TokenizationToggleAllowlistEstimateFeeParams.js +13 -0
  69. package/dist/model/TokenizationTokenDetailInfo.js +6 -6
  70. package/dist/model/TokenizationTokenInfo.js +4 -4
  71. package/dist/model/TokenizationTokenOperationSource.js +1 -1
  72. package/dist/model/TokenizationTokenPermissionParams.js +1 -1
  73. package/dist/model/TokenizationTokenPermissionType.js +15 -0
  74. package/dist/model/TokenizationTokenStandard.js +5 -0
  75. package/dist/model/TokenizationUnpauseEstimateFeeParams.js +13 -0
  76. package/dist/model/TokenizationUnpauseTokenRequest.js +13 -0
  77. package/dist/model/TokenizationUpdateAllowlistAddressesEstimateFeeParams.js +13 -0
  78. package/dist/model/TokenizationUpdateAllowlistAddressesParamsAddressesInner.js +1 -1
  79. package/dist/model/TokenizationUpdateAllowlistAddressesRequest.js +13 -0
  80. package/dist/model/TokenizationUpdateBlocklistAddressesEstimateFeeParams.js +13 -0
  81. package/dist/model/TokenizationUpdateBlocklistAddressesParamsAddressesInner.js +1 -1
  82. package/dist/model/TokenizationUpdateBlocklistAddressesRequest.js +13 -0
  83. package/dist/model/TokenizationWeb3OperationSource.js +2 -2
  84. package/dist/model/UpdateCustodialWalletParams.js +13 -6
  85. package/dist/model/UpdateMpcWalletParams.js +13 -6
  86. package/dist/model/UpdateWalletParams.js +6 -0
  87. package/dist/model/WalletInfo.js +6 -0
  88. package/docs/ApprovalDetail.md +1 -1
  89. package/docs/AutoSweepApi.md +285 -0
  90. package/docs/AutoSweepTask.md +16 -0
  91. package/docs/AutoSweepTaskStatus.md +12 -0
  92. package/docs/CreateAutoSweepTask.md +10 -0
  93. package/docs/CreateCryptoAddressRequest.md +3 -3
  94. package/docs/CreateCustodialWalletParams.md +1 -0
  95. package/docs/CreateExchangeWalletParams.md +1 -0
  96. package/docs/CreateMpcWalletParams.md +1 -0
  97. package/docs/CreateSafeWalletParams.md +1 -0
  98. package/docs/CreateSettlement.md +1 -1
  99. package/docs/CreateSmartContractWalletParams.md +1 -0
  100. package/docs/CreateSweepToAddress.md +10 -0
  101. package/docs/CreateWalletParams.md +1 -0
  102. package/docs/CreatedWalletInfo.md +1 -0
  103. package/docs/CustodialWalletInfo.md +1 -0
  104. package/docs/DeleteCryptoAddress201Response.md +1 -1
  105. package/docs/ExchangeWalletInfo.md +1 -0
  106. package/docs/GetTokenizationAllowlistActivation200Response.md +9 -0
  107. package/docs/ListAutoSweepTask200Response.md +10 -0
  108. package/docs/ListMerchantBalances200Response.md +9 -0
  109. package/docs/ListPaymentWalletBalances200Response.md +9 -0
  110. package/docs/ListTokenizationBlocklistAddresses200Response.md +10 -0
  111. package/docs/ListWalletSweepToAddresses200Response.md +9 -0
  112. package/docs/MPCWalletInfo.md +1 -0
  113. package/docs/MerchantBalance.md +16 -0
  114. package/docs/PaymentApi.md +228 -10
  115. package/docs/PaymentWalletBalance.md +14 -0
  116. package/docs/PspBalance.md +14 -0
  117. package/docs/ReceivedAmountPerAddress.md +10 -0
  118. package/docs/SafeWallet.md +1 -0
  119. package/docs/SettlementDetail.md +1 -1
  120. package/docs/SmartContractWalletInfo.md +1 -0
  121. package/docs/SweepToAddress.md +11 -0
  122. package/docs/SweepToAddressStatus.md +12 -0
  123. package/docs/TokenizationActivityInfo.md +2 -2
  124. package/docs/TokenizationAllowlistActivationRequest.md +1 -0
  125. package/docs/TokenizationAllowlistAddressNote.md +3 -3
  126. package/docs/TokenizationAllowlistAddressesResponse.md +10 -0
  127. package/docs/TokenizationApi.md +1069 -0
  128. package/docs/TokenizationBlocklistAddressNote.md +3 -3
  129. package/docs/TokenizationBurnEstimateFeeParams.md +1 -0
  130. package/docs/TokenizationBurnTokenParamsBurnsInner.md +2 -2
  131. package/docs/TokenizationBurnTokenRequest.md +1 -0
  132. package/docs/TokenizationContractCallEstimateFeeParams.md +1 -0
  133. package/docs/TokenizationContractCallParamsData.md +2 -1
  134. package/docs/TokenizationContractCallRequest.md +1 -0
  135. package/docs/TokenizationContractCallType.md +2 -0
  136. package/docs/TokenizationERC20TokenParams.md +1 -1
  137. package/docs/TokenizationEstimateFeeRequestOperationParams.md +1 -0
  138. package/docs/TokenizationEvmContractCallParams.md +1 -1
  139. package/docs/TokenizationIssueEstimateFeeParams.md +1 -0
  140. package/docs/TokenizationIssueTokenParamsTokenParams.md +2 -2
  141. package/docs/TokenizationIssuedTokenRequest.md +2 -1
  142. package/docs/TokenizationMintEstimateFeeParams.md +1 -0
  143. package/docs/TokenizationMintTokenRequest.md +1 -0
  144. package/docs/TokenizationMpcOperationSource.md +1 -1
  145. package/docs/TokenizationPauseEstimateFeeParams.md +1 -0
  146. package/docs/TokenizationPauseTokenRequest.md +1 -0
  147. package/docs/TokenizationSOLTokenParams.md +14 -0
  148. package/docs/TokenizationSolContractCallParams.md +10 -0
  149. package/docs/TokenizationSolTokenPermissionParams.md +13 -0
  150. package/docs/TokenizationToggleAllowlistEstimateFeeParams.md +1 -0
  151. package/docs/TokenizationTokenDetailInfo.md +1 -1
  152. package/docs/TokenizationTokenInfo.md +1 -1
  153. package/docs/TokenizationTokenOperationSource.md +1 -1
  154. package/docs/TokenizationTokenPermissionType.md +6 -0
  155. package/docs/TokenizationTokenStandard.md +2 -0
  156. package/docs/TokenizationUnpauseEstimateFeeParams.md +1 -0
  157. package/docs/TokenizationUnpauseTokenRequest.md +1 -0
  158. package/docs/TokenizationUpdateAllowlistAddressesEstimateFeeParams.md +1 -0
  159. package/docs/TokenizationUpdateAllowlistAddressesParamsAddressesInner.md +1 -1
  160. package/docs/TokenizationUpdateAllowlistAddressesRequest.md +1 -0
  161. package/docs/TokenizationUpdateBlocklistAddressesEstimateFeeParams.md +1 -0
  162. package/docs/TokenizationUpdateBlocklistAddressesParamsAddressesInner.md +1 -1
  163. package/docs/TokenizationUpdateBlocklistAddressesRequest.md +1 -0
  164. package/docs/TokenizationWeb3OperationSource.md +1 -1
  165. package/docs/TransactionsApi.md +112 -0
  166. package/docs/UpdateCustodialWalletParams.md +2 -1
  167. package/docs/UpdateMpcWalletParams.md +2 -1
  168. package/docs/UpdateWalletParams.md +1 -0
  169. package/docs/WalletInfo.md +1 -0
  170. package/package.json +1 -1
@@ -21,13 +21,17 @@ var _GetExchangeRate200Response = _interopRequireDefault(require("../model/GetEx
21
21
  var _GetRefunds200Response = _interopRequireDefault(require("../model/GetRefunds200Response"));
22
22
  var _GetSettlementInfoByIds200Response = _interopRequireDefault(require("../model/GetSettlementInfoByIds200Response"));
23
23
  var _ListForcedSweepRequests200Response = _interopRequireDefault(require("../model/ListForcedSweepRequests200Response"));
24
+ var _ListMerchantBalances200Response = _interopRequireDefault(require("../model/ListMerchantBalances200Response"));
24
25
  var _ListMerchants200Response = _interopRequireDefault(require("../model/ListMerchants200Response"));
25
26
  var _ListPaymentOrders200Response = _interopRequireDefault(require("../model/ListPaymentOrders200Response"));
27
+ var _ListPaymentWalletBalances200Response = _interopRequireDefault(require("../model/ListPaymentWalletBalances200Response"));
26
28
  var _ListSettlementDetails200Response = _interopRequireDefault(require("../model/ListSettlementDetails200Response"));
27
29
  var _ListSettlementRequests200Response = _interopRequireDefault(require("../model/ListSettlementRequests200Response"));
28
30
  var _ListTopUpPayers200Response = _interopRequireDefault(require("../model/ListTopUpPayers200Response"));
29
31
  var _Merchant = _interopRequireDefault(require("../model/Merchant"));
30
32
  var _Order = _interopRequireDefault(require("../model/Order"));
33
+ var _PspBalance = _interopRequireDefault(require("../model/PspBalance"));
34
+ var _ReceivedAmountPerAddress = _interopRequireDefault(require("../model/ReceivedAmountPerAddress"));
31
35
  var _Refund = _interopRequireDefault(require("../model/Refund"));
32
36
  var _Settlement = _interopRequireDefault(require("../model/Settlement"));
33
37
  var _SupportedToken = _interopRequireDefault(require("../model/SupportedToken"));
@@ -71,7 +75,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
71
75
 
72
76
  /**
73
77
  * Cancel refund order
74
- * This operation cancels a specified refund order.
78
+ * This operation cancels a specified refund order. You can only cancel refund orders that have not been processed yet.
75
79
  * @param {String} refund_id The refund order ID.
76
80
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/Refund} and HTTP response
77
81
  */
@@ -101,7 +105,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
101
105
 
102
106
  /**
103
107
  * Cancel refund order
104
- * This operation cancels a specified refund order.
108
+ * This operation cancels a specified refund order. You can only cancel refund orders that have not been processed yet.
105
109
  * @param {String} refund_id The refund order ID.
106
110
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/Refund}
107
111
  */
@@ -115,9 +119,9 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
115
119
 
116
120
  /**
117
121
  * Create crypto address
118
- * Create a new cryptocurrency address for receiving payouts or transfers. The address must match the specified `token_id`'s blockchain. Optionally, a label can be provided to help categorize the address internally.
122
+ * This operation registers a crypto address for crypto withdrawal. The registered address can later be referenced by its ID when creating settlement requests.
119
123
  * @param {Object} opts Optional parameters
120
- * @param {module:model/CreateCryptoAddressRequest} [CreateCryptoAddressRequest] The request body to create a crypto address.
124
+ * @param {module:model/CreateCryptoAddressRequest} [CreateCryptoAddressRequest] The request body to register a crypto address.
121
125
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/CryptoAddress} and HTTP response
122
126
  */
123
127
  }, {
@@ -141,9 +145,9 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
141
145
 
142
146
  /**
143
147
  * Create crypto address
144
- * Create a new cryptocurrency address for receiving payouts or transfers. The address must match the specified `token_id`'s blockchain. Optionally, a label can be provided to help categorize the address internally.
148
+ * This operation registers a crypto address for crypto withdrawal. The registered address can later be referenced by its ID when creating settlement requests.
145
149
  * @param {Object} opts Optional parameters
146
- * @param {module:model/CreateCryptoAddressRequest} opts.CreateCryptoAddressRequest The request body to create a crypto address.
150
+ * @param {module:model/CreateCryptoAddressRequest} opts.CreateCryptoAddressRequest The request body to register a crypto address.
147
151
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/CryptoAddress}
148
152
  */
149
153
  }, {
@@ -361,7 +365,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
361
365
 
362
366
  /**
363
367
  * Delete crypto address
364
- * This operation deletes a crypto address.
368
+ * This operation unregisters a crypto address from being used for crypto withdrawals.
365
369
  * @param {String} crypto_address_id The crypto address ID.
366
370
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/DeleteCryptoAddress201Response} and HTTP response
367
371
  */
@@ -391,7 +395,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
391
395
 
392
396
  /**
393
397
  * Delete crypto address
394
- * This operation deletes a crypto address.
398
+ * This operation unregisters a crypto address from being used for crypto withdrawals.
395
399
  * @param {String} crypto_address_id The crypto address ID.
396
400
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/DeleteCryptoAddress201Response}
397
401
  */
@@ -454,6 +458,64 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
454
458
  });
455
459
  }
456
460
 
461
+ /**
462
+ * Get payer balance by address
463
+ * This operation retrieves aggregated balance details for a specific token and payer, with amounts grouped by address.
464
+ * @param {String} merchant_id The merchant ID.
465
+ * @param {String} payer_id Unique payer identifier on the Cobo side, auto-generated by the system.
466
+ * @param {String} token_id The token ID, which is a unique identifier that specifies both the blockchain network and cryptocurrency token in the format `{CHAIN}_{TOKEN}`. Supported values include: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
467
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link Array.<module:model/ReceivedAmountPerAddress>} and HTTP response
468
+ */
469
+ }, {
470
+ key: "getPayerBalanceByAddressWithHttpInfo",
471
+ value: function getPayerBalanceByAddressWithHttpInfo(merchant_id, payer_id, token_id) {
472
+ var postBody = null;
473
+ if (postBody && postBody.toJSON) {
474
+ postBody = postBody.toJSON();
475
+ }
476
+ // verify the required parameter 'merchant_id' is set
477
+ if (merchant_id === undefined || merchant_id === null) {
478
+ throw new Error("Missing the required parameter 'merchant_id' when calling getPayerBalanceByAddress");
479
+ }
480
+ // verify the required parameter 'payer_id' is set
481
+ if (payer_id === undefined || payer_id === null) {
482
+ throw new Error("Missing the required parameter 'payer_id' when calling getPayerBalanceByAddress");
483
+ }
484
+ // verify the required parameter 'token_id' is set
485
+ if (token_id === undefined || token_id === null) {
486
+ throw new Error("Missing the required parameter 'token_id' when calling getPayerBalanceByAddress");
487
+ }
488
+ var pathParams = {};
489
+ var queryParams = {
490
+ 'merchant_id': merchant_id,
491
+ 'payer_id': payer_id,
492
+ 'token_id': token_id
493
+ };
494
+ var headerParams = {};
495
+ var formParams = {};
496
+ var authNames = ['OAuth2', 'CoboAuth'];
497
+ var contentTypes = [];
498
+ var accepts = ['application/json'];
499
+ var returnType = [_ReceivedAmountPerAddress["default"]];
500
+ return this.apiClient.callApi('/payments/balance/payer/address', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
501
+ }
502
+
503
+ /**
504
+ * Get payer balance by address
505
+ * This operation retrieves aggregated balance details for a specific token and payer, with amounts grouped by address.
506
+ * @param {String} merchant_id The merchant ID.
507
+ * @param {String} payer_id Unique payer identifier on the Cobo side, auto-generated by the system.
508
+ * @param {String} token_id The token ID, which is a unique identifier that specifies both the blockchain network and cryptocurrency token in the format `{CHAIN}_{TOKEN}`. Supported values include: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
509
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link Array.<module:model/ReceivedAmountPerAddress>}
510
+ */
511
+ }, {
512
+ key: "getPayerBalanceByAddress",
513
+ value: function getPayerBalanceByAddress(merchant_id, payer_id, token_id) {
514
+ return this.getPayerBalanceByAddressWithHttpInfo(merchant_id, payer_id, token_id).then(function (response_and_data) {
515
+ return response_and_data.data;
516
+ });
517
+ }
518
+
457
519
  /**
458
520
  * Get pay-in order information
459
521
  * This operation retrieves details of a specific pay-in order.
@@ -498,6 +560,50 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
498
560
  });
499
561
  }
500
562
 
563
+ /**
564
+ * Get psp balance
565
+ * This operation retrieves the information of psp balance.
566
+ * @param {String} token_id The token ID, which is a unique identifier that specifies both the blockchain network and cryptocurrency token in the format `{CHAIN}_{TOKEN}`. Supported values include: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
567
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/PspBalance} and HTTP response
568
+ */
569
+ }, {
570
+ key: "getPspBalanceWithHttpInfo",
571
+ value: function getPspBalanceWithHttpInfo(token_id) {
572
+ var postBody = null;
573
+ if (postBody && postBody.toJSON) {
574
+ postBody = postBody.toJSON();
575
+ }
576
+ // verify the required parameter 'token_id' is set
577
+ if (token_id === undefined || token_id === null) {
578
+ throw new Error("Missing the required parameter 'token_id' when calling getPspBalance");
579
+ }
580
+ var pathParams = {};
581
+ var queryParams = {
582
+ 'token_id': token_id
583
+ };
584
+ var headerParams = {};
585
+ var formParams = {};
586
+ var authNames = ['OAuth2', 'CoboAuth'];
587
+ var contentTypes = [];
588
+ var accepts = ['application/json'];
589
+ var returnType = _PspBalance["default"];
590
+ return this.apiClient.callApi('/payments/balance/psp', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
591
+ }
592
+
593
+ /**
594
+ * Get psp balance
595
+ * This operation retrieves the information of psp balance.
596
+ * @param {String} token_id The token ID, which is a unique identifier that specifies both the blockchain network and cryptocurrency token in the format `{CHAIN}_{TOKEN}`. Supported values include: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
597
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/PspBalance}
598
+ */
599
+ }, {
600
+ key: "getPspBalance",
601
+ value: function getPspBalance(token_id) {
602
+ return this.getPspBalanceWithHttpInfo(token_id).then(function (response_and_data) {
603
+ return response_and_data.data;
604
+ });
605
+ }
606
+
501
607
  /**
502
608
  * Get refund order information
503
609
  * This operation retrieves the detailed information about a specified refund order.
@@ -551,7 +657,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
551
657
  * @param {String} [after] A cursor indicating the position after the current page. This value is generated by Cobo and returned in the response. You do not need to provide it on the first request. When paginating forward (to the next page), you should pass the after value returned from the last response.
552
658
  * @param {String} [merchant_id] The merchant ID.
553
659
  * @param {String} [request_id] The request ID.
554
- * @param {String} [statuses] A list of statuses of order, refund or settle request.
660
+ * @param {String} [statuses] A list of order, refund or settlement statuses. You can refer to the following operations for the possible status values: - [Get pay-in order information](https://www.cobo.com/developers/v2/api-references/payment/get-pay-in-order-information) - [Get refund order information](https://www.cobo.com/developers/v2/api-references/payment/get-refund-order-information) - [List all settlement details](https://www.cobo.com/developers/v2/api-references/payment/list-all-settlement-details)
555
661
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetRefunds200Response} and HTTP response
556
662
  */
557
663
  }, {
@@ -589,7 +695,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
589
695
  * @param {String} opts.after A cursor indicating the position after the current page. This value is generated by Cobo and returned in the response. You do not need to provide it on the first request. When paginating forward (to the next page), you should pass the after value returned from the last response.
590
696
  * @param {String} opts.merchant_id The merchant ID.
591
697
  * @param {String} opts.request_id The request ID.
592
- * @param {String} opts.statuses A list of statuses of order, refund or settle request.
698
+ * @param {String} opts.statuses A list of order, refund or settlement statuses. You can refer to the following operations for the possible status values: - [Get pay-in order information](https://www.cobo.com/developers/v2/api-references/payment/get-pay-in-order-information) - [Get refund order information](https://www.cobo.com/developers/v2/api-references/payment/get-refund-order-information) - [List all settlement details](https://www.cobo.com/developers/v2/api-references/payment/list-all-settlement-details)
593
699
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetRefunds200Response}
594
700
  */
595
701
  }, {
@@ -882,6 +988,63 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
882
988
  });
883
989
  }
884
990
 
991
+ /**
992
+ * List merchant balances
993
+ * This operation retrieves the information of merchant balances.
994
+ * @param {String} token_id The token ID, which is a unique identifier that specifies both the blockchain network and cryptocurrency token in the format `{CHAIN}_{TOKEN}`. Supported values include: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
995
+ * @param {module:model/AcquiringType} acquiring_type AcquiringType defines the acquisition logic used in the payment flow: - `Order`: Each order is created with a specific amount and associated payment request. Funds are settled on a per-order basis. - `TopUp`: Recharge-style flow where funds are topped up to a payer balance or account. Useful for flexible or usage-based payment models.
996
+ * @param {Object} opts Optional parameters
997
+ * @param {String} [merchant_ids] A list of merchant IDs to query.
998
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListMerchantBalances200Response} and HTTP response
999
+ */
1000
+ }, {
1001
+ key: "listMerchantBalancesWithHttpInfo",
1002
+ value: function listMerchantBalancesWithHttpInfo(token_id, acquiring_type, opts) {
1003
+ opts = opts || {};
1004
+ var postBody = null;
1005
+ if (postBody && postBody.toJSON) {
1006
+ postBody = postBody.toJSON();
1007
+ }
1008
+ // verify the required parameter 'token_id' is set
1009
+ if (token_id === undefined || token_id === null) {
1010
+ throw new Error("Missing the required parameter 'token_id' when calling listMerchantBalances");
1011
+ }
1012
+ // verify the required parameter 'acquiring_type' is set
1013
+ if (acquiring_type === undefined || acquiring_type === null) {
1014
+ throw new Error("Missing the required parameter 'acquiring_type' when calling listMerchantBalances");
1015
+ }
1016
+ var pathParams = {};
1017
+ var queryParams = {
1018
+ 'merchant_ids': opts['merchant_ids'],
1019
+ 'token_id': token_id,
1020
+ 'acquiring_type': acquiring_type
1021
+ };
1022
+ var headerParams = {};
1023
+ var formParams = {};
1024
+ var authNames = ['OAuth2', 'CoboAuth'];
1025
+ var contentTypes = [];
1026
+ var accepts = ['application/json'];
1027
+ var returnType = _ListMerchantBalances200Response["default"];
1028
+ return this.apiClient.callApi('/payments/balance/merchants', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1029
+ }
1030
+
1031
+ /**
1032
+ * List merchant balances
1033
+ * This operation retrieves the information of merchant balances.
1034
+ * @param {String} token_id The token ID, which is a unique identifier that specifies both the blockchain network and cryptocurrency token in the format `{CHAIN}_{TOKEN}`. Supported values include: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
1035
+ * @param {module:model/AcquiringType} acquiring_type AcquiringType defines the acquisition logic used in the payment flow: - `Order`: Each order is created with a specific amount and associated payment request. Funds are settled on a per-order basis. - `TopUp`: Recharge-style flow where funds are topped up to a payer balance or account. Useful for flexible or usage-based payment models.
1036
+ * @param {Object} opts Optional parameters
1037
+ * @param {String} opts.merchant_ids A list of merchant IDs to query.
1038
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListMerchantBalances200Response}
1039
+ */
1040
+ }, {
1041
+ key: "listMerchantBalances",
1042
+ value: function listMerchantBalances(token_id, acquiring_type, opts) {
1043
+ return this.listMerchantBalancesWithHttpInfo(token_id, acquiring_type, opts).then(function (response_and_data) {
1044
+ return response_and_data.data;
1045
+ });
1046
+ }
1047
+
885
1048
  /**
886
1049
  * List all merchants
887
1050
  * This operation retrieves the information of all merchants. You can filter the results by using a keyword for fuzzy search on merchant names or by specifying a wallet ID.
@@ -946,7 +1109,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
946
1109
  * @param {String} [after] A cursor indicating the position after the current page. This value is generated by Cobo and returned in the response. You do not need to provide it on the first request. When paginating forward (to the next page), you should pass the after value returned from the last response.
947
1110
  * @param {String} [merchant_id] The merchant ID.
948
1111
  * @param {String} [psp_order_id] A unique reference code assigned by the developer to identify this order in their system.
949
- * @param {String} [statuses] A list of statuses of order, refund or settle request.
1112
+ * @param {String} [statuses] A list of order, refund or settlement statuses. You can refer to the following operations for the possible status values: - [Get pay-in order information](https://www.cobo.com/developers/v2/api-references/payment/get-pay-in-order-information) - [Get refund order information](https://www.cobo.com/developers/v2/api-references/payment/get-refund-order-information) - [List all settlement details](https://www.cobo.com/developers/v2/api-references/payment/list-all-settlement-details)
950
1113
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListPaymentOrders200Response} and HTTP response
951
1114
  */
952
1115
  }, {
@@ -984,7 +1147,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
984
1147
  * @param {String} opts.after A cursor indicating the position after the current page. This value is generated by Cobo and returned in the response. You do not need to provide it on the first request. When paginating forward (to the next page), you should pass the after value returned from the last response.
985
1148
  * @param {String} opts.merchant_id The merchant ID.
986
1149
  * @param {String} opts.psp_order_id A unique reference code assigned by the developer to identify this order in their system.
987
- * @param {String} opts.statuses A list of statuses of order, refund or settle request.
1150
+ * @param {String} opts.statuses A list of order, refund or settlement statuses. You can refer to the following operations for the possible status values: - [Get pay-in order information](https://www.cobo.com/developers/v2/api-references/payment/get-pay-in-order-information) - [Get refund order information](https://www.cobo.com/developers/v2/api-references/payment/get-refund-order-information) - [List all settlement details](https://www.cobo.com/developers/v2/api-references/payment/list-all-settlement-details)
988
1151
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListPaymentOrders200Response}
989
1152
  */
990
1153
  }, {
@@ -1031,6 +1194,56 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
1031
1194
  });
1032
1195
  }
1033
1196
 
1197
+ /**
1198
+ * List payment wallet balances
1199
+ * This operation retrieves the information of payment wallet balances.
1200
+ * @param {String} token_id The token ID, which is a unique identifier that specifies both the blockchain network and cryptocurrency token in the format `{CHAIN}_{TOKEN}`. Supported values include: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
1201
+ * @param {Object} opts Optional parameters
1202
+ * @param {String} [wallet_ids] A list of wallet IDs to query.
1203
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListPaymentWalletBalances200Response} and HTTP response
1204
+ */
1205
+ }, {
1206
+ key: "listPaymentWalletBalancesWithHttpInfo",
1207
+ value: function listPaymentWalletBalancesWithHttpInfo(token_id, opts) {
1208
+ opts = opts || {};
1209
+ var postBody = null;
1210
+ if (postBody && postBody.toJSON) {
1211
+ postBody = postBody.toJSON();
1212
+ }
1213
+ // verify the required parameter 'token_id' is set
1214
+ if (token_id === undefined || token_id === null) {
1215
+ throw new Error("Missing the required parameter 'token_id' when calling listPaymentWalletBalances");
1216
+ }
1217
+ var pathParams = {};
1218
+ var queryParams = {
1219
+ 'wallet_ids': opts['wallet_ids'],
1220
+ 'token_id': token_id
1221
+ };
1222
+ var headerParams = {};
1223
+ var formParams = {};
1224
+ var authNames = ['OAuth2', 'CoboAuth'];
1225
+ var contentTypes = [];
1226
+ var accepts = ['application/json'];
1227
+ var returnType = _ListPaymentWalletBalances200Response["default"];
1228
+ return this.apiClient.callApi('/payments/balance/payment_wallets', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
1229
+ }
1230
+
1231
+ /**
1232
+ * List payment wallet balances
1233
+ * This operation retrieves the information of payment wallet balances.
1234
+ * @param {String} token_id The token ID, which is a unique identifier that specifies both the blockchain network and cryptocurrency token in the format `{CHAIN}_{TOKEN}`. Supported values include: - USDC: `ETH_USDC`, `ARBITRUM_USDCOIN`, `SOL_USDC`, `BASE_USDC`, `MATIC_USDC2`, `BSC_USDC` - USDT: `TRON_USDT`, `ETH_USDT`, `ARBITRUM_USDT`, `SOL_USDT`, `BASE_USDT`, `MATIC_USDT`, `BSC_USDT`
1235
+ * @param {Object} opts Optional parameters
1236
+ * @param {String} opts.wallet_ids A list of wallet IDs to query.
1237
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListPaymentWalletBalances200Response}
1238
+ */
1239
+ }, {
1240
+ key: "listPaymentWalletBalances",
1241
+ value: function listPaymentWalletBalances(token_id, opts) {
1242
+ return this.listPaymentWalletBalancesWithHttpInfo(token_id, opts).then(function (response_and_data) {
1243
+ return response_and_data.data;
1244
+ });
1245
+ }
1246
+
1034
1247
  /**
1035
1248
  * List all settlement details
1036
1249
  * This operation retrieves the information of all settlement details. You can filter the result by merchant ID or status.
@@ -1039,7 +1252,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
1039
1252
  * @param {String} [before] A cursor indicating the position before the current page. This value is generated by Cobo and returned in the response. If you are paginating forward from the beginning, you do not need to provide it on the first request. When paginating backward (to the previous page), you should pass the before value returned from the last response.
1040
1253
  * @param {String} [after] A cursor indicating the position after the current page. This value is generated by Cobo and returned in the response. You do not need to provide it on the first request. When paginating forward (to the next page), you should pass the after value returned from the last response.
1041
1254
  * @param {String} [merchant_id] The merchant ID.
1042
- * @param {String} [statuses] A list of statuses of order, refund or settle request.
1255
+ * @param {String} [statuses] A list of order, refund or settlement statuses. You can refer to the following operations for the possible status values: - [Get pay-in order information](https://www.cobo.com/developers/v2/api-references/payment/get-pay-in-order-information) - [Get refund order information](https://www.cobo.com/developers/v2/api-references/payment/get-refund-order-information) - [List all settlement details](https://www.cobo.com/developers/v2/api-references/payment/list-all-settlement-details)
1043
1256
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListSettlementDetails200Response} and HTTP response
1044
1257
  */
1045
1258
  }, {
@@ -1075,7 +1288,7 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
1075
1288
  * @param {String} opts.before A cursor indicating the position before the current page. This value is generated by Cobo and returned in the response. If you are paginating forward from the beginning, you do not need to provide it on the first request. When paginating backward (to the previous page), you should pass the before value returned from the last response.
1076
1289
  * @param {String} opts.after A cursor indicating the position after the current page. This value is generated by Cobo and returned in the response. You do not need to provide it on the first request. When paginating forward (to the next page), you should pass the after value returned from the last response.
1077
1290
  * @param {String} opts.merchant_id The merchant ID.
1078
- * @param {String} opts.statuses A list of statuses of order, refund or settle request.
1291
+ * @param {String} opts.statuses A list of order, refund or settlement statuses. You can refer to the following operations for the possible status values: - [Get pay-in order information](https://www.cobo.com/developers/v2/api-references/payment/get-pay-in-order-information) - [Get refund order information](https://www.cobo.com/developers/v2/api-references/payment/get-refund-order-information) - [List all settlement details](https://www.cobo.com/developers/v2/api-references/payment/list-all-settlement-details)
1079
1292
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListSettlementDetails200Response}
1080
1293
  */
1081
1294
  }, {
@@ -1296,8 +1509,8 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
1296
1509
  }
1297
1510
 
1298
1511
  /**
1299
- * Update refund order information
1300
- * This operation updates a specified refund order.
1512
+ * Update refund order
1513
+ * This operation updates a specified refund order by modifying its recipient address. You can only update the recipient address for refund orders that have not been processed yet.
1301
1514
  * @param {String} refund_id The refund order ID.
1302
1515
  * @param {Object} opts Optional parameters
1303
1516
  * @param {module:model/UpdateRefundByIdRequest} [UpdateRefundByIdRequest] The request body to update a refund order.
@@ -1329,8 +1542,8 @@ var PaymentApi = exports["default"] = /*#__PURE__*/function () {
1329
1542
  }
1330
1543
 
1331
1544
  /**
1332
- * Update refund order information
1333
- * This operation updates a specified refund order.
1545
+ * Update refund order
1546
+ * This operation updates a specified refund order by modifying its recipient address. You can only update the recipient address for refund orders that have not been processed yet.
1334
1547
  * @param {String} refund_id The refund order ID.
1335
1548
  * @param {Object} opts Optional parameters
1336
1549
  * @param {module:model/UpdateRefundByIdRequest} opts.UpdateRefundByIdRequest The request body to update a refund order.