A better Rust ATProto crate
at oauth 1.9 kB view raw
1// @generated by jacquard-lexicon. DO NOT EDIT. 2// 3// Lexicon: app.bsky.notification.unregisterPush 4// 5// This file was automatically generated from Lexicon schemas. 6// Any manual changes will be overwritten on the next regeneration. 7 8#[jacquard_derive::lexicon] 9#[derive( 10 serde::Serialize, 11 serde::Deserialize, 12 Debug, 13 Clone, 14 PartialEq, 15 Eq, 16 bon::Builder 17)] 18#[serde(rename_all = "camelCase")] 19#[builder(start_fn = new)] 20pub struct UnregisterPush<'a> { 21 #[serde(borrow)] 22 #[builder(into)] 23 pub app_id: jacquard_common::CowStr<'a>, 24 #[serde(borrow)] 25 #[builder(into)] 26 pub platform: jacquard_common::CowStr<'a>, 27 #[serde(borrow)] 28 pub service_did: jacquard_common::types::string::Did<'a>, 29 #[serde(borrow)] 30 #[builder(into)] 31 pub token: jacquard_common::CowStr<'a>, 32 #[serde(flatten)] 33 #[serde(borrow)] 34 #[builder(default)] 35 pub extra_data: ::std::collections::BTreeMap< 36 ::jacquard_common::smol_str::SmolStr, 37 ::jacquard_common::types::value::Data<'a>, 38 >, 39} 40 41impl jacquard_common::IntoStatic for UnregisterPush<'_> { 42 type Output = UnregisterPush<'static>; 43 fn into_static(self) -> Self::Output { 44 UnregisterPush { 45 app_id: self.app_id.into_static(), 46 platform: self.platform.into_static(), 47 service_did: self.service_did.into_static(), 48 token: self.token.into_static(), 49 extra_data: self.extra_data.into_static(), 50 } 51 } 52} 53 54impl jacquard_common::types::xrpc::XrpcRequest for UnregisterPush<'_> { 55 const NSID: &'static str = "app.bsky.notification.unregisterPush"; 56 const METHOD: jacquard_common::types::xrpc::XrpcMethod = jacquard_common::types::xrpc::XrpcMethod::Procedure( 57 "application/json", 58 ); 59 const OUTPUT_ENCODING: &'static str = "application/json"; 60 type Output<'de> = (); 61 type Err<'de> = jacquard_common::types::xrpc::GenericError<'de>; 62}