atrium_api/tools/ozone/moderation/
defs.rs

1// @generated - This file is generated by atrium-codegen. DO NOT EDIT.
2//!Definitions for the `tools.ozone.moderation.defs` namespace.
3///Logs account status related events on a repo subject. Normally captured by automod from the firehose and emitted to ozone for historical tracking.
4#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
5#[serde(rename_all = "camelCase")]
6pub struct AccountEventData {
7    ///Indicates that the account has a repository which can be fetched from the host that emitted this event.
8    pub active: bool,
9    #[serde(skip_serializing_if = "core::option::Option::is_none")]
10    pub comment: core::option::Option<String>,
11    #[serde(skip_serializing_if = "core::option::Option::is_none")]
12    pub status: core::option::Option<String>,
13    pub timestamp: crate::types::string::Datetime,
14}
15pub type AccountEvent = crate::types::Object<AccountEventData>;
16#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
17#[serde(rename_all = "camelCase")]
18pub struct AccountHostingData {
19    #[serde(skip_serializing_if = "core::option::Option::is_none")]
20    pub created_at: core::option::Option<crate::types::string::Datetime>,
21    #[serde(skip_serializing_if = "core::option::Option::is_none")]
22    pub deactivated_at: core::option::Option<crate::types::string::Datetime>,
23    #[serde(skip_serializing_if = "core::option::Option::is_none")]
24    pub deleted_at: core::option::Option<crate::types::string::Datetime>,
25    #[serde(skip_serializing_if = "core::option::Option::is_none")]
26    pub reactivated_at: core::option::Option<crate::types::string::Datetime>,
27    pub status: String,
28    #[serde(skip_serializing_if = "core::option::Option::is_none")]
29    pub updated_at: core::option::Option<crate::types::string::Datetime>,
30}
31pub type AccountHosting = crate::types::Object<AccountHostingData>;
32///Statistics about a particular account subject
33#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
34#[serde(rename_all = "camelCase")]
35pub struct AccountStatsData {
36    ///Total number of appeals against a moderation action on the account
37    #[serde(skip_serializing_if = "core::option::Option::is_none")]
38    pub appeal_count: core::option::Option<i64>,
39    ///Number of times the account was escalated
40    #[serde(skip_serializing_if = "core::option::Option::is_none")]
41    pub escalate_count: core::option::Option<i64>,
42    ///Total number of reports on the account
43    #[serde(skip_serializing_if = "core::option::Option::is_none")]
44    pub report_count: core::option::Option<i64>,
45    ///Number of times the account was suspended
46    #[serde(skip_serializing_if = "core::option::Option::is_none")]
47    pub suspend_count: core::option::Option<i64>,
48    ///Number of times the account was taken down
49    #[serde(skip_serializing_if = "core::option::Option::is_none")]
50    pub takedown_count: core::option::Option<i64>,
51}
52pub type AccountStats = crate::types::Object<AccountStatsData>;
53#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
54#[serde(rename_all = "camelCase")]
55pub struct BlobViewData {
56    pub cid: crate::types::string::Cid,
57    pub created_at: crate::types::string::Datetime,
58    #[serde(skip_serializing_if = "core::option::Option::is_none")]
59    pub details: core::option::Option<crate::types::Union<BlobViewDetailsRefs>>,
60    pub mime_type: String,
61    #[serde(skip_serializing_if = "core::option::Option::is_none")]
62    pub moderation: core::option::Option<Moderation>,
63    pub size: i64,
64}
65pub type BlobView = crate::types::Object<BlobViewData>;
66///Logs identity related events on a repo subject. Normally captured by automod from the firehose and emitted to ozone for historical tracking.
67#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
68#[serde(rename_all = "camelCase")]
69pub struct IdentityEventData {
70    #[serde(skip_serializing_if = "core::option::Option::is_none")]
71    pub comment: core::option::Option<String>,
72    #[serde(skip_serializing_if = "core::option::Option::is_none")]
73    pub handle: core::option::Option<crate::types::string::Handle>,
74    #[serde(skip_serializing_if = "core::option::Option::is_none")]
75    pub pds_host: core::option::Option<String>,
76    pub timestamp: crate::types::string::Datetime,
77    #[serde(skip_serializing_if = "core::option::Option::is_none")]
78    pub tombstone: core::option::Option<bool>,
79}
80pub type IdentityEvent = crate::types::Object<IdentityEventData>;
81#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
82#[serde(rename_all = "camelCase")]
83pub struct ImageDetailsData {
84    pub height: i64,
85    pub width: i64,
86}
87pub type ImageDetails = crate::types::Object<ImageDetailsData>;
88#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
89#[serde(rename_all = "camelCase")]
90pub struct ModEventAcknowledgeData {
91    ///If true, all other reports on content authored by this account will be resolved (acknowledged).
92    #[serde(skip_serializing_if = "core::option::Option::is_none")]
93    pub acknowledge_account_subjects: core::option::Option<bool>,
94    #[serde(skip_serializing_if = "core::option::Option::is_none")]
95    pub comment: core::option::Option<String>,
96}
97pub type ModEventAcknowledge = crate::types::Object<ModEventAcknowledgeData>;
98///Add a comment to a subject. An empty comment will clear any previously set sticky comment.
99#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
100#[serde(rename_all = "camelCase")]
101pub struct ModEventCommentData {
102    #[serde(skip_serializing_if = "core::option::Option::is_none")]
103    pub comment: core::option::Option<String>,
104    ///Make the comment persistent on the subject
105    #[serde(skip_serializing_if = "core::option::Option::is_none")]
106    pub sticky: core::option::Option<bool>,
107}
108pub type ModEventComment = crate::types::Object<ModEventCommentData>;
109///Divert a record's blobs to a 3rd party service for further scanning/tagging
110#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
111#[serde(rename_all = "camelCase")]
112pub struct ModEventDivertData {
113    #[serde(skip_serializing_if = "core::option::Option::is_none")]
114    pub comment: core::option::Option<String>,
115}
116pub type ModEventDivert = crate::types::Object<ModEventDivertData>;
117///Keep a log of outgoing email to a user
118#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
119#[serde(rename_all = "camelCase")]
120pub struct ModEventEmailData {
121    ///Additional comment about the outgoing comm.
122    #[serde(skip_serializing_if = "core::option::Option::is_none")]
123    pub comment: core::option::Option<String>,
124    ///The content of the email sent to the user.
125    #[serde(skip_serializing_if = "core::option::Option::is_none")]
126    pub content: core::option::Option<String>,
127    ///The subject line of the email sent to the user.
128    pub subject_line: String,
129}
130pub type ModEventEmail = crate::types::Object<ModEventEmailData>;
131#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
132#[serde(rename_all = "camelCase")]
133pub struct ModEventEscalateData {
134    #[serde(skip_serializing_if = "core::option::Option::is_none")]
135    pub comment: core::option::Option<String>,
136}
137pub type ModEventEscalate = crate::types::Object<ModEventEscalateData>;
138///Apply/Negate labels on a subject
139#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
140#[serde(rename_all = "camelCase")]
141pub struct ModEventLabelData {
142    #[serde(skip_serializing_if = "core::option::Option::is_none")]
143    pub comment: core::option::Option<String>,
144    pub create_label_vals: Vec<String>,
145    ///Indicates how long the label will remain on the subject. Only applies on labels that are being added.
146    #[serde(skip_serializing_if = "core::option::Option::is_none")]
147    pub duration_in_hours: core::option::Option<i64>,
148    pub negate_label_vals: Vec<String>,
149}
150pub type ModEventLabel = crate::types::Object<ModEventLabelData>;
151///Mute incoming reports on a subject
152#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
153#[serde(rename_all = "camelCase")]
154pub struct ModEventMuteData {
155    #[serde(skip_serializing_if = "core::option::Option::is_none")]
156    pub comment: core::option::Option<String>,
157    ///Indicates how long the subject should remain muted.
158    pub duration_in_hours: i64,
159}
160pub type ModEventMute = crate::types::Object<ModEventMuteData>;
161///Mute incoming reports from an account
162#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
163#[serde(rename_all = "camelCase")]
164pub struct ModEventMuteReporterData {
165    #[serde(skip_serializing_if = "core::option::Option::is_none")]
166    pub comment: core::option::Option<String>,
167    ///Indicates how long the account should remain muted. Falsy value here means a permanent mute.
168    #[serde(skip_serializing_if = "core::option::Option::is_none")]
169    pub duration_in_hours: core::option::Option<i64>,
170}
171pub type ModEventMuteReporter = crate::types::Object<ModEventMuteReporterData>;
172///Set priority score of the subject. Higher score means higher priority.
173#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
174#[serde(rename_all = "camelCase")]
175pub struct ModEventPriorityScoreData {
176    #[serde(skip_serializing_if = "core::option::Option::is_none")]
177    pub comment: core::option::Option<String>,
178    pub score: crate::types::LimitedU8<100u8>,
179}
180pub type ModEventPriorityScore = crate::types::Object<ModEventPriorityScoreData>;
181///Report a subject
182#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
183#[serde(rename_all = "camelCase")]
184pub struct ModEventReportData {
185    #[serde(skip_serializing_if = "core::option::Option::is_none")]
186    pub comment: core::option::Option<String>,
187    ///Set to true if the reporter was muted from reporting at the time of the event. These reports won't impact the reviewState of the subject.
188    #[serde(skip_serializing_if = "core::option::Option::is_none")]
189    pub is_reporter_muted: core::option::Option<bool>,
190    pub report_type: crate::com::atproto::moderation::defs::ReasonType,
191}
192pub type ModEventReport = crate::types::Object<ModEventReportData>;
193///Resolve appeal on a subject
194#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
195#[serde(rename_all = "camelCase")]
196pub struct ModEventResolveAppealData {
197    ///Describe resolution.
198    #[serde(skip_serializing_if = "core::option::Option::is_none")]
199    pub comment: core::option::Option<String>,
200}
201pub type ModEventResolveAppeal = crate::types::Object<ModEventResolveAppealData>;
202///Revert take down action on a subject
203#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
204#[serde(rename_all = "camelCase")]
205pub struct ModEventReverseTakedownData {
206    ///Describe reasoning behind the reversal.
207    #[serde(skip_serializing_if = "core::option::Option::is_none")]
208    pub comment: core::option::Option<String>,
209}
210pub type ModEventReverseTakedown = crate::types::Object<ModEventReverseTakedownData>;
211///Add/Remove a tag on a subject
212#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
213#[serde(rename_all = "camelCase")]
214pub struct ModEventTagData {
215    ///Tags to be added to the subject. If already exists, won't be duplicated.
216    pub add: Vec<String>,
217    ///Additional comment about added/removed tags.
218    #[serde(skip_serializing_if = "core::option::Option::is_none")]
219    pub comment: core::option::Option<String>,
220    ///Tags to be removed to the subject. Ignores a tag If it doesn't exist, won't be duplicated.
221    pub remove: Vec<String>,
222}
223pub type ModEventTag = crate::types::Object<ModEventTagData>;
224///Take down a subject permanently or temporarily
225#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
226#[serde(rename_all = "camelCase")]
227pub struct ModEventTakedownData {
228    ///If true, all other reports on content authored by this account will be resolved (acknowledged).
229    #[serde(skip_serializing_if = "core::option::Option::is_none")]
230    pub acknowledge_account_subjects: core::option::Option<bool>,
231    #[serde(skip_serializing_if = "core::option::Option::is_none")]
232    pub comment: core::option::Option<String>,
233    ///Indicates how long the takedown should be in effect before automatically expiring.
234    #[serde(skip_serializing_if = "core::option::Option::is_none")]
235    pub duration_in_hours: core::option::Option<i64>,
236    ///Names/Keywords of the policies that drove the decision.
237    #[serde(skip_serializing_if = "core::option::Option::is_none")]
238    pub policies: core::option::Option<Vec<String>>,
239}
240pub type ModEventTakedown = crate::types::Object<ModEventTakedownData>;
241///Unmute action on a subject
242#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
243#[serde(rename_all = "camelCase")]
244pub struct ModEventUnmuteData {
245    ///Describe reasoning behind the reversal.
246    #[serde(skip_serializing_if = "core::option::Option::is_none")]
247    pub comment: core::option::Option<String>,
248}
249pub type ModEventUnmute = crate::types::Object<ModEventUnmuteData>;
250///Unmute incoming reports from an account
251#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
252#[serde(rename_all = "camelCase")]
253pub struct ModEventUnmuteReporterData {
254    ///Describe reasoning behind the reversal.
255    #[serde(skip_serializing_if = "core::option::Option::is_none")]
256    pub comment: core::option::Option<String>,
257}
258pub type ModEventUnmuteReporter = crate::types::Object<ModEventUnmuteReporterData>;
259#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
260#[serde(rename_all = "camelCase")]
261pub struct ModEventViewData {
262    pub created_at: crate::types::string::Datetime,
263    pub created_by: crate::types::string::Did,
264    #[serde(skip_serializing_if = "core::option::Option::is_none")]
265    pub creator_handle: core::option::Option<String>,
266    pub event: crate::types::Union<ModEventViewEventRefs>,
267    pub id: i64,
268    pub subject: crate::types::Union<ModEventViewSubjectRefs>,
269    pub subject_blob_cids: Vec<String>,
270    #[serde(skip_serializing_if = "core::option::Option::is_none")]
271    pub subject_handle: core::option::Option<String>,
272}
273pub type ModEventView = crate::types::Object<ModEventViewData>;
274#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
275#[serde(rename_all = "camelCase")]
276pub struct ModEventViewDetailData {
277    pub created_at: crate::types::string::Datetime,
278    pub created_by: crate::types::string::Did,
279    pub event: crate::types::Union<ModEventViewDetailEventRefs>,
280    pub id: i64,
281    pub subject: crate::types::Union<ModEventViewDetailSubjectRefs>,
282    pub subject_blobs: Vec<BlobView>,
283}
284pub type ModEventViewDetail = crate::types::Object<ModEventViewDetailData>;
285#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
286#[serde(rename_all = "camelCase")]
287pub struct ModerationData {
288    #[serde(skip_serializing_if = "core::option::Option::is_none")]
289    pub subject_status: core::option::Option<SubjectStatusView>,
290}
291pub type Moderation = crate::types::Object<ModerationData>;
292#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
293#[serde(rename_all = "camelCase")]
294pub struct ModerationDetailData {
295    #[serde(skip_serializing_if = "core::option::Option::is_none")]
296    pub subject_status: core::option::Option<SubjectStatusView>,
297}
298pub type ModerationDetail = crate::types::Object<ModerationDetailData>;
299///Logs lifecycle event on a record subject. Normally captured by automod from the firehose and emitted to ozone for historical tracking.
300#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
301#[serde(rename_all = "camelCase")]
302pub struct RecordEventData {
303    #[serde(skip_serializing_if = "core::option::Option::is_none")]
304    pub cid: core::option::Option<crate::types::string::Cid>,
305    #[serde(skip_serializing_if = "core::option::Option::is_none")]
306    pub comment: core::option::Option<String>,
307    pub op: String,
308    pub timestamp: crate::types::string::Datetime,
309}
310pub type RecordEvent = crate::types::Object<RecordEventData>;
311#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
312#[serde(rename_all = "camelCase")]
313pub struct RecordHostingData {
314    #[serde(skip_serializing_if = "core::option::Option::is_none")]
315    pub created_at: core::option::Option<crate::types::string::Datetime>,
316    #[serde(skip_serializing_if = "core::option::Option::is_none")]
317    pub deleted_at: core::option::Option<crate::types::string::Datetime>,
318    pub status: String,
319    #[serde(skip_serializing_if = "core::option::Option::is_none")]
320    pub updated_at: core::option::Option<crate::types::string::Datetime>,
321}
322pub type RecordHosting = crate::types::Object<RecordHostingData>;
323#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
324#[serde(rename_all = "camelCase")]
325pub struct RecordViewData {
326    pub blob_cids: Vec<crate::types::string::Cid>,
327    pub cid: crate::types::string::Cid,
328    pub indexed_at: crate::types::string::Datetime,
329    pub moderation: Moderation,
330    pub repo: RepoView,
331    pub uri: String,
332    pub value: crate::types::Unknown,
333}
334pub type RecordView = crate::types::Object<RecordViewData>;
335#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
336#[serde(rename_all = "camelCase")]
337pub struct RecordViewDetailData {
338    pub blobs: Vec<BlobView>,
339    pub cid: crate::types::string::Cid,
340    pub indexed_at: crate::types::string::Datetime,
341    #[serde(skip_serializing_if = "core::option::Option::is_none")]
342    pub labels: core::option::Option<Vec<crate::com::atproto::label::defs::Label>>,
343    pub moderation: ModerationDetail,
344    pub repo: RepoView,
345    pub uri: String,
346    pub value: crate::types::Unknown,
347}
348pub type RecordViewDetail = crate::types::Object<RecordViewDetailData>;
349#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
350#[serde(rename_all = "camelCase")]
351pub struct RecordViewNotFoundData {
352    pub uri: String,
353}
354pub type RecordViewNotFound = crate::types::Object<RecordViewNotFoundData>;
355///Statistics about a set of record subject items
356#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
357#[serde(rename_all = "camelCase")]
358pub struct RecordsStatsData {
359    ///Number of items that were appealed at least once
360    #[serde(skip_serializing_if = "core::option::Option::is_none")]
361    pub appealed_count: core::option::Option<i64>,
362    ///Number of items that were escalated at least once
363    #[serde(skip_serializing_if = "core::option::Option::is_none")]
364    pub escalated_count: core::option::Option<i64>,
365    ///Number of item currently in "reviewOpen" or "reviewEscalated" state
366    #[serde(skip_serializing_if = "core::option::Option::is_none")]
367    pub pending_count: core::option::Option<i64>,
368    ///Number of item currently in "reviewNone" or "reviewClosed" state
369    #[serde(skip_serializing_if = "core::option::Option::is_none")]
370    pub processed_count: core::option::Option<i64>,
371    ///Number of items that were reported at least once
372    #[serde(skip_serializing_if = "core::option::Option::is_none")]
373    pub reported_count: core::option::Option<i64>,
374    ///Total number of item in the set
375    #[serde(skip_serializing_if = "core::option::Option::is_none")]
376    pub subject_count: core::option::Option<i64>,
377    ///Number of item currently taken down
378    #[serde(skip_serializing_if = "core::option::Option::is_none")]
379    pub takendown_count: core::option::Option<i64>,
380    ///Cumulative sum of the number of reports on the items in the set
381    #[serde(skip_serializing_if = "core::option::Option::is_none")]
382    pub total_reports: core::option::Option<i64>,
383}
384pub type RecordsStats = crate::types::Object<RecordsStatsData>;
385#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
386#[serde(rename_all = "camelCase")]
387pub struct RepoViewData {
388    #[serde(skip_serializing_if = "core::option::Option::is_none")]
389    pub deactivated_at: core::option::Option<crate::types::string::Datetime>,
390    pub did: crate::types::string::Did,
391    #[serde(skip_serializing_if = "core::option::Option::is_none")]
392    pub email: core::option::Option<String>,
393    pub handle: crate::types::string::Handle,
394    pub indexed_at: crate::types::string::Datetime,
395    #[serde(skip_serializing_if = "core::option::Option::is_none")]
396    pub invite_note: core::option::Option<String>,
397    #[serde(skip_serializing_if = "core::option::Option::is_none")]
398    pub invited_by: core::option::Option<crate::com::atproto::server::defs::InviteCode>,
399    #[serde(skip_serializing_if = "core::option::Option::is_none")]
400    pub invites_disabled: core::option::Option<bool>,
401    pub moderation: Moderation,
402    pub related_records: Vec<crate::types::Unknown>,
403    #[serde(skip_serializing_if = "core::option::Option::is_none")]
404    pub threat_signatures: core::option::Option<
405        Vec<crate::com::atproto::admin::defs::ThreatSignature>,
406    >,
407}
408pub type RepoView = crate::types::Object<RepoViewData>;
409#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
410#[serde(rename_all = "camelCase")]
411pub struct RepoViewDetailData {
412    #[serde(skip_serializing_if = "core::option::Option::is_none")]
413    pub deactivated_at: core::option::Option<crate::types::string::Datetime>,
414    pub did: crate::types::string::Did,
415    #[serde(skip_serializing_if = "core::option::Option::is_none")]
416    pub email: core::option::Option<String>,
417    #[serde(skip_serializing_if = "core::option::Option::is_none")]
418    pub email_confirmed_at: core::option::Option<crate::types::string::Datetime>,
419    pub handle: crate::types::string::Handle,
420    pub indexed_at: crate::types::string::Datetime,
421    #[serde(skip_serializing_if = "core::option::Option::is_none")]
422    pub invite_note: core::option::Option<String>,
423    #[serde(skip_serializing_if = "core::option::Option::is_none")]
424    pub invited_by: core::option::Option<crate::com::atproto::server::defs::InviteCode>,
425    #[serde(skip_serializing_if = "core::option::Option::is_none")]
426    pub invites: core::option::Option<
427        Vec<crate::com::atproto::server::defs::InviteCode>,
428    >,
429    #[serde(skip_serializing_if = "core::option::Option::is_none")]
430    pub invites_disabled: core::option::Option<bool>,
431    #[serde(skip_serializing_if = "core::option::Option::is_none")]
432    pub labels: core::option::Option<Vec<crate::com::atproto::label::defs::Label>>,
433    pub moderation: ModerationDetail,
434    pub related_records: Vec<crate::types::Unknown>,
435    #[serde(skip_serializing_if = "core::option::Option::is_none")]
436    pub threat_signatures: core::option::Option<
437        Vec<crate::com::atproto::admin::defs::ThreatSignature>,
438    >,
439}
440pub type RepoViewDetail = crate::types::Object<RepoViewDetailData>;
441#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
442#[serde(rename_all = "camelCase")]
443pub struct RepoViewNotFoundData {
444    pub did: crate::types::string::Did,
445}
446pub type RepoViewNotFound = crate::types::Object<RepoViewNotFoundData>;
447#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
448#[serde(rename_all = "camelCase")]
449pub struct ReporterStatsData {
450    ///The total number of reports made by the user on accounts.
451    pub account_report_count: i64,
452    pub did: crate::types::string::Did,
453    ///The total number of accounts labeled as a result of the user's reports.
454    pub labeled_account_count: i64,
455    ///The total number of records labeled as a result of the user's reports.
456    pub labeled_record_count: i64,
457    ///The total number of reports made by the user on records.
458    pub record_report_count: i64,
459    ///The total number of accounts reported by the user.
460    pub reported_account_count: i64,
461    ///The total number of records reported by the user.
462    pub reported_record_count: i64,
463    ///The total number of accounts taken down as a result of the user's reports.
464    pub takendown_account_count: i64,
465    ///The total number of records taken down as a result of the user's reports.
466    pub takendown_record_count: i64,
467}
468pub type ReporterStats = crate::types::Object<ReporterStatsData>;
469///Moderator review status of a subject: Closed. Indicates that the subject was already reviewed and resolved by a moderator
470pub const REVIEW_CLOSED: &str = "tools.ozone.moderation.defs#reviewClosed";
471///Moderator review status of a subject: Escalated. Indicates that the subject was escalated for review by a moderator
472pub const REVIEW_ESCALATED: &str = "tools.ozone.moderation.defs#reviewEscalated";
473///Moderator review status of a subject: Unnecessary. Indicates that the subject does not need a review at the moment but there is probably some moderation related metadata available for it
474pub const REVIEW_NONE: &str = "tools.ozone.moderation.defs#reviewNone";
475///Moderator review status of a subject: Open. Indicates that the subject needs to be reviewed by a moderator
476pub const REVIEW_OPEN: &str = "tools.ozone.moderation.defs#reviewOpen";
477pub type SubjectReviewState = String;
478#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
479#[serde(rename_all = "camelCase")]
480pub struct SubjectStatusViewData {
481    ///Statistics related to the account subject
482    #[serde(skip_serializing_if = "core::option::Option::is_none")]
483    pub account_stats: core::option::Option<AccountStats>,
484    ///True indicates that the a previously taken moderator action was appealed against, by the author of the content. False indicates last appeal was resolved by moderators.
485    #[serde(skip_serializing_if = "core::option::Option::is_none")]
486    pub appealed: core::option::Option<bool>,
487    ///Sticky comment on the subject.
488    #[serde(skip_serializing_if = "core::option::Option::is_none")]
489    pub comment: core::option::Option<String>,
490    ///Timestamp referencing the first moderation status impacting event was emitted on the subject
491    pub created_at: crate::types::string::Datetime,
492    #[serde(skip_serializing_if = "core::option::Option::is_none")]
493    pub hosting: core::option::Option<crate::types::Union<SubjectStatusViewHostingRefs>>,
494    pub id: i64,
495    ///Timestamp referencing when the author of the subject appealed a moderation action
496    #[serde(skip_serializing_if = "core::option::Option::is_none")]
497    pub last_appealed_at: core::option::Option<crate::types::string::Datetime>,
498    #[serde(skip_serializing_if = "core::option::Option::is_none")]
499    pub last_reported_at: core::option::Option<crate::types::string::Datetime>,
500    #[serde(skip_serializing_if = "core::option::Option::is_none")]
501    pub last_reviewed_at: core::option::Option<crate::types::string::Datetime>,
502    #[serde(skip_serializing_if = "core::option::Option::is_none")]
503    pub last_reviewed_by: core::option::Option<crate::types::string::Did>,
504    #[serde(skip_serializing_if = "core::option::Option::is_none")]
505    pub mute_reporting_until: core::option::Option<crate::types::string::Datetime>,
506    #[serde(skip_serializing_if = "core::option::Option::is_none")]
507    pub mute_until: core::option::Option<crate::types::string::Datetime>,
508    ///Numeric value representing the level of priority. Higher score means higher priority.
509    #[serde(skip_serializing_if = "core::option::Option::is_none")]
510    pub priority_score: core::option::Option<crate::types::LimitedU8<100u8>>,
511    ///Statistics related to the record subjects authored by the subject's account
512    #[serde(skip_serializing_if = "core::option::Option::is_none")]
513    pub records_stats: core::option::Option<RecordsStats>,
514    pub review_state: SubjectReviewState,
515    pub subject: crate::types::Union<SubjectStatusViewSubjectRefs>,
516    #[serde(skip_serializing_if = "core::option::Option::is_none")]
517    pub subject_blob_cids: core::option::Option<Vec<crate::types::string::Cid>>,
518    #[serde(skip_serializing_if = "core::option::Option::is_none")]
519    pub subject_repo_handle: core::option::Option<String>,
520    #[serde(skip_serializing_if = "core::option::Option::is_none")]
521    pub suspend_until: core::option::Option<crate::types::string::Datetime>,
522    #[serde(skip_serializing_if = "core::option::Option::is_none")]
523    pub tags: core::option::Option<Vec<String>>,
524    #[serde(skip_serializing_if = "core::option::Option::is_none")]
525    pub takendown: core::option::Option<bool>,
526    ///Timestamp referencing when the last update was made to the moderation status of the subject
527    pub updated_at: crate::types::string::Datetime,
528}
529pub type SubjectStatusView = crate::types::Object<SubjectStatusViewData>;
530///Detailed view of a subject. For record subjects, the author's repo and profile will be returned.
531#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
532#[serde(rename_all = "camelCase")]
533pub struct SubjectViewData {
534    #[serde(skip_serializing_if = "core::option::Option::is_none")]
535    pub profile: core::option::Option<crate::types::Union<SubjectViewProfileRefs>>,
536    #[serde(skip_serializing_if = "core::option::Option::is_none")]
537    pub record: core::option::Option<RecordViewDetail>,
538    #[serde(skip_serializing_if = "core::option::Option::is_none")]
539    pub repo: core::option::Option<RepoViewDetail>,
540    #[serde(skip_serializing_if = "core::option::Option::is_none")]
541    pub status: core::option::Option<SubjectStatusView>,
542    pub subject: String,
543    pub r#type: crate::com::atproto::moderation::defs::SubjectType,
544}
545pub type SubjectView = crate::types::Object<SubjectViewData>;
546#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
547#[serde(rename_all = "camelCase")]
548pub struct VideoDetailsData {
549    pub height: i64,
550    pub length: i64,
551    pub width: i64,
552}
553pub type VideoDetails = crate::types::Object<VideoDetailsData>;
554#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
555#[serde(tag = "$type")]
556pub enum BlobViewDetailsRefs {
557    #[serde(rename = "tools.ozone.moderation.defs#imageDetails")]
558    ImageDetails(Box<ImageDetails>),
559    #[serde(rename = "tools.ozone.moderation.defs#videoDetails")]
560    VideoDetails(Box<VideoDetails>),
561}
562#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
563#[serde(tag = "$type")]
564pub enum ModEventViewDetailEventRefs {
565    #[serde(rename = "tools.ozone.moderation.defs#modEventTakedown")]
566    ModEventTakedown(Box<ModEventTakedown>),
567    #[serde(rename = "tools.ozone.moderation.defs#modEventReverseTakedown")]
568    ModEventReverseTakedown(Box<ModEventReverseTakedown>),
569    #[serde(rename = "tools.ozone.moderation.defs#modEventComment")]
570    ModEventComment(Box<ModEventComment>),
571    #[serde(rename = "tools.ozone.moderation.defs#modEventReport")]
572    ModEventReport(Box<ModEventReport>),
573    #[serde(rename = "tools.ozone.moderation.defs#modEventLabel")]
574    ModEventLabel(Box<ModEventLabel>),
575    #[serde(rename = "tools.ozone.moderation.defs#modEventAcknowledge")]
576    ModEventAcknowledge(Box<ModEventAcknowledge>),
577    #[serde(rename = "tools.ozone.moderation.defs#modEventEscalate")]
578    ModEventEscalate(Box<ModEventEscalate>),
579    #[serde(rename = "tools.ozone.moderation.defs#modEventMute")]
580    ModEventMute(Box<ModEventMute>),
581    #[serde(rename = "tools.ozone.moderation.defs#modEventUnmute")]
582    ModEventUnmute(Box<ModEventUnmute>),
583    #[serde(rename = "tools.ozone.moderation.defs#modEventMuteReporter")]
584    ModEventMuteReporter(Box<ModEventMuteReporter>),
585    #[serde(rename = "tools.ozone.moderation.defs#modEventUnmuteReporter")]
586    ModEventUnmuteReporter(Box<ModEventUnmuteReporter>),
587    #[serde(rename = "tools.ozone.moderation.defs#modEventEmail")]
588    ModEventEmail(Box<ModEventEmail>),
589    #[serde(rename = "tools.ozone.moderation.defs#modEventResolveAppeal")]
590    ModEventResolveAppeal(Box<ModEventResolveAppeal>),
591    #[serde(rename = "tools.ozone.moderation.defs#modEventDivert")]
592    ModEventDivert(Box<ModEventDivert>),
593    #[serde(rename = "tools.ozone.moderation.defs#modEventTag")]
594    ModEventTag(Box<ModEventTag>),
595    #[serde(rename = "tools.ozone.moderation.defs#accountEvent")]
596    AccountEvent(Box<AccountEvent>),
597    #[serde(rename = "tools.ozone.moderation.defs#identityEvent")]
598    IdentityEvent(Box<IdentityEvent>),
599    #[serde(rename = "tools.ozone.moderation.defs#recordEvent")]
600    RecordEvent(Box<RecordEvent>),
601    #[serde(rename = "tools.ozone.moderation.defs#modEventPriorityScore")]
602    ModEventPriorityScore(Box<ModEventPriorityScore>),
603}
604#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
605#[serde(tag = "$type")]
606pub enum ModEventViewDetailSubjectRefs {
607    #[serde(rename = "tools.ozone.moderation.defs#repoView")]
608    RepoView(Box<RepoView>),
609    #[serde(rename = "tools.ozone.moderation.defs#repoViewNotFound")]
610    RepoViewNotFound(Box<RepoViewNotFound>),
611    #[serde(rename = "tools.ozone.moderation.defs#recordView")]
612    RecordView(Box<RecordView>),
613    #[serde(rename = "tools.ozone.moderation.defs#recordViewNotFound")]
614    RecordViewNotFound(Box<RecordViewNotFound>),
615}
616#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
617#[serde(tag = "$type")]
618pub enum ModEventViewEventRefs {
619    #[serde(rename = "tools.ozone.moderation.defs#modEventTakedown")]
620    ModEventTakedown(Box<ModEventTakedown>),
621    #[serde(rename = "tools.ozone.moderation.defs#modEventReverseTakedown")]
622    ModEventReverseTakedown(Box<ModEventReverseTakedown>),
623    #[serde(rename = "tools.ozone.moderation.defs#modEventComment")]
624    ModEventComment(Box<ModEventComment>),
625    #[serde(rename = "tools.ozone.moderation.defs#modEventReport")]
626    ModEventReport(Box<ModEventReport>),
627    #[serde(rename = "tools.ozone.moderation.defs#modEventLabel")]
628    ModEventLabel(Box<ModEventLabel>),
629    #[serde(rename = "tools.ozone.moderation.defs#modEventAcknowledge")]
630    ModEventAcknowledge(Box<ModEventAcknowledge>),
631    #[serde(rename = "tools.ozone.moderation.defs#modEventEscalate")]
632    ModEventEscalate(Box<ModEventEscalate>),
633    #[serde(rename = "tools.ozone.moderation.defs#modEventMute")]
634    ModEventMute(Box<ModEventMute>),
635    #[serde(rename = "tools.ozone.moderation.defs#modEventUnmute")]
636    ModEventUnmute(Box<ModEventUnmute>),
637    #[serde(rename = "tools.ozone.moderation.defs#modEventMuteReporter")]
638    ModEventMuteReporter(Box<ModEventMuteReporter>),
639    #[serde(rename = "tools.ozone.moderation.defs#modEventUnmuteReporter")]
640    ModEventUnmuteReporter(Box<ModEventUnmuteReporter>),
641    #[serde(rename = "tools.ozone.moderation.defs#modEventEmail")]
642    ModEventEmail(Box<ModEventEmail>),
643    #[serde(rename = "tools.ozone.moderation.defs#modEventResolveAppeal")]
644    ModEventResolveAppeal(Box<ModEventResolveAppeal>),
645    #[serde(rename = "tools.ozone.moderation.defs#modEventDivert")]
646    ModEventDivert(Box<ModEventDivert>),
647    #[serde(rename = "tools.ozone.moderation.defs#modEventTag")]
648    ModEventTag(Box<ModEventTag>),
649    #[serde(rename = "tools.ozone.moderation.defs#accountEvent")]
650    AccountEvent(Box<AccountEvent>),
651    #[serde(rename = "tools.ozone.moderation.defs#identityEvent")]
652    IdentityEvent(Box<IdentityEvent>),
653    #[serde(rename = "tools.ozone.moderation.defs#recordEvent")]
654    RecordEvent(Box<RecordEvent>),
655    #[serde(rename = "tools.ozone.moderation.defs#modEventPriorityScore")]
656    ModEventPriorityScore(Box<ModEventPriorityScore>),
657}
658#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
659#[serde(tag = "$type")]
660pub enum ModEventViewSubjectRefs {
661    #[serde(rename = "com.atproto.admin.defs#repoRef")]
662    ComAtprotoAdminDefsRepoRef(Box<crate::com::atproto::admin::defs::RepoRef>),
663    #[serde(rename = "com.atproto.repo.strongRef")]
664    ComAtprotoRepoStrongRefMain(Box<crate::com::atproto::repo::strong_ref::Main>),
665    #[serde(rename = "chat.bsky.convo.defs#messageRef")]
666    ChatBskyConvoDefsMessageRef(Box<crate::chat::bsky::convo::defs::MessageRef>),
667}
668#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
669#[serde(tag = "$type")]
670pub enum SubjectStatusViewHostingRefs {
671    #[serde(rename = "tools.ozone.moderation.defs#accountHosting")]
672    AccountHosting(Box<AccountHosting>),
673    #[serde(rename = "tools.ozone.moderation.defs#recordHosting")]
674    RecordHosting(Box<RecordHosting>),
675}
676#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
677#[serde(tag = "$type")]
678pub enum SubjectStatusViewSubjectRefs {
679    #[serde(rename = "com.atproto.admin.defs#repoRef")]
680    ComAtprotoAdminDefsRepoRef(Box<crate::com::atproto::admin::defs::RepoRef>),
681    #[serde(rename = "com.atproto.repo.strongRef")]
682    ComAtprotoRepoStrongRefMain(Box<crate::com::atproto::repo::strong_ref::Main>),
683}
684#[derive(serde::Serialize, serde::Deserialize, Debug, Clone, PartialEq, Eq)]
685#[serde(tag = "$type")]
686pub enum SubjectViewProfileRefs {}