mirror of
https://github.com/stoatchat/stoatchat.git
synced 2026-07-14 13:36:59 +00:00
Finish implementing all routes.
This commit is contained in:
@@ -4,7 +4,10 @@ use serde::{ Deserialize, Serialize };
|
||||
pub struct Channel {
|
||||
#[serde(rename = "_id")]
|
||||
pub id: String,
|
||||
#[serde(rename = "type")]
|
||||
pub channel_type: u8,
|
||||
|
||||
pub last_message: Option<String>,
|
||||
|
||||
// for Direct Messages
|
||||
pub recipients: Option<Vec<String>>,
|
||||
|
||||
@@ -1,8 +1,13 @@
|
||||
|
||||
use serde::{ Deserialize, Serialize };
|
||||
use bson::{ UtcDateTime };
|
||||
|
||||
#[derive(Serialize, Deserialize, Debug)]
|
||||
pub struct Message {
|
||||
#[serde(rename = "_id")]
|
||||
pub id: String,
|
||||
pub id: String,
|
||||
pub channel: String,
|
||||
pub author: String,
|
||||
|
||||
pub content: String,
|
||||
pub edited: Option<UtcDateTime>,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user