jacquard_api/app_bsky/
actor.rs

1// @generated by jacquard-lexicon. DO NOT EDIT.
2//
3// Lexicon: app.bsky.actor.defs
4//
5// This file was automatically generated from Lexicon schemas.
6// Any manual changes will be overwritten on the next regeneration.
7
8pub mod get_preferences;
9pub mod get_profile;
10pub mod get_profiles;
11pub mod get_suggestions;
12pub mod profile;
13pub mod put_preferences;
14pub mod search_actors;
15pub mod search_actors_typeahead;
16pub mod status;
17
18#[jacquard_derive::lexicon]
19#[derive(
20    serde::Serialize,
21    serde::Deserialize,
22    Debug,
23    Clone,
24    PartialEq,
25    Eq,
26    jacquard_derive::IntoStatic,
27    bon::Builder
28)]
29#[serde(rename_all = "camelCase")]
30pub struct AdultContentPref<'a> {
31    pub enabled: bool,
32}
33
34/// If set, an active progress guide. Once completed, can be set to undefined. Should have unspecced fields tracking progress.
35#[jacquard_derive::lexicon]
36#[derive(
37    serde::Serialize,
38    serde::Deserialize,
39    Debug,
40    Clone,
41    PartialEq,
42    Eq,
43    jacquard_derive::IntoStatic,
44    Default
45)]
46#[serde(rename_all = "camelCase")]
47pub struct BskyAppProgressGuide<'a> {
48    #[serde(borrow)]
49    pub guide: jacquard_common::CowStr<'a>,
50}
51
52/// A grab bag of state that's specific to the bsky.app program. Third-party apps shouldn't use this.
53#[jacquard_derive::lexicon]
54#[derive(
55    serde::Serialize,
56    serde::Deserialize,
57    Debug,
58    Clone,
59    PartialEq,
60    Eq,
61    jacquard_derive::IntoStatic,
62    Default
63)]
64#[serde(rename_all = "camelCase")]
65pub struct BskyAppStatePref<'a> {
66    #[serde(skip_serializing_if = "std::option::Option::is_none")]
67    #[serde(borrow)]
68    pub active_progress_guide: std::option::Option<
69        crate::app_bsky::actor::BskyAppProgressGuide<'a>,
70    >,
71    /// Storage for NUXs the user has encountered.
72    #[serde(skip_serializing_if = "std::option::Option::is_none")]
73    #[serde(borrow)]
74    pub nuxs: std::option::Option<Vec<crate::app_bsky::actor::Nux<'a>>>,
75    /// An array of tokens which identify nudges (modals, popups, tours, highlight dots) that should be shown to the user.
76    #[serde(skip_serializing_if = "std::option::Option::is_none")]
77    #[serde(borrow)]
78    pub queued_nudges: std::option::Option<Vec<jacquard_common::CowStr<'a>>>,
79}
80
81#[jacquard_derive::lexicon]
82#[derive(
83    serde::Serialize,
84    serde::Deserialize,
85    Debug,
86    Clone,
87    PartialEq,
88    Eq,
89    jacquard_derive::IntoStatic,
90    Default
91)]
92#[serde(rename_all = "camelCase")]
93pub struct ContentLabelPref<'a> {
94    #[serde(borrow)]
95    pub label: jacquard_common::CowStr<'a>,
96    /// Which labeler does this preference apply to? If undefined, applies globally.
97    #[serde(skip_serializing_if = "std::option::Option::is_none")]
98    #[serde(borrow)]
99    pub labeler_did: std::option::Option<jacquard_common::types::string::Did<'a>>,
100    #[serde(borrow)]
101    pub visibility: jacquard_common::CowStr<'a>,
102}
103
104#[jacquard_derive::lexicon]
105#[derive(
106    serde::Serialize,
107    serde::Deserialize,
108    Debug,
109    Clone,
110    PartialEq,
111    Eq,
112    jacquard_derive::IntoStatic,
113    Default
114)]
115#[serde(rename_all = "camelCase")]
116pub struct FeedViewPref<'a> {
117    /// The URI of the feed, or an identifier which describes the feed.
118    #[serde(borrow)]
119    pub feed: jacquard_common::CowStr<'a>,
120    /// Hide quote posts in the feed.
121    #[serde(skip_serializing_if = "std::option::Option::is_none")]
122    pub hide_quote_posts: std::option::Option<bool>,
123    /// Hide replies in the feed.
124    #[serde(skip_serializing_if = "std::option::Option::is_none")]
125    pub hide_replies: std::option::Option<bool>,
126    /// Hide replies in the feed if they do not have this number of likes.
127    #[serde(skip_serializing_if = "std::option::Option::is_none")]
128    pub hide_replies_by_like_count: std::option::Option<i64>,
129    /// Hide replies in the feed if they are not by followed users.
130    #[serde(skip_serializing_if = "std::option::Option::is_none")]
131    pub hide_replies_by_unfollowed: std::option::Option<bool>,
132    /// Hide reposts in the feed.
133    #[serde(skip_serializing_if = "std::option::Option::is_none")]
134    pub hide_reposts: std::option::Option<bool>,
135}
136
137#[jacquard_derive::lexicon]
138#[derive(
139    serde::Serialize,
140    serde::Deserialize,
141    Debug,
142    Clone,
143    PartialEq,
144    Eq,
145    jacquard_derive::IntoStatic,
146    bon::Builder
147)]
148#[serde(rename_all = "camelCase")]
149pub struct HiddenPostsPref<'a> {
150    /// A list of URIs of posts the account owner has hidden.
151    #[serde(borrow)]
152    pub items: Vec<jacquard_common::types::string::AtUri<'a>>,
153}
154
155#[jacquard_derive::lexicon]
156#[derive(
157    serde::Serialize,
158    serde::Deserialize,
159    Debug,
160    Clone,
161    PartialEq,
162    Eq,
163    jacquard_derive::IntoStatic,
164    bon::Builder
165)]
166#[serde(rename_all = "camelCase")]
167pub struct InterestsPref<'a> {
168    /// A list of tags which describe the account owner's interests gathered during onboarding.
169    #[serde(borrow)]
170    pub tags: Vec<jacquard_common::CowStr<'a>>,
171}
172
173/// The subject's followers whom you also follow
174#[jacquard_derive::lexicon]
175#[derive(
176    serde::Serialize,
177    serde::Deserialize,
178    Debug,
179    Clone,
180    PartialEq,
181    Eq,
182    jacquard_derive::IntoStatic,
183    bon::Builder
184)]
185#[serde(rename_all = "camelCase")]
186pub struct KnownFollowers<'a> {
187    pub count: i64,
188    #[serde(borrow)]
189    pub followers: Vec<crate::app_bsky::actor::ProfileViewBasic<'a>>,
190}
191
192#[jacquard_derive::lexicon]
193#[derive(
194    serde::Serialize,
195    serde::Deserialize,
196    Debug,
197    Clone,
198    PartialEq,
199    Eq,
200    jacquard_derive::IntoStatic,
201    bon::Builder
202)]
203#[serde(rename_all = "camelCase")]
204pub struct LabelerPrefItem<'a> {
205    #[serde(borrow)]
206    pub did: jacquard_common::types::string::Did<'a>,
207}
208
209#[jacquard_derive::lexicon]
210#[derive(
211    serde::Serialize,
212    serde::Deserialize,
213    Debug,
214    Clone,
215    PartialEq,
216    Eq,
217    jacquard_derive::IntoStatic,
218    bon::Builder
219)]
220#[serde(rename_all = "camelCase")]
221pub struct LabelersPref<'a> {
222    #[serde(borrow)]
223    pub labelers: Vec<crate::app_bsky::actor::LabelerPrefItem<'a>>,
224}
225
226/// A word that the account owner has muted.
227#[jacquard_derive::lexicon]
228#[derive(
229    serde::Serialize,
230    serde::Deserialize,
231    Debug,
232    Clone,
233    PartialEq,
234    Eq,
235    jacquard_derive::IntoStatic,
236    bon::Builder
237)]
238#[serde(rename_all = "camelCase")]
239pub struct MutedWord<'a> {
240    /// Groups of users to apply the muted word to. If undefined, applies to all users.
241    #[serde(skip_serializing_if = "std::option::Option::is_none")]
242    #[builder(into)]
243    #[serde(borrow)]
244    pub actor_target: Option<jacquard_common::CowStr<'a>>,
245    /// The date and time at which the muted word will expire and no longer be applied.
246    #[serde(skip_serializing_if = "std::option::Option::is_none")]
247    #[builder(into)]
248    pub expires_at: Option<jacquard_common::types::string::Datetime>,
249    #[serde(skip_serializing_if = "std::option::Option::is_none")]
250    #[builder(into)]
251    #[serde(borrow)]
252    pub id: Option<jacquard_common::CowStr<'a>>,
253    /// The intended targets of the muted word.
254    #[serde(borrow)]
255    pub targets: Vec<crate::app_bsky::actor::MutedWordTarget<'a>>,
256    /// The muted word itself.
257    #[serde(borrow)]
258    #[builder(into)]
259    pub value: jacquard_common::CowStr<'a>,
260}
261
262#[derive(Debug, Clone, PartialEq, Eq, Hash)]
263pub enum MutedWordTarget<'a> {
264    Content,
265    Tag,
266    Other(jacquard_common::CowStr<'a>),
267}
268
269impl<'a> MutedWordTarget<'a> {
270    pub fn as_str(&self) -> &str {
271        match self {
272            Self::Content => "content",
273            Self::Tag => "tag",
274            Self::Other(s) => s.as_ref(),
275        }
276    }
277}
278
279impl<'a> From<&'a str> for MutedWordTarget<'a> {
280    fn from(s: &'a str) -> Self {
281        match s {
282            "content" => Self::Content,
283            "tag" => Self::Tag,
284            _ => Self::Other(jacquard_common::CowStr::from(s)),
285        }
286    }
287}
288
289impl<'a> From<String> for MutedWordTarget<'a> {
290    fn from(s: String) -> Self {
291        match s.as_str() {
292            "content" => Self::Content,
293            "tag" => Self::Tag,
294            _ => Self::Other(jacquard_common::CowStr::from(s)),
295        }
296    }
297}
298
299impl<'a> AsRef<str> for MutedWordTarget<'a> {
300    fn as_ref(&self) -> &str {
301        self.as_str()
302    }
303}
304
305impl<'a> serde::Serialize for MutedWordTarget<'a> {
306    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
307    where
308        S: serde::Serializer,
309    {
310        serializer.serialize_str(self.as_str())
311    }
312}
313
314impl<'de, 'a> serde::Deserialize<'de> for MutedWordTarget<'a>
315where
316    'de: 'a,
317{
318    fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
319    where
320        D: serde::Deserializer<'de>,
321    {
322        let s = <&'de str>::deserialize(deserializer)?;
323        Ok(Self::from(s))
324    }
325}
326
327impl jacquard_common::IntoStatic for MutedWordTarget<'_> {
328    type Output = MutedWordTarget<'static>;
329    fn into_static(self) -> Self::Output {
330        match self {
331            MutedWordTarget::Content => MutedWordTarget::Content,
332            MutedWordTarget::Tag => MutedWordTarget::Tag,
333            MutedWordTarget::Other(v) => MutedWordTarget::Other(v.into_static()),
334        }
335    }
336}
337
338#[jacquard_derive::lexicon]
339#[derive(
340    serde::Serialize,
341    serde::Deserialize,
342    Debug,
343    Clone,
344    PartialEq,
345    Eq,
346    jacquard_derive::IntoStatic,
347    bon::Builder
348)]
349#[serde(rename_all = "camelCase")]
350pub struct MutedWordsPref<'a> {
351    /// A list of words the account owner has muted.
352    #[serde(borrow)]
353    pub items: Vec<crate::app_bsky::actor::MutedWord<'a>>,
354}
355
356/// A new user experiences (NUX) storage object
357#[jacquard_derive::lexicon]
358#[derive(
359    serde::Serialize,
360    serde::Deserialize,
361    Debug,
362    Clone,
363    PartialEq,
364    Eq,
365    jacquard_derive::IntoStatic,
366    bon::Builder
367)]
368#[serde(rename_all = "camelCase")]
369pub struct Nux<'a> {
370    pub completed: bool,
371    /// Arbitrary data for the NUX. The structure is defined by the NUX itself. Limited to 300 characters.
372    #[serde(skip_serializing_if = "std::option::Option::is_none")]
373    #[builder(into)]
374    #[serde(borrow)]
375    pub data: Option<jacquard_common::CowStr<'a>>,
376    /// The date and time at which the NUX will expire and should be considered completed.
377    #[serde(skip_serializing_if = "std::option::Option::is_none")]
378    #[builder(into)]
379    pub expires_at: Option<jacquard_common::types::string::Datetime>,
380    #[serde(borrow)]
381    #[builder(into)]
382    pub id: jacquard_common::CowStr<'a>,
383}
384
385#[jacquard_derive::lexicon]
386#[derive(
387    serde::Serialize,
388    serde::Deserialize,
389    Debug,
390    Clone,
391    PartialEq,
392    Eq,
393    jacquard_derive::IntoStatic,
394    Default
395)]
396#[serde(rename_all = "camelCase")]
397pub struct PersonalDetailsPref<'a> {
398    /// The birth date of account owner.
399    #[serde(skip_serializing_if = "std::option::Option::is_none")]
400    pub birth_date: std::option::Option<jacquard_common::types::string::Datetime>,
401}
402
403/// Default post interaction settings for the account. These values should be applied as default values when creating new posts. These refs should mirror the threadgate and postgate records exactly.
404#[jacquard_derive::lexicon]
405#[derive(
406    serde::Serialize,
407    serde::Deserialize,
408    Debug,
409    Clone,
410    PartialEq,
411    Eq,
412    jacquard_derive::IntoStatic,
413    Default
414)]
415#[serde(rename_all = "camelCase")]
416pub struct PostInteractionSettingsPref<'a> {
417    /// Matches postgate record. List of rules defining who can embed this users posts. If value is an empty array or is undefined, no particular rules apply and anyone can embed.
418    #[serde(skip_serializing_if = "std::option::Option::is_none")]
419    #[serde(borrow)]
420    pub postgate_embedding_rules: std::option::Option<
421        Vec<crate::app_bsky::feed::postgate::DisableRule<'a>>,
422    >,
423    /// Matches threadgate record. List of rules defining who can reply to this users posts. If value is an empty array, no one can reply. If value is undefined, anyone can reply.
424    #[serde(skip_serializing_if = "std::option::Option::is_none")]
425    #[serde(borrow)]
426    pub threadgate_allow_rules: std::option::Option<
427        Vec<PostInteractionSettingsPrefThreadgateAllowRulesItem<'a>>,
428    >,
429}
430
431#[jacquard_derive::open_union]
432#[derive(
433    serde::Serialize,
434    serde::Deserialize,
435    Debug,
436    Clone,
437    PartialEq,
438    Eq,
439    jacquard_derive::IntoStatic
440)]
441#[serde(tag = "$type")]
442#[serde(bound(deserialize = "'de: 'a"))]
443pub enum PostInteractionSettingsPrefThreadgateAllowRulesItem<'a> {
444    #[serde(rename = "app.bsky.feed.threadgate#mentionRule")]
445    ThreadgateMentionRule(Box<crate::app_bsky::feed::threadgate::MentionRule<'a>>),
446    #[serde(rename = "app.bsky.feed.threadgate#followerRule")]
447    ThreadgateFollowerRule(Box<crate::app_bsky::feed::threadgate::FollowerRule<'a>>),
448    #[serde(rename = "app.bsky.feed.threadgate#followingRule")]
449    ThreadgateFollowingRule(Box<crate::app_bsky::feed::threadgate::FollowingRule<'a>>),
450    #[serde(rename = "app.bsky.feed.threadgate#listRule")]
451    ThreadgateListRule(Box<crate::app_bsky::feed::threadgate::ListRule<'a>>),
452}
453
454#[jacquard_derive::open_union]
455#[derive(
456    serde::Serialize,
457    serde::Deserialize,
458    Debug,
459    Clone,
460    PartialEq,
461    Eq,
462    jacquard_derive::IntoStatic
463)]
464#[serde(tag = "$type")]
465#[serde(bound(deserialize = "'de: 'a"))]
466pub enum PreferencesItem<'a> {
467    #[serde(rename = "app.bsky.actor.defs#adultContentPref")]
468    AdultContentPref(Box<crate::app_bsky::actor::AdultContentPref<'a>>),
469    #[serde(rename = "app.bsky.actor.defs#contentLabelPref")]
470    ContentLabelPref(Box<crate::app_bsky::actor::ContentLabelPref<'a>>),
471    #[serde(rename = "app.bsky.actor.defs#savedFeedsPref")]
472    SavedFeedsPref(Box<crate::app_bsky::actor::SavedFeedsPref<'a>>),
473    #[serde(rename = "app.bsky.actor.defs#savedFeedsPrefV2")]
474    SavedFeedsPrefV2(Box<crate::app_bsky::actor::SavedFeedsPrefV2<'a>>),
475    #[serde(rename = "app.bsky.actor.defs#personalDetailsPref")]
476    PersonalDetailsPref(Box<crate::app_bsky::actor::PersonalDetailsPref<'a>>),
477    #[serde(rename = "app.bsky.actor.defs#feedViewPref")]
478    FeedViewPref(Box<crate::app_bsky::actor::FeedViewPref<'a>>),
479    #[serde(rename = "app.bsky.actor.defs#threadViewPref")]
480    ThreadViewPref(Box<crate::app_bsky::actor::ThreadViewPref<'a>>),
481    #[serde(rename = "app.bsky.actor.defs#interestsPref")]
482    InterestsPref(Box<crate::app_bsky::actor::InterestsPref<'a>>),
483    #[serde(rename = "app.bsky.actor.defs#mutedWordsPref")]
484    MutedWordsPref(Box<crate::app_bsky::actor::MutedWordsPref<'a>>),
485    #[serde(rename = "app.bsky.actor.defs#hiddenPostsPref")]
486    HiddenPostsPref(Box<crate::app_bsky::actor::HiddenPostsPref<'a>>),
487    #[serde(rename = "app.bsky.actor.defs#bskyAppStatePref")]
488    BskyAppStatePref(Box<crate::app_bsky::actor::BskyAppStatePref<'a>>),
489    #[serde(rename = "app.bsky.actor.defs#labelersPref")]
490    LabelersPref(Box<crate::app_bsky::actor::LabelersPref<'a>>),
491    #[serde(rename = "app.bsky.actor.defs#postInteractionSettingsPref")]
492    PostInteractionSettingsPref(
493        Box<crate::app_bsky::actor::PostInteractionSettingsPref<'a>>,
494    ),
495    #[serde(rename = "app.bsky.actor.defs#verificationPrefs")]
496    VerificationPrefs(Box<crate::app_bsky::actor::VerificationPrefs<'a>>),
497}
498
499pub type Preferences<'a> = Vec<PreferencesItem<'a>>;
500#[jacquard_derive::lexicon]
501#[derive(
502    serde::Serialize,
503    serde::Deserialize,
504    Debug,
505    Clone,
506    PartialEq,
507    Eq,
508    jacquard_derive::IntoStatic,
509    Default
510)]
511#[serde(rename_all = "camelCase")]
512pub struct ProfileAssociated<'a> {
513    #[serde(skip_serializing_if = "std::option::Option::is_none")]
514    #[serde(borrow)]
515    pub activity_subscription: std::option::Option<
516        crate::app_bsky::actor::ProfileAssociatedActivitySubscription<'a>,
517    >,
518    #[serde(skip_serializing_if = "std::option::Option::is_none")]
519    #[serde(borrow)]
520    pub chat: std::option::Option<crate::app_bsky::actor::ProfileAssociatedChat<'a>>,
521    #[serde(skip_serializing_if = "std::option::Option::is_none")]
522    pub feedgens: std::option::Option<i64>,
523    #[serde(skip_serializing_if = "std::option::Option::is_none")]
524    pub labeler: std::option::Option<bool>,
525    #[serde(skip_serializing_if = "std::option::Option::is_none")]
526    pub lists: std::option::Option<i64>,
527    #[serde(skip_serializing_if = "std::option::Option::is_none")]
528    pub starter_packs: std::option::Option<i64>,
529}
530
531#[jacquard_derive::lexicon]
532#[derive(
533    serde::Serialize,
534    serde::Deserialize,
535    Debug,
536    Clone,
537    PartialEq,
538    Eq,
539    jacquard_derive::IntoStatic,
540    Default
541)]
542#[serde(rename_all = "camelCase")]
543pub struct ProfileAssociatedActivitySubscription<'a> {
544    #[serde(borrow)]
545    pub allow_subscriptions: jacquard_common::CowStr<'a>,
546}
547
548#[jacquard_derive::lexicon]
549#[derive(
550    serde::Serialize,
551    serde::Deserialize,
552    Debug,
553    Clone,
554    PartialEq,
555    Eq,
556    jacquard_derive::IntoStatic,
557    Default
558)]
559#[serde(rename_all = "camelCase")]
560pub struct ProfileAssociatedChat<'a> {
561    #[serde(borrow)]
562    pub allow_incoming: jacquard_common::CowStr<'a>,
563}
564
565#[jacquard_derive::lexicon]
566#[derive(
567    serde::Serialize,
568    serde::Deserialize,
569    Debug,
570    Clone,
571    PartialEq,
572    Eq,
573    jacquard_derive::IntoStatic,
574    bon::Builder
575)]
576#[serde(rename_all = "camelCase")]
577pub struct ProfileView<'a> {
578    #[serde(skip_serializing_if = "std::option::Option::is_none")]
579    #[builder(into)]
580    #[serde(borrow)]
581    pub associated: Option<crate::app_bsky::actor::ProfileAssociated<'a>>,
582    #[serde(skip_serializing_if = "std::option::Option::is_none")]
583    #[builder(into)]
584    #[serde(borrow)]
585    pub avatar: Option<jacquard_common::types::string::Uri<'a>>,
586    #[serde(skip_serializing_if = "std::option::Option::is_none")]
587    #[builder(into)]
588    pub created_at: Option<jacquard_common::types::string::Datetime>,
589    #[serde(skip_serializing_if = "std::option::Option::is_none")]
590    #[builder(into)]
591    #[serde(borrow)]
592    pub description: Option<jacquard_common::CowStr<'a>>,
593    #[serde(borrow)]
594    pub did: jacquard_common::types::string::Did<'a>,
595    #[serde(skip_serializing_if = "std::option::Option::is_none")]
596    #[builder(into)]
597    #[serde(borrow)]
598    pub display_name: Option<jacquard_common::CowStr<'a>>,
599    #[serde(borrow)]
600    pub handle: jacquard_common::types::string::Handle<'a>,
601    #[serde(skip_serializing_if = "std::option::Option::is_none")]
602    #[builder(into)]
603    pub indexed_at: Option<jacquard_common::types::string::Datetime>,
604    #[serde(skip_serializing_if = "std::option::Option::is_none")]
605    #[builder(into)]
606    #[serde(borrow)]
607    pub labels: Option<Vec<crate::com_atproto::label::Label<'a>>>,
608    #[serde(skip_serializing_if = "std::option::Option::is_none")]
609    #[builder(into)]
610    #[serde(borrow)]
611    pub pronouns: Option<jacquard_common::CowStr<'a>>,
612    #[serde(skip_serializing_if = "std::option::Option::is_none")]
613    #[builder(into)]
614    #[serde(borrow)]
615    pub status: Option<crate::app_bsky::actor::StatusView<'a>>,
616    #[serde(skip_serializing_if = "std::option::Option::is_none")]
617    #[builder(into)]
618    #[serde(borrow)]
619    pub verification: Option<crate::app_bsky::actor::VerificationState<'a>>,
620    #[serde(skip_serializing_if = "std::option::Option::is_none")]
621    #[builder(into)]
622    #[serde(borrow)]
623    pub viewer: Option<crate::app_bsky::actor::ViewerState<'a>>,
624}
625
626#[jacquard_derive::lexicon]
627#[derive(
628    serde::Serialize,
629    serde::Deserialize,
630    Debug,
631    Clone,
632    PartialEq,
633    Eq,
634    jacquard_derive::IntoStatic,
635    bon::Builder
636)]
637#[serde(rename_all = "camelCase")]
638pub struct ProfileViewBasic<'a> {
639    #[serde(skip_serializing_if = "std::option::Option::is_none")]
640    #[builder(into)]
641    #[serde(borrow)]
642    pub associated: Option<crate::app_bsky::actor::ProfileAssociated<'a>>,
643    #[serde(skip_serializing_if = "std::option::Option::is_none")]
644    #[builder(into)]
645    #[serde(borrow)]
646    pub avatar: Option<jacquard_common::types::string::Uri<'a>>,
647    #[serde(skip_serializing_if = "std::option::Option::is_none")]
648    #[builder(into)]
649    pub created_at: Option<jacquard_common::types::string::Datetime>,
650    #[serde(borrow)]
651    pub did: jacquard_common::types::string::Did<'a>,
652    #[serde(skip_serializing_if = "std::option::Option::is_none")]
653    #[builder(into)]
654    #[serde(borrow)]
655    pub display_name: Option<jacquard_common::CowStr<'a>>,
656    #[serde(borrow)]
657    pub handle: jacquard_common::types::string::Handle<'a>,
658    #[serde(skip_serializing_if = "std::option::Option::is_none")]
659    #[builder(into)]
660    #[serde(borrow)]
661    pub labels: Option<Vec<crate::com_atproto::label::Label<'a>>>,
662    #[serde(skip_serializing_if = "std::option::Option::is_none")]
663    #[builder(into)]
664    #[serde(borrow)]
665    pub pronouns: Option<jacquard_common::CowStr<'a>>,
666    #[serde(skip_serializing_if = "std::option::Option::is_none")]
667    #[builder(into)]
668    #[serde(borrow)]
669    pub status: Option<crate::app_bsky::actor::StatusView<'a>>,
670    #[serde(skip_serializing_if = "std::option::Option::is_none")]
671    #[builder(into)]
672    #[serde(borrow)]
673    pub verification: Option<crate::app_bsky::actor::VerificationState<'a>>,
674    #[serde(skip_serializing_if = "std::option::Option::is_none")]
675    #[builder(into)]
676    #[serde(borrow)]
677    pub viewer: Option<crate::app_bsky::actor::ViewerState<'a>>,
678}
679
680#[jacquard_derive::lexicon]
681#[derive(
682    serde::Serialize,
683    serde::Deserialize,
684    Debug,
685    Clone,
686    PartialEq,
687    Eq,
688    jacquard_derive::IntoStatic,
689    bon::Builder
690)]
691#[serde(rename_all = "camelCase")]
692pub struct ProfileViewDetailed<'a> {
693    #[serde(skip_serializing_if = "std::option::Option::is_none")]
694    #[builder(into)]
695    #[serde(borrow)]
696    pub associated: Option<crate::app_bsky::actor::ProfileAssociated<'a>>,
697    #[serde(skip_serializing_if = "std::option::Option::is_none")]
698    #[builder(into)]
699    #[serde(borrow)]
700    pub avatar: Option<jacquard_common::types::string::Uri<'a>>,
701    #[serde(skip_serializing_if = "std::option::Option::is_none")]
702    #[builder(into)]
703    #[serde(borrow)]
704    pub banner: Option<jacquard_common::types::string::Uri<'a>>,
705    #[serde(skip_serializing_if = "std::option::Option::is_none")]
706    #[builder(into)]
707    pub created_at: Option<jacquard_common::types::string::Datetime>,
708    #[serde(skip_serializing_if = "std::option::Option::is_none")]
709    #[builder(into)]
710    #[serde(borrow)]
711    pub description: Option<jacquard_common::CowStr<'a>>,
712    #[serde(borrow)]
713    pub did: jacquard_common::types::string::Did<'a>,
714    #[serde(skip_serializing_if = "std::option::Option::is_none")]
715    #[builder(into)]
716    #[serde(borrow)]
717    pub display_name: Option<jacquard_common::CowStr<'a>>,
718    #[serde(skip_serializing_if = "std::option::Option::is_none")]
719    #[builder(into)]
720    pub followers_count: Option<i64>,
721    #[serde(skip_serializing_if = "std::option::Option::is_none")]
722    #[builder(into)]
723    pub follows_count: Option<i64>,
724    #[serde(borrow)]
725    pub handle: jacquard_common::types::string::Handle<'a>,
726    #[serde(skip_serializing_if = "std::option::Option::is_none")]
727    #[builder(into)]
728    pub indexed_at: Option<jacquard_common::types::string::Datetime>,
729    #[serde(skip_serializing_if = "std::option::Option::is_none")]
730    #[builder(into)]
731    #[serde(borrow)]
732    pub joined_via_starter_pack: Option<
733        crate::app_bsky::graph::StarterPackViewBasic<'a>,
734    >,
735    #[serde(skip_serializing_if = "std::option::Option::is_none")]
736    #[builder(into)]
737    #[serde(borrow)]
738    pub labels: Option<Vec<crate::com_atproto::label::Label<'a>>>,
739    #[serde(skip_serializing_if = "std::option::Option::is_none")]
740    #[builder(into)]
741    #[serde(borrow)]
742    pub pinned_post: Option<crate::com_atproto::repo::strong_ref::StrongRef<'a>>,
743    #[serde(skip_serializing_if = "std::option::Option::is_none")]
744    #[builder(into)]
745    pub posts_count: Option<i64>,
746    #[serde(skip_serializing_if = "std::option::Option::is_none")]
747    #[builder(into)]
748    #[serde(borrow)]
749    pub pronouns: Option<jacquard_common::CowStr<'a>>,
750    #[serde(skip_serializing_if = "std::option::Option::is_none")]
751    #[builder(into)]
752    #[serde(borrow)]
753    pub status: Option<crate::app_bsky::actor::StatusView<'a>>,
754    #[serde(skip_serializing_if = "std::option::Option::is_none")]
755    #[builder(into)]
756    #[serde(borrow)]
757    pub verification: Option<crate::app_bsky::actor::VerificationState<'a>>,
758    #[serde(skip_serializing_if = "std::option::Option::is_none")]
759    #[builder(into)]
760    #[serde(borrow)]
761    pub viewer: Option<crate::app_bsky::actor::ViewerState<'a>>,
762    #[serde(skip_serializing_if = "std::option::Option::is_none")]
763    #[builder(into)]
764    #[serde(borrow)]
765    pub website: Option<jacquard_common::types::string::Uri<'a>>,
766}
767
768#[jacquard_derive::lexicon]
769#[derive(
770    serde::Serialize,
771    serde::Deserialize,
772    Debug,
773    Clone,
774    PartialEq,
775    Eq,
776    jacquard_derive::IntoStatic,
777    bon::Builder
778)]
779#[serde(rename_all = "camelCase")]
780pub struct SavedFeed<'a> {
781    #[serde(borrow)]
782    #[builder(into)]
783    pub id: jacquard_common::CowStr<'a>,
784    pub pinned: bool,
785    #[serde(borrow)]
786    #[builder(into)]
787    pub r#type: jacquard_common::CowStr<'a>,
788    #[serde(borrow)]
789    #[builder(into)]
790    pub value: jacquard_common::CowStr<'a>,
791}
792
793#[jacquard_derive::lexicon]
794#[derive(
795    serde::Serialize,
796    serde::Deserialize,
797    Debug,
798    Clone,
799    PartialEq,
800    Eq,
801    jacquard_derive::IntoStatic,
802    bon::Builder
803)]
804#[serde(rename_all = "camelCase")]
805pub struct SavedFeedsPref<'a> {
806    #[serde(borrow)]
807    pub pinned: Vec<jacquard_common::types::string::AtUri<'a>>,
808    #[serde(borrow)]
809    pub saved: Vec<jacquard_common::types::string::AtUri<'a>>,
810    #[serde(skip_serializing_if = "std::option::Option::is_none")]
811    #[builder(into)]
812    pub timeline_index: Option<i64>,
813}
814
815#[jacquard_derive::lexicon]
816#[derive(
817    serde::Serialize,
818    serde::Deserialize,
819    Debug,
820    Clone,
821    PartialEq,
822    Eq,
823    jacquard_derive::IntoStatic,
824    bon::Builder
825)]
826#[serde(rename_all = "camelCase")]
827pub struct SavedFeedsPrefV2<'a> {
828    #[serde(borrow)]
829    pub items: Vec<crate::app_bsky::actor::SavedFeed<'a>>,
830}
831
832#[jacquard_derive::lexicon]
833#[derive(
834    serde::Serialize,
835    serde::Deserialize,
836    Debug,
837    Clone,
838    PartialEq,
839    Eq,
840    jacquard_derive::IntoStatic,
841    bon::Builder
842)]
843#[serde(rename_all = "camelCase")]
844pub struct StatusView<'a> {
845    /// An optional embed associated with the status.
846    #[serde(skip_serializing_if = "std::option::Option::is_none")]
847    #[builder(into)]
848    #[serde(borrow)]
849    pub embed: Option<crate::app_bsky::embed::external::View<'a>>,
850    /// The date when this status will expire. The application might choose to no longer return the status after expiration.
851    #[serde(skip_serializing_if = "std::option::Option::is_none")]
852    #[builder(into)]
853    pub expires_at: Option<jacquard_common::types::string::Datetime>,
854    /// True if the status is not expired, false if it is expired. Only present if expiration was set.
855    #[serde(skip_serializing_if = "std::option::Option::is_none")]
856    #[builder(into)]
857    pub is_active: Option<bool>,
858    #[serde(borrow)]
859    pub record: jacquard_common::types::value::Data<'a>,
860    /// The status for the account.
861    #[serde(borrow)]
862    #[builder(into)]
863    pub status: jacquard_common::CowStr<'a>,
864}
865
866#[jacquard_derive::lexicon]
867#[derive(
868    serde::Serialize,
869    serde::Deserialize,
870    Debug,
871    Clone,
872    PartialEq,
873    Eq,
874    jacquard_derive::IntoStatic,
875    Default
876)]
877#[serde(rename_all = "camelCase")]
878pub struct ThreadViewPref<'a> {
879    /// Show followed users at the top of all replies.
880    #[serde(skip_serializing_if = "std::option::Option::is_none")]
881    pub prioritize_followed_users: std::option::Option<bool>,
882    /// Sorting mode for threads.
883    #[serde(skip_serializing_if = "std::option::Option::is_none")]
884    #[serde(borrow)]
885    pub sort: std::option::Option<jacquard_common::CowStr<'a>>,
886}
887
888/// Preferences for how verified accounts appear in the app.
889#[jacquard_derive::lexicon]
890#[derive(
891    serde::Serialize,
892    serde::Deserialize,
893    Debug,
894    Clone,
895    PartialEq,
896    Eq,
897    jacquard_derive::IntoStatic,
898    Default
899)]
900#[serde(rename_all = "camelCase")]
901pub struct VerificationPrefs<'a> {
902    /// Hide the blue check badges for verified accounts and trusted verifiers.
903    #[serde(skip_serializing_if = "std::option::Option::is_none")]
904    pub hide_badges: std::option::Option<bool>,
905}
906
907/// Represents the verification information about the user this object is attached to.
908#[jacquard_derive::lexicon]
909#[derive(
910    serde::Serialize,
911    serde::Deserialize,
912    Debug,
913    Clone,
914    PartialEq,
915    Eq,
916    jacquard_derive::IntoStatic,
917    bon::Builder
918)]
919#[serde(rename_all = "camelCase")]
920pub struct VerificationState<'a> {
921    /// The user's status as a trusted verifier.
922    #[serde(borrow)]
923    #[builder(into)]
924    pub trusted_verifier_status: jacquard_common::CowStr<'a>,
925    /// All verifications issued by trusted verifiers on behalf of this user. Verifications by untrusted verifiers are not included.
926    #[serde(borrow)]
927    pub verifications: Vec<crate::app_bsky::actor::VerificationView<'a>>,
928    /// The user's status as a verified account.
929    #[serde(borrow)]
930    #[builder(into)]
931    pub verified_status: jacquard_common::CowStr<'a>,
932}
933
934/// An individual verification for an associated subject.
935#[jacquard_derive::lexicon]
936#[derive(
937    serde::Serialize,
938    serde::Deserialize,
939    Debug,
940    Clone,
941    PartialEq,
942    Eq,
943    jacquard_derive::IntoStatic,
944    bon::Builder
945)]
946#[serde(rename_all = "camelCase")]
947pub struct VerificationView<'a> {
948    /// Timestamp when the verification was created.
949    pub created_at: jacquard_common::types::string::Datetime,
950    /// True if the verification passes validation, otherwise false.
951    pub is_valid: bool,
952    /// The user who issued this verification.
953    #[serde(borrow)]
954    pub issuer: jacquard_common::types::string::Did<'a>,
955    /// The AT-URI of the verification record.
956    #[serde(borrow)]
957    pub uri: jacquard_common::types::string::AtUri<'a>,
958}
959
960/// Metadata about the requesting account's relationship with the subject account. Only has meaningful content for authed requests.
961#[jacquard_derive::lexicon]
962#[derive(
963    serde::Serialize,
964    serde::Deserialize,
965    Debug,
966    Clone,
967    PartialEq,
968    Eq,
969    jacquard_derive::IntoStatic,
970    Default
971)]
972#[serde(rename_all = "camelCase")]
973pub struct ViewerState<'a> {
974    /// This property is present only in selected cases, as an optimization.
975    #[serde(skip_serializing_if = "std::option::Option::is_none")]
976    #[serde(borrow)]
977    pub activity_subscription: std::option::Option<
978        crate::app_bsky::notification::ActivitySubscription<'a>,
979    >,
980    #[serde(skip_serializing_if = "std::option::Option::is_none")]
981    pub blocked_by: std::option::Option<bool>,
982    #[serde(skip_serializing_if = "std::option::Option::is_none")]
983    #[serde(borrow)]
984    pub blocking: std::option::Option<jacquard_common::types::string::AtUri<'a>>,
985    #[serde(skip_serializing_if = "std::option::Option::is_none")]
986    #[serde(borrow)]
987    pub blocking_by_list: std::option::Option<crate::app_bsky::graph::ListViewBasic<'a>>,
988    #[serde(skip_serializing_if = "std::option::Option::is_none")]
989    #[serde(borrow)]
990    pub followed_by: std::option::Option<jacquard_common::types::string::AtUri<'a>>,
991    #[serde(skip_serializing_if = "std::option::Option::is_none")]
992    #[serde(borrow)]
993    pub following: std::option::Option<jacquard_common::types::string::AtUri<'a>>,
994    /// This property is present only in selected cases, as an optimization.
995    #[serde(skip_serializing_if = "std::option::Option::is_none")]
996    #[serde(borrow)]
997    pub known_followers: std::option::Option<crate::app_bsky::actor::KnownFollowers<'a>>,
998    #[serde(skip_serializing_if = "std::option::Option::is_none")]
999    pub muted: std::option::Option<bool>,
1000    #[serde(skip_serializing_if = "std::option::Option::is_none")]
1001    #[serde(borrow)]
1002    pub muted_by_list: std::option::Option<crate::app_bsky::graph::ListViewBasic<'a>>,
1003}