1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
// This file is generated by atrium-codegen. DO NOT EDIT.
//!Definitions for the `app.bsky.feed.post` namespace.
#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
#[serde(rename_all = "camelCase")]
pub struct Record {
    ///Client-declared timestamp when this post was originally created.
    pub created_at: crate::types::string::Datetime,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub embed: Option<RecordEmbedEnum>,
    ///DEPRECATED: replaced by app.bsky.richtext.facet.
    #[serde(skip_serializing_if = "Option::is_none")]
    pub entities: Option<Vec<Entity>>,
    ///Annotations of text (mentions, URLs, hashtags, etc)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub facets: Option<Vec<crate::app::bsky::richtext::facet::Main>>,
    ///Self-label values for this post. Effectively content warnings.
    #[serde(skip_serializing_if = "Option::is_none")]
    pub labels: Option<RecordLabelsEnum>,
    ///Indicates human language of post primary text content.
    #[serde(skip_serializing_if = "Option::is_none")]
    pub langs: Option<Vec<crate::types::string::Language>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub reply: Option<ReplyRef>,
    ///Additional hashtags, in addition to any included in post text and facets.
    #[serde(skip_serializing_if = "Option::is_none")]
    pub tags: Option<Vec<String>>,
    ///The primary post content. May be an empty string, if there are embeds.
    pub text: String,
}
///Deprecated: use facets instead.
#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
#[serde(rename_all = "camelCase")]
pub struct Entity {
    pub index: TextSlice,
    ///Expected values are 'mention' and 'link'.
    pub r#type: String,
    pub value: String,
}
#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
#[serde(rename_all = "camelCase")]
pub struct ReplyRef {
    pub parent: crate::com::atproto::repo::strong_ref::Main,
    pub root: crate::com::atproto::repo::strong_ref::Main,
}
///Deprecated. Use app.bsky.richtext instead -- A text segment. Start is inclusive, end is exclusive. Indices are for utf16-encoded strings.
#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
#[serde(rename_all = "camelCase")]
pub struct TextSlice {
    pub end: usize,
    pub start: usize,
}
#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
#[serde(tag = "$type")]
pub enum RecordEmbedEnum {
    #[serde(rename = "app.bsky.embed.images")]
    AppBskyEmbedImagesMain(Box<crate::app::bsky::embed::images::Main>),
    #[serde(rename = "app.bsky.embed.external")]
    AppBskyEmbedExternalMain(Box<crate::app::bsky::embed::external::Main>),
    #[serde(rename = "app.bsky.embed.record")]
    AppBskyEmbedRecordMain(Box<crate::app::bsky::embed::record::Main>),
    #[serde(rename = "app.bsky.embed.recordWithMedia")]
    AppBskyEmbedRecordWithMediaMain(
        Box<crate::app::bsky::embed::record_with_media::Main>,
    ),
}
#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
#[serde(tag = "$type")]
pub enum RecordLabelsEnum {
    #[serde(rename = "com.atproto.label.defs#selfLabels")]
    ComAtprotoLabelDefsSelfLabels(Box<crate::com::atproto::label::defs::SelfLabels>),
}