structs.go 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. package discordgo
  2. // TODO: Eventually everything here gets moved to a better place.
  3. type Message struct {
  4. Id int `json:"id,string"`
  5. Author User `json:"author"`
  6. Content string `json:"content"`
  7. Attachments []Attachment `json:"attachments"`
  8. Tts bool `json:"tts"`
  9. Embeds []Embed `json:"embeds"`
  10. Timestamp string `json:"timestamp"`
  11. MentionEveryone bool `json:"mention_everyone"`
  12. EditedTimestamp string `json:"edited_timestamp"`
  13. Mentions []User `json:"mentions"`
  14. ChannelId int `json:"channel_id,string"`
  15. }
  16. type Attachment struct { //TODO figure this out
  17. }
  18. type Embed struct { // TODO figure this out
  19. }
  20. type VoiceRegion struct {
  21. Id string `json:"id"`
  22. Name string `json:"name"`
  23. SampleHostname string `json:"sample_hostname"`
  24. SamplePort int `json:"sample_port"`
  25. }
  26. type VoiceIce struct {
  27. Ttl int `json:"ttl,string"`
  28. Servers []IceServer `json:"servers"`
  29. }
  30. type IceServer struct {
  31. Url string `json:"url"`
  32. Username string `json:"username"`
  33. Credential string `json:"credential"`
  34. }
  35. type Invite struct {
  36. MaxAge int `json:"max_age"`
  37. Code string `json:"code"`
  38. Guild Guild `json:"guild"`
  39. Revoked bool `json:"revoked"`
  40. CreatedAt string `json:"created_at"` // TODO make timestamp
  41. Temporary bool `json:"temporary"`
  42. Uses int `json:"uses"`
  43. MaxUses int `json:"max_uses"`
  44. Inviter User `json:"inviter"`
  45. XkcdPass bool `json:"xkcdpass"`
  46. Channel Channel `json:"channel"`
  47. }