Struct aptos_rest_client::Client
source · [−]pub struct Client { /* private fields */ }Implementations
sourceimpl Client
impl Client
pub fn new(base_url: Url) -> Self
pub async fn get_aptos_version(&self) -> Result<Response<AptosVersion>>
pub async fn get_block_info(&self, version: u64) -> Result<Response<BlockInfo>>
pub async fn get_account_balance(
&self,
address: AccountAddress
) -> Result<Response<Balance>>
pub async fn get_index(&self) -> Result<Response<IndexResponse>>
pub async fn get_ledger_information(&self) -> Result<Response<State>>
pub async fn submit(
&self,
txn: &SignedTransaction
) -> Result<Response<PendingTransaction>>
pub async fn submit_and_wait(
&self,
txn: &SignedTransaction
) -> Result<Response<Transaction>>
pub async fn wait_for_transaction(
&self,
pending_transaction: &PendingTransaction
) -> Result<Response<Transaction>>
pub async fn wait_for_signed_transaction(
&self,
transaction: &SignedTransaction
) -> Result<Response<Transaction>>
pub async fn wait_for_transaction_by_hash(
&self,
hash: HashValue,
expiration_timestamp_secs: u64
) -> Result<Response<Transaction>>
pub async fn get_transactions(
&self,
start: Option<u64>,
limit: Option<u16>
) -> Result<Response<Vec<Transaction>>>
pub async fn get_transaction(
&self,
hash: HashValue
) -> Result<Response<Transaction>>
pub async fn get_transaction_by_version(
&self,
version: u64
) -> Result<Response<Transaction>>
pub async fn get_account_transactions(
&self,
address: AccountAddress,
start: Option<u64>,
limit: Option<u64>
) -> Result<Response<Vec<Transaction>>>
pub async fn get_account_resources(
&self,
address: AccountAddress
) -> Result<Response<Vec<Resource>>>
pub async fn get_account_resources_at_version(
&self,
address: AccountAddress,
version: u64
) -> Result<Response<Vec<Resource>>>
pub async fn get_resource<T: DeserializeOwned>(
&self,
address: AccountAddress,
resource_type: &str
) -> Result<Response<T>>
pub async fn get_account_resource(
&self,
address: AccountAddress,
resource_type: &str
) -> Result<Response<Option<Resource>>>
pub async fn get_account_resource_at_version(
&self,
address: AccountAddress,
resource_type: &str,
version: u64
) -> Result<Response<Option<Resource>>>
pub async fn get_account_modules(
&self,
address: AccountAddress
) -> Result<Response<Vec<MoveModuleBytecode>>>
pub async fn get_table_item<K: Serialize>(
&self,
table_handle: u128,
key_type: &str,
value_type: &str,
key: K
) -> Result<Response<Value>>
pub async fn get_account(
&self,
address: AccountAddress
) -> Result<Response<Account>>
pub async fn health_check(&self, seconds: u64) -> Result<()>
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Client
impl Send for Client
impl Sync for Client
impl Unpin for Client
impl !UnwindSafe for Client
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<T> Pointable for T
impl<T> Pointable for T
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more