Struct authzen_opa::OPAQuery
source · pub struct OPAQuery<'a, Data: Clone = Value> {
pub input: Cow<'a, OPAQueryInput<'a, Data>>,
pub config: OPAQueryConfig<'a>,
pub data: Option<Value>,
}Fields§
§input: Cow<'a, OPAQueryInput<'a, Data>>§config: OPAQueryConfig<'a>§data: Option<Value>Implementations§
Trait Implementations§
source§impl<'de: 'a, 'a, Data> Deserialize<'de> for OPAQuery<'a, Data>where
Data: Deserialize<'de> + Clone,
impl<'de: 'a, 'a, Data> Deserialize<'de> for OPAQuery<'a, Data>where Data: Deserialize<'de> + Clone,
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<Data: Clone + Serialize> Endpoint for OPAQuery<'_, Data>
impl<Data: Clone + Serialize> Endpoint for OPAQuery<'_, Data>
const METHOD: Method = Method::POST
type Params<'a> where Self: 'a = OPAQueryConfig<'a>
fn params(&self) -> Self::Params<'_>
fn path(&self) -> Path
fn headers(&self) -> HeaderMap
source§fn body(&self) -> Body
fn body(&self) -> Body
body returns the opaque Body type because the actual body serialization may vary from endpoint
to endpoint; e.g. one endpoint may want to use serde_json to serialize body data in json format
while another may simply want to use the raw contents of a string as the bytes to be sent