Add GuildCreateSchema as per Spacebar Docs

This commit is contained in:
bitfl0wer 2023-05-13 22:11:06 +02:00
parent fe5beee228
commit 72a4d57aff
No known key found for this signature in database
GPG Key ID: 84BBB60DF895ABF2
1 changed files with 13 additions and 1 deletions

View File

@ -3,7 +3,7 @@ use serde::{Deserialize, Serialize};
use crate::errors::FieldFormatError;
use super::Embed;
use super::{Channel, Embed};
/**
A struct that represents a well-formed email address.
@ -287,6 +287,18 @@ impl MessageSendSchema {
}
}
#[derive(Debug, Deserialize, Serialize)]
#[serde(rename_all = "snake_case")]
pub struct GuildCreateSchema {
name: Option<String>,
region: Option<String>,
icon: Option<String>,
channels: Option<Vec<Channel>>,
guild_template_code: Option<String>,
system_channel_id: Option<String>,
rules_channel_id: Option<String>,
}
// I know that some of these tests are... really really basic and unneccessary, but sometimes, I
// just feel like writing tests, so there you go :) -@bitfl0wer
#[cfg(test)]