shrike 0.1.0

AT Protocol library for Rust
Documentation
// Code generated by lexgen. DO NOT EDIT.

#[derive(Debug, Clone, Default, serde::Serialize, serde::Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct UnspeccedGetPopularFeedGeneratorsParams {
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub cursor: Option<String>,
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub limit: Option<i64>,
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub query: Option<String>,
}

#[derive(Debug, Clone, serde::Serialize, serde::Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct UnspeccedGetPopularFeedGeneratorsOutput {
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub cursor: Option<String>,
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub feeds: Vec<crate::api::app::bsky::FeedDefsGeneratorView>,
    /// Extra fields not defined in the schema.
    #[serde(flatten)]
    pub extra: std::collections::HashMap<String, serde_json::Value>,
}

/// UnspeccedGetPopularFeedGenerators — An unspecced view of globally popular feed generators.
pub async fn unspecced_get_popular_feed_generators(
    client: &crate::xrpc::Client,
    params: &UnspeccedGetPopularFeedGeneratorsParams,
) -> Result<UnspeccedGetPopularFeedGeneratorsOutput, crate::xrpc::Error> {
    client
        .query("app.bsky.unspecced.getPopularFeedGenerators", params)
        .await
}