1// @generated by jacquard-lexicon. DO NOT EDIT.
2//
3// Lexicon: app.bsky.feed.generator
4//
5// This file was automatically generated from Lexicon schemas.
6// Any manual changes will be overwritten on the next regeneration.
7
8///Record declaring of the existence of a feed generator, and containing metadata about it. The record can exist in any repository.
9#[jacquard_derive::lexicon]
10#[derive(
11 serde::Serialize,
12 serde::Deserialize,
13 Debug,
14 Clone,
15 PartialEq,
16 Eq,
17 jacquard_derive::IntoStatic
18)]
19#[serde(rename_all = "camelCase")]
20pub struct Generator<'a> {
21 ///Declaration that a feed accepts feedback interactions from a client through app.bsky.feed.sendInteractions
22 #[serde(skip_serializing_if = "std::option::Option::is_none")]
23 pub accepts_interactions: std::option::Option<bool>,
24 #[serde(skip_serializing_if = "std::option::Option::is_none")]
25 #[serde(borrow)]
26 pub avatar: std::option::Option<jacquard_common::types::blob::Blob<'a>>,
27 #[serde(skip_serializing_if = "std::option::Option::is_none")]
28 #[serde(borrow)]
29 pub content_mode: std::option::Option<jacquard_common::CowStr<'a>>,
30 pub created_at: jacquard_common::types::string::Datetime,
31 #[serde(skip_serializing_if = "std::option::Option::is_none")]
32 #[serde(borrow)]
33 pub description: std::option::Option<jacquard_common::CowStr<'a>>,
34 #[serde(skip_serializing_if = "std::option::Option::is_none")]
35 #[serde(borrow)]
36 pub description_facets: std::option::Option<
37 Vec<crate::app_bsky::richtext::facet::Facet<'a>>,
38 >,
39 #[serde(borrow)]
40 pub did: jacquard_common::types::string::Did<'a>,
41 #[serde(borrow)]
42 pub display_name: jacquard_common::CowStr<'a>,
43 ///Self-label values
44 #[serde(skip_serializing_if = "std::option::Option::is_none")]
45 #[serde(borrow)]
46 pub labels: std::option::Option<GeneratorRecordLabels<'a>>,
47}
48
49#[jacquard_derive::open_union]
50#[derive(
51 serde::Serialize,
52 serde::Deserialize,
53 Debug,
54 Clone,
55 PartialEq,
56 Eq,
57 jacquard_derive::IntoStatic
58)]
59#[serde(tag = "$type")]
60#[serde(bound(deserialize = "'de: 'a"))]
61pub enum GeneratorRecordLabels<'a> {
62 #[serde(rename = "com.atproto.label.defs#selfLabels")]
63 DefsSelfLabels(Box<crate::com_atproto::label::SelfLabels<'a>>),
64}
65
66impl jacquard_common::types::collection::Collection for Generator<'_> {
67 const NSID: &'static str = "app.bsky.feed.generator";
68}