@Generated(value="software.amazon.awssdk:codegen") @ThreadSafe public interface ManagedBlockchainQueryAsyncClient extends AwsClient
builder() method.
Amazon Managed Blockchain (AMB) Query provides you with convenient access to multi-blockchain network data, which makes it easier for you to extract contextual data related to blockchain activity. You can use AMB Query to read data from public blockchain networks, such as Bitcoin Mainnet and Ethereum Mainnet. You can also get information such as the current and historical balances of addresses, or you can get a list of blockchain transactions for a given time period. Additionally, you can get details of a given transaction, such as transaction events, which you can further analyze or use in business logic for your applications.
| Modifier and Type | Field and Description |
|---|---|
static String |
SERVICE_METADATA_ID
Value for looking up the service's metadata from the
ServiceMetadataProvider. |
static String |
SERVICE_NAME |
| Modifier and Type | Method and Description |
|---|---|
default CompletableFuture<BatchGetTokenBalanceResponse> |
batchGetTokenBalance(BatchGetTokenBalanceRequest batchGetTokenBalanceRequest)
Gets the token balance for a batch of tokens by using the
GetTokenBalance action for every token in
the request. |
default CompletableFuture<BatchGetTokenBalanceResponse> |
batchGetTokenBalance(Consumer<BatchGetTokenBalanceRequest.Builder> batchGetTokenBalanceRequest)
Gets the token balance for a batch of tokens by using the
GetTokenBalance action for every token in
the request. |
static ManagedBlockchainQueryAsyncClientBuilder |
builder()
Create a builder that can be used to configure and create a
ManagedBlockchainQueryAsyncClient. |
static ManagedBlockchainQueryAsyncClient |
create()
Create a
ManagedBlockchainQueryAsyncClient with the region loaded from the
DefaultAwsRegionProviderChain and credentials loaded from the
DefaultCredentialsProvider. |
default CompletableFuture<GetTokenBalanceResponse> |
getTokenBalance(Consumer<GetTokenBalanceRequest.Builder> getTokenBalanceRequest)
Gets the balance of a specific token, including native tokens, for a given address (wallet or contract) on the
blockchain.
|
default CompletableFuture<GetTokenBalanceResponse> |
getTokenBalance(GetTokenBalanceRequest getTokenBalanceRequest)
Gets the balance of a specific token, including native tokens, for a given address (wallet or contract) on the
blockchain.
|
default CompletableFuture<GetTransactionResponse> |
getTransaction(Consumer<GetTransactionRequest.Builder> getTransactionRequest)
Get the details of a transaction.
|
default CompletableFuture<GetTransactionResponse> |
getTransaction(GetTransactionRequest getTransactionRequest)
Get the details of a transaction.
|
default CompletableFuture<ListTokenBalancesResponse> |
listTokenBalances(Consumer<ListTokenBalancesRequest.Builder> listTokenBalancesRequest)
This action returns the following for a given a blockchain network:
|
default CompletableFuture<ListTokenBalancesResponse> |
listTokenBalances(ListTokenBalancesRequest listTokenBalancesRequest)
This action returns the following for a given a blockchain network:
|
default ListTokenBalancesPublisher |
listTokenBalancesPaginator(Consumer<ListTokenBalancesRequest.Builder> listTokenBalancesRequest)
This action returns the following for a given a blockchain network:
|
default ListTokenBalancesPublisher |
listTokenBalancesPaginator(ListTokenBalancesRequest listTokenBalancesRequest)
This action returns the following for a given a blockchain network:
|
default CompletableFuture<ListTransactionEventsResponse> |
listTransactionEvents(Consumer<ListTransactionEventsRequest.Builder> listTransactionEventsRequest)
An array of
TransactionEvent objects. |
default CompletableFuture<ListTransactionEventsResponse> |
listTransactionEvents(ListTransactionEventsRequest listTransactionEventsRequest)
An array of
TransactionEvent objects. |
default ListTransactionEventsPublisher |
listTransactionEventsPaginator(Consumer<ListTransactionEventsRequest.Builder> listTransactionEventsRequest)
An array of
TransactionEvent objects. |
default ListTransactionEventsPublisher |
listTransactionEventsPaginator(ListTransactionEventsRequest listTransactionEventsRequest)
An array of
TransactionEvent objects. |
default CompletableFuture<ListTransactionsResponse> |
listTransactions(Consumer<ListTransactionsRequest.Builder> listTransactionsRequest)
Lists all of the transactions on a given wallet address or to a specific contract.
|
default CompletableFuture<ListTransactionsResponse> |
listTransactions(ListTransactionsRequest listTransactionsRequest)
Lists all of the transactions on a given wallet address or to a specific contract.
|
default ListTransactionsPublisher |
listTransactionsPaginator(Consumer<ListTransactionsRequest.Builder> listTransactionsRequest)
Lists all of the transactions on a given wallet address or to a specific contract.
|
default ListTransactionsPublisher |
listTransactionsPaginator(ListTransactionsRequest listTransactionsRequest)
Lists all of the transactions on a given wallet address or to a specific contract.
|
default ManagedBlockchainQueryServiceClientConfiguration |
serviceClientConfiguration() |
serviceNameclosestatic final String SERVICE_NAME
static final String SERVICE_METADATA_ID
ServiceMetadataProvider.default CompletableFuture<BatchGetTokenBalanceResponse> batchGetTokenBalance(BatchGetTokenBalanceRequest batchGetTokenBalanceRequest)
Gets the token balance for a batch of tokens by using the GetTokenBalance action for every token in
the request.
Only the native tokens BTC,ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported.
batchGetTokenBalanceRequest - default CompletableFuture<BatchGetTokenBalanceResponse> batchGetTokenBalance(Consumer<BatchGetTokenBalanceRequest.Builder> batchGetTokenBalanceRequest)
Gets the token balance for a batch of tokens by using the GetTokenBalance action for every token in
the request.
Only the native tokens BTC,ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported.
This is a convenience which creates an instance of the BatchGetTokenBalanceRequest.Builder avoiding the
need to create one manually via BatchGetTokenBalanceRequest.builder()
batchGetTokenBalanceRequest - A Consumer that will call methods on
BatchGetTokenBalanceRequest.Builder
to create a request.default CompletableFuture<GetTokenBalanceResponse> getTokenBalance(GetTokenBalanceRequest getTokenBalanceRequest)
Gets the balance of a specific token, including native tokens, for a given address (wallet or contract) on the blockchain.
Only the native tokens BTC,ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported.
getTokenBalanceRequest - default CompletableFuture<GetTokenBalanceResponse> getTokenBalance(Consumer<GetTokenBalanceRequest.Builder> getTokenBalanceRequest)
Gets the balance of a specific token, including native tokens, for a given address (wallet or contract) on the blockchain.
Only the native tokens BTC,ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported.
This is a convenience which creates an instance of the GetTokenBalanceRequest.Builder avoiding the need
to create one manually via GetTokenBalanceRequest.builder()
getTokenBalanceRequest - A Consumer that will call methods on
GetTokenBalanceRequest.Builder to
create a request.default CompletableFuture<GetTransactionResponse> getTransaction(GetTransactionRequest getTransactionRequest)
Get the details of a transaction.
getTransactionRequest - default CompletableFuture<GetTransactionResponse> getTransaction(Consumer<GetTransactionRequest.Builder> getTransactionRequest)
Get the details of a transaction.
This is a convenience which creates an instance of the GetTransactionRequest.Builder avoiding the need to
create one manually via GetTransactionRequest.builder()
getTransactionRequest - A Consumer that will call methods on
GetTransactionRequest.Builder to
create a request.default CompletableFuture<ListTokenBalancesResponse> listTokenBalances(ListTokenBalancesRequest listTokenBalancesRequest)
This action returns the following for a given a blockchain network:
Lists all token balances owned by an address (either a contact address or a wallet address).
Lists all token balances for all tokens created by a contract.
Lists all token balances for a given token.
You must always specify the network property of the tokenFilter when using this operation.
listTokenBalancesRequest - default CompletableFuture<ListTokenBalancesResponse> listTokenBalances(Consumer<ListTokenBalancesRequest.Builder> listTokenBalancesRequest)
This action returns the following for a given a blockchain network:
Lists all token balances owned by an address (either a contact address or a wallet address).
Lists all token balances for all tokens created by a contract.
Lists all token balances for a given token.
You must always specify the network property of the tokenFilter when using this operation.
This is a convenience which creates an instance of the ListTokenBalancesRequest.Builder avoiding the need
to create one manually via ListTokenBalancesRequest.builder()
listTokenBalancesRequest - A Consumer that will call methods on
ListTokenBalancesRequest.Builder to
create a request.default ListTokenBalancesPublisher listTokenBalancesPaginator(ListTokenBalancesRequest listTokenBalancesRequest)
This action returns the following for a given a blockchain network:
Lists all token balances owned by an address (either a contact address or a wallet address).
Lists all token balances for all tokens created by a contract.
Lists all token balances for a given token.
You must always specify the network property of the tokenFilter when using this operation.
This is a variant of
listTokenBalances(software.amazon.awssdk.services.managedblockchainquery.model.ListTokenBalancesRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new Subscription i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the subscribe helper method
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTokenBalancesPublisher publisher = client.listTokenBalancesPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTokenBalancesPublisher publisher = client.listTokenBalancesPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.managedblockchainquery.model.ListTokenBalancesResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.managedblockchainquery.model.ListTokenBalancesResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
listTokenBalances(software.amazon.awssdk.services.managedblockchainquery.model.ListTokenBalancesRequest)
operation.
listTokenBalancesRequest - default ListTokenBalancesPublisher listTokenBalancesPaginator(Consumer<ListTokenBalancesRequest.Builder> listTokenBalancesRequest)
This action returns the following for a given a blockchain network:
Lists all token balances owned by an address (either a contact address or a wallet address).
Lists all token balances for all tokens created by a contract.
Lists all token balances for a given token.
You must always specify the network property of the tokenFilter when using this operation.
This is a variant of
listTokenBalances(software.amazon.awssdk.services.managedblockchainquery.model.ListTokenBalancesRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new Subscription i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the subscribe helper method
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTokenBalancesPublisher publisher = client.listTokenBalancesPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTokenBalancesPublisher publisher = client.listTokenBalancesPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.managedblockchainquery.model.ListTokenBalancesResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.managedblockchainquery.model.ListTokenBalancesResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
listTokenBalances(software.amazon.awssdk.services.managedblockchainquery.model.ListTokenBalancesRequest)
operation.
This is a convenience which creates an instance of the ListTokenBalancesRequest.Builder avoiding the need
to create one manually via ListTokenBalancesRequest.builder()
listTokenBalancesRequest - A Consumer that will call methods on
ListTokenBalancesRequest.Builder to
create a request.default CompletableFuture<ListTransactionEventsResponse> listTransactionEvents(ListTransactionEventsRequest listTransactionEventsRequest)
An array of TransactionEvent objects. Each object contains details about the transaction event.
listTransactionEventsRequest - default CompletableFuture<ListTransactionEventsResponse> listTransactionEvents(Consumer<ListTransactionEventsRequest.Builder> listTransactionEventsRequest)
An array of TransactionEvent objects. Each object contains details about the transaction event.
This is a convenience which creates an instance of the ListTransactionEventsRequest.Builder avoiding the
need to create one manually via ListTransactionEventsRequest.builder()
listTransactionEventsRequest - A Consumer that will call methods on
ListTransactionEventsRequest.Builder
to create a request.default ListTransactionEventsPublisher listTransactionEventsPaginator(ListTransactionEventsRequest listTransactionEventsRequest)
An array of TransactionEvent objects. Each object contains details about the transaction event.
This is a variant of
listTransactionEvents(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionEventsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new Subscription i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the subscribe helper method
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTransactionEventsPublisher publisher = client.listTransactionEventsPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTransactionEventsPublisher publisher = client.listTransactionEventsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionEventsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionEventsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
listTransactionEvents(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionEventsRequest)
operation.
listTransactionEventsRequest - default ListTransactionEventsPublisher listTransactionEventsPaginator(Consumer<ListTransactionEventsRequest.Builder> listTransactionEventsRequest)
An array of TransactionEvent objects. Each object contains details about the transaction event.
This is a variant of
listTransactionEvents(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionEventsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new Subscription i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the subscribe helper method
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTransactionEventsPublisher publisher = client.listTransactionEventsPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTransactionEventsPublisher publisher = client.listTransactionEventsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionEventsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionEventsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
listTransactionEvents(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionEventsRequest)
operation.
This is a convenience which creates an instance of the ListTransactionEventsRequest.Builder avoiding the
need to create one manually via ListTransactionEventsRequest.builder()
listTransactionEventsRequest - A Consumer that will call methods on
ListTransactionEventsRequest.Builder
to create a request.default CompletableFuture<ListTransactionsResponse> listTransactions(ListTransactionsRequest listTransactionsRequest)
Lists all of the transactions on a given wallet address or to a specific contract.
listTransactionsRequest - default CompletableFuture<ListTransactionsResponse> listTransactions(Consumer<ListTransactionsRequest.Builder> listTransactionsRequest)
Lists all of the transactions on a given wallet address or to a specific contract.
This is a convenience which creates an instance of the ListTransactionsRequest.Builder avoiding the need
to create one manually via ListTransactionsRequest.builder()
listTransactionsRequest - A Consumer that will call methods on
ListTransactionsRequest.Builder to
create a request.default ListTransactionsPublisher listTransactionsPaginator(ListTransactionsRequest listTransactionsRequest)
Lists all of the transactions on a given wallet address or to a specific contract.
This is a variant of
listTransactions(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new Subscription i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the subscribe helper method
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTransactionsPublisher publisher = client.listTransactionsPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTransactionsPublisher publisher = client.listTransactionsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
listTransactions(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionsRequest)
operation.
listTransactionsRequest - default ListTransactionsPublisher listTransactionsPaginator(Consumer<ListTransactionsRequest.Builder> listTransactionsRequest)
Lists all of the transactions on a given wallet address or to a specific contract.
This is a variant of
listTransactions(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new Subscription i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the subscribe helper method
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTransactionsPublisher publisher = client.listTransactionsPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.managedblockchainquery.paginators.ListTransactionsPublisher publisher = client.listTransactionsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
listTransactions(software.amazon.awssdk.services.managedblockchainquery.model.ListTransactionsRequest)
operation.
This is a convenience which creates an instance of the ListTransactionsRequest.Builder avoiding the need
to create one manually via ListTransactionsRequest.builder()
listTransactionsRequest - A Consumer that will call methods on
ListTransactionsRequest.Builder to
create a request.default ManagedBlockchainQueryServiceClientConfiguration serviceClientConfiguration()
serviceClientConfiguration in interface AwsClientserviceClientConfiguration in interface SdkClientstatic ManagedBlockchainQueryAsyncClient create()
ManagedBlockchainQueryAsyncClient with the region loaded from the
DefaultAwsRegionProviderChain and credentials loaded from the
DefaultCredentialsProvider.static ManagedBlockchainQueryAsyncClientBuilder builder()
ManagedBlockchainQueryAsyncClient.Copyright © 2023. All rights reserved.