pub struct EncryptedQueryRequestBuilder<'a, T> { /* private fields */ }Expand description
A request builder that VEIL-seals query params and sends them as ?data=<base64url>.
Obtained from RequestBuilder::encrypted_query. Finalise with
send (async) or
send_sync (sync).
The expected response is also VEIL-sealed and is opened transparently.
Implementations§
Source§impl<'a, T: Encode> EncryptedQueryRequestBuilder<'a, T>
impl<'a, T: Encode> EncryptedQueryRequestBuilder<'a, T>
Sourcepub async fn send<R>(self) -> Result<R, ClientError>
pub async fn send<R>(self) -> Result<R, ClientError>
Sends the request asynchronously.
The params are VEIL-sealed with the configured SerializationKey and
base64url-encoded, then appended to the URL as ?data=<base64url>. When the
response arrives, its bytes are VEIL-opened with the same key to produce R.
Any cipher failure is wrapped in ClientError::Serialization.
Sourcepub fn send_sync<R>(self) -> Result<R, ClientError>
pub fn send_sync<R>(self) -> Result<R, ClientError>
Sends the request synchronously.
Same behaviour as send — params are VEIL-sealed and base64url-encoded
as ?data=<value>, and the sealed response bytes are VEIL-opened to R — but the
network call blocks the current thread. Any cipher failure is wrapped in
ClientError::Serialization.