mangadex_api_schema_rust/v5/
user.rs1use mangadex_api_types::{RelationshipType, UserRole};
2use serde::Deserialize;
3
4use crate::TypedAttributes;
5
6#[derive(Clone, Debug, Deserialize, Default)]
8#[non_exhaustive]
9#[cfg_attr(feature = "serialize", derive(serde::Serialize))]
10#[cfg_attr(feature = "specta", derive(specta::Type))]
11pub struct UserAttributes {
12 pub username: String,
13 pub roles: Vec<UserRole>,
14 pub version: u32,
15}
16
17impl TypedAttributes for UserAttributes {
18 const TYPE_: mangadex_api_types::RelationshipType = RelationshipType::User;
19}