Methods
(static) deletePrivacyGroup(options)
Delete a privacy group
Parameters:
Name | Type | Description |
---|---|---|
options |
Options passed into
|
Returns:
Promise<transaction count | never>
(static) getMarkerTransaction(txHash, retries, delay)
Returns the Private Marker transaction
Parameters:
Name | Type | Description |
---|---|---|
txHash |
string | The transaction hash |
retries |
int | Number of retries to be made to get the private marker transaction receipt |
delay |
int | The delay between the retries |
Returns:
Promise to resolve the private marker transaction receipt
(static) getTransactionCount(options)
Get the transaction count
Parameters:
Name | Type | Description |
---|---|---|
options |
Options passed into |
Returns:
Promise<transaction count | never>
(inner) addToPrivacyGroup(options) → {Promise.<(AxiosResponse.<any>|never)>}
Add to an existing on-chain privacy group
Parameters:
Name | Type | Description |
---|---|---|
options |
Map to add the members options map can contain the following:
|
Returns:
- Type
- Promise.<(AxiosResponse.<any>|never)>
(inner) call(options) → {Promise.<AxiosResponse.<T>>}
Invokes a private contract function locally
Parameters:
Name | Type | Description |
---|---|---|
options |
Options passed into
|
Returns:
- Type
- Promise.<AxiosResponse.<T>>
(inner) createXPrivacyGroup(options) → {Promise.<(AxiosResponse.<any>|never)>}
Create an on chain privacy group
Parameters:
Name | Type | Description |
---|---|---|
options |
Map to add the members options map can contain the following:
|
Returns:
- Type
- Promise.<(AxiosResponse.<any>|never)>
(inner) findOnChainPrivacyGroup(options)
Find privacy groups
Parameters:
Name | Type | Description |
---|---|---|
options |
Map to find the group options map can contain the following:
|
Returns:
Promise<privacy group | never>
(inner) findPrivacyGroup(options)
Find privacy groups
Parameters:
Name | Type | Description |
---|---|---|
options |
Options passed into
|
Returns:
Promise<transaction count | never>
(inner) genericSendRawTransaction(options, method)
Send a transaction to eea_sendRawTransaction
or priv_distributeRawTransaction
Parameters:
Name | Type | Description |
---|---|---|
options |
Used to create the private transaction
|
|
method |
Name of the method of the transaction to call. |
(inner) getTransactionReceipt(txHash, enclavePublicKey, retries, delay) → {Promise.<(AxiosResponse.<any>|never)>}
Get the private transaction Receipt.
Parameters:
Name | Type | Default | Description |
---|---|---|---|
txHash |
string | Transaction Hash of the marker transaction |
|
enclavePublicKey |
string | Public key used to start-up the Enclave |
|
retries |
int |
300
|
Number of retries to be made to get the private marker transaction receipt |
delay |
int |
1000
|
The delay between the retries |
Returns:
- Type
- Promise.<(AxiosResponse.<any>|never)>
(inner) removeFromPrivacyGroup(options) → {Promise.<(AxiosResponse.<any>|never)>}
Remove a member from an on-chain privacy group
Parameters:
Name | Type | Description |
---|---|---|
options |
Map to add the members options map can contain the following:
|
Returns:
- Type
- Promise.<(AxiosResponse.<any>|never)>
(inner) sendRawTransaction(options) → {Promise.<(AxiosResponse.<any>|never)>}
Send the Raw transaction to the Besu node
Parameters:
Name | Type | Description |
---|---|---|
options |
Map to send a raw transaction to besu options map can contain the following:
|
Returns:
- Type
- Promise.<(AxiosResponse.<any>|never)>
(inner) setPrivacyGroupLockState(options) → {Promise.<(AxiosResponse.<any>|never)>}
Either lock or unlock the privacy group for member adding
Parameters:
Name | Type | Description |
---|---|---|
options |
Map to lock the group options map can contain the following:
|
Returns:
- Type
- Promise.<(AxiosResponse.<any>|never)>
(async, inner) subscribe(privacyGroupId, filter, callback) → {PrivateSubscription}
Subscribe to new logs matching a filter
If the provider supports subscriptions, it uses priv_subscribe
, otherwise
it uses polling and priv_getFilterChanges
to get new logs. Returns an
error to the callback if there is a problem subscribing or creating the filter.
Parameters:
Name | Type | Description |
---|---|---|
privacyGroupId |
string | |
filter |
* | |
callback |
function | returns the filter/subscription ID, or an error |
Returns:
a subscription object that manages the lifecycle of the filter or subscription
- Type
- PrivateSubscription