import 'package:multibaas/api.dart';
All URIs are relative to https://your_deployment.multibaas.com/api/v0
Method | HTTP request | Description |
---|---|---|
addHsmConfig | POST /hsm/config | Add HSM config |
addHsmKey | POST /hsm/key | Add HSM key |
createHsmKey | POST /hsm/key/new | Create HSM key |
listHsm | GET /hsm | List HSM configs and wallets |
listHsmWallets | GET /hsm/wallets | List HSM wallets |
removeHsmConfig | DELETE /hsm/config/{client_id} | Remove HSM config |
removeHsmKey | DELETE /hsm/key/{wallet_address} | Remove HSM key |
setLocalNonce | POST /chains/{chain}/hsm/nonce/{wallet_address} | Set local nonce |
signAndSubmitTransaction | POST /chains/{chain}/hsm/submit | Sign and submit transaction |
signData | POST /chains/{chain}/hsm/sign | Sign data |
BaseResponse addHsmConfig(baseAzureAccount)
Add HSM config
Adds a new Azure account configuration.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
final BaseAzureAccount baseAzureAccount = ; // BaseAzureAccount |
try {
final response = api.addHsmConfig(baseAzureAccount);
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->addHsmConfig: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
baseAzureAccount | BaseAzureAccount | [optional] |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponse addHsmKey(addKey)
Add HSM key
Adds an existing key configuration.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
final AddKey addKey = ; // AddKey |
try {
final response = api.addHsmKey(addKey);
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->addHsmKey: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
addKey | AddKey | [optional] |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
CreateHsmKey200Response createHsmKey(createKey)
Create HSM key
Creates a new key in the Azure KeyVault.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
final CreateKey createKey = ; // CreateKey |
try {
final response = api.createHsmKey(createKey);
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->createHsmKey: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
createKey | CreateKey | [optional] |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ListHsm200Response listHsm()
List HSM configs and wallets
Returns a list of HSM configs and their associated wallets.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
try {
final response = api.listHsm();
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->listHsm: $e\n');
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ListHsmWallets200Response listHsmWallets(keyName, keyVersion, vaultName, baseGroupName, clientId, publicAddress, limit, offset)
List HSM wallets
Returns a list of HSM wallets.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
final String keyName = keyName_example; // String | Filter wallets by a key name.
final String keyVersion = keyVersion_example; // String | Filter wallets by a key version.
final String vaultName = vaultName_example; // String | Filter wallets by a vault name.
final String baseGroupName = baseGroupName_example; // String | Filter wallets by a base group name.
final String clientId = clientId_example; // String | Filter wallets by a client ID.
final String publicAddress = publicAddress_example; // String | Filter wallets by a public address.
final int limit = 789; // int |
final int offset = 789; // int |
try {
final response = api.listHsmWallets(keyName, keyVersion, vaultName, baseGroupName, clientId, publicAddress, limit, offset);
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->listHsmWallets: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
keyName | String | Filter wallets by a key name. | [optional] |
keyVersion | String | Filter wallets by a key version. | [optional] |
vaultName | String | Filter wallets by a vault name. | [optional] |
baseGroupName | String | Filter wallets by a base group name. | [optional] |
clientId | String | Filter wallets by a client ID. | [optional] |
publicAddress | String | Filter wallets by a public address. | [optional] |
limit | int | [optional] | |
offset | int | [optional] |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponse removeHsmConfig(clientId)
Remove HSM config
Removes the specified Azure account configuration and its associated keys.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
final String clientId = clientId_example; // String | The HSM client ID.
try {
final response = api.removeHsmConfig(clientId);
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->removeHsmConfig: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
clientId | String | The HSM client ID. |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponse removeHsmKey(walletAddress)
Remove HSM key
Removes the specified key configuration.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
final String walletAddress = walletAddress_example; // String | An HSM ethereum address.
try {
final response = api.removeHsmKey(walletAddress);
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->removeHsmKey: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
walletAddress | String | An HSM ethereum address. |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BaseResponse setLocalNonce(chain, walletAddress, setNonceRequest)
Set local nonce
Sets the next transaction nonce for the given HSM address that will be used with the nonce management feature.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
final ChainName chain = ; // ChainName | The blockchain chain label.
final String walletAddress = walletAddress_example; // String | An HSM ethereum address.
final SetNonceRequest setNonceRequest = ; // SetNonceRequest |
try {
final response = api.setLocalNonce(chain, walletAddress, setNonceRequest);
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->setLocalNonce: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
chain | ChainName | The blockchain chain label. | |
walletAddress | String | An HSM ethereum address. | |
setNonceRequest | SetNonceRequest | [optional] |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TransferEth200Response signAndSubmitTransaction(chain, baseTransactionToSign)
Sign and submit transaction
Signs and submits the given transaction using an HSM address.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
final ChainName chain = ; // ChainName | The blockchain chain label.
final BaseTransactionToSign baseTransactionToSign = ; // BaseTransactionToSign |
try {
final response = api.signAndSubmitTransaction(chain, baseTransactionToSign);
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->signAndSubmitTransaction: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
chain | ChainName | The blockchain chain label. | |
baseTransactionToSign | BaseTransactionToSign | [optional] |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SignData200Response signData(chain, hSMSignRequest)
Sign data
Signs the given data using the given HSM address.
import 'package:multibaas/api.dart';
// TODO Configure API key authorization: cookie
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
final api = Multibaas().getHsmApi();
final ChainName chain = ; // ChainName | The blockchain chain label.
final HSMSignRequest hSMSignRequest = ; // HSMSignRequest |
try {
final response = api.signData(chain, hSMSignRequest);
print(response);
} catch on DioException (e) {
print('Exception when calling HsmApi->signData: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
chain | ChainName | The blockchain chain label. | |
hSMSignRequest | HSMSignRequest | [optional] |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]