1// @generated by jacquard-lexicon. DO NOT EDIT.
2//
3// Lexicon: app.bsky.notification.registerPush
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 RegisterPush<'a> {
21 ///Set to true when the actor is age restricted
22 #[serde(skip_serializing_if = "std::option::Option::is_none")]
23 pub age_restricted: std::option::Option<bool>,
24 #[serde(borrow)]
25 #[builder(into)]
26 pub app_id: jacquard_common::CowStr<'a>,
27 #[serde(borrow)]
28 #[builder(into)]
29 pub platform: jacquard_common::CowStr<'a>,
30 #[serde(borrow)]
31 pub service_did: jacquard_common::types::string::Did<'a>,
32 #[serde(borrow)]
33 #[builder(into)]
34 pub token: jacquard_common::CowStr<'a>,
35 #[serde(flatten)]
36 #[serde(borrow)]
37 #[builder(default)]
38 pub extra_data: ::std::collections::BTreeMap<
39 ::jacquard_common::smol_str::SmolStr,
40 ::jacquard_common::types::value::Data<'a>,
41 >,
42}
43
44impl jacquard_common::IntoStatic for RegisterPush<'_> {
45 type Output = RegisterPush<'static>;
46 fn into_static(self) -> Self::Output {
47 RegisterPush {
48 age_restricted: self.age_restricted.into_static(),
49 app_id: self.app_id.into_static(),
50 platform: self.platform.into_static(),
51 service_did: self.service_did.into_static(),
52 token: self.token.into_static(),
53 extra_data: self.extra_data.into_static(),
54 }
55 }
56}
57
58impl jacquard_common::types::xrpc::XrpcRequest for RegisterPush<'_> {
59 const NSID: &'static str = "app.bsky.notification.registerPush";
60 const METHOD: jacquard_common::types::xrpc::XrpcMethod = jacquard_common::types::xrpc::XrpcMethod::Procedure(
61 "application/json",
62 );
63 const OUTPUT_ENCODING: &'static str = "application/json";
64 type Output<'de> = ();
65 type Err<'de> = jacquard_common::types::xrpc::GenericError<'de>;
66}