// @generated by jacquard-lexicon. DO NOT EDIT. // // Lexicon: tools.ozone.safelink.queryEvents // // This file was automatically generated from Lexicon schemas. // Any manual changes will be overwritten on the next regeneration. #[jacquard_derive::lexicon] #[derive( serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq, jacquard_derive::IntoStatic, Default )] #[serde(rename_all = "camelCase")] pub struct QueryEvents<'a> { /// Cursor for pagination #[serde(skip_serializing_if = "std::option::Option::is_none")] #[serde(borrow)] pub cursor: std::option::Option>, /// Maximum number of results to return #[serde(skip_serializing_if = "std::option::Option::is_none")] pub limit: std::option::Option, /// Filter by pattern type #[serde(skip_serializing_if = "std::option::Option::is_none")] #[serde(borrow)] pub pattern_type: std::option::Option>, /// Sort direction #[serde(skip_serializing_if = "std::option::Option::is_none")] #[serde(borrow)] pub sort_direction: std::option::Option>, /// Filter by specific URLs or domains #[serde(skip_serializing_if = "std::option::Option::is_none")] #[serde(borrow)] pub urls: std::option::Option>>, } #[jacquard_derive::lexicon] #[derive( serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq, jacquard_derive::IntoStatic )] #[serde(rename_all = "camelCase")] pub struct QueryEventsOutput<'a> { /// Next cursor for pagination. Only present if there are more results. #[serde(skip_serializing_if = "std::option::Option::is_none")] #[serde(borrow)] pub cursor: std::option::Option>, #[serde(borrow)] pub events: Vec>, } ///Response type for ///tools.ozone.safelink.queryEvents pub struct QueryEventsResponse; impl jacquard_common::xrpc::XrpcResp for QueryEventsResponse { const NSID: &'static str = "tools.ozone.safelink.queryEvents"; const ENCODING: &'static str = "application/json"; type Output<'de> = QueryEventsOutput<'de>; type Err<'de> = jacquard_common::xrpc::GenericError<'de>; } impl<'a> jacquard_common::xrpc::XrpcRequest for QueryEvents<'a> { const NSID: &'static str = "tools.ozone.safelink.queryEvents"; const METHOD: jacquard_common::xrpc::XrpcMethod = jacquard_common::xrpc::XrpcMethod::Procedure( "application/json", ); type Response = QueryEventsResponse; } ///Endpoint type for ///tools.ozone.safelink.queryEvents pub struct QueryEventsRequest; impl jacquard_common::xrpc::XrpcEndpoint for QueryEventsRequest { const PATH: &'static str = "/xrpc/tools.ozone.safelink.queryEvents"; const METHOD: jacquard_common::xrpc::XrpcMethod = jacquard_common::xrpc::XrpcMethod::Procedure( "application/json", ); type Request<'de> = QueryEvents<'de>; type Response = QueryEventsResponse; }