Struct terra_rust_api::Terra [−][src]
pub struct Terra<'a> { pub chain_id: &'a str, pub gas_options: Option<&'a GasOptions>, // some fields omitted }
The main structure that all API calls are generated from
Fields
chain_id: &'a str
The Chain of the network
gas_options: Option<&'a GasOptions>
Gas Options used to help with gas/fee generation of transactions
Implementations
impl<'a> Terra<'_>
[src]
impl<'a> Terra<'_>
[src]pub async fn lcd_client(
url: &'a str,
chain_id: &'a str,
gas_options: &'a GasOptions
) -> Result<Terra<'a>>
[src]
url: &'a str,
chain_id: &'a str,
gas_options: &'a GasOptions
) -> Result<Terra<'a>>
Create a FULL client interface
pub async fn lcd_client_no_tx(
url: &'a str,
chain_id: &'a str
) -> Result<Terra<'a>>
[src]
url: &'a str,
chain_id: &'a str
) -> Result<Terra<'a>>
Create a read-only / query client interface
pub fn auth(&self) -> Auth<'_>
[src]
Auth API functions
pub fn staking(&self) -> Staking<'_>
[src]
Staking API functions
pub fn market(&self) -> Market<'_>
[src]
Market API functions
pub fn oracle(&self) -> Oracle<'_>
[src]
Oracle API functions
pub fn tendermint(&self) -> Tendermint<'_>
[src]
Tendermint (MISC) API Functions
pub fn tx(&self) -> TX<'_>
[src]
TXS API Functions
pub async fn send_cmd<T: for<'de> Deserialize<'de>>(
&self,
path: &str,
args: Option<&str>
) -> Result<T>
[src]
&self,
path: &str,
args: Option<&str>
) -> Result<T>
used to send a GET command to the LCD
pub async fn post_cmd<R: for<'de> Serialize, T: for<'de> Deserialize<'de>>(
&self,
path: &str,
args: &R
) -> Result<T>
[src]
&self,
path: &str,
args: &R
) -> Result<T>
used to send a POST with a JSON body to the LCD
pub async fn calc_fees(&'a self, messages: &[Box<dyn Msg>]) -> Result<StdFee>
[src]
Generate Fee structure, either by estimation method or hardcoded
Auto Trait Implementations
impl<'a> !RefUnwindSafe for Terra<'a>
impl<'a> !RefUnwindSafe for Terra<'a>
impl<'a> !UnwindSafe for Terra<'a>
impl<'a> !UnwindSafe for Terra<'a>
Blanket Implementations
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Same<T> for T
impl<T> Same<T> for T
type Output = T
Should always be Self