forked from jmug/stoatchat
27
crates/core/models/src/v0/channel_invites.rs
Normal file
27
crates/core/models/src/v0/channel_invites.rs
Normal file
@@ -0,0 +1,27 @@
|
||||
auto_derived!(
|
||||
/// Invite
|
||||
pub enum Invite {
|
||||
/// Invite to a specific server channel
|
||||
Server {
|
||||
/// Invite code
|
||||
#[cfg_attr(feature = "serde", serde(rename = "_id"))]
|
||||
code: String,
|
||||
/// Id of the server this invite points to
|
||||
server: String,
|
||||
/// Id of user who created this invite
|
||||
creator: String,
|
||||
/// Id of the server channel this invite points to
|
||||
channel: String,
|
||||
},
|
||||
/// Invite to a group channel
|
||||
Group {
|
||||
/// Invite code
|
||||
#[cfg_attr(feature = "serde", serde(rename = "_id"))]
|
||||
code: String,
|
||||
/// Id of user who created this invite
|
||||
creator: String,
|
||||
/// Id of the group channel this invite points to
|
||||
channel: String,
|
||||
},
|
||||
}
|
||||
);
|
||||
@@ -1,4 +1,5 @@
|
||||
mod bots;
|
||||
mod channel_invites;
|
||||
mod channel_webhooks;
|
||||
mod channels;
|
||||
mod files;
|
||||
@@ -7,6 +8,7 @@ mod servers;
|
||||
mod users;
|
||||
|
||||
pub use bots::*;
|
||||
pub use channel_invites::*;
|
||||
pub use channel_webhooks::*;
|
||||
pub use channels::*;
|
||||
pub use files::*;
|
||||
|
||||
Reference in New Issue
Block a user