Struct cosmwasm_std::GrpcQuery
source · pub struct GrpcQuery {
pub path: String,
pub data: Binary,
}
Expand description
Queries the chain using a grpc query. This allows to query information that is not exposed in our API. The chain needs to allowlist the supported queries. The drawback of this query is that you have to handle the protobuf encoding and decoding yourself.
The returned data is protobuf encoded. The protobuf type depends on the query.
To find the path, as well as the request and response types, you can query the chain’s gRPC endpoint using a tool like grpcurl.
Fields§
§path: String
The fully qualified endpoint path used for routing.
It follows the format /service_path/method_name
,
eg. “/cosmos.authz.v1beta1.Query/Grants”
data: Binary
The expected protobuf message type (not Any), binary encoded
Trait Implementations§
source§impl<'de> Deserialize<'de> for GrpcQuery
impl<'de> Deserialize<'de> for GrpcQuery
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<C: CustomQuery> From<GrpcQuery> for QueryRequest<C>
impl<C: CustomQuery> From<GrpcQuery> for QueryRequest<C>
source§impl JsonSchema for GrpcQuery
impl JsonSchema for GrpcQuery
source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
source§fn json_schema(gen: &mut SchemaGenerator) -> Schema
fn json_schema(gen: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref
keyword. Read moresource§impl PartialEq for GrpcQuery
impl PartialEq for GrpcQuery
impl Eq for GrpcQuery
impl StructuralPartialEq for GrpcQuery
Auto Trait Implementations§
impl Freeze for GrpcQuery
impl RefUnwindSafe for GrpcQuery
impl Send for GrpcQuery
impl Sync for GrpcQuery
impl Unpin for GrpcQuery
impl UnwindSafe for GrpcQuery
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more