proto-blue-api 0.3.3

AT Protocol high-level API: agent, rich text, moderation, generated types
Documentation
// Generated by atproto-codegen. Do not edit.
//! Lexicon: com.atproto.label.subscribeLabels
#![allow(clippy::pedantic, clippy::nursery, clippy::all)]

use serde::{Deserialize, Serialize};

#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct Info {
    #[serde(skip_serializing_if = "Option::is_none")]
    pub message: Option<String>,
    pub name: String,
}

#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct Labels {
    pub labels: Vec<crate::com::atproto::label::defs::Label>,
    pub seq: i64,
}

/// Subscribe to stream of labels (and negations). Public endpoint implemented by mod services. Uses same sequencing scheme as repo event stream.
/// XRPC Subscription: com.atproto.label.subscribeLabels
#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct Params {
    #[serde(skip_serializing_if = "Option::is_none")]
    pub cursor: Option<i64>,
}

#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(tag = "$type")]
pub enum Message {
    #[serde(rename = "com.atproto.label.subscribeLabels#labels")]
    AtprotoLabelSubscribeLabelsLabels(Box<Labels>),
    #[serde(rename = "com.atproto.label.subscribeLabels#info")]
    AtprotoLabelSubscribeLabelsInfo(Box<Info>),
    #[serde(other)]
    Other,
}