Safe Haskell | None |
---|---|
Language | Haskell2010 |
Discord.Internal.Rest.Guild
Description
Provides actions for Channel API interactions
Synopsis
- data GuildRequest a where
- CreateGuild :: CreateGuildOpts -> GuildRequest Guild
- GetGuild :: GuildId -> GuildRequest Guild
- ModifyGuild :: GuildId -> ModifyGuildOpts -> GuildRequest Guild
- DeleteGuild :: GuildId -> GuildRequest ()
- GetGuildChannels :: GuildId -> GuildRequest [Channel]
- CreateGuildChannel :: GuildId -> Text -> [Overwrite] -> CreateGuildChannelOpts -> GuildRequest Channel
- ModifyGuildChannelPositions :: GuildId -> [(ChannelId, Int)] -> GuildRequest [Channel]
- GetGuildMember :: GuildId -> UserId -> GuildRequest GuildMember
- ListGuildMembers :: GuildId -> GuildMembersTiming -> GuildRequest [GuildMember]
- AddGuildMember :: GuildId -> UserId -> AddGuildMemberOpts -> GuildRequest ()
- ModifyGuildMember :: GuildId -> UserId -> ModifyGuildMemberOpts -> GuildRequest ()
- ModifyCurrentUserNick :: GuildId -> Text -> GuildRequest ()
- AddGuildMemberRole :: GuildId -> UserId -> RoleId -> GuildRequest ()
- RemoveGuildMemberRole :: GuildId -> UserId -> RoleId -> GuildRequest ()
- RemoveGuildMember :: GuildId -> UserId -> GuildRequest ()
- GetGuildBans :: GuildId -> GuildRequest [GuildBan]
- GetGuildBan :: GuildId -> UserId -> GuildRequest GuildBan
- CreateGuildBan :: GuildId -> UserId -> CreateGuildBanOpts -> GuildRequest ()
- RemoveGuildBan :: GuildId -> UserId -> GuildRequest ()
- GetGuildRoles :: GuildId -> GuildRequest [Role]
- CreateGuildRole :: GuildId -> ModifyGuildRoleOpts -> GuildRequest Role
- ModifyGuildRolePositions :: GuildId -> [(RoleId, Integer)] -> GuildRequest [Role]
- ModifyGuildRole :: GuildId -> RoleId -> ModifyGuildRoleOpts -> GuildRequest Role
- DeleteGuildRole :: GuildId -> RoleId -> GuildRequest ()
- GetGuildPruneCount :: GuildId -> Integer -> GuildRequest Object
- BeginGuildPrune :: GuildId -> Integer -> GuildRequest Object
- GetGuildVoiceRegions :: GuildId -> GuildRequest [VoiceRegion]
- GetGuildInvites :: GuildId -> GuildRequest [Invite]
- GetGuildIntegrations :: GuildId -> GuildRequest [Integration]
- CreateGuildIntegration :: GuildId -> IntegrationId -> CreateGuildIntegrationOpts -> GuildRequest ()
- ModifyGuildIntegration :: GuildId -> IntegrationId -> ModifyGuildIntegrationOpts -> GuildRequest ()
- DeleteGuildIntegration :: GuildId -> IntegrationId -> GuildRequest ()
- SyncGuildIntegration :: GuildId -> IntegrationId -> GuildRequest ()
- GetGuildEmbed :: GuildId -> GuildRequest GuildEmbed
- ModifyGuildEmbed :: GuildId -> GuildEmbed -> GuildRequest GuildEmbed
- GetGuildVanityURL :: GuildId -> GuildRequest Text
- data CreateGuildChannelOpts
- data CreateGuildOpts = CreateGuildOpts {}
- data ModifyGuildOpts = ModifyGuildOpts {}
- data AddGuildMemberOpts = AddGuildMemberOpts {}
- data ModifyGuildMemberOpts = ModifyGuildMemberOpts {}
- data GuildMembersTiming = GuildMembersTiming {}
- data CreateGuildBanOpts = CreateGuildBanOpts {}
- data ModifyGuildRoleOpts = ModifyGuildRoleOpts {}
- data CreateGuildIntegrationOpts = CreateGuildIntegrationOpts {}
- data ModifyGuildIntegrationOpts = ModifyGuildIntegrationOpts {}
Documentation
data GuildRequest a where Source #
Data constructor for requests. See API
Constructors
CreateGuild :: CreateGuildOpts -> GuildRequest Guild | |
GetGuild :: GuildId -> GuildRequest Guild | Returns the new |
ModifyGuild :: GuildId -> ModifyGuildOpts -> GuildRequest Guild | Modify a guild's settings. Returns the updated |
DeleteGuild :: GuildId -> GuildRequest () | Delete a guild permanently. User must be owner. Fires a Guild Delete |
GetGuildChannels :: GuildId -> GuildRequest [Channel] | Returns a list of guild |
CreateGuildChannel :: GuildId -> Text -> [Overwrite] -> CreateGuildChannelOpts -> GuildRequest Channel | Create a new |
ModifyGuildChannelPositions :: GuildId -> [(ChannelId, Int)] -> GuildRequest [Channel] | Modify the positions of a set of channel objects for the guild. Requires
|
GetGuildMember :: GuildId -> UserId -> GuildRequest GuildMember | Returns a guild |
ListGuildMembers :: GuildId -> GuildMembersTiming -> GuildRequest [GuildMember] | Returns a list of guild |
AddGuildMember :: GuildId -> UserId -> AddGuildMemberOpts -> GuildRequest () | Adds a user to the guild, provided you have a valid oauth2 access token
for the user with the guilds.join scope. Returns the guild |
ModifyGuildMember :: GuildId -> UserId -> ModifyGuildMemberOpts -> GuildRequest () | Modify attributes of a guild |
ModifyCurrentUserNick :: GuildId -> Text -> GuildRequest () | Modify the nickname of the current user |
AddGuildMemberRole :: GuildId -> UserId -> RoleId -> GuildRequest () | Add a member to a guild role. Requires |
RemoveGuildMemberRole :: GuildId -> UserId -> RoleId -> GuildRequest () | Remove a member from a guild role. Requires |
RemoveGuildMember :: GuildId -> UserId -> GuildRequest () | Remove a member from a guild. Requires |
GetGuildBans :: GuildId -> GuildRequest [GuildBan] | Returns a list of |
GetGuildBan :: GuildId -> UserId -> GuildRequest GuildBan | Returns a |
CreateGuildBan :: GuildId -> UserId -> CreateGuildBanOpts -> GuildRequest () | Create a guild ban, and optionally Delete previous messages sent by the banned
user. Requires the |
RemoveGuildBan :: GuildId -> UserId -> GuildRequest () | Remove the ban for a user. Requires the |
GetGuildRoles :: GuildId -> GuildRequest [Role] | Returns a list of |
CreateGuildRole :: GuildId -> ModifyGuildRoleOpts -> GuildRequest Role | Create a new |
ModifyGuildRolePositions :: GuildId -> [(RoleId, Integer)] -> GuildRequest [Role] | Modify the positions of a set of role objects for the guild. Requires the
|
ModifyGuildRole :: GuildId -> RoleId -> ModifyGuildRoleOpts -> GuildRequest Role | Modify a guild role. Requires the |
DeleteGuildRole :: GuildId -> RoleId -> GuildRequest () | Delete a guild role. Requires the |
GetGuildPruneCount :: GuildId -> Integer -> GuildRequest Object | Returns an object with one |
BeginGuildPrune :: GuildId -> Integer -> GuildRequest Object | Begin a prune operation. Requires the |
GetGuildVoiceRegions :: GuildId -> GuildRequest [VoiceRegion] | Returns a list of |
GetGuildInvites :: GuildId -> GuildRequest [Invite] | Returns a list of |
GetGuildIntegrations :: GuildId -> GuildRequest [Integration] | Return a list of |
CreateGuildIntegration :: GuildId -> IntegrationId -> CreateGuildIntegrationOpts -> GuildRequest () | Attach an |
ModifyGuildIntegration :: GuildId -> IntegrationId -> ModifyGuildIntegrationOpts -> GuildRequest () | Modify the behavior and settings of a |
DeleteGuildIntegration :: GuildId -> IntegrationId -> GuildRequest () | Delete the attached |
SyncGuildIntegration :: GuildId -> IntegrationId -> GuildRequest () | Sync an |
GetGuildEmbed :: GuildId -> GuildRequest GuildEmbed | Returns the |
ModifyGuildEmbed :: GuildId -> GuildEmbed -> GuildRequest GuildEmbed | Modify a |
GetGuildVanityURL :: GuildId -> GuildRequest Text | Vanity URL |
Instances
Request (GuildRequest a) Source # | |
Defined in Discord.Internal.Rest.Guild Methods majorRoute :: GuildRequest a -> String Source # jsonRequest :: GuildRequest a -> JsonRequest Source # |
data CreateGuildChannelOpts Source #
Instances
data CreateGuildOpts Source #
Constructors
CreateGuildOpts | |
Fields |
Instances
data ModifyGuildOpts Source #
Constructors
ModifyGuildOpts | |
Instances
data AddGuildMemberOpts Source #
Constructors
AddGuildMemberOpts | |
Instances
data ModifyGuildMemberOpts Source #
Constructors
ModifyGuildMemberOpts | |
Instances
data GuildMembersTiming Source #
Constructors
GuildMembersTiming | |
Fields |
data CreateGuildBanOpts Source #
Constructors
CreateGuildBanOpts | |
Instances
data ModifyGuildRoleOpts Source #
Constructors
ModifyGuildRoleOpts | |
Instances
data CreateGuildIntegrationOpts Source #
Constructors
CreateGuildIntegrationOpts | |
Fields |
Instances
data ModifyGuildIntegrationOpts Source #
Constructors
ModifyGuildIntegrationOpts | |