pub struct Client { /* private fields */ }
Expand description
The client struct to interface with a rosetta endpoint.
Implementations§
Source§impl Client
impl Client
Sourcepub async fn network_list(&self) -> Result<Vec<NetworkIdentifier>>
pub async fn network_list(&self) -> Result<Vec<NetworkIdentifier>>
Make a call to the /network/list endpoint.
Sourcepub async fn network_options(
&self,
network_identifier: NetworkIdentifier,
) -> Result<NetworkOptionsResponse>
pub async fn network_options( &self, network_identifier: NetworkIdentifier, ) -> Result<NetworkOptionsResponse>
Make a call to the /network/options endpoint.
Sourcepub async fn network_status(
&self,
network_identifier: NetworkIdentifier,
) -> Result<NetworkStatusResponse>
pub async fn network_status( &self, network_identifier: NetworkIdentifier, ) -> Result<NetworkStatusResponse>
Make a call to the /network/status endpoint.
Sourcepub async fn account_balance(
&self,
request: &AccountBalanceRequest,
) -> Result<AccountBalanceResponse>
pub async fn account_balance( &self, request: &AccountBalanceRequest, ) -> Result<AccountBalanceResponse>
Make a call to the /account/balance endpoint.
Sourcepub async fn account_coins(
&self,
request: &AccountCoinsRequest,
) -> Result<AccountCoinsResponse>
pub async fn account_coins( &self, request: &AccountCoinsRequest, ) -> Result<AccountCoinsResponse>
Make a call to the /account/coins endpoint.
Sourcepub async fn account_faucet(
&self,
request: &AccountFaucetRequest,
) -> Result<TransactionIdentifierResponse>
pub async fn account_faucet( &self, request: &AccountFaucetRequest, ) -> Result<TransactionIdentifierResponse>
Make a call to the /account/faucet endpoint.
Sourcepub async fn block(&self, request: &BlockRequest) -> Result<BlockResponse>
pub async fn block(&self, request: &BlockRequest) -> Result<BlockResponse>
Make a call to the /block endpoint.
Sourcepub async fn block_transaction(
&self,
request: &BlockTransactionRequest,
) -> Result<BlockTransactionResponse>
pub async fn block_transaction( &self, request: &BlockTransactionRequest, ) -> Result<BlockTransactionResponse>
Make a call to the /block/transaction endpoint.
Sourcepub async fn mempool(
&self,
network_identifier: NetworkIdentifier,
) -> Result<MempoolResponse>
pub async fn mempool( &self, network_identifier: NetworkIdentifier, ) -> Result<MempoolResponse>
Make a call to the /mempool endpoint.
Sourcepub async fn mempool_transaction(
&self,
request: &MempoolTransactionRequest,
) -> Result<MempoolTransactionResponse>
pub async fn mempool_transaction( &self, request: &MempoolTransactionRequest, ) -> Result<MempoolTransactionResponse>
Make a call to the /mempool/transaction endpoint.
Sourcepub async fn call(&self, request: &CallRequest) -> Result<CallResponse>
pub async fn call(&self, request: &CallRequest) -> Result<CallResponse>
Make a call to the /call endpoint.
Sourcepub async fn construction_combine(
&self,
request: &ConstructionCombineRequest,
) -> Result<ConstructionCombineResponse>
pub async fn construction_combine( &self, request: &ConstructionCombineRequest, ) -> Result<ConstructionCombineResponse>
Make a call to the /construction/combine endpoint.
Sourcepub async fn construction_derive(
&self,
request: &ConstructionDeriveRequest,
) -> Result<ConstructionDeriveResponse>
pub async fn construction_derive( &self, request: &ConstructionDeriveRequest, ) -> Result<ConstructionDeriveResponse>
Make a call to the /construction/derive endpoint.
Sourcepub async fn construction_hash(
&self,
request: &ConstructionHashRequest,
) -> Result<TransactionIdentifierResponse>
pub async fn construction_hash( &self, request: &ConstructionHashRequest, ) -> Result<TransactionIdentifierResponse>
Make a call to the /construction/hash endpoint.
Sourcepub async fn construction_metadata(
&self,
request: &ConstructionMetadataRequest,
) -> Result<ConstructionMetadataResponse>
pub async fn construction_metadata( &self, request: &ConstructionMetadataRequest, ) -> Result<ConstructionMetadataResponse>
Make a call to the /construction/metadata endpoint.
Sourcepub async fn construction_parse(
&self,
request: &ConstructionParseRequest,
) -> Result<ConstructionParseResponse>
pub async fn construction_parse( &self, request: &ConstructionParseRequest, ) -> Result<ConstructionParseResponse>
Make a call to the /construction/parse endpoint.
Sourcepub async fn construction_payloads(
&self,
request: &ConstructionPayloadsRequest,
) -> Result<ConstructionPayloadsResponse>
pub async fn construction_payloads( &self, request: &ConstructionPayloadsRequest, ) -> Result<ConstructionPayloadsResponse>
Make a call to the /construction/payloads endpoint.
Sourcepub async fn construction_preprocess(
&self,
request: &ConstructionPreprocessRequest,
) -> Result<ConstructionPreprocessResponse>
pub async fn construction_preprocess( &self, request: &ConstructionPreprocessRequest, ) -> Result<ConstructionPreprocessResponse>
Make a call to the /construction/preprocess endpoint.
Sourcepub async fn construction_submit(
&self,
request: &ConstructionSubmitRequest,
) -> Result<TransactionIdentifierResponse>
pub async fn construction_submit( &self, request: &ConstructionSubmitRequest, ) -> Result<TransactionIdentifierResponse>
Make a call to the /construction/submit endpoint.
Sourcepub async fn events_blocks(
&self,
request: &EventsBlocksRequest,
) -> Result<EventsBlocksResponse>
pub async fn events_blocks( &self, request: &EventsBlocksRequest, ) -> Result<EventsBlocksResponse>
Make a call to the /events/blocks endpoint.
Sourcepub async fn search_transactions(
&self,
request: &SearchTransactionsRequest,
) -> Result<SearchTransactionsResponse>
pub async fn search_transactions( &self, request: &SearchTransactionsRequest, ) -> Result<SearchTransactionsResponse>
Make a call to the /search/transactions endpoint.