aien-sovereign-core
Autonomous sovereign intelligence engine and runtime core for NVIDIA DGX Spark
Brought by drakestapleton
aien-sovereign-core / crates / spark-discord-hub / src / models.rs
| 1 | #[allow(dead_code)] |
| 2 | use serde::{Deserialize, Serialize}; |
| 3 | |
| 4 | #[derive(Debug, Clone, Deserialize)] |
| 5 | pub struct DiscordUser { |
| 6 | pub id: String, |
| 7 | pub username: String, |
| 8 | pub bot: Option<bool>, |
| 9 | } |
| 10 | |
| 11 | #[derive(Debug, Clone, Deserialize)] |
| 12 | pub struct DiscordMessage { |
| 13 | pub id: String, |
| 14 | pub channel_id: String, |
| 15 | pub content: String, |
| 16 | pub author: DiscordUser, |
| 17 | pub guild_id: Option<String>, |
| 18 | } |
| 19 | |
| 20 | #[derive(Debug, Clone, Serialize)] |
| 21 | pub struct CreateMessagePayload { |
| 22 | pub content: String, |
| 23 | #[serde(skip_serializing_if = "Option::is_none")] |
| 24 | pub message_reference: Option<MessageReference>, |
| 25 | } |
| 26 | |
| 27 | #[derive(Debug, Clone, Serialize)] |
| 28 | pub struct MessageReference { |
| 29 | pub message_id: String, |
| 30 | } |