diff --git a/server.go b/server.go new file mode 100644 index 0000000..f4d7e5c --- /dev/null +++ b/server.go @@ -0,0 +1,32 @@ +package revoltgo + +// Server struct. +type Server struct { + Id string `json:"_id"` + Nonce string `json:"nonce"` + OwnerId string `json:"owner"` + Name string `json:"name"` + Description string `json:"description"` + ChannelIds []string `json:"channels"` + Categories []*ServerCategories `json:"categories"` + SystemMessages *SystemMessages `json:"system_messages"` + Roles map[string]interface{} `json:"roles"` + DefaultPermissions []interface{} `json:"default_permissions"` + Icon *Attachment `json:"icon"` + Banner *Attachment `json:"banner"` +} + +// Server categories struct. +type ServerCategories struct { + Id string `json:"id"` + Title string `json:"title"` + ChannelIds []string `json:"channels"` +} + +// System messages struct. +type SystemMessages struct { + UserJoined string `json:"user_joined"` + UserLeft string `json:"user_left"` + UserKicked string `json:"user_kicker"` + UserBanned string `json:"user_banned"` +}