@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,1069 @@
|
|
|
1
|
+
# CoboWaas2.TokenizationApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://api.dev.cobo.com/v2*
|
|
4
|
+
|
|
5
|
+
Method | HTTP request | Description
|
|
6
|
+
------------- | ------------- | -------------
|
|
7
|
+
[**burnTokenization**](TokenizationApi.md#burnTokenization) | **POST** /tokenization/tokens/{token_id}/burn | Burn tokens
|
|
8
|
+
[**estimateTokenizationFee**](TokenizationApi.md#estimateTokenizationFee) | **POST** /tokenization/estimate_fee | Estimate tokenization operation fee
|
|
9
|
+
[**getTokenizationActivity**](TokenizationApi.md#getTokenizationActivity) | **GET** /tokenization/activities/{activity_id} | Get tokenization activity details
|
|
10
|
+
[**getTokenizationAllowlistActivation**](TokenizationApi.md#getTokenizationAllowlistActivation) | **GET** /tokenization/tokens/{token_id}/allowlist/activation | Get allowlist activation status
|
|
11
|
+
[**getTokenizationInfo**](TokenizationApi.md#getTokenizationInfo) | **GET** /tokenization/tokens/{token_id} | Get token details
|
|
12
|
+
[**issueToken**](TokenizationApi.md#issueToken) | **POST** /tokenization/tokens | Issue token
|
|
13
|
+
[**listIssuedTokens**](TokenizationApi.md#listIssuedTokens) | **GET** /tokenization/tokens | List issued tokens
|
|
14
|
+
[**listTokenizationActivities**](TokenizationApi.md#listTokenizationActivities) | **GET** /tokenization/activities | List tokenization activities
|
|
15
|
+
[**listTokenizationAllowlistAddresses**](TokenizationApi.md#listTokenizationAllowlistAddresses) | **GET** /tokenization/tokens/{token_id}/allowlist/addresses | List addresses on allowlist
|
|
16
|
+
[**listTokenizationBlocklistAddresses**](TokenizationApi.md#listTokenizationBlocklistAddresses) | **GET** /tokenization/tokens/{token_id}/blocklist/addresses | Lists addresses on blocklist
|
|
17
|
+
[**listTokenizationHoldings**](TokenizationApi.md#listTokenizationHoldings) | **GET** /tokenization/tokens/{token_id}/holdings | Get token holdings information
|
|
18
|
+
[**listTokenizationSupportedChains**](TokenizationApi.md#listTokenizationSupportedChains) | **GET** /tokenization/enabled_chains | List supported chains for tokenization
|
|
19
|
+
[**mintTokenization**](TokenizationApi.md#mintTokenization) | **POST** /tokenization/tokens/{token_id}/mint | Mint tokens
|
|
20
|
+
[**pauseTokenization**](TokenizationApi.md#pauseTokenization) | **POST** /tokenization/tokens/{token_id}/pause | Pause token contract
|
|
21
|
+
[**tokenizationContractCall**](TokenizationApi.md#tokenizationContractCall) | **POST** /tokenization/tokens/{token_id}/contract_call | Call token contract
|
|
22
|
+
[**unpauseTokenization**](TokenizationApi.md#unpauseTokenization) | **POST** /tokenization/tokens/{token_id}/unpause | Unpause token contract
|
|
23
|
+
[**updateTokenizationAllowlistActivation**](TokenizationApi.md#updateTokenizationAllowlistActivation) | **POST** /tokenization/tokens/{token_id}/allowlist/activation | Activate or deactivate allowlist
|
|
24
|
+
[**updateTokenizationAllowlistAddresses**](TokenizationApi.md#updateTokenizationAllowlistAddresses) | **POST** /tokenization/tokens/{token_id}/allowlist/addresses | Update addresses on allowlist
|
|
25
|
+
[**updateTokenizationBlocklistAddresses**](TokenizationApi.md#updateTokenizationBlocklistAddresses) | **POST** /tokenization/tokens/{token_id}/blocklist/addresses | Update addresses on blocklist
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
## burnTokenization
|
|
30
|
+
|
|
31
|
+
> TokenizationOperationResponse burnTokenization(token_id, opts)
|
|
32
|
+
|
|
33
|
+
Burn tokens
|
|
34
|
+
|
|
35
|
+
This operation burns tokens from a specified address. Creates a burn transaction that will decrease the token supply.
|
|
36
|
+
|
|
37
|
+
### Example
|
|
38
|
+
|
|
39
|
+
```javascript
|
|
40
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
41
|
+
// Initialize the API client
|
|
42
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
43
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
44
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
45
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
46
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
47
|
+
// Call the API
|
|
48
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
49
|
+
const token_id = "ETH_USDT";
|
|
50
|
+
const opts = {
|
|
51
|
+
'TokenizationBurnTokenRequest': new CoboWaas2.TokenizationBurnTokenRequest()
|
|
52
|
+
};
|
|
53
|
+
apiInstance.burnTokenization(token_id, opts).then((data) => {
|
|
54
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
55
|
+
}, (error) => {
|
|
56
|
+
console.error(error);
|
|
57
|
+
});
|
|
58
|
+
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
### Parameters
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
Name | Type | Description | Notes
|
|
65
|
+
------------- | ------------- | ------------- | -------------
|
|
66
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
67
|
+
**TokenizationBurnTokenRequest** | [**TokenizationBurnTokenRequest**](TokenizationBurnTokenRequest.md)| The request body for burning tokens. | [optional]
|
|
68
|
+
|
|
69
|
+
### Return type
|
|
70
|
+
|
|
71
|
+
[**TokenizationOperationResponse**](TokenizationOperationResponse.md)
|
|
72
|
+
|
|
73
|
+
### Authorization
|
|
74
|
+
|
|
75
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
76
|
+
|
|
77
|
+
### HTTP request headers
|
|
78
|
+
|
|
79
|
+
- **Content-Type**: application/json
|
|
80
|
+
- **Accept**: application/json
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
## estimateTokenizationFee
|
|
84
|
+
|
|
85
|
+
> EstimatedFee estimateTokenizationFee(TokenizationEstimateFeeRequest)
|
|
86
|
+
|
|
87
|
+
Estimate tokenization operation fee
|
|
88
|
+
|
|
89
|
+
This operation estimates the fee required for tokenization operations. For EVM-based chains, this calculates the gas cost for the specified operation.
|
|
90
|
+
|
|
91
|
+
### Example
|
|
92
|
+
|
|
93
|
+
```javascript
|
|
94
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
95
|
+
// Initialize the API client
|
|
96
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
97
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
98
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
99
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
100
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
101
|
+
// Call the API
|
|
102
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
103
|
+
const TokenizationEstimateFeeRequest = new CoboWaas2.TokenizationEstimateFeeRequest();
|
|
104
|
+
apiInstance.estimateTokenizationFee(TokenizationEstimateFeeRequest).then((data) => {
|
|
105
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
106
|
+
}, (error) => {
|
|
107
|
+
console.error(error);
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
### Parameters
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
Name | Type | Description | Notes
|
|
116
|
+
------------- | ------------- | ------------- | -------------
|
|
117
|
+
**TokenizationEstimateFeeRequest** | [**TokenizationEstimateFeeRequest**](TokenizationEstimateFeeRequest.md)| The request body to estimate tokenization operation fee. |
|
|
118
|
+
|
|
119
|
+
### Return type
|
|
120
|
+
|
|
121
|
+
[**EstimatedFee**](EstimatedFee.md)
|
|
122
|
+
|
|
123
|
+
### Authorization
|
|
124
|
+
|
|
125
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
126
|
+
|
|
127
|
+
### HTTP request headers
|
|
128
|
+
|
|
129
|
+
- **Content-Type**: application/json
|
|
130
|
+
- **Accept**: application/json
|
|
131
|
+
|
|
132
|
+
|
|
133
|
+
## getTokenizationActivity
|
|
134
|
+
|
|
135
|
+
> TokenizationActivityInfo getTokenizationActivity(activity_id)
|
|
136
|
+
|
|
137
|
+
Get tokenization activity details
|
|
138
|
+
|
|
139
|
+
This operation retrieves the detailed information for a specific tokenization activity by its ID.
|
|
140
|
+
|
|
141
|
+
### Example
|
|
142
|
+
|
|
143
|
+
```javascript
|
|
144
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
145
|
+
// Initialize the API client
|
|
146
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
147
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
148
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
149
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
150
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
151
|
+
// Call the API
|
|
152
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
153
|
+
const activity_id = "b7c8e9d0-f1a2-3b4c-5d6e-7f8a9b0c1d2e";
|
|
154
|
+
apiInstance.getTokenizationActivity(activity_id).then((data) => {
|
|
155
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
156
|
+
}, (error) => {
|
|
157
|
+
console.error(error);
|
|
158
|
+
});
|
|
159
|
+
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
### Parameters
|
|
163
|
+
|
|
164
|
+
|
|
165
|
+
Name | Type | Description | Notes
|
|
166
|
+
------------- | ------------- | ------------- | -------------
|
|
167
|
+
**activity_id** | **String**| The ID of the activity. |
|
|
168
|
+
|
|
169
|
+
### Return type
|
|
170
|
+
|
|
171
|
+
[**TokenizationActivityInfo**](TokenizationActivityInfo.md)
|
|
172
|
+
|
|
173
|
+
### Authorization
|
|
174
|
+
|
|
175
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
176
|
+
|
|
177
|
+
### HTTP request headers
|
|
178
|
+
|
|
179
|
+
- **Content-Type**: Not defined
|
|
180
|
+
- **Accept**: application/json
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
## getTokenizationAllowlistActivation
|
|
184
|
+
|
|
185
|
+
> GetTokenizationAllowlistActivation200Response getTokenizationAllowlistActivation(token_id)
|
|
186
|
+
|
|
187
|
+
Get allowlist activation status
|
|
188
|
+
|
|
189
|
+
This operation retrieves the allowlist activation status of the token contract.
|
|
190
|
+
|
|
191
|
+
### Example
|
|
192
|
+
|
|
193
|
+
```javascript
|
|
194
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
195
|
+
// Initialize the API client
|
|
196
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
197
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
198
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
199
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
200
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
201
|
+
// Call the API
|
|
202
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
203
|
+
const token_id = "ETH_USDT";
|
|
204
|
+
apiInstance.getTokenizationAllowlistActivation(token_id).then((data) => {
|
|
205
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
206
|
+
}, (error) => {
|
|
207
|
+
console.error(error);
|
|
208
|
+
});
|
|
209
|
+
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
### Parameters
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
Name | Type | Description | Notes
|
|
216
|
+
------------- | ------------- | ------------- | -------------
|
|
217
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
218
|
+
|
|
219
|
+
### Return type
|
|
220
|
+
|
|
221
|
+
[**GetTokenizationAllowlistActivation200Response**](GetTokenizationAllowlistActivation200Response.md)
|
|
222
|
+
|
|
223
|
+
### Authorization
|
|
224
|
+
|
|
225
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
226
|
+
|
|
227
|
+
### HTTP request headers
|
|
228
|
+
|
|
229
|
+
- **Content-Type**: Not defined
|
|
230
|
+
- **Accept**: application/json
|
|
231
|
+
|
|
232
|
+
|
|
233
|
+
## getTokenizationInfo
|
|
234
|
+
|
|
235
|
+
> TokenizationTokenDetailInfo getTokenizationInfo(token_id)
|
|
236
|
+
|
|
237
|
+
Get token details
|
|
238
|
+
|
|
239
|
+
This operation retrieves the detailed information for a specific issued token by its ID.
|
|
240
|
+
|
|
241
|
+
### Example
|
|
242
|
+
|
|
243
|
+
```javascript
|
|
244
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
245
|
+
// Initialize the API client
|
|
246
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
247
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
248
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
249
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
250
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
251
|
+
// Call the API
|
|
252
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
253
|
+
const token_id = "ETH_USDT";
|
|
254
|
+
apiInstance.getTokenizationInfo(token_id).then((data) => {
|
|
255
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
256
|
+
}, (error) => {
|
|
257
|
+
console.error(error);
|
|
258
|
+
});
|
|
259
|
+
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
### Parameters
|
|
263
|
+
|
|
264
|
+
|
|
265
|
+
Name | Type | Description | Notes
|
|
266
|
+
------------- | ------------- | ------------- | -------------
|
|
267
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
268
|
+
|
|
269
|
+
### Return type
|
|
270
|
+
|
|
271
|
+
[**TokenizationTokenDetailInfo**](TokenizationTokenDetailInfo.md)
|
|
272
|
+
|
|
273
|
+
### Authorization
|
|
274
|
+
|
|
275
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
276
|
+
|
|
277
|
+
### HTTP request headers
|
|
278
|
+
|
|
279
|
+
- **Content-Type**: Not defined
|
|
280
|
+
- **Accept**: application/json
|
|
281
|
+
|
|
282
|
+
|
|
283
|
+
## issueToken
|
|
284
|
+
|
|
285
|
+
> TokenizationOperationResponse issueToken(TokenizationIssuedTokenRequest)
|
|
286
|
+
|
|
287
|
+
Issue token
|
|
288
|
+
|
|
289
|
+
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.
|
|
290
|
+
|
|
291
|
+
### Example
|
|
292
|
+
|
|
293
|
+
```javascript
|
|
294
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
295
|
+
// Initialize the API client
|
|
296
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
297
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
298
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
299
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
300
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
301
|
+
// Call the API
|
|
302
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
303
|
+
const TokenizationIssuedTokenRequest = new CoboWaas2.TokenizationIssuedTokenRequest();
|
|
304
|
+
apiInstance.issueToken(TokenizationIssuedTokenRequest).then((data) => {
|
|
305
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
306
|
+
}, (error) => {
|
|
307
|
+
console.error(error);
|
|
308
|
+
});
|
|
309
|
+
|
|
310
|
+
```
|
|
311
|
+
|
|
312
|
+
### Parameters
|
|
313
|
+
|
|
314
|
+
|
|
315
|
+
Name | Type | Description | Notes
|
|
316
|
+
------------- | ------------- | ------------- | -------------
|
|
317
|
+
**TokenizationIssuedTokenRequest** | [**TokenizationIssuedTokenRequest**](TokenizationIssuedTokenRequest.md)| The request body to issue a new token. |
|
|
318
|
+
|
|
319
|
+
### Return type
|
|
320
|
+
|
|
321
|
+
[**TokenizationOperationResponse**](TokenizationOperationResponse.md)
|
|
322
|
+
|
|
323
|
+
### Authorization
|
|
324
|
+
|
|
325
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
326
|
+
|
|
327
|
+
### HTTP request headers
|
|
328
|
+
|
|
329
|
+
- **Content-Type**: application/json
|
|
330
|
+
- **Accept**: application/json
|
|
331
|
+
|
|
332
|
+
|
|
333
|
+
## listIssuedTokens
|
|
334
|
+
|
|
335
|
+
> TokenizationListTokenInfoResponse listIssuedTokens(opts)
|
|
336
|
+
|
|
337
|
+
List issued tokens
|
|
338
|
+
|
|
339
|
+
This operation retrieves a list of tokens issued by the organization. Returns issued token information including total supply, holdings, and token status.
|
|
340
|
+
|
|
341
|
+
### Example
|
|
342
|
+
|
|
343
|
+
```javascript
|
|
344
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
345
|
+
// Initialize the API client
|
|
346
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
347
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
348
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
349
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
350
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
351
|
+
// Call the API
|
|
352
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
353
|
+
const opts = {
|
|
354
|
+
'chain_id': "ETH",
|
|
355
|
+
'token_id': "ETH_USDT",
|
|
356
|
+
'token_standard': new CoboWaas2.TokenizationTokenStandard(),
|
|
357
|
+
'status': new CoboWaas2.TokenizationStatus(),
|
|
358
|
+
'limit': 10,
|
|
359
|
+
'before': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGmk1",
|
|
360
|
+
'after': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGSAk"
|
|
361
|
+
};
|
|
362
|
+
apiInstance.listIssuedTokens(opts).then((data) => {
|
|
363
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
364
|
+
}, (error) => {
|
|
365
|
+
console.error(error);
|
|
366
|
+
});
|
|
367
|
+
|
|
368
|
+
```
|
|
369
|
+
|
|
370
|
+
### Parameters
|
|
371
|
+
|
|
372
|
+
|
|
373
|
+
Name | Type | Description | Notes
|
|
374
|
+
------------- | ------------- | ------------- | -------------
|
|
375
|
+
**chain_id** | **String**| 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). | [optional]
|
|
376
|
+
**token_id** | **String**| 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). | [optional]
|
|
377
|
+
**token_standard** | [**TokenizationTokenStandard**](.md)| Filter by token standard. | [optional]
|
|
378
|
+
**status** | [**TokenizationStatus**](.md)| Filter by token status. | [optional]
|
|
379
|
+
**limit** | **Number**| The maximum number of objects to return. For most operations, the value range is [1, 50]. | [optional] [default to 10]
|
|
380
|
+
**before** | **String**| 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. | [optional]
|
|
381
|
+
**after** | **String**| 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. | [optional]
|
|
382
|
+
|
|
383
|
+
### Return type
|
|
384
|
+
|
|
385
|
+
[**TokenizationListTokenInfoResponse**](TokenizationListTokenInfoResponse.md)
|
|
386
|
+
|
|
387
|
+
### Authorization
|
|
388
|
+
|
|
389
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
390
|
+
|
|
391
|
+
### HTTP request headers
|
|
392
|
+
|
|
393
|
+
- **Content-Type**: Not defined
|
|
394
|
+
- **Accept**: application/json
|
|
395
|
+
|
|
396
|
+
|
|
397
|
+
## listTokenizationActivities
|
|
398
|
+
|
|
399
|
+
> TokenizationListActivitiesResponse listTokenizationActivities(opts)
|
|
400
|
+
|
|
401
|
+
List tokenization activities
|
|
402
|
+
|
|
403
|
+
This operation retrieves a list of tokenization activities.
|
|
404
|
+
|
|
405
|
+
### Example
|
|
406
|
+
|
|
407
|
+
```javascript
|
|
408
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
409
|
+
// Initialize the API client
|
|
410
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
411
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
412
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
413
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
414
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
415
|
+
// Call the API
|
|
416
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
417
|
+
const opts = {
|
|
418
|
+
'token_id': "ETH_USDT",
|
|
419
|
+
'activity_type': new CoboWaas2.TokenizationOperationType(),
|
|
420
|
+
'activity_status': new CoboWaas2.TokenizationActivityStatus(),
|
|
421
|
+
'limit': 10,
|
|
422
|
+
'after': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGSAk",
|
|
423
|
+
'before': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGmk1",
|
|
424
|
+
'direction': "ASC"
|
|
425
|
+
};
|
|
426
|
+
apiInstance.listTokenizationActivities(opts).then((data) => {
|
|
427
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
428
|
+
}, (error) => {
|
|
429
|
+
console.error(error);
|
|
430
|
+
});
|
|
431
|
+
|
|
432
|
+
```
|
|
433
|
+
|
|
434
|
+
### Parameters
|
|
435
|
+
|
|
436
|
+
|
|
437
|
+
Name | Type | Description | Notes
|
|
438
|
+
------------- | ------------- | ------------- | -------------
|
|
439
|
+
**token_id** | **String**| 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). | [optional]
|
|
440
|
+
**activity_type** | [**TokenizationOperationType**](.md)| Filter by tokenization activity type. | [optional]
|
|
441
|
+
**activity_status** | [**TokenizationActivityStatus**](.md)| Filter by tokenization activity status. | [optional]
|
|
442
|
+
**limit** | **Number**| The maximum number of objects to return. For most operations, the value range is [1, 50]. | [optional] [default to 10]
|
|
443
|
+
**after** | **String**| 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. | [optional]
|
|
444
|
+
**before** | **String**| 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. | [optional]
|
|
445
|
+
**direction** | **String**| The sort direction. Possible values include: - `ASC`: Sort the results in ascending order. - `DESC`: Sort the results in descending order. | [optional] [default to 'ASC']
|
|
446
|
+
|
|
447
|
+
### Return type
|
|
448
|
+
|
|
449
|
+
[**TokenizationListActivitiesResponse**](TokenizationListActivitiesResponse.md)
|
|
450
|
+
|
|
451
|
+
### Authorization
|
|
452
|
+
|
|
453
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
454
|
+
|
|
455
|
+
### HTTP request headers
|
|
456
|
+
|
|
457
|
+
- **Content-Type**: Not defined
|
|
458
|
+
- **Accept**: application/json
|
|
459
|
+
|
|
460
|
+
|
|
461
|
+
## listTokenizationAllowlistAddresses
|
|
462
|
+
|
|
463
|
+
> TokenizationAllowlistAddressesResponse listTokenizationAllowlistAddresses(token_id, opts)
|
|
464
|
+
|
|
465
|
+
List addresses on allowlist
|
|
466
|
+
|
|
467
|
+
This operation lists addresses on the allowlist.
|
|
468
|
+
|
|
469
|
+
### Example
|
|
470
|
+
|
|
471
|
+
```javascript
|
|
472
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
473
|
+
// Initialize the API client
|
|
474
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
475
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
476
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
477
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
478
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
479
|
+
// Call the API
|
|
480
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
481
|
+
const token_id = "ETH_USDT";
|
|
482
|
+
const opts = {
|
|
483
|
+
'limit': 10,
|
|
484
|
+
'after': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGSAk",
|
|
485
|
+
'before': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGmk1",
|
|
486
|
+
'direction': "ASC"
|
|
487
|
+
};
|
|
488
|
+
apiInstance.listTokenizationAllowlistAddresses(token_id, opts).then((data) => {
|
|
489
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
490
|
+
}, (error) => {
|
|
491
|
+
console.error(error);
|
|
492
|
+
});
|
|
493
|
+
|
|
494
|
+
```
|
|
495
|
+
|
|
496
|
+
### Parameters
|
|
497
|
+
|
|
498
|
+
|
|
499
|
+
Name | Type | Description | Notes
|
|
500
|
+
------------- | ------------- | ------------- | -------------
|
|
501
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
502
|
+
**limit** | **Number**| The maximum number of objects to return. For most operations, the value range is [1, 50]. | [optional] [default to 10]
|
|
503
|
+
**after** | **String**| 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. | [optional]
|
|
504
|
+
**before** | **String**| 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. | [optional]
|
|
505
|
+
**direction** | **String**| The sort direction. Possible values include: - `ASC`: Sort the results in ascending order. - `DESC`: Sort the results in descending order. | [optional] [default to 'ASC']
|
|
506
|
+
|
|
507
|
+
### Return type
|
|
508
|
+
|
|
509
|
+
[**TokenizationAllowlistAddressesResponse**](TokenizationAllowlistAddressesResponse.md)
|
|
510
|
+
|
|
511
|
+
### Authorization
|
|
512
|
+
|
|
513
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
514
|
+
|
|
515
|
+
### HTTP request headers
|
|
516
|
+
|
|
517
|
+
- **Content-Type**: Not defined
|
|
518
|
+
- **Accept**: application/json
|
|
519
|
+
|
|
520
|
+
|
|
521
|
+
## listTokenizationBlocklistAddresses
|
|
522
|
+
|
|
523
|
+
> ListTokenizationBlocklistAddresses200Response listTokenizationBlocklistAddresses(token_id, opts)
|
|
524
|
+
|
|
525
|
+
Lists addresses on blocklist
|
|
526
|
+
|
|
527
|
+
This operation lists addresses on the blocklist.
|
|
528
|
+
|
|
529
|
+
### Example
|
|
530
|
+
|
|
531
|
+
```javascript
|
|
532
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
533
|
+
// Initialize the API client
|
|
534
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
535
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
536
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
537
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
538
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
539
|
+
// Call the API
|
|
540
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
541
|
+
const token_id = "ETH_USDT";
|
|
542
|
+
const opts = {
|
|
543
|
+
'limit': 10,
|
|
544
|
+
'after': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGSAk",
|
|
545
|
+
'before': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGmk1",
|
|
546
|
+
'direction': "ASC"
|
|
547
|
+
};
|
|
548
|
+
apiInstance.listTokenizationBlocklistAddresses(token_id, opts).then((data) => {
|
|
549
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
550
|
+
}, (error) => {
|
|
551
|
+
console.error(error);
|
|
552
|
+
});
|
|
553
|
+
|
|
554
|
+
```
|
|
555
|
+
|
|
556
|
+
### Parameters
|
|
557
|
+
|
|
558
|
+
|
|
559
|
+
Name | Type | Description | Notes
|
|
560
|
+
------------- | ------------- | ------------- | -------------
|
|
561
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
562
|
+
**limit** | **Number**| The maximum number of objects to return. For most operations, the value range is [1, 50]. | [optional] [default to 10]
|
|
563
|
+
**after** | **String**| 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. | [optional]
|
|
564
|
+
**before** | **String**| 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. | [optional]
|
|
565
|
+
**direction** | **String**| The sort direction. Possible values include: - `ASC`: Sort the results in ascending order. - `DESC`: Sort the results in descending order. | [optional] [default to 'ASC']
|
|
566
|
+
|
|
567
|
+
### Return type
|
|
568
|
+
|
|
569
|
+
[**ListTokenizationBlocklistAddresses200Response**](ListTokenizationBlocklistAddresses200Response.md)
|
|
570
|
+
|
|
571
|
+
### Authorization
|
|
572
|
+
|
|
573
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
574
|
+
|
|
575
|
+
### HTTP request headers
|
|
576
|
+
|
|
577
|
+
- **Content-Type**: Not defined
|
|
578
|
+
- **Accept**: application/json
|
|
579
|
+
|
|
580
|
+
|
|
581
|
+
## listTokenizationHoldings
|
|
582
|
+
|
|
583
|
+
> TokenizationListHoldingsResponse listTokenizationHoldings(token_id, opts)
|
|
584
|
+
|
|
585
|
+
Get token holdings information
|
|
586
|
+
|
|
587
|
+
This operation retrieves the holdings information for a specific issued token, showing which wallets hold the token and their respective balances.
|
|
588
|
+
|
|
589
|
+
### Example
|
|
590
|
+
|
|
591
|
+
```javascript
|
|
592
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
593
|
+
// Initialize the API client
|
|
594
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
595
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
596
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
597
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
598
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
599
|
+
// Call the API
|
|
600
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
601
|
+
const token_id = "ETH_USDT";
|
|
602
|
+
const opts = {
|
|
603
|
+
'limit': 10,
|
|
604
|
+
'before': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGmk1",
|
|
605
|
+
'after': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGSAk"
|
|
606
|
+
};
|
|
607
|
+
apiInstance.listTokenizationHoldings(token_id, opts).then((data) => {
|
|
608
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
609
|
+
}, (error) => {
|
|
610
|
+
console.error(error);
|
|
611
|
+
});
|
|
612
|
+
|
|
613
|
+
```
|
|
614
|
+
|
|
615
|
+
### Parameters
|
|
616
|
+
|
|
617
|
+
|
|
618
|
+
Name | Type | Description | Notes
|
|
619
|
+
------------- | ------------- | ------------- | -------------
|
|
620
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
621
|
+
**limit** | **Number**| The maximum number of objects to return. For most operations, the value range is [1, 50]. | [optional] [default to 10]
|
|
622
|
+
**before** | **String**| 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. | [optional]
|
|
623
|
+
**after** | **String**| 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. | [optional]
|
|
624
|
+
|
|
625
|
+
### Return type
|
|
626
|
+
|
|
627
|
+
[**TokenizationListHoldingsResponse**](TokenizationListHoldingsResponse.md)
|
|
628
|
+
|
|
629
|
+
### Authorization
|
|
630
|
+
|
|
631
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
632
|
+
|
|
633
|
+
### HTTP request headers
|
|
634
|
+
|
|
635
|
+
- **Content-Type**: Not defined
|
|
636
|
+
- **Accept**: application/json
|
|
637
|
+
|
|
638
|
+
|
|
639
|
+
## listTokenizationSupportedChains
|
|
640
|
+
|
|
641
|
+
> TokenizationListEnabledChainsResponse listTokenizationSupportedChains(opts)
|
|
642
|
+
|
|
643
|
+
List supported chains for tokenization
|
|
644
|
+
|
|
645
|
+
This operation retrieves a list of tokenization supported chains.
|
|
646
|
+
|
|
647
|
+
### Example
|
|
648
|
+
|
|
649
|
+
```javascript
|
|
650
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
651
|
+
// Initialize the API client
|
|
652
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
653
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
654
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
655
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
656
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
657
|
+
// Call the API
|
|
658
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
659
|
+
const opts = {
|
|
660
|
+
'limit': 10,
|
|
661
|
+
'after': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGSAk",
|
|
662
|
+
'before': "RqeEoTkgKG5rpzqYzg2Hd3szmPoj2cE7w5jWwShz3C1vyGmk1"
|
|
663
|
+
};
|
|
664
|
+
apiInstance.listTokenizationSupportedChains(opts).then((data) => {
|
|
665
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
666
|
+
}, (error) => {
|
|
667
|
+
console.error(error);
|
|
668
|
+
});
|
|
669
|
+
|
|
670
|
+
```
|
|
671
|
+
|
|
672
|
+
### Parameters
|
|
673
|
+
|
|
674
|
+
|
|
675
|
+
Name | Type | Description | Notes
|
|
676
|
+
------------- | ------------- | ------------- | -------------
|
|
677
|
+
**limit** | **Number**| The maximum number of objects to return. For most operations, the value range is [1, 50]. | [optional] [default to 10]
|
|
678
|
+
**after** | **String**| 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. | [optional]
|
|
679
|
+
**before** | **String**| 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. | [optional]
|
|
680
|
+
|
|
681
|
+
### Return type
|
|
682
|
+
|
|
683
|
+
[**TokenizationListEnabledChainsResponse**](TokenizationListEnabledChainsResponse.md)
|
|
684
|
+
|
|
685
|
+
### Authorization
|
|
686
|
+
|
|
687
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
688
|
+
|
|
689
|
+
### HTTP request headers
|
|
690
|
+
|
|
691
|
+
- **Content-Type**: Not defined
|
|
692
|
+
- **Accept**: application/json
|
|
693
|
+
|
|
694
|
+
|
|
695
|
+
## mintTokenization
|
|
696
|
+
|
|
697
|
+
> TokenizationOperationResponse mintTokenization(token_id, TokenizationMintTokenRequest)
|
|
698
|
+
|
|
699
|
+
Mint tokens
|
|
700
|
+
|
|
701
|
+
This operation mints new tokens to a specified address. Creates a mint transaction that will increase the token supply.
|
|
702
|
+
|
|
703
|
+
### Example
|
|
704
|
+
|
|
705
|
+
```javascript
|
|
706
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
707
|
+
// Initialize the API client
|
|
708
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
709
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
710
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
711
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
712
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
713
|
+
// Call the API
|
|
714
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
715
|
+
const token_id = "ETH_USDT";
|
|
716
|
+
const TokenizationMintTokenRequest = new CoboWaas2.TokenizationMintTokenRequest();
|
|
717
|
+
apiInstance.mintTokenization(token_id, TokenizationMintTokenRequest).then((data) => {
|
|
718
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
719
|
+
}, (error) => {
|
|
720
|
+
console.error(error);
|
|
721
|
+
});
|
|
722
|
+
|
|
723
|
+
```
|
|
724
|
+
|
|
725
|
+
### Parameters
|
|
726
|
+
|
|
727
|
+
|
|
728
|
+
Name | Type | Description | Notes
|
|
729
|
+
------------- | ------------- | ------------- | -------------
|
|
730
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
731
|
+
**TokenizationMintTokenRequest** | [**TokenizationMintTokenRequest**](TokenizationMintTokenRequest.md)| The request body for minting tokens. |
|
|
732
|
+
|
|
733
|
+
### Return type
|
|
734
|
+
|
|
735
|
+
[**TokenizationOperationResponse**](TokenizationOperationResponse.md)
|
|
736
|
+
|
|
737
|
+
### Authorization
|
|
738
|
+
|
|
739
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
740
|
+
|
|
741
|
+
### HTTP request headers
|
|
742
|
+
|
|
743
|
+
- **Content-Type**: application/json
|
|
744
|
+
- **Accept**: application/json
|
|
745
|
+
|
|
746
|
+
|
|
747
|
+
## pauseTokenization
|
|
748
|
+
|
|
749
|
+
> TokenizationOperationResponse pauseTokenization(token_id, opts)
|
|
750
|
+
|
|
751
|
+
Pause token contract
|
|
752
|
+
|
|
753
|
+
This operation pauses the token contract, temporarily halting token operations and transfers.
|
|
754
|
+
|
|
755
|
+
### Example
|
|
756
|
+
|
|
757
|
+
```javascript
|
|
758
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
759
|
+
// Initialize the API client
|
|
760
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
761
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
762
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
763
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
764
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
765
|
+
// Call the API
|
|
766
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
767
|
+
const token_id = "ETH_USDT";
|
|
768
|
+
const opts = {
|
|
769
|
+
'TokenizationPauseTokenRequest': new CoboWaas2.TokenizationPauseTokenRequest()
|
|
770
|
+
};
|
|
771
|
+
apiInstance.pauseTokenization(token_id, opts).then((data) => {
|
|
772
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
773
|
+
}, (error) => {
|
|
774
|
+
console.error(error);
|
|
775
|
+
});
|
|
776
|
+
|
|
777
|
+
```
|
|
778
|
+
|
|
779
|
+
### Parameters
|
|
780
|
+
|
|
781
|
+
|
|
782
|
+
Name | Type | Description | Notes
|
|
783
|
+
------------- | ------------- | ------------- | -------------
|
|
784
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
785
|
+
**TokenizationPauseTokenRequest** | [**TokenizationPauseTokenRequest**](TokenizationPauseTokenRequest.md)| The request body for pausing tokens. | [optional]
|
|
786
|
+
|
|
787
|
+
### Return type
|
|
788
|
+
|
|
789
|
+
[**TokenizationOperationResponse**](TokenizationOperationResponse.md)
|
|
790
|
+
|
|
791
|
+
### Authorization
|
|
792
|
+
|
|
793
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
794
|
+
|
|
795
|
+
### HTTP request headers
|
|
796
|
+
|
|
797
|
+
- **Content-Type**: application/json
|
|
798
|
+
- **Accept**: application/json
|
|
799
|
+
|
|
800
|
+
|
|
801
|
+
## tokenizationContractCall
|
|
802
|
+
|
|
803
|
+
> TokenizationOperationResponse tokenizationContractCall(token_id, opts)
|
|
804
|
+
|
|
805
|
+
Call token contract
|
|
806
|
+
|
|
807
|
+
This operation performs a contract call on the token contract.
|
|
808
|
+
|
|
809
|
+
### Example
|
|
810
|
+
|
|
811
|
+
```javascript
|
|
812
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
813
|
+
// Initialize the API client
|
|
814
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
815
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
816
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
817
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
818
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
819
|
+
// Call the API
|
|
820
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
821
|
+
const token_id = "ETH_USDT";
|
|
822
|
+
const opts = {
|
|
823
|
+
'TokenizationContractCallRequest': new CoboWaas2.TokenizationContractCallRequest()
|
|
824
|
+
};
|
|
825
|
+
apiInstance.tokenizationContractCall(token_id, opts).then((data) => {
|
|
826
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
827
|
+
}, (error) => {
|
|
828
|
+
console.error(error);
|
|
829
|
+
});
|
|
830
|
+
|
|
831
|
+
```
|
|
832
|
+
|
|
833
|
+
### Parameters
|
|
834
|
+
|
|
835
|
+
|
|
836
|
+
Name | Type | Description | Notes
|
|
837
|
+
------------- | ------------- | ------------- | -------------
|
|
838
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
839
|
+
**TokenizationContractCallRequest** | [**TokenizationContractCallRequest**](TokenizationContractCallRequest.md)| The request body for contract call. | [optional]
|
|
840
|
+
|
|
841
|
+
### Return type
|
|
842
|
+
|
|
843
|
+
[**TokenizationOperationResponse**](TokenizationOperationResponse.md)
|
|
844
|
+
|
|
845
|
+
### Authorization
|
|
846
|
+
|
|
847
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
848
|
+
|
|
849
|
+
### HTTP request headers
|
|
850
|
+
|
|
851
|
+
- **Content-Type**: application/json
|
|
852
|
+
- **Accept**: application/json
|
|
853
|
+
|
|
854
|
+
|
|
855
|
+
## unpauseTokenization
|
|
856
|
+
|
|
857
|
+
> TokenizationOperationResponse unpauseTokenization(token_id, opts)
|
|
858
|
+
|
|
859
|
+
Unpause token contract
|
|
860
|
+
|
|
861
|
+
This operation unpauses the token contract, resuming token operations and transfers.
|
|
862
|
+
|
|
863
|
+
### Example
|
|
864
|
+
|
|
865
|
+
```javascript
|
|
866
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
867
|
+
// Initialize the API client
|
|
868
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
869
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
870
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
871
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
872
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
873
|
+
// Call the API
|
|
874
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
875
|
+
const token_id = "ETH_USDT";
|
|
876
|
+
const opts = {
|
|
877
|
+
'TokenizationUnpauseTokenRequest': new CoboWaas2.TokenizationUnpauseTokenRequest()
|
|
878
|
+
};
|
|
879
|
+
apiInstance.unpauseTokenization(token_id, opts).then((data) => {
|
|
880
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
881
|
+
}, (error) => {
|
|
882
|
+
console.error(error);
|
|
883
|
+
});
|
|
884
|
+
|
|
885
|
+
```
|
|
886
|
+
|
|
887
|
+
### Parameters
|
|
888
|
+
|
|
889
|
+
|
|
890
|
+
Name | Type | Description | Notes
|
|
891
|
+
------------- | ------------- | ------------- | -------------
|
|
892
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
893
|
+
**TokenizationUnpauseTokenRequest** | [**TokenizationUnpauseTokenRequest**](TokenizationUnpauseTokenRequest.md)| The request body for unpausing tokens. | [optional]
|
|
894
|
+
|
|
895
|
+
### Return type
|
|
896
|
+
|
|
897
|
+
[**TokenizationOperationResponse**](TokenizationOperationResponse.md)
|
|
898
|
+
|
|
899
|
+
### Authorization
|
|
900
|
+
|
|
901
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
902
|
+
|
|
903
|
+
### HTTP request headers
|
|
904
|
+
|
|
905
|
+
- **Content-Type**: application/json
|
|
906
|
+
- **Accept**: application/json
|
|
907
|
+
|
|
908
|
+
|
|
909
|
+
## updateTokenizationAllowlistActivation
|
|
910
|
+
|
|
911
|
+
> TokenizationOperationResponse updateTokenizationAllowlistActivation(token_id, opts)
|
|
912
|
+
|
|
913
|
+
Activate or deactivate allowlist
|
|
914
|
+
|
|
915
|
+
This operation activates or deactivates the allowlist.
|
|
916
|
+
|
|
917
|
+
### Example
|
|
918
|
+
|
|
919
|
+
```javascript
|
|
920
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
921
|
+
// Initialize the API client
|
|
922
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
923
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
924
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
925
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
926
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
927
|
+
// Call the API
|
|
928
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
929
|
+
const token_id = "ETH_USDT";
|
|
930
|
+
const opts = {
|
|
931
|
+
'TokenizationAllowlistActivationRequest': new CoboWaas2.TokenizationAllowlistActivationRequest()
|
|
932
|
+
};
|
|
933
|
+
apiInstance.updateTokenizationAllowlistActivation(token_id, opts).then((data) => {
|
|
934
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
935
|
+
}, (error) => {
|
|
936
|
+
console.error(error);
|
|
937
|
+
});
|
|
938
|
+
|
|
939
|
+
```
|
|
940
|
+
|
|
941
|
+
### Parameters
|
|
942
|
+
|
|
943
|
+
|
|
944
|
+
Name | Type | Description | Notes
|
|
945
|
+
------------- | ------------- | ------------- | -------------
|
|
946
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
947
|
+
**TokenizationAllowlistActivationRequest** | [**TokenizationAllowlistActivationRequest**](TokenizationAllowlistActivationRequest.md)| The request body for activating or deactivating the allowlist. | [optional]
|
|
948
|
+
|
|
949
|
+
### Return type
|
|
950
|
+
|
|
951
|
+
[**TokenizationOperationResponse**](TokenizationOperationResponse.md)
|
|
952
|
+
|
|
953
|
+
### Authorization
|
|
954
|
+
|
|
955
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
956
|
+
|
|
957
|
+
### HTTP request headers
|
|
958
|
+
|
|
959
|
+
- **Content-Type**: application/json
|
|
960
|
+
- **Accept**: application/json
|
|
961
|
+
|
|
962
|
+
|
|
963
|
+
## updateTokenizationAllowlistAddresses
|
|
964
|
+
|
|
965
|
+
> TokenizationOperationResponse updateTokenizationAllowlistAddresses(token_id, opts)
|
|
966
|
+
|
|
967
|
+
Update addresses on allowlist
|
|
968
|
+
|
|
969
|
+
This operation updates addresses on the allowlist.
|
|
970
|
+
|
|
971
|
+
### Example
|
|
972
|
+
|
|
973
|
+
```javascript
|
|
974
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
975
|
+
// Initialize the API client
|
|
976
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
977
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
978
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
979
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
980
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
981
|
+
// Call the API
|
|
982
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
983
|
+
const token_id = "ETH_USDT";
|
|
984
|
+
const opts = {
|
|
985
|
+
'TokenizationUpdateAllowlistAddressesRequest': new CoboWaas2.TokenizationUpdateAllowlistAddressesRequest()
|
|
986
|
+
};
|
|
987
|
+
apiInstance.updateTokenizationAllowlistAddresses(token_id, opts).then((data) => {
|
|
988
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
989
|
+
}, (error) => {
|
|
990
|
+
console.error(error);
|
|
991
|
+
});
|
|
992
|
+
|
|
993
|
+
```
|
|
994
|
+
|
|
995
|
+
### Parameters
|
|
996
|
+
|
|
997
|
+
|
|
998
|
+
Name | Type | Description | Notes
|
|
999
|
+
------------- | ------------- | ------------- | -------------
|
|
1000
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
1001
|
+
**TokenizationUpdateAllowlistAddressesRequest** | [**TokenizationUpdateAllowlistAddressesRequest**](TokenizationUpdateAllowlistAddressesRequest.md)| The request body for adding or removing multiple addresses on the allowlist. | [optional]
|
|
1002
|
+
|
|
1003
|
+
### Return type
|
|
1004
|
+
|
|
1005
|
+
[**TokenizationOperationResponse**](TokenizationOperationResponse.md)
|
|
1006
|
+
|
|
1007
|
+
### Authorization
|
|
1008
|
+
|
|
1009
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
1010
|
+
|
|
1011
|
+
### HTTP request headers
|
|
1012
|
+
|
|
1013
|
+
- **Content-Type**: application/json
|
|
1014
|
+
- **Accept**: application/json
|
|
1015
|
+
|
|
1016
|
+
|
|
1017
|
+
## updateTokenizationBlocklistAddresses
|
|
1018
|
+
|
|
1019
|
+
> TokenizationOperationResponse updateTokenizationBlocklistAddresses(token_id, opts)
|
|
1020
|
+
|
|
1021
|
+
Update addresses on blocklist
|
|
1022
|
+
|
|
1023
|
+
This operation updates addresses on the blocklist.
|
|
1024
|
+
|
|
1025
|
+
### Example
|
|
1026
|
+
|
|
1027
|
+
```javascript
|
|
1028
|
+
const CoboWaas2 = require('@cobo/cobo-waas2');
|
|
1029
|
+
// Initialize the API client
|
|
1030
|
+
const apiClient = CoboWaas2.ApiClient.instance
|
|
1031
|
+
// Select the development environment. To use the production environment, replace `Env.DEV` with `Env.PROD`
|
|
1032
|
+
apiClient.setEnv(CoboWaas2.Env.DEV);
|
|
1033
|
+
// Replace `<YOUR_PRIVATE_KEY>` with your private key
|
|
1034
|
+
apiClient.setPrivateKey("<YOUR_PRIVATE_KEY>");
|
|
1035
|
+
// Call the API
|
|
1036
|
+
const apiInstance = new CoboWaas2.TokenizationApi();
|
|
1037
|
+
const token_id = "ETH_USDT";
|
|
1038
|
+
const opts = {
|
|
1039
|
+
'TokenizationUpdateBlocklistAddressesRequest': new CoboWaas2.TokenizationUpdateBlocklistAddressesRequest()
|
|
1040
|
+
};
|
|
1041
|
+
apiInstance.updateTokenizationBlocklistAddresses(token_id, opts).then((data) => {
|
|
1042
|
+
console.log('API called successfully. Returned data: ' + data);
|
|
1043
|
+
}, (error) => {
|
|
1044
|
+
console.error(error);
|
|
1045
|
+
});
|
|
1046
|
+
|
|
1047
|
+
```
|
|
1048
|
+
|
|
1049
|
+
### Parameters
|
|
1050
|
+
|
|
1051
|
+
|
|
1052
|
+
Name | Type | Description | Notes
|
|
1053
|
+
------------- | ------------- | ------------- | -------------
|
|
1054
|
+
**token_id** | **String**| The token ID, which is the unique identifier of a token. |
|
|
1055
|
+
**TokenizationUpdateBlocklistAddressesRequest** | [**TokenizationUpdateBlocklistAddressesRequest**](TokenizationUpdateBlocklistAddressesRequest.md)| The request body for adding or removing multiple addresses on the blocklist. | [optional]
|
|
1056
|
+
|
|
1057
|
+
### Return type
|
|
1058
|
+
|
|
1059
|
+
[**TokenizationOperationResponse**](TokenizationOperationResponse.md)
|
|
1060
|
+
|
|
1061
|
+
### Authorization
|
|
1062
|
+
|
|
1063
|
+
[OAuth2](../README.md#OAuth2), [CoboAuth](../README.md#CoboAuth)
|
|
1064
|
+
|
|
1065
|
+
### HTTP request headers
|
|
1066
|
+
|
|
1067
|
+
- **Content-Type**: application/json
|
|
1068
|
+
- **Accept**: application/json
|
|
1069
|
+
|