@cobo/cobo-waas2 1.20.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.
- package/README.md +60 -4
- package/dist/ApiClient.js +11 -2
- package/dist/PreRequestScript.js +2 -4
- package/dist/api/AutoSweepApi.js +289 -0
- package/dist/api/PaymentApi.js +386 -24
- package/dist/api/TokenizationApi.js +1024 -0
- package/dist/api/TransactionsApi.js +103 -2
- package/dist/api/WalletsApi.js +2 -2
- package/dist/crypto/ApiSigner.js +5 -1
- package/dist/index.js +175 -0
- package/dist/model/AddressesEventData.js +3 -3
- package/dist/model/ApprovalDetail.js +7 -7
- package/dist/model/AutoSweepTask.js +198 -0
- package/dist/model/AutoSweepTaskStatus.js +61 -0
- package/dist/model/BalanceUpdateInfoEventData.js +3 -3
- package/dist/model/ChainsEventData.js +3 -3
- package/dist/model/CreateAutoSweepTask.js +126 -0
- package/dist/model/CreateCryptoAddressRequest.js +138 -0
- package/dist/model/CreateCustodialWalletParams.js +9 -0
- package/dist/model/CreateExchangeWalletParams.js +14 -0
- package/dist/model/CreateMpcWalletParams.js +14 -0
- package/dist/model/CreatePaymentOrderRequest.js +5 -5
- package/dist/model/CreateSafeWalletParams.js +9 -0
- package/dist/model/CreateSettlement.js +27 -4
- package/dist/model/CreateSmartContractWalletParams.js +6 -0
- package/dist/model/CreateSweepToAddress.js +126 -0
- package/dist/model/CreateWalletParams.js +6 -0
- package/dist/model/CreatedWalletInfo.js +6 -0
- package/dist/model/CryptoAddress.js +12 -12
- package/dist/model/CustodialWalletInfo.js +9 -0
- package/dist/model/DeleteCryptoAddress201Response.js +110 -0
- package/dist/model/ExchangeWalletInfo.js +14 -0
- package/dist/model/ForcedSweep.js +9 -9
- package/dist/model/ForcedSweepRequest.js +8 -9
- package/dist/model/GetTokenizationAllowlistActivation200Response.js +107 -0
- package/dist/model/ListAutoSweepTask200Response.js +123 -0
- package/dist/model/ListMerchantBalances200Response.js +107 -0
- package/dist/model/ListPaymentWalletBalances200Response.js +107 -0
- package/dist/model/ListSettlementDetails200Response.js +123 -0
- package/dist/model/ListTokenizationBlocklistAddresses200Response.js +145 -0
- package/dist/model/ListWalletSweepToAddresses200Response.js +107 -0
- package/dist/model/MPCVaultEventData.js +3 -3
- package/dist/model/MPCWalletInfo.js +14 -0
- package/dist/model/MerchantBalance.js +201 -0
- package/dist/model/PaymentAddressUpdateEventData.js +13 -13
- package/dist/model/PaymentOrderEventData.js +3 -3
- package/dist/model/PaymentRefundEventData.js +3 -3
- package/dist/model/PaymentSettlementEvent.js +42 -3
- package/dist/model/PaymentTransactionEventData.js +6 -6
- package/dist/model/PaymentWalletBalance.js +177 -0
- package/dist/model/PspBalance.js +175 -0
- package/dist/model/ReceivedAmountPerAddress.js +126 -0
- package/dist/model/SafeWallet.js +9 -0
- package/dist/model/Settlement.js +27 -0
- package/dist/model/SettlementDetail.js +26 -0
- package/dist/model/SettlementInfo.js +7 -7
- package/dist/model/SmartContractWalletInfo.js +6 -0
- package/dist/model/SuspendedTokenEventData.js +3 -3
- package/dist/model/SweepToAddress.js +135 -0
- package/dist/model/SweepToAddressStatus.js +61 -0
- package/dist/model/TSSRequestWebhookEventData.js +3 -3
- package/dist/model/TokenListingEventData.js +3 -3
- package/dist/model/TokenizationActivityInfo.js +8 -4
- package/dist/model/TokenizationAllowlistActivationRequest.js +13 -0
- package/dist/model/TokenizationAllowlistAddressNote.js +4 -4
- package/dist/model/TokenizationAllowlistAddressesResponse.js +145 -0
- package/dist/model/TokenizationBlocklistAddressNote.js +4 -4
- package/dist/model/TokenizationBurnEstimateFeeParams.js +13 -0
- package/dist/model/TokenizationBurnTokenParamsBurnsInner.js +4 -4
- package/dist/model/TokenizationBurnTokenRequest.js +13 -0
- package/dist/model/TokenizationContractCallEstimateFeeParams.js +13 -0
- package/dist/model/TokenizationContractCallParamsData.js +43 -9
- package/dist/model/TokenizationContractCallRequest.js +13 -0
- package/dist/model/TokenizationContractCallType.js +5 -0
- package/dist/model/TokenizationERC20TokenParams.js +4 -4
- package/dist/model/TokenizationEstimateFeeRequestOperationParams.js +6 -0
- package/dist/model/TokenizationEvmContractCallParams.js +2 -2
- package/dist/model/TokenizationIssueEstimateFeeParams.js +13 -0
- package/dist/model/TokenizationIssueTokenParamsTokenParams.js +40 -12
- package/dist/model/TokenizationIssuedTokenRequest.js +14 -1
- package/dist/model/TokenizationMintEstimateFeeParams.js +13 -0
- package/dist/model/TokenizationMintTokenRequest.js +13 -0
- package/dist/model/TokenizationMpcOperationSource.js +2 -2
- package/dist/model/TokenizationPauseEstimateFeeParams.js +13 -0
- package/dist/model/TokenizationPauseTokenRequest.js +13 -0
- package/dist/model/TokenizationSOLTokenParams.js +173 -0
- package/dist/model/TokenizationSolContractCallParams.js +137 -0
- package/dist/model/TokenizationSolTokenPermissionParams.js +140 -0
- package/dist/model/TokenizationToggleAllowlistEstimateFeeParams.js +13 -0
- package/dist/model/TokenizationTokenDetailInfo.js +6 -6
- package/dist/model/TokenizationTokenInfo.js +4 -4
- package/dist/model/TokenizationTokenOperationSource.js +1 -1
- package/dist/model/TokenizationTokenPermissionParams.js +1 -1
- package/dist/model/TokenizationTokenPermissionType.js +15 -0
- package/dist/model/TokenizationTokenStandard.js +5 -0
- package/dist/model/TokenizationUnpauseEstimateFeeParams.js +13 -0
- package/dist/model/TokenizationUnpauseTokenRequest.js +13 -0
- package/dist/model/TokenizationUpdateAllowlistAddressesEstimateFeeParams.js +13 -0
- package/dist/model/TokenizationUpdateAllowlistAddressesParamsAddressesInner.js +1 -1
- package/dist/model/TokenizationUpdateAllowlistAddressesRequest.js +13 -0
- package/dist/model/TokenizationUpdateBlocklistAddressesEstimateFeeParams.js +13 -0
- package/dist/model/TokenizationUpdateBlocklistAddressesParamsAddressesInner.js +1 -1
- package/dist/model/TokenizationUpdateBlocklistAddressesRequest.js +13 -0
- package/dist/model/TokenizationWeb3OperationSource.js +2 -2
- package/dist/model/TokensEventData.js +3 -3
- package/dist/model/TopUpAddress.js +0 -1
- package/dist/model/TransactionWebhookEventData.js +3 -3
- package/dist/model/UpdateCustodialWalletParams.js +13 -6
- package/dist/model/UpdateMpcWalletParams.js +13 -6
- package/dist/model/UpdateTopUpAddress.js +3 -3
- package/dist/model/UpdateWalletParams.js +6 -0
- package/dist/model/WalletInfo.js +6 -0
- package/dist/model/WalletInfoEventData.js +3 -3
- package/dist/model/WebhookEventData.js +19 -7
- package/dist/model/WebhookEventDataType.js +2 -2
- package/docs/AddressesEventData.md +1 -1
- package/docs/ApprovalDetail.md +1 -1
- package/docs/AutoSweepApi.md +285 -0
- package/docs/AutoSweepTask.md +16 -0
- package/docs/AutoSweepTaskStatus.md +12 -0
- package/docs/BalanceUpdateInfoEventData.md +1 -1
- package/docs/ChainsEventData.md +1 -1
- package/docs/CreateAutoSweepTask.md +10 -0
- package/docs/CreateCryptoAddressRequest.md +11 -0
- package/docs/CreateCustodialWalletParams.md +1 -0
- package/docs/CreateExchangeWalletParams.md +1 -0
- package/docs/CreateMpcWalletParams.md +1 -0
- package/docs/CreatePaymentOrderRequest.md +3 -3
- package/docs/CreateSafeWalletParams.md +1 -0
- package/docs/CreateSettlement.md +1 -1
- package/docs/CreateSmartContractWalletParams.md +1 -0
- package/docs/CreateSweepToAddress.md +10 -0
- package/docs/CreateWalletParams.md +1 -0
- package/docs/CreatedWalletInfo.md +1 -0
- package/docs/CryptoAddress.md +1 -1
- package/docs/CustodialWalletInfo.md +1 -0
- package/docs/DeleteCryptoAddress201Response.md +9 -0
- package/docs/ExchangeWalletInfo.md +1 -0
- package/docs/ForcedSweep.md +7 -7
- package/docs/ForcedSweepRequest.md +4 -4
- package/docs/GetTokenizationAllowlistActivation200Response.md +9 -0
- package/docs/ListAutoSweepTask200Response.md +10 -0
- package/docs/ListMerchantBalances200Response.md +9 -0
- package/docs/ListPaymentWalletBalances200Response.md +9 -0
- package/docs/ListSettlementDetails200Response.md +10 -0
- package/docs/ListTokenizationBlocklistAddresses200Response.md +10 -0
- package/docs/ListWalletSweepToAddresses200Response.md +9 -0
- package/docs/MPCVaultEventData.md +1 -1
- package/docs/MPCWalletInfo.md +1 -0
- package/docs/MerchantBalance.md +16 -0
- package/docs/PaymentAddressUpdateEventData.md +6 -6
- package/docs/PaymentApi.md +403 -16
- package/docs/PaymentOrderEventData.md +1 -1
- package/docs/PaymentRefundEventData.md +1 -1
- package/docs/PaymentSettlementEvent.md +4 -1
- package/docs/PaymentTransactionEventData.md +4 -4
- package/docs/PaymentWalletBalance.md +14 -0
- package/docs/PspBalance.md +14 -0
- package/docs/ReceivedAmountPerAddress.md +10 -0
- package/docs/SafeWallet.md +1 -0
- package/docs/Settlement.md +3 -0
- package/docs/SettlementDetail.md +2 -0
- package/docs/SettlementInfo.md +6 -6
- package/docs/SmartContractWalletInfo.md +1 -0
- package/docs/SuspendedTokenEventData.md +1 -1
- package/docs/SweepToAddress.md +11 -0
- package/docs/SweepToAddressStatus.md +12 -0
- package/docs/TSSRequestWebhookEventData.md +1 -1
- package/docs/TokenListingEventData.md +1 -1
- package/docs/TokenizationActivityInfo.md +2 -2
- package/docs/TokenizationAllowlistActivationRequest.md +1 -0
- package/docs/TokenizationAllowlistAddressNote.md +3 -3
- package/docs/TokenizationAllowlistAddressesResponse.md +10 -0
- package/docs/TokenizationApi.md +1069 -0
- package/docs/TokenizationBlocklistAddressNote.md +3 -3
- package/docs/TokenizationBurnEstimateFeeParams.md +1 -0
- package/docs/TokenizationBurnTokenParamsBurnsInner.md +2 -2
- package/docs/TokenizationBurnTokenRequest.md +1 -0
- package/docs/TokenizationContractCallEstimateFeeParams.md +1 -0
- package/docs/TokenizationContractCallParamsData.md +2 -1
- package/docs/TokenizationContractCallRequest.md +1 -0
- package/docs/TokenizationContractCallType.md +2 -0
- package/docs/TokenizationERC20TokenParams.md +1 -1
- package/docs/TokenizationEstimateFeeRequestOperationParams.md +1 -0
- package/docs/TokenizationEvmContractCallParams.md +1 -1
- package/docs/TokenizationIssueEstimateFeeParams.md +1 -0
- package/docs/TokenizationIssueTokenParamsTokenParams.md +2 -2
- package/docs/TokenizationIssuedTokenRequest.md +2 -1
- package/docs/TokenizationMintEstimateFeeParams.md +1 -0
- package/docs/TokenizationMintTokenRequest.md +1 -0
- package/docs/TokenizationMpcOperationSource.md +1 -1
- package/docs/TokenizationPauseEstimateFeeParams.md +1 -0
- package/docs/TokenizationPauseTokenRequest.md +1 -0
- package/docs/TokenizationSOLTokenParams.md +14 -0
- package/docs/TokenizationSolContractCallParams.md +10 -0
- package/docs/TokenizationSolTokenPermissionParams.md +13 -0
- package/docs/TokenizationToggleAllowlistEstimateFeeParams.md +1 -0
- package/docs/TokenizationTokenDetailInfo.md +1 -1
- package/docs/TokenizationTokenInfo.md +1 -1
- package/docs/TokenizationTokenOperationSource.md +1 -1
- package/docs/TokenizationTokenPermissionType.md +6 -0
- package/docs/TokenizationTokenStandard.md +2 -0
- package/docs/TokenizationUnpauseEstimateFeeParams.md +1 -0
- package/docs/TokenizationUnpauseTokenRequest.md +1 -0
- package/docs/TokenizationUpdateAllowlistAddressesEstimateFeeParams.md +1 -0
- package/docs/TokenizationUpdateAllowlistAddressesParamsAddressesInner.md +1 -1
- package/docs/TokenizationUpdateAllowlistAddressesRequest.md +1 -0
- package/docs/TokenizationUpdateBlocklistAddressesEstimateFeeParams.md +1 -0
- package/docs/TokenizationUpdateBlocklistAddressesParamsAddressesInner.md +1 -1
- package/docs/TokenizationUpdateBlocklistAddressesRequest.md +1 -0
- package/docs/TokenizationWeb3OperationSource.md +1 -1
- package/docs/TokensEventData.md +1 -1
- package/docs/TransactionWebhookEventData.md +1 -1
- package/docs/TransactionsApi.md +113 -1
- package/docs/UpdateCustodialWalletParams.md +2 -1
- package/docs/UpdateMpcWalletParams.md +2 -1
- package/docs/UpdateTopUpAddress.md +1 -1
- package/docs/UpdateWalletParams.md +1 -0
- package/docs/WalletInfo.md +1 -0
- package/docs/WalletInfoEventData.md +1 -1
- package/docs/WalletsApi.md +1 -1
- package/docs/WebhookEventData.md +9 -7
- package/docs/WebhookEventDataType.md +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,1024 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
|
|
8
|
+
var _ErrorResponse = _interopRequireDefault(require("../model/ErrorResponse"));
|
|
9
|
+
var _EstimatedFee = _interopRequireDefault(require("../model/EstimatedFee"));
|
|
10
|
+
var _GetTokenizationAllowlistActivation200Response = _interopRequireDefault(require("../model/GetTokenizationAllowlistActivation200Response"));
|
|
11
|
+
var _ListTokenizationBlocklistAddresses200Response = _interopRequireDefault(require("../model/ListTokenizationBlocklistAddresses200Response"));
|
|
12
|
+
var _TokenizationActivityInfo = _interopRequireDefault(require("../model/TokenizationActivityInfo"));
|
|
13
|
+
var _TokenizationActivityStatus = _interopRequireDefault(require("../model/TokenizationActivityStatus"));
|
|
14
|
+
var _TokenizationAllowlistActivationRequest = _interopRequireDefault(require("../model/TokenizationAllowlistActivationRequest"));
|
|
15
|
+
var _TokenizationAllowlistAddressesResponse = _interopRequireDefault(require("../model/TokenizationAllowlistAddressesResponse"));
|
|
16
|
+
var _TokenizationBurnTokenRequest = _interopRequireDefault(require("../model/TokenizationBurnTokenRequest"));
|
|
17
|
+
var _TokenizationContractCallRequest = _interopRequireDefault(require("../model/TokenizationContractCallRequest"));
|
|
18
|
+
var _TokenizationEstimateFeeRequest = _interopRequireDefault(require("../model/TokenizationEstimateFeeRequest"));
|
|
19
|
+
var _TokenizationIssuedTokenRequest = _interopRequireDefault(require("../model/TokenizationIssuedTokenRequest"));
|
|
20
|
+
var _TokenizationListActivitiesResponse = _interopRequireDefault(require("../model/TokenizationListActivitiesResponse"));
|
|
21
|
+
var _TokenizationListEnabledChainsResponse = _interopRequireDefault(require("../model/TokenizationListEnabledChainsResponse"));
|
|
22
|
+
var _TokenizationListHoldingsResponse = _interopRequireDefault(require("../model/TokenizationListHoldingsResponse"));
|
|
23
|
+
var _TokenizationListTokenInfoResponse = _interopRequireDefault(require("../model/TokenizationListTokenInfoResponse"));
|
|
24
|
+
var _TokenizationMintTokenRequest = _interopRequireDefault(require("../model/TokenizationMintTokenRequest"));
|
|
25
|
+
var _TokenizationOperationResponse = _interopRequireDefault(require("../model/TokenizationOperationResponse"));
|
|
26
|
+
var _TokenizationOperationType = _interopRequireDefault(require("../model/TokenizationOperationType"));
|
|
27
|
+
var _TokenizationPauseTokenRequest = _interopRequireDefault(require("../model/TokenizationPauseTokenRequest"));
|
|
28
|
+
var _TokenizationStatus = _interopRequireDefault(require("../model/TokenizationStatus"));
|
|
29
|
+
var _TokenizationTokenDetailInfo = _interopRequireDefault(require("../model/TokenizationTokenDetailInfo"));
|
|
30
|
+
var _TokenizationTokenStandard = _interopRequireDefault(require("../model/TokenizationTokenStandard"));
|
|
31
|
+
var _TokenizationUnpauseTokenRequest = _interopRequireDefault(require("../model/TokenizationUnpauseTokenRequest"));
|
|
32
|
+
var _TokenizationUpdateAllowlistAddressesRequest = _interopRequireDefault(require("../model/TokenizationUpdateAllowlistAddressesRequest"));
|
|
33
|
+
var _TokenizationUpdateBlocklistAddressesRequest = _interopRequireDefault(require("../model/TokenizationUpdateBlocklistAddressesRequest"));
|
|
34
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
35
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
36
|
+
function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
|
|
37
|
+
function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
|
|
38
|
+
function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
|
|
39
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
40
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /**
|
|
41
|
+
* Cobo Wallet as a Service 2.0
|
|
42
|
+
*
|
|
43
|
+
* Contact: help@cobo.com
|
|
44
|
+
*
|
|
45
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
46
|
+
* https://openapi-generator.tech
|
|
47
|
+
* Do not edit the class manually.
|
|
48
|
+
*
|
|
49
|
+
*/
|
|
50
|
+
/**
|
|
51
|
+
* Tokenization service.
|
|
52
|
+
* @module api/TokenizationApi
|
|
53
|
+
*/
|
|
54
|
+
var TokenizationApi = exports["default"] = /*#__PURE__*/function () {
|
|
55
|
+
/**
|
|
56
|
+
* Constructs a new TokenizationApi.
|
|
57
|
+
* @alias module:api/TokenizationApi
|
|
58
|
+
* @class
|
|
59
|
+
* @param {module:ApiClient} [apiClient] Optional API client implementation to use,
|
|
60
|
+
* default to {@link module:ApiClient#instance} if unspecified.
|
|
61
|
+
*/
|
|
62
|
+
function TokenizationApi(apiClient) {
|
|
63
|
+
_classCallCheck(this, TokenizationApi);
|
|
64
|
+
this.apiClient = apiClient || _ApiClient["default"].instance;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
/**
|
|
68
|
+
* Burn tokens
|
|
69
|
+
* This operation burns tokens from a specified address. Creates a burn transaction that will decrease the token supply.
|
|
70
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
71
|
+
* @param {Object} opts Optional parameters
|
|
72
|
+
* @param {module:model/TokenizationBurnTokenRequest} [TokenizationBurnTokenRequest] The request body for burning tokens.
|
|
73
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationOperationResponse} and HTTP response
|
|
74
|
+
*/
|
|
75
|
+
return _createClass(TokenizationApi, [{
|
|
76
|
+
key: "burnTokenizationWithHttpInfo",
|
|
77
|
+
value: function burnTokenizationWithHttpInfo(token_id, opts) {
|
|
78
|
+
opts = opts || {};
|
|
79
|
+
var postBody = opts['TokenizationBurnTokenRequest'];
|
|
80
|
+
if (postBody && postBody.toJSON) {
|
|
81
|
+
postBody = postBody.toJSON();
|
|
82
|
+
}
|
|
83
|
+
// verify the required parameter 'token_id' is set
|
|
84
|
+
if (token_id === undefined || token_id === null) {
|
|
85
|
+
throw new Error("Missing the required parameter 'token_id' when calling burnTokenization");
|
|
86
|
+
}
|
|
87
|
+
var pathParams = {
|
|
88
|
+
'token_id': token_id
|
|
89
|
+
};
|
|
90
|
+
var queryParams = {};
|
|
91
|
+
var headerParams = {};
|
|
92
|
+
var formParams = {};
|
|
93
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
94
|
+
var contentTypes = ['application/json'];
|
|
95
|
+
var accepts = ['application/json'];
|
|
96
|
+
var returnType = _TokenizationOperationResponse["default"];
|
|
97
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/burn', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
/**
|
|
101
|
+
* Burn tokens
|
|
102
|
+
* This operation burns tokens from a specified address. Creates a burn transaction that will decrease the token supply.
|
|
103
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
104
|
+
* @param {Object} opts Optional parameters
|
|
105
|
+
* @param {module:model/TokenizationBurnTokenRequest} opts.TokenizationBurnTokenRequest The request body for burning tokens.
|
|
106
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationOperationResponse}
|
|
107
|
+
*/
|
|
108
|
+
}, {
|
|
109
|
+
key: "burnTokenization",
|
|
110
|
+
value: function burnTokenization(token_id, opts) {
|
|
111
|
+
return this.burnTokenizationWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
112
|
+
return response_and_data.data;
|
|
113
|
+
});
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
/**
|
|
117
|
+
* Estimate tokenization operation fee
|
|
118
|
+
* This operation estimates the fee required for tokenization operations. For EVM-based chains, this calculates the gas cost for the specified operation.
|
|
119
|
+
* @param {module:model/TokenizationEstimateFeeRequest} TokenizationEstimateFeeRequest The request body to estimate tokenization operation fee.
|
|
120
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/EstimatedFee} and HTTP response
|
|
121
|
+
*/
|
|
122
|
+
}, {
|
|
123
|
+
key: "estimateTokenizationFeeWithHttpInfo",
|
|
124
|
+
value: function estimateTokenizationFeeWithHttpInfo(TokenizationEstimateFeeRequest) {
|
|
125
|
+
var postBody = TokenizationEstimateFeeRequest;
|
|
126
|
+
if (postBody && postBody.toJSON) {
|
|
127
|
+
postBody = postBody.toJSON();
|
|
128
|
+
}
|
|
129
|
+
// verify the required parameter 'TokenizationEstimateFeeRequest' is set
|
|
130
|
+
if (TokenizationEstimateFeeRequest === undefined || TokenizationEstimateFeeRequest === null) {
|
|
131
|
+
throw new Error("Missing the required parameter 'TokenizationEstimateFeeRequest' when calling estimateTokenizationFee");
|
|
132
|
+
}
|
|
133
|
+
var pathParams = {};
|
|
134
|
+
var queryParams = {};
|
|
135
|
+
var headerParams = {};
|
|
136
|
+
var formParams = {};
|
|
137
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
138
|
+
var contentTypes = ['application/json'];
|
|
139
|
+
var accepts = ['application/json'];
|
|
140
|
+
var returnType = _EstimatedFee["default"];
|
|
141
|
+
return this.apiClient.callApi('/tokenization/estimate_fee', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
/**
|
|
145
|
+
* Estimate tokenization operation fee
|
|
146
|
+
* This operation estimates the fee required for tokenization operations. For EVM-based chains, this calculates the gas cost for the specified operation.
|
|
147
|
+
* @param {module:model/TokenizationEstimateFeeRequest} TokenizationEstimateFeeRequest The request body to estimate tokenization operation fee.
|
|
148
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EstimatedFee}
|
|
149
|
+
*/
|
|
150
|
+
}, {
|
|
151
|
+
key: "estimateTokenizationFee",
|
|
152
|
+
value: function estimateTokenizationFee(TokenizationEstimateFeeRequest) {
|
|
153
|
+
return this.estimateTokenizationFeeWithHttpInfo(TokenizationEstimateFeeRequest).then(function (response_and_data) {
|
|
154
|
+
return response_and_data.data;
|
|
155
|
+
});
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
/**
|
|
159
|
+
* Get tokenization activity details
|
|
160
|
+
* This operation retrieves the detailed information for a specific tokenization activity by its ID.
|
|
161
|
+
* @param {String} activity_id The ID of the activity.
|
|
162
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationActivityInfo} and HTTP response
|
|
163
|
+
*/
|
|
164
|
+
}, {
|
|
165
|
+
key: "getTokenizationActivityWithHttpInfo",
|
|
166
|
+
value: function getTokenizationActivityWithHttpInfo(activity_id) {
|
|
167
|
+
var postBody = null;
|
|
168
|
+
if (postBody && postBody.toJSON) {
|
|
169
|
+
postBody = postBody.toJSON();
|
|
170
|
+
}
|
|
171
|
+
// verify the required parameter 'activity_id' is set
|
|
172
|
+
if (activity_id === undefined || activity_id === null) {
|
|
173
|
+
throw new Error("Missing the required parameter 'activity_id' when calling getTokenizationActivity");
|
|
174
|
+
}
|
|
175
|
+
var pathParams = {
|
|
176
|
+
'activity_id': activity_id
|
|
177
|
+
};
|
|
178
|
+
var queryParams = {};
|
|
179
|
+
var headerParams = {};
|
|
180
|
+
var formParams = {};
|
|
181
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
182
|
+
var contentTypes = [];
|
|
183
|
+
var accepts = ['application/json'];
|
|
184
|
+
var returnType = _TokenizationActivityInfo["default"];
|
|
185
|
+
return this.apiClient.callApi('/tokenization/activities/{activity_id}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
/**
|
|
189
|
+
* Get tokenization activity details
|
|
190
|
+
* This operation retrieves the detailed information for a specific tokenization activity by its ID.
|
|
191
|
+
* @param {String} activity_id The ID of the activity.
|
|
192
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationActivityInfo}
|
|
193
|
+
*/
|
|
194
|
+
}, {
|
|
195
|
+
key: "getTokenizationActivity",
|
|
196
|
+
value: function getTokenizationActivity(activity_id) {
|
|
197
|
+
return this.getTokenizationActivityWithHttpInfo(activity_id).then(function (response_and_data) {
|
|
198
|
+
return response_and_data.data;
|
|
199
|
+
});
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
/**
|
|
203
|
+
* Get allowlist activation status
|
|
204
|
+
* This operation retrieves the allowlist activation status of the token contract.
|
|
205
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
206
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/GetTokenizationAllowlistActivation200Response} and HTTP response
|
|
207
|
+
*/
|
|
208
|
+
}, {
|
|
209
|
+
key: "getTokenizationAllowlistActivationWithHttpInfo",
|
|
210
|
+
value: function getTokenizationAllowlistActivationWithHttpInfo(token_id) {
|
|
211
|
+
var postBody = null;
|
|
212
|
+
if (postBody && postBody.toJSON) {
|
|
213
|
+
postBody = postBody.toJSON();
|
|
214
|
+
}
|
|
215
|
+
// verify the required parameter 'token_id' is set
|
|
216
|
+
if (token_id === undefined || token_id === null) {
|
|
217
|
+
throw new Error("Missing the required parameter 'token_id' when calling getTokenizationAllowlistActivation");
|
|
218
|
+
}
|
|
219
|
+
var pathParams = {
|
|
220
|
+
'token_id': token_id
|
|
221
|
+
};
|
|
222
|
+
var queryParams = {};
|
|
223
|
+
var headerParams = {};
|
|
224
|
+
var formParams = {};
|
|
225
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
226
|
+
var contentTypes = [];
|
|
227
|
+
var accepts = ['application/json'];
|
|
228
|
+
var returnType = _GetTokenizationAllowlistActivation200Response["default"];
|
|
229
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/allowlist/activation', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
/**
|
|
233
|
+
* Get allowlist activation status
|
|
234
|
+
* This operation retrieves the allowlist activation status of the token contract.
|
|
235
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
236
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/GetTokenizationAllowlistActivation200Response}
|
|
237
|
+
*/
|
|
238
|
+
}, {
|
|
239
|
+
key: "getTokenizationAllowlistActivation",
|
|
240
|
+
value: function getTokenizationAllowlistActivation(token_id) {
|
|
241
|
+
return this.getTokenizationAllowlistActivationWithHttpInfo(token_id).then(function (response_and_data) {
|
|
242
|
+
return response_and_data.data;
|
|
243
|
+
});
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
/**
|
|
247
|
+
* Get token details
|
|
248
|
+
* This operation retrieves the detailed information for a specific issued token by its ID.
|
|
249
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
250
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationTokenDetailInfo} and HTTP response
|
|
251
|
+
*/
|
|
252
|
+
}, {
|
|
253
|
+
key: "getTokenizationInfoWithHttpInfo",
|
|
254
|
+
value: function getTokenizationInfoWithHttpInfo(token_id) {
|
|
255
|
+
var postBody = null;
|
|
256
|
+
if (postBody && postBody.toJSON) {
|
|
257
|
+
postBody = postBody.toJSON();
|
|
258
|
+
}
|
|
259
|
+
// verify the required parameter 'token_id' is set
|
|
260
|
+
if (token_id === undefined || token_id === null) {
|
|
261
|
+
throw new Error("Missing the required parameter 'token_id' when calling getTokenizationInfo");
|
|
262
|
+
}
|
|
263
|
+
var pathParams = {
|
|
264
|
+
'token_id': token_id
|
|
265
|
+
};
|
|
266
|
+
var queryParams = {};
|
|
267
|
+
var headerParams = {};
|
|
268
|
+
var formParams = {};
|
|
269
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
270
|
+
var contentTypes = [];
|
|
271
|
+
var accepts = ['application/json'];
|
|
272
|
+
var returnType = _TokenizationTokenDetailInfo["default"];
|
|
273
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
/**
|
|
277
|
+
* Get token details
|
|
278
|
+
* This operation retrieves the detailed information for a specific issued token by its ID.
|
|
279
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
280
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationTokenDetailInfo}
|
|
281
|
+
*/
|
|
282
|
+
}, {
|
|
283
|
+
key: "getTokenizationInfo",
|
|
284
|
+
value: function getTokenizationInfo(token_id) {
|
|
285
|
+
return this.getTokenizationInfoWithHttpInfo(token_id).then(function (response_and_data) {
|
|
286
|
+
return response_and_data.data;
|
|
287
|
+
});
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
/**
|
|
291
|
+
* Issue token
|
|
292
|
+
* This operation issues a new token contract. It supports various blockchain platforms. For EVM-based chains, this involves issuing a new smart contract from a template.
|
|
293
|
+
* @param {module:model/TokenizationIssuedTokenRequest} TokenizationIssuedTokenRequest The request body to issue a new token.
|
|
294
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationOperationResponse} and HTTP response
|
|
295
|
+
*/
|
|
296
|
+
}, {
|
|
297
|
+
key: "issueTokenWithHttpInfo",
|
|
298
|
+
value: function issueTokenWithHttpInfo(TokenizationIssuedTokenRequest) {
|
|
299
|
+
var postBody = TokenizationIssuedTokenRequest;
|
|
300
|
+
if (postBody && postBody.toJSON) {
|
|
301
|
+
postBody = postBody.toJSON();
|
|
302
|
+
}
|
|
303
|
+
// verify the required parameter 'TokenizationIssuedTokenRequest' is set
|
|
304
|
+
if (TokenizationIssuedTokenRequest === undefined || TokenizationIssuedTokenRequest === null) {
|
|
305
|
+
throw new Error("Missing the required parameter 'TokenizationIssuedTokenRequest' when calling issueToken");
|
|
306
|
+
}
|
|
307
|
+
var pathParams = {};
|
|
308
|
+
var queryParams = {};
|
|
309
|
+
var headerParams = {};
|
|
310
|
+
var formParams = {};
|
|
311
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
312
|
+
var contentTypes = ['application/json'];
|
|
313
|
+
var accepts = ['application/json'];
|
|
314
|
+
var returnType = _TokenizationOperationResponse["default"];
|
|
315
|
+
return this.apiClient.callApi('/tokenization/tokens', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
/**
|
|
319
|
+
* Issue token
|
|
320
|
+
* This operation issues a new token contract. It supports various blockchain platforms. For EVM-based chains, this involves issuing a new smart contract from a template.
|
|
321
|
+
* @param {module:model/TokenizationIssuedTokenRequest} TokenizationIssuedTokenRequest The request body to issue a new token.
|
|
322
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationOperationResponse}
|
|
323
|
+
*/
|
|
324
|
+
}, {
|
|
325
|
+
key: "issueToken",
|
|
326
|
+
value: function issueToken(TokenizationIssuedTokenRequest) {
|
|
327
|
+
return this.issueTokenWithHttpInfo(TokenizationIssuedTokenRequest).then(function (response_and_data) {
|
|
328
|
+
return response_and_data.data;
|
|
329
|
+
});
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
/**
|
|
333
|
+
* List issued tokens
|
|
334
|
+
* This operation retrieves a list of tokens issued by the organization. Returns issued token information including total supply, holdings, and token status.
|
|
335
|
+
* @param {Object} opts Optional parameters
|
|
336
|
+
* @param {String} [chain_id] The chain ID, which is the unique identifier of a blockchain. You can retrieve the IDs of all the chains you can use by calling [List enabled chains](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-chains).
|
|
337
|
+
* @param {String} [token_id] The token ID, which is the unique identifier of a token. You can retrieve the IDs of all the tokens you can use by calling [List enabled tokens](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-tokens).
|
|
338
|
+
* @param {module:model/TokenizationTokenStandard} [token_standard] Filter by token standard.
|
|
339
|
+
* @param {module:model/TokenizationStatus} [status] Filter by token status.
|
|
340
|
+
* @param {Number} [limit = 10)] The maximum number of objects to return. For most operations, the value range is [1, 50].
|
|
341
|
+
* @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.
|
|
342
|
+
* @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.
|
|
343
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationListTokenInfoResponse} and HTTP response
|
|
344
|
+
*/
|
|
345
|
+
}, {
|
|
346
|
+
key: "listIssuedTokensWithHttpInfo",
|
|
347
|
+
value: function listIssuedTokensWithHttpInfo(opts) {
|
|
348
|
+
opts = opts || {};
|
|
349
|
+
var postBody = null;
|
|
350
|
+
if (postBody && postBody.toJSON) {
|
|
351
|
+
postBody = postBody.toJSON();
|
|
352
|
+
}
|
|
353
|
+
var pathParams = {};
|
|
354
|
+
var queryParams = {
|
|
355
|
+
'chain_id': opts['chain_id'],
|
|
356
|
+
'token_id': opts['token_id'],
|
|
357
|
+
'token_standard': opts['token_standard'],
|
|
358
|
+
'status': opts['status'],
|
|
359
|
+
'limit': opts['limit'],
|
|
360
|
+
'before': opts['before'],
|
|
361
|
+
'after': opts['after']
|
|
362
|
+
};
|
|
363
|
+
var headerParams = {};
|
|
364
|
+
var formParams = {};
|
|
365
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
366
|
+
var contentTypes = [];
|
|
367
|
+
var accepts = ['application/json'];
|
|
368
|
+
var returnType = _TokenizationListTokenInfoResponse["default"];
|
|
369
|
+
return this.apiClient.callApi('/tokenization/tokens', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
370
|
+
}
|
|
371
|
+
|
|
372
|
+
/**
|
|
373
|
+
* List issued tokens
|
|
374
|
+
* This operation retrieves a list of tokens issued by the organization. Returns issued token information including total supply, holdings, and token status.
|
|
375
|
+
* @param {Object} opts Optional parameters
|
|
376
|
+
* @param {String} opts.chain_id The chain ID, which is the unique identifier of a blockchain. You can retrieve the IDs of all the chains you can use by calling [List enabled chains](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-chains).
|
|
377
|
+
* @param {String} opts.token_id The token ID, which is the unique identifier of a token. You can retrieve the IDs of all the tokens you can use by calling [List enabled tokens](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-tokens).
|
|
378
|
+
* @param {module:model/TokenizationTokenStandard} opts.token_standard Filter by token standard.
|
|
379
|
+
* @param {module:model/TokenizationStatus} opts.status Filter by token status.
|
|
380
|
+
* @param {Number} opts.limit The maximum number of objects to return. For most operations, the value range is [1, 50]. (default to 10)
|
|
381
|
+
* @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.
|
|
382
|
+
* @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.
|
|
383
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationListTokenInfoResponse}
|
|
384
|
+
*/
|
|
385
|
+
}, {
|
|
386
|
+
key: "listIssuedTokens",
|
|
387
|
+
value: function listIssuedTokens(opts) {
|
|
388
|
+
return this.listIssuedTokensWithHttpInfo(opts).then(function (response_and_data) {
|
|
389
|
+
return response_and_data.data;
|
|
390
|
+
});
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
/**
|
|
394
|
+
* List tokenization activities
|
|
395
|
+
* This operation retrieves a list of tokenization activities.
|
|
396
|
+
* @param {Object} opts Optional parameters
|
|
397
|
+
* @param {String} [token_id] The token ID, which is the unique identifier of a token. You can retrieve the IDs of all the tokens you can use by calling [List enabled tokens](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-tokens).
|
|
398
|
+
* @param {module:model/TokenizationOperationType} [activity_type] Filter by tokenization activity type.
|
|
399
|
+
* @param {module:model/TokenizationActivityStatus} [activity_status] Filter by tokenization activity status.
|
|
400
|
+
* @param {Number} [limit = 10)] The maximum number of objects to return. For most operations, the value range is [1, 50].
|
|
401
|
+
* @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.
|
|
402
|
+
* @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.
|
|
403
|
+
* @param {module:model/String} [direction = 'ASC')] The sort direction. Possible values include: - `ASC`: Sort the results in ascending order. - `DESC`: Sort the results in descending order.
|
|
404
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationListActivitiesResponse} and HTTP response
|
|
405
|
+
*/
|
|
406
|
+
}, {
|
|
407
|
+
key: "listTokenizationActivitiesWithHttpInfo",
|
|
408
|
+
value: function listTokenizationActivitiesWithHttpInfo(opts) {
|
|
409
|
+
opts = opts || {};
|
|
410
|
+
var postBody = null;
|
|
411
|
+
if (postBody && postBody.toJSON) {
|
|
412
|
+
postBody = postBody.toJSON();
|
|
413
|
+
}
|
|
414
|
+
var pathParams = {};
|
|
415
|
+
var queryParams = {
|
|
416
|
+
'token_id': opts['token_id'],
|
|
417
|
+
'activity_type': opts['activity_type'],
|
|
418
|
+
'activity_status': opts['activity_status'],
|
|
419
|
+
'limit': opts['limit'],
|
|
420
|
+
'after': opts['after'],
|
|
421
|
+
'before': opts['before'],
|
|
422
|
+
'direction': opts['direction']
|
|
423
|
+
};
|
|
424
|
+
var headerParams = {};
|
|
425
|
+
var formParams = {};
|
|
426
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
427
|
+
var contentTypes = [];
|
|
428
|
+
var accepts = ['application/json'];
|
|
429
|
+
var returnType = _TokenizationListActivitiesResponse["default"];
|
|
430
|
+
return this.apiClient.callApi('/tokenization/activities', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
/**
|
|
434
|
+
* List tokenization activities
|
|
435
|
+
* This operation retrieves a list of tokenization activities.
|
|
436
|
+
* @param {Object} opts Optional parameters
|
|
437
|
+
* @param {String} opts.token_id The token ID, which is the unique identifier of a token. You can retrieve the IDs of all the tokens you can use by calling [List enabled tokens](https://www.cobo.com/developers/v2/api-references/wallets/list-enabled-tokens).
|
|
438
|
+
* @param {module:model/TokenizationOperationType} opts.activity_type Filter by tokenization activity type.
|
|
439
|
+
* @param {module:model/TokenizationActivityStatus} opts.activity_status Filter by tokenization activity status.
|
|
440
|
+
* @param {Number} opts.limit The maximum number of objects to return. For most operations, the value range is [1, 50]. (default to 10)
|
|
441
|
+
* @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.
|
|
442
|
+
* @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.
|
|
443
|
+
* @param {module:model/String} opts.direction The sort direction. Possible values include: - `ASC`: Sort the results in ascending order. - `DESC`: Sort the results in descending order. (default to 'ASC')
|
|
444
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationListActivitiesResponse}
|
|
445
|
+
*/
|
|
446
|
+
}, {
|
|
447
|
+
key: "listTokenizationActivities",
|
|
448
|
+
value: function listTokenizationActivities(opts) {
|
|
449
|
+
return this.listTokenizationActivitiesWithHttpInfo(opts).then(function (response_and_data) {
|
|
450
|
+
return response_and_data.data;
|
|
451
|
+
});
|
|
452
|
+
}
|
|
453
|
+
|
|
454
|
+
/**
|
|
455
|
+
* List addresses on allowlist
|
|
456
|
+
* This operation lists addresses on the allowlist.
|
|
457
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
458
|
+
* @param {Object} opts Optional parameters
|
|
459
|
+
* @param {Number} [limit = 10)] The maximum number of objects to return. For most operations, the value range is [1, 50].
|
|
460
|
+
* @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.
|
|
461
|
+
* @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.
|
|
462
|
+
* @param {module:model/String} [direction = 'ASC')] The sort direction. Possible values include: - `ASC`: Sort the results in ascending order. - `DESC`: Sort the results in descending order.
|
|
463
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationAllowlistAddressesResponse} and HTTP response
|
|
464
|
+
*/
|
|
465
|
+
}, {
|
|
466
|
+
key: "listTokenizationAllowlistAddressesWithHttpInfo",
|
|
467
|
+
value: function listTokenizationAllowlistAddressesWithHttpInfo(token_id, opts) {
|
|
468
|
+
opts = opts || {};
|
|
469
|
+
var postBody = null;
|
|
470
|
+
if (postBody && postBody.toJSON) {
|
|
471
|
+
postBody = postBody.toJSON();
|
|
472
|
+
}
|
|
473
|
+
// verify the required parameter 'token_id' is set
|
|
474
|
+
if (token_id === undefined || token_id === null) {
|
|
475
|
+
throw new Error("Missing the required parameter 'token_id' when calling listTokenizationAllowlistAddresses");
|
|
476
|
+
}
|
|
477
|
+
var pathParams = {
|
|
478
|
+
'token_id': token_id
|
|
479
|
+
};
|
|
480
|
+
var queryParams = {
|
|
481
|
+
'limit': opts['limit'],
|
|
482
|
+
'after': opts['after'],
|
|
483
|
+
'before': opts['before'],
|
|
484
|
+
'direction': opts['direction']
|
|
485
|
+
};
|
|
486
|
+
var headerParams = {};
|
|
487
|
+
var formParams = {};
|
|
488
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
489
|
+
var contentTypes = [];
|
|
490
|
+
var accepts = ['application/json'];
|
|
491
|
+
var returnType = _TokenizationAllowlistAddressesResponse["default"];
|
|
492
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/allowlist/addresses', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
493
|
+
}
|
|
494
|
+
|
|
495
|
+
/**
|
|
496
|
+
* List addresses on allowlist
|
|
497
|
+
* This operation lists addresses on the allowlist.
|
|
498
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
499
|
+
* @param {Object} opts Optional parameters
|
|
500
|
+
* @param {Number} opts.limit The maximum number of objects to return. For most operations, the value range is [1, 50]. (default to 10)
|
|
501
|
+
* @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.
|
|
502
|
+
* @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.
|
|
503
|
+
* @param {module:model/String} opts.direction The sort direction. Possible values include: - `ASC`: Sort the results in ascending order. - `DESC`: Sort the results in descending order. (default to 'ASC')
|
|
504
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationAllowlistAddressesResponse}
|
|
505
|
+
*/
|
|
506
|
+
}, {
|
|
507
|
+
key: "listTokenizationAllowlistAddresses",
|
|
508
|
+
value: function listTokenizationAllowlistAddresses(token_id, opts) {
|
|
509
|
+
return this.listTokenizationAllowlistAddressesWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
510
|
+
return response_and_data.data;
|
|
511
|
+
});
|
|
512
|
+
}
|
|
513
|
+
|
|
514
|
+
/**
|
|
515
|
+
* Lists addresses on blocklist
|
|
516
|
+
* This operation lists addresses on the blocklist.
|
|
517
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
518
|
+
* @param {Object} opts Optional parameters
|
|
519
|
+
* @param {Number} [limit = 10)] The maximum number of objects to return. For most operations, the value range is [1, 50].
|
|
520
|
+
* @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.
|
|
521
|
+
* @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.
|
|
522
|
+
* @param {module:model/String} [direction = 'ASC')] The sort direction. Possible values include: - `ASC`: Sort the results in ascending order. - `DESC`: Sort the results in descending order.
|
|
523
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ListTokenizationBlocklistAddresses200Response} and HTTP response
|
|
524
|
+
*/
|
|
525
|
+
}, {
|
|
526
|
+
key: "listTokenizationBlocklistAddressesWithHttpInfo",
|
|
527
|
+
value: function listTokenizationBlocklistAddressesWithHttpInfo(token_id, opts) {
|
|
528
|
+
opts = opts || {};
|
|
529
|
+
var postBody = null;
|
|
530
|
+
if (postBody && postBody.toJSON) {
|
|
531
|
+
postBody = postBody.toJSON();
|
|
532
|
+
}
|
|
533
|
+
// verify the required parameter 'token_id' is set
|
|
534
|
+
if (token_id === undefined || token_id === null) {
|
|
535
|
+
throw new Error("Missing the required parameter 'token_id' when calling listTokenizationBlocklistAddresses");
|
|
536
|
+
}
|
|
537
|
+
var pathParams = {
|
|
538
|
+
'token_id': token_id
|
|
539
|
+
};
|
|
540
|
+
var queryParams = {
|
|
541
|
+
'limit': opts['limit'],
|
|
542
|
+
'after': opts['after'],
|
|
543
|
+
'before': opts['before'],
|
|
544
|
+
'direction': opts['direction']
|
|
545
|
+
};
|
|
546
|
+
var headerParams = {};
|
|
547
|
+
var formParams = {};
|
|
548
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
549
|
+
var contentTypes = [];
|
|
550
|
+
var accepts = ['application/json'];
|
|
551
|
+
var returnType = _ListTokenizationBlocklistAddresses200Response["default"];
|
|
552
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/blocklist/addresses', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
553
|
+
}
|
|
554
|
+
|
|
555
|
+
/**
|
|
556
|
+
* Lists addresses on blocklist
|
|
557
|
+
* This operation lists addresses on the blocklist.
|
|
558
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
559
|
+
* @param {Object} opts Optional parameters
|
|
560
|
+
* @param {Number} opts.limit The maximum number of objects to return. For most operations, the value range is [1, 50]. (default to 10)
|
|
561
|
+
* @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.
|
|
562
|
+
* @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.
|
|
563
|
+
* @param {module:model/String} opts.direction The sort direction. Possible values include: - `ASC`: Sort the results in ascending order. - `DESC`: Sort the results in descending order. (default to 'ASC')
|
|
564
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ListTokenizationBlocklistAddresses200Response}
|
|
565
|
+
*/
|
|
566
|
+
}, {
|
|
567
|
+
key: "listTokenizationBlocklistAddresses",
|
|
568
|
+
value: function listTokenizationBlocklistAddresses(token_id, opts) {
|
|
569
|
+
return this.listTokenizationBlocklistAddressesWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
570
|
+
return response_and_data.data;
|
|
571
|
+
});
|
|
572
|
+
}
|
|
573
|
+
|
|
574
|
+
/**
|
|
575
|
+
* Get token holdings information
|
|
576
|
+
* This operation retrieves the holdings information for a specific issued token, showing which wallets hold the token and their respective balances.
|
|
577
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
578
|
+
* @param {Object} opts Optional parameters
|
|
579
|
+
* @param {Number} [limit = 10)] The maximum number of objects to return. For most operations, the value range is [1, 50].
|
|
580
|
+
* @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.
|
|
581
|
+
* @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.
|
|
582
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationListHoldingsResponse} and HTTP response
|
|
583
|
+
*/
|
|
584
|
+
}, {
|
|
585
|
+
key: "listTokenizationHoldingsWithHttpInfo",
|
|
586
|
+
value: function listTokenizationHoldingsWithHttpInfo(token_id, opts) {
|
|
587
|
+
opts = opts || {};
|
|
588
|
+
var postBody = null;
|
|
589
|
+
if (postBody && postBody.toJSON) {
|
|
590
|
+
postBody = postBody.toJSON();
|
|
591
|
+
}
|
|
592
|
+
// verify the required parameter 'token_id' is set
|
|
593
|
+
if (token_id === undefined || token_id === null) {
|
|
594
|
+
throw new Error("Missing the required parameter 'token_id' when calling listTokenizationHoldings");
|
|
595
|
+
}
|
|
596
|
+
var pathParams = {
|
|
597
|
+
'token_id': token_id
|
|
598
|
+
};
|
|
599
|
+
var queryParams = {
|
|
600
|
+
'limit': opts['limit'],
|
|
601
|
+
'before': opts['before'],
|
|
602
|
+
'after': opts['after']
|
|
603
|
+
};
|
|
604
|
+
var headerParams = {};
|
|
605
|
+
var formParams = {};
|
|
606
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
607
|
+
var contentTypes = [];
|
|
608
|
+
var accepts = ['application/json'];
|
|
609
|
+
var returnType = _TokenizationListHoldingsResponse["default"];
|
|
610
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/holdings', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
611
|
+
}
|
|
612
|
+
|
|
613
|
+
/**
|
|
614
|
+
* Get token holdings information
|
|
615
|
+
* This operation retrieves the holdings information for a specific issued token, showing which wallets hold the token and their respective balances.
|
|
616
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
617
|
+
* @param {Object} opts Optional parameters
|
|
618
|
+
* @param {Number} opts.limit The maximum number of objects to return. For most operations, the value range is [1, 50]. (default to 10)
|
|
619
|
+
* @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.
|
|
620
|
+
* @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.
|
|
621
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationListHoldingsResponse}
|
|
622
|
+
*/
|
|
623
|
+
}, {
|
|
624
|
+
key: "listTokenizationHoldings",
|
|
625
|
+
value: function listTokenizationHoldings(token_id, opts) {
|
|
626
|
+
return this.listTokenizationHoldingsWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
627
|
+
return response_and_data.data;
|
|
628
|
+
});
|
|
629
|
+
}
|
|
630
|
+
|
|
631
|
+
/**
|
|
632
|
+
* List supported chains for tokenization
|
|
633
|
+
* This operation retrieves a list of tokenization supported chains.
|
|
634
|
+
* @param {Object} opts Optional parameters
|
|
635
|
+
* @param {Number} [limit = 10)] The maximum number of objects to return. For most operations, the value range is [1, 50].
|
|
636
|
+
* @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.
|
|
637
|
+
* @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.
|
|
638
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationListEnabledChainsResponse} and HTTP response
|
|
639
|
+
*/
|
|
640
|
+
}, {
|
|
641
|
+
key: "listTokenizationSupportedChainsWithHttpInfo",
|
|
642
|
+
value: function listTokenizationSupportedChainsWithHttpInfo(opts) {
|
|
643
|
+
opts = opts || {};
|
|
644
|
+
var postBody = null;
|
|
645
|
+
if (postBody && postBody.toJSON) {
|
|
646
|
+
postBody = postBody.toJSON();
|
|
647
|
+
}
|
|
648
|
+
var pathParams = {};
|
|
649
|
+
var queryParams = {
|
|
650
|
+
'limit': opts['limit'],
|
|
651
|
+
'after': opts['after'],
|
|
652
|
+
'before': opts['before']
|
|
653
|
+
};
|
|
654
|
+
var headerParams = {};
|
|
655
|
+
var formParams = {};
|
|
656
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
657
|
+
var contentTypes = [];
|
|
658
|
+
var accepts = ['application/json'];
|
|
659
|
+
var returnType = _TokenizationListEnabledChainsResponse["default"];
|
|
660
|
+
return this.apiClient.callApi('/tokenization/enabled_chains', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
661
|
+
}
|
|
662
|
+
|
|
663
|
+
/**
|
|
664
|
+
* List supported chains for tokenization
|
|
665
|
+
* This operation retrieves a list of tokenization supported chains.
|
|
666
|
+
* @param {Object} opts Optional parameters
|
|
667
|
+
* @param {Number} opts.limit The maximum number of objects to return. For most operations, the value range is [1, 50]. (default to 10)
|
|
668
|
+
* @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.
|
|
669
|
+
* @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.
|
|
670
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationListEnabledChainsResponse}
|
|
671
|
+
*/
|
|
672
|
+
}, {
|
|
673
|
+
key: "listTokenizationSupportedChains",
|
|
674
|
+
value: function listTokenizationSupportedChains(opts) {
|
|
675
|
+
return this.listTokenizationSupportedChainsWithHttpInfo(opts).then(function (response_and_data) {
|
|
676
|
+
return response_and_data.data;
|
|
677
|
+
});
|
|
678
|
+
}
|
|
679
|
+
|
|
680
|
+
/**
|
|
681
|
+
* Mint tokens
|
|
682
|
+
* This operation mints new tokens to a specified address. Creates a mint transaction that will increase the token supply.
|
|
683
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
684
|
+
* @param {module:model/TokenizationMintTokenRequest} TokenizationMintTokenRequest The request body for minting tokens.
|
|
685
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationOperationResponse} and HTTP response
|
|
686
|
+
*/
|
|
687
|
+
}, {
|
|
688
|
+
key: "mintTokenizationWithHttpInfo",
|
|
689
|
+
value: function mintTokenizationWithHttpInfo(token_id, TokenizationMintTokenRequest) {
|
|
690
|
+
var postBody = TokenizationMintTokenRequest;
|
|
691
|
+
if (postBody && postBody.toJSON) {
|
|
692
|
+
postBody = postBody.toJSON();
|
|
693
|
+
}
|
|
694
|
+
// verify the required parameter 'token_id' is set
|
|
695
|
+
if (token_id === undefined || token_id === null) {
|
|
696
|
+
throw new Error("Missing the required parameter 'token_id' when calling mintTokenization");
|
|
697
|
+
}
|
|
698
|
+
// verify the required parameter 'TokenizationMintTokenRequest' is set
|
|
699
|
+
if (TokenizationMintTokenRequest === undefined || TokenizationMintTokenRequest === null) {
|
|
700
|
+
throw new Error("Missing the required parameter 'TokenizationMintTokenRequest' when calling mintTokenization");
|
|
701
|
+
}
|
|
702
|
+
var pathParams = {
|
|
703
|
+
'token_id': token_id
|
|
704
|
+
};
|
|
705
|
+
var queryParams = {};
|
|
706
|
+
var headerParams = {};
|
|
707
|
+
var formParams = {};
|
|
708
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
709
|
+
var contentTypes = ['application/json'];
|
|
710
|
+
var accepts = ['application/json'];
|
|
711
|
+
var returnType = _TokenizationOperationResponse["default"];
|
|
712
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/mint', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
713
|
+
}
|
|
714
|
+
|
|
715
|
+
/**
|
|
716
|
+
* Mint tokens
|
|
717
|
+
* This operation mints new tokens to a specified address. Creates a mint transaction that will increase the token supply.
|
|
718
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
719
|
+
* @param {module:model/TokenizationMintTokenRequest} TokenizationMintTokenRequest The request body for minting tokens.
|
|
720
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationOperationResponse}
|
|
721
|
+
*/
|
|
722
|
+
}, {
|
|
723
|
+
key: "mintTokenization",
|
|
724
|
+
value: function mintTokenization(token_id, TokenizationMintTokenRequest) {
|
|
725
|
+
return this.mintTokenizationWithHttpInfo(token_id, TokenizationMintTokenRequest).then(function (response_and_data) {
|
|
726
|
+
return response_and_data.data;
|
|
727
|
+
});
|
|
728
|
+
}
|
|
729
|
+
|
|
730
|
+
/**
|
|
731
|
+
* Pause token contract
|
|
732
|
+
* This operation pauses the token contract, temporarily halting token operations and transfers.
|
|
733
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
734
|
+
* @param {Object} opts Optional parameters
|
|
735
|
+
* @param {module:model/TokenizationPauseTokenRequest} [TokenizationPauseTokenRequest] The request body for pausing tokens.
|
|
736
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationOperationResponse} and HTTP response
|
|
737
|
+
*/
|
|
738
|
+
}, {
|
|
739
|
+
key: "pauseTokenizationWithHttpInfo",
|
|
740
|
+
value: function pauseTokenizationWithHttpInfo(token_id, opts) {
|
|
741
|
+
opts = opts || {};
|
|
742
|
+
var postBody = opts['TokenizationPauseTokenRequest'];
|
|
743
|
+
if (postBody && postBody.toJSON) {
|
|
744
|
+
postBody = postBody.toJSON();
|
|
745
|
+
}
|
|
746
|
+
// verify the required parameter 'token_id' is set
|
|
747
|
+
if (token_id === undefined || token_id === null) {
|
|
748
|
+
throw new Error("Missing the required parameter 'token_id' when calling pauseTokenization");
|
|
749
|
+
}
|
|
750
|
+
var pathParams = {
|
|
751
|
+
'token_id': token_id
|
|
752
|
+
};
|
|
753
|
+
var queryParams = {};
|
|
754
|
+
var headerParams = {};
|
|
755
|
+
var formParams = {};
|
|
756
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
757
|
+
var contentTypes = ['application/json'];
|
|
758
|
+
var accepts = ['application/json'];
|
|
759
|
+
var returnType = _TokenizationOperationResponse["default"];
|
|
760
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/pause', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
761
|
+
}
|
|
762
|
+
|
|
763
|
+
/**
|
|
764
|
+
* Pause token contract
|
|
765
|
+
* This operation pauses the token contract, temporarily halting token operations and transfers.
|
|
766
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
767
|
+
* @param {Object} opts Optional parameters
|
|
768
|
+
* @param {module:model/TokenizationPauseTokenRequest} opts.TokenizationPauseTokenRequest The request body for pausing tokens.
|
|
769
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationOperationResponse}
|
|
770
|
+
*/
|
|
771
|
+
}, {
|
|
772
|
+
key: "pauseTokenization",
|
|
773
|
+
value: function pauseTokenization(token_id, opts) {
|
|
774
|
+
return this.pauseTokenizationWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
775
|
+
return response_and_data.data;
|
|
776
|
+
});
|
|
777
|
+
}
|
|
778
|
+
|
|
779
|
+
/**
|
|
780
|
+
* Call token contract
|
|
781
|
+
* This operation performs a contract call on the token contract.
|
|
782
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
783
|
+
* @param {Object} opts Optional parameters
|
|
784
|
+
* @param {module:model/TokenizationContractCallRequest} [TokenizationContractCallRequest] The request body for contract call.
|
|
785
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationOperationResponse} and HTTP response
|
|
786
|
+
*/
|
|
787
|
+
}, {
|
|
788
|
+
key: "tokenizationContractCallWithHttpInfo",
|
|
789
|
+
value: function tokenizationContractCallWithHttpInfo(token_id, opts) {
|
|
790
|
+
opts = opts || {};
|
|
791
|
+
var postBody = opts['TokenizationContractCallRequest'];
|
|
792
|
+
if (postBody && postBody.toJSON) {
|
|
793
|
+
postBody = postBody.toJSON();
|
|
794
|
+
}
|
|
795
|
+
// verify the required parameter 'token_id' is set
|
|
796
|
+
if (token_id === undefined || token_id === null) {
|
|
797
|
+
throw new Error("Missing the required parameter 'token_id' when calling tokenizationContractCall");
|
|
798
|
+
}
|
|
799
|
+
var pathParams = {
|
|
800
|
+
'token_id': token_id
|
|
801
|
+
};
|
|
802
|
+
var queryParams = {};
|
|
803
|
+
var headerParams = {};
|
|
804
|
+
var formParams = {};
|
|
805
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
806
|
+
var contentTypes = ['application/json'];
|
|
807
|
+
var accepts = ['application/json'];
|
|
808
|
+
var returnType = _TokenizationOperationResponse["default"];
|
|
809
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/contract_call', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
810
|
+
}
|
|
811
|
+
|
|
812
|
+
/**
|
|
813
|
+
* Call token contract
|
|
814
|
+
* This operation performs a contract call on the token contract.
|
|
815
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
816
|
+
* @param {Object} opts Optional parameters
|
|
817
|
+
* @param {module:model/TokenizationContractCallRequest} opts.TokenizationContractCallRequest The request body for contract call.
|
|
818
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationOperationResponse}
|
|
819
|
+
*/
|
|
820
|
+
}, {
|
|
821
|
+
key: "tokenizationContractCall",
|
|
822
|
+
value: function tokenizationContractCall(token_id, opts) {
|
|
823
|
+
return this.tokenizationContractCallWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
824
|
+
return response_and_data.data;
|
|
825
|
+
});
|
|
826
|
+
}
|
|
827
|
+
|
|
828
|
+
/**
|
|
829
|
+
* Unpause token contract
|
|
830
|
+
* This operation unpauses the token contract, resuming token operations and transfers.
|
|
831
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
832
|
+
* @param {Object} opts Optional parameters
|
|
833
|
+
* @param {module:model/TokenizationUnpauseTokenRequest} [TokenizationUnpauseTokenRequest] The request body for unpausing tokens.
|
|
834
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationOperationResponse} and HTTP response
|
|
835
|
+
*/
|
|
836
|
+
}, {
|
|
837
|
+
key: "unpauseTokenizationWithHttpInfo",
|
|
838
|
+
value: function unpauseTokenizationWithHttpInfo(token_id, opts) {
|
|
839
|
+
opts = opts || {};
|
|
840
|
+
var postBody = opts['TokenizationUnpauseTokenRequest'];
|
|
841
|
+
if (postBody && postBody.toJSON) {
|
|
842
|
+
postBody = postBody.toJSON();
|
|
843
|
+
}
|
|
844
|
+
// verify the required parameter 'token_id' is set
|
|
845
|
+
if (token_id === undefined || token_id === null) {
|
|
846
|
+
throw new Error("Missing the required parameter 'token_id' when calling unpauseTokenization");
|
|
847
|
+
}
|
|
848
|
+
var pathParams = {
|
|
849
|
+
'token_id': token_id
|
|
850
|
+
};
|
|
851
|
+
var queryParams = {};
|
|
852
|
+
var headerParams = {};
|
|
853
|
+
var formParams = {};
|
|
854
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
855
|
+
var contentTypes = ['application/json'];
|
|
856
|
+
var accepts = ['application/json'];
|
|
857
|
+
var returnType = _TokenizationOperationResponse["default"];
|
|
858
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/unpause', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
859
|
+
}
|
|
860
|
+
|
|
861
|
+
/**
|
|
862
|
+
* Unpause token contract
|
|
863
|
+
* This operation unpauses the token contract, resuming token operations and transfers.
|
|
864
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
865
|
+
* @param {Object} opts Optional parameters
|
|
866
|
+
* @param {module:model/TokenizationUnpauseTokenRequest} opts.TokenizationUnpauseTokenRequest The request body for unpausing tokens.
|
|
867
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationOperationResponse}
|
|
868
|
+
*/
|
|
869
|
+
}, {
|
|
870
|
+
key: "unpauseTokenization",
|
|
871
|
+
value: function unpauseTokenization(token_id, opts) {
|
|
872
|
+
return this.unpauseTokenizationWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
873
|
+
return response_and_data.data;
|
|
874
|
+
});
|
|
875
|
+
}
|
|
876
|
+
|
|
877
|
+
/**
|
|
878
|
+
* Activate or deactivate allowlist
|
|
879
|
+
* This operation activates or deactivates the allowlist.
|
|
880
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
881
|
+
* @param {Object} opts Optional parameters
|
|
882
|
+
* @param {module:model/TokenizationAllowlistActivationRequest} [TokenizationAllowlistActivationRequest] The request body for activating or deactivating the allowlist.
|
|
883
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationOperationResponse} and HTTP response
|
|
884
|
+
*/
|
|
885
|
+
}, {
|
|
886
|
+
key: "updateTokenizationAllowlistActivationWithHttpInfo",
|
|
887
|
+
value: function updateTokenizationAllowlistActivationWithHttpInfo(token_id, opts) {
|
|
888
|
+
opts = opts || {};
|
|
889
|
+
var postBody = opts['TokenizationAllowlistActivationRequest'];
|
|
890
|
+
if (postBody && postBody.toJSON) {
|
|
891
|
+
postBody = postBody.toJSON();
|
|
892
|
+
}
|
|
893
|
+
// verify the required parameter 'token_id' is set
|
|
894
|
+
if (token_id === undefined || token_id === null) {
|
|
895
|
+
throw new Error("Missing the required parameter 'token_id' when calling updateTokenizationAllowlistActivation");
|
|
896
|
+
}
|
|
897
|
+
var pathParams = {
|
|
898
|
+
'token_id': token_id
|
|
899
|
+
};
|
|
900
|
+
var queryParams = {};
|
|
901
|
+
var headerParams = {};
|
|
902
|
+
var formParams = {};
|
|
903
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
904
|
+
var contentTypes = ['application/json'];
|
|
905
|
+
var accepts = ['application/json'];
|
|
906
|
+
var returnType = _TokenizationOperationResponse["default"];
|
|
907
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/allowlist/activation', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
908
|
+
}
|
|
909
|
+
|
|
910
|
+
/**
|
|
911
|
+
* Activate or deactivate allowlist
|
|
912
|
+
* This operation activates or deactivates the allowlist.
|
|
913
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
914
|
+
* @param {Object} opts Optional parameters
|
|
915
|
+
* @param {module:model/TokenizationAllowlistActivationRequest} opts.TokenizationAllowlistActivationRequest The request body for activating or deactivating the allowlist.
|
|
916
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationOperationResponse}
|
|
917
|
+
*/
|
|
918
|
+
}, {
|
|
919
|
+
key: "updateTokenizationAllowlistActivation",
|
|
920
|
+
value: function updateTokenizationAllowlistActivation(token_id, opts) {
|
|
921
|
+
return this.updateTokenizationAllowlistActivationWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
922
|
+
return response_and_data.data;
|
|
923
|
+
});
|
|
924
|
+
}
|
|
925
|
+
|
|
926
|
+
/**
|
|
927
|
+
* Update addresses on allowlist
|
|
928
|
+
* This operation updates addresses on the allowlist.
|
|
929
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
930
|
+
* @param {Object} opts Optional parameters
|
|
931
|
+
* @param {module:model/TokenizationUpdateAllowlistAddressesRequest} [TokenizationUpdateAllowlistAddressesRequest] The request body for adding or removing multiple addresses on the allowlist.
|
|
932
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationOperationResponse} and HTTP response
|
|
933
|
+
*/
|
|
934
|
+
}, {
|
|
935
|
+
key: "updateTokenizationAllowlistAddressesWithHttpInfo",
|
|
936
|
+
value: function updateTokenizationAllowlistAddressesWithHttpInfo(token_id, opts) {
|
|
937
|
+
opts = opts || {};
|
|
938
|
+
var postBody = opts['TokenizationUpdateAllowlistAddressesRequest'];
|
|
939
|
+
if (postBody && postBody.toJSON) {
|
|
940
|
+
postBody = postBody.toJSON();
|
|
941
|
+
}
|
|
942
|
+
// verify the required parameter 'token_id' is set
|
|
943
|
+
if (token_id === undefined || token_id === null) {
|
|
944
|
+
throw new Error("Missing the required parameter 'token_id' when calling updateTokenizationAllowlistAddresses");
|
|
945
|
+
}
|
|
946
|
+
var pathParams = {
|
|
947
|
+
'token_id': token_id
|
|
948
|
+
};
|
|
949
|
+
var queryParams = {};
|
|
950
|
+
var headerParams = {};
|
|
951
|
+
var formParams = {};
|
|
952
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
953
|
+
var contentTypes = ['application/json'];
|
|
954
|
+
var accepts = ['application/json'];
|
|
955
|
+
var returnType = _TokenizationOperationResponse["default"];
|
|
956
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/allowlist/addresses', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
957
|
+
}
|
|
958
|
+
|
|
959
|
+
/**
|
|
960
|
+
* Update addresses on allowlist
|
|
961
|
+
* This operation updates addresses on the allowlist.
|
|
962
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
963
|
+
* @param {Object} opts Optional parameters
|
|
964
|
+
* @param {module:model/TokenizationUpdateAllowlistAddressesRequest} opts.TokenizationUpdateAllowlistAddressesRequest The request body for adding or removing multiple addresses on the allowlist.
|
|
965
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationOperationResponse}
|
|
966
|
+
*/
|
|
967
|
+
}, {
|
|
968
|
+
key: "updateTokenizationAllowlistAddresses",
|
|
969
|
+
value: function updateTokenizationAllowlistAddresses(token_id, opts) {
|
|
970
|
+
return this.updateTokenizationAllowlistAddressesWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
971
|
+
return response_and_data.data;
|
|
972
|
+
});
|
|
973
|
+
}
|
|
974
|
+
|
|
975
|
+
/**
|
|
976
|
+
* Update addresses on blocklist
|
|
977
|
+
* This operation updates addresses on the blocklist.
|
|
978
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
979
|
+
* @param {Object} opts Optional parameters
|
|
980
|
+
* @param {module:model/TokenizationUpdateBlocklistAddressesRequest} [TokenizationUpdateBlocklistAddressesRequest] The request body for adding or removing multiple addresses on the blocklist.
|
|
981
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TokenizationOperationResponse} and HTTP response
|
|
982
|
+
*/
|
|
983
|
+
}, {
|
|
984
|
+
key: "updateTokenizationBlocklistAddressesWithHttpInfo",
|
|
985
|
+
value: function updateTokenizationBlocklistAddressesWithHttpInfo(token_id, opts) {
|
|
986
|
+
opts = opts || {};
|
|
987
|
+
var postBody = opts['TokenizationUpdateBlocklistAddressesRequest'];
|
|
988
|
+
if (postBody && postBody.toJSON) {
|
|
989
|
+
postBody = postBody.toJSON();
|
|
990
|
+
}
|
|
991
|
+
// verify the required parameter 'token_id' is set
|
|
992
|
+
if (token_id === undefined || token_id === null) {
|
|
993
|
+
throw new Error("Missing the required parameter 'token_id' when calling updateTokenizationBlocklistAddresses");
|
|
994
|
+
}
|
|
995
|
+
var pathParams = {
|
|
996
|
+
'token_id': token_id
|
|
997
|
+
};
|
|
998
|
+
var queryParams = {};
|
|
999
|
+
var headerParams = {};
|
|
1000
|
+
var formParams = {};
|
|
1001
|
+
var authNames = ['OAuth2', 'CoboAuth'];
|
|
1002
|
+
var contentTypes = ['application/json'];
|
|
1003
|
+
var accepts = ['application/json'];
|
|
1004
|
+
var returnType = _TokenizationOperationResponse["default"];
|
|
1005
|
+
return this.apiClient.callApi('/tokenization/tokens/{token_id}/blocklist/addresses', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
|
|
1006
|
+
}
|
|
1007
|
+
|
|
1008
|
+
/**
|
|
1009
|
+
* Update addresses on blocklist
|
|
1010
|
+
* This operation updates addresses on the blocklist.
|
|
1011
|
+
* @param {String} token_id The token ID, which is the unique identifier of a token.
|
|
1012
|
+
* @param {Object} opts Optional parameters
|
|
1013
|
+
* @param {module:model/TokenizationUpdateBlocklistAddressesRequest} opts.TokenizationUpdateBlocklistAddressesRequest The request body for adding or removing multiple addresses on the blocklist.
|
|
1014
|
+
* @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TokenizationOperationResponse}
|
|
1015
|
+
*/
|
|
1016
|
+
}, {
|
|
1017
|
+
key: "updateTokenizationBlocklistAddresses",
|
|
1018
|
+
value: function updateTokenizationBlocklistAddresses(token_id, opts) {
|
|
1019
|
+
return this.updateTokenizationBlocklistAddressesWithHttpInfo(token_id, opts).then(function (response_and_data) {
|
|
1020
|
+
return response_and_data.data;
|
|
1021
|
+
});
|
|
1022
|
+
}
|
|
1023
|
+
}]);
|
|
1024
|
+
}();
|