diff --git a/.gitignore b/.gitignore index 0d11c046d..dee8a5889 100644 --- a/.gitignore +++ b/.gitignore @@ -14,3 +14,4 @@ docs/deploy/deploy_key.pub # Miscellaneous .tmp/ .vscode/ +docs/docs.json diff --git a/docs/docs.json b/docs/docs.json deleted file mode 100644 index c2d86f22f..000000000 --- a/docs/docs.json +++ /dev/null @@ -1 +0,0 @@ -{"meta":{"version":13,"date":1477538681375},"classes":[{"id":"Client","name":"Client","description":"The starting point for making a Discord Bot.","meta":{"line":19,"file":"Client.js","path":"src/client"},"extends":["EventEmitter"],"classConstructor":{"id":"Client()","name":"Client","memberof":"Client","params":[{"name":"options","description":"Options for the client","optional":true,"type":{"types":[[["ClientOptions",""]]]}}]},"methods":[{"id":"Client#login","name":"login","description":"Logs the client in. If successful, resolves with the account's token. If you're making a bot, it's\rmuch better to use a bot account rather than a user account.\rBot accounts have higher rate limits and have access to some features user accounts don't have. User bots\rthat are making a lot of API requests can even be banned.","memberof":"Client","examples":["// log the client in using a token\rconst token = 'my token';\rclient.login(token);","// log the client in using email and password\rconst email = 'user@email.com';\rconst password = 'supersecret123';\rclient.login(email, password);"],"meta":{"line":227,"file":"Client.js","path":"src/client"},"returns":{"types":[[["Promise",".<"],["string",">"]]]},"params":[{"name":"tokenOrEmail","description":"The token or email used for the account. If it is an email, a password _must_ be\rprovided.","type":{"types":[[["string",""]]]}},{"name":"password","description":"The password for the account, only needed if an email was provided.","optional":true,"type":{"types":[[["string",""]]]}}]},{"id":"Client#destroy","name":"destroy","description":"Destroys the client and logs out.","memberof":"Client","meta":{"line":236,"file":"Client.js","path":"src/client"},"returns":{"types":[[["Promise",""]]]},"params":[]},{"id":"Client#syncGuilds","name":"syncGuilds","description":"This shouldn't really be necessary to most developers as it is automatically invoked every 30 seconds, however\rif you wish to force a sync of Guild data, you can use this. Only applicable to user accounts.","memberof":"Client","meta":{"line":252,"file":"Client.js","path":"src/client"},"returns":{"types":[[["null",""]]]},"params":[{"name":"guilds","description":"An array or collection of guilds to sync","optional":true,"type":{"types":[[["Array",".<"],["Guild",">"]],[["Collection",".<"],["string",", "],["Guild",">"]]]}}]},{"id":"Client#fetchUser","name":"fetchUser","description":"Caches a user, or obtains it from the cache if it's already cached.\rIf the user isn't already cached, it will only be obtainable by OAuth bot accounts.","memberof":"Client","meta":{"line":267,"file":"Client.js","path":"src/client"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[{"name":"id","description":"The ID of the user to obtain","type":{"types":[[["string",""]]]}}]},{"id":"Client#fetchInvite","name":"fetchInvite","description":"Fetches an invite object from an invite code.","memberof":"Client","meta":{"line":277,"file":"Client.js","path":"src/client"},"returns":{"types":[[["Promise",".<"],["Invite",">"]]]},"params":[{"name":"invite","description":"An invite code or URL","type":{"types":[[["InviteResolvable",""]]]}}]},{"id":"Client#fetchWebhook","name":"fetchWebhook","description":"Fetch a webhook by ID.","memberof":"Client","meta":{"line":287,"file":"Client.js","path":"src/client"},"returns":{"types":[[["Promise",".<"],["Webhook",">"]]]},"params":[{"name":"id","description":"ID of the webhook","type":{"types":[[["string",""]]]}}]},{"id":"Client#sweepMessages","name":"sweepMessages","description":"Sweeps all channels' messages and removes the ones older than the max message lifetime.\rIf the message has been edited, the time of the edit is used rather than the time of the original message.","memberof":"Client","meta":{"line":299,"file":"Client.js","path":"src/client"},"returns":{"types":[[["number",""]]]},"params":[{"name":"lifetime","description":"Messages that are older than this (in seconds)\rwill be removed from the caches. The default is based on the client's `messageCacheLifetime` option.","optional":true,"type":{"types":[[["number",""]]]}}]}],"properties":[{"id":"Client#options","name":"options","description":"The options the client was instantiated with","memberof":"Client","type":{"types":[[["ClientOptions",""]]]},"meta":{"line":34,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#rest","name":"rest","description":"The REST manager of the client","memberof":"Client","type":{"types":[[["RESTManager",""]]]},"access":"private","meta":{"line":42,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#dataManager","name":"dataManager","description":"The data manager of the Client","memberof":"Client","type":{"types":[[["ClientDataManager",""]]]},"access":"private","meta":{"line":49,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#manager","name":"manager","description":"The manager of the Client","memberof":"Client","type":{"types":[[["ClientManager",""]]]},"access":"private","meta":{"line":56,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#ws","name":"ws","description":"The WebSocket Manager of the Client","memberof":"Client","type":{"types":[[["WebSocketManager",""]]]},"access":"private","meta":{"line":63,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#resolver","name":"resolver","description":"The Data Resolver of the Client","memberof":"Client","type":{"types":[[["ClientDataResolver",""]]]},"access":"private","meta":{"line":70,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#actions","name":"actions","description":"The Action Manager of the Client","memberof":"Client","type":{"types":[[["ActionsManager",""]]]},"access":"private","meta":{"line":77,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#voice","name":"voice","description":"The Voice Manager of the Client","memberof":"Client","type":{"types":[[["ClientVoiceManager",""]]]},"access":"private","meta":{"line":84,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#shard","name":"shard","description":"The shard helpers for the client (only if the process was spawned as a child, such as from a ShardingManager)","memberof":"Client","type":{"types":[[["ShardUtil",""]]]},"meta":{"line":90,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#users","name":"users","description":"A Collection of the Client's stored users","memberof":"Client","type":{"types":[[["Collection",".<"],["string",", "],["User",">"]]]},"meta":{"line":96,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#guilds","name":"guilds","description":"A Collection of the Client's stored guilds","memberof":"Client","type":{"types":[[["Collection",".<"],["string",", "],["Guild",">"]]]},"meta":{"line":102,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#channels","name":"channels","description":"A Collection of the Client's stored channels","memberof":"Client","type":{"types":[[["Collection",".<"],["string",", "],["Channel",">"]]]},"meta":{"line":108,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#presences","name":"presences","description":"A Collection of presences for friends of the logged in user.\rThis is only present for user accounts, not bot accounts!","memberof":"Client","type":{"types":[[["Collection",".<"],["string",", "],["Presence",">"]]]},"meta":{"line":115,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#token","name":"token","description":"The authorization token for the logged in user/bot.","memberof":"Client","type":{"types":[[["string",""]]]},"meta":{"line":122,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#email","name":"email","description":"The email, if there is one, for the logged in Client","memberof":"Client","type":{"types":[[["string",""]]]},"meta":{"line":131,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#password","name":"password","description":"The password, if there is one, for the logged in Client","memberof":"Client","type":{"types":[[["string",""]]]},"meta":{"line":137,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#user","name":"user","description":"The ClientUser representing the logged in Client","memberof":"Client","type":{"types":[[["ClientUser",""]]]},"meta":{"line":143,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#readyAt","name":"readyAt","description":"The date at which the Client was regarded as being in the `READY` state.","memberof":"Client","type":{"types":[[["Date",""]]]},"meta":{"line":149,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#status","name":"status","description":"The status for the logged in Client.","memberof":"Client","type":{"types":[[["number",""]]]},"meta":{"line":164,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#uptime","name":"uptime","description":"The uptime for the logged in Client.","memberof":"Client","type":{"types":[[["number",""]]]},"meta":{"line":173,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#voiceConnections","name":"voiceConnections","description":"Returns a Collection, mapping Guild ID to Voice Connections.","memberof":"Client","type":{"types":[[["Collection",".<"],["string",", "],["VoiceConnection",">"]]]},"meta":{"line":182,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#emojis","name":"emojis","description":"The emojis that the client can use. Mapped by emoji ID.","memberof":"Client","type":{"types":[[["Collection",".<"],["string",", "],["Emoji",">"]]]},"meta":{"line":191,"file":"Client.js","path":"src/client"},"props":[]},{"id":"Client#readyTimestamp","name":"readyTimestamp","description":"The timestamp that the client was last ready at","memberof":"Client","type":{"types":[[["number",""]]]},"meta":{"line":204,"file":"Client.js","path":"src/client"},"props":[]}],"events":[{"id":"Client#event:channelUpdate","name":"channelUpdate","description":"Emitted whenever a channel is updated - e.g. name change, topic change.","memberof":"Client","meta":{"line":27,"file":"ChannelUpdate.js","path":"src/client/actions"},"params":[{"name":"oldChannel","description":"The channel before the update","type":{"types":[[["Channel",""]]]}},{"name":"newChannel","description":"The channel after the update","type":{"types":[[["Channel",""]]]}}]},{"id":"Client#event:guildUnavailable","name":"guildUnavailable","description":"Emitted whenever a guild becomes unavailable, likely due to a server outage.","memberof":"Client","meta":{"line":45,"file":"GuildDelete.js","path":"src/client/actions"},"params":[{"name":"guild","description":"The guild that has become unavailable.","type":{"types":[[["Guild",""]]]}}]},{"id":"Client#event:guildEmojiCreate","name":"guildEmojiCreate","description":"Emitted whenever an emoji is created","memberof":"Client","meta":{"line":13,"file":"GuildEmojiCreate.js","path":"src/client/actions"},"params":[{"name":"emoji","description":"The emoji that was created.","type":{"types":[[["Emoji",""]]]}}]},{"id":"Client#event:guildEmojiDelete","name":"guildEmojiDelete","description":"Emitted whenever an emoji is deleted","memberof":"Client","meta":{"line":13,"file":"GuildEmojiDelete.js","path":"src/client/actions"},"params":[{"name":"emoji","description":"The emoji that was deleted.","type":{"types":[[["Emoji",""]]]}}]},{"id":"Client#event:guildEmojiUpdate","name":"guildEmojiUpdate","description":"Emitted whenever an emoji is updated","memberof":"Client","meta":{"line":23,"file":"GuildEmojiUpdate.js","path":"src/client/actions"},"params":[{"name":"oldEmoji","description":"The old emoji","type":{"types":[[["Emoji",""]]]}},{"name":"newEmoji","description":"The new emoji","type":{"types":[[["Emoji",""]]]}}]},{"id":"Client#event:guildMemberRemove","name":"guildMemberRemove","description":"Emitted whenever a member leaves a guild, or is kicked.","memberof":"Client","meta":{"line":43,"file":"GuildMemberRemove.js","path":"src/client/actions"},"params":[{"name":"member","description":"The member that has left/been kicked from the guild.","type":{"types":[[["GuildMember",""]]]}}]},{"id":"Client#event:roleCreate","name":"roleCreate","description":"Emitted whenever a role is created.","memberof":"Client","meta":{"line":26,"file":"GuildRoleCreate.js","path":"src/client/actions"},"params":[{"name":"role","description":"The role that was created.","type":{"types":[[["Role",""]]]}}]},{"id":"Client#event:roleDelete","name":"roleDelete","description":"Emitted whenever a guild role is deleted.","memberof":"Client","meta":{"line":40,"file":"GuildRoleDelete.js","path":"src/client/actions"},"params":[{"name":"role","description":"The role that was deleted.","type":{"types":[[["Role",""]]]}}]},{"id":"Client#event:roleUpdate","name":"roleUpdate","description":"Emitted whenever a guild role is updated.","memberof":"Client","meta":{"line":34,"file":"GuildRoleUpdate.js","path":"src/client/actions"},"params":[{"name":"oldRole","description":"The role before the update.","type":{"types":[[["Role",""]]]}},{"name":"newRole","description":"The role after the update.","type":{"types":[[["Role",""]]]}}]},{"id":"Client#event:guildUpdate","name":"guildUpdate","description":"Emitted whenever a guild is updated - e.g. name change.","memberof":"Client","meta":{"line":27,"file":"GuildUpdate.js","path":"src/client/actions"},"params":[{"name":"oldGuild","description":"The guild before the update.","type":{"types":[[["Guild",""]]]}},{"name":"newGuild","description":"The guild after the update.","type":{"types":[[["Guild",""]]]}}]},{"id":"Client#event:messageUpdate","name":"messageUpdate","description":"Emitted whenever a message is updated - e.g. embed or content change.","memberof":"Client","meta":{"line":36,"file":"MessageUpdate.js","path":"src/client/actions"},"params":[{"name":"oldMessage","description":"The message before the update.","type":{"types":[[["Message",""]]]}},{"name":"newMessage","description":"The message after the update.","type":{"types":[[["Message",""]]]}}]},{"id":"Client#event:warn","name":"warn","description":"Emitted for general warnings","memberof":"Client","meta":{"line":400,"file":"Client.js","path":"src/client"},"params":[{"name":"The","description":"warning","type":{"types":[[["string",""]]]}}]},{"id":"Client#event:debug","name":"debug","description":"Emitted for general debugging information","memberof":"Client","meta":{"line":406,"file":"Client.js","path":"src/client"},"params":[{"name":"The","description":"debug information","type":{"types":[[["string",""]]]}}]},{"id":"Client#event:guildCreate","name":"guildCreate","description":"Emitted whenever the client joins a Guild.","memberof":"Client","meta":{"line":26,"file":"ClientDataManager.js","path":"src/client"},"params":[{"name":"guild","description":"The created guild","type":{"types":[[["Guild",""]]]}}]},{"id":"Client#event:channelCreate","name":"channelCreate","description":"Emitted whenever a Channel is created.","memberof":"Client","meta":{"line":11,"file":"ChannelCreate.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"channel","description":"The channel that was created","type":{"types":[[["Channel",""]]]}}]},{"id":"Client#event:channelDelete","name":"channelDelete","description":"Emitted whenever a Channel is deleted.","memberof":"Client","meta":{"line":14,"file":"ChannelDelete.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"channel","description":"The channel that was deleted","type":{"types":[[["Channel",""]]]}}]},{"id":"Client#event:channelPinsUpdate","name":"channelPinsUpdate","description":"Emitted whenever the pins of a Channel are updated. Due to the nature of the WebSocket event, not much information\rcan be provided easily here - you need to manually check the pins yourself.","memberof":"Client","meta":{"line":23,"file":"ChannelPinsUpdate.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"channel","description":"The channel that the pins update occured in","type":{"types":[[["Channel",""]]]}},{"name":"time","description":"The time of the pins update","type":{"types":[[["Date",""]]]}}]},{"id":"Client#event:guildBanAdd","name":"guildBanAdd","description":"Emitted whenever a member is banned from a guild.","memberof":"Client","meta":{"line":16,"file":"GuildBanAdd.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"guild","description":"The guild that the ban occurred in","type":{"types":[[["Guild",""]]]}},{"name":"user","description":"The user that was banned","type":{"types":[[["User",""]]]}}]},{"id":"Client#event:guildBanRemove","name":"guildBanRemove","description":"Emitted whenever a member is unbanned from a guild.","memberof":"Client","meta":{"line":13,"file":"GuildBanRemove.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"guild","description":"The guild that the unban occurred in","type":{"types":[[["Guild",""]]]}},{"name":"user","description":"The user that was unbanned","type":{"types":[[["User",""]]]}}]},{"id":"Client#event:guildDelete","name":"guildDelete","description":"Emitted whenever a Guild is deleted/left.","memberof":"Client","meta":{"line":13,"file":"GuildDelete.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"guild","description":"The guild that was deleted","type":{"types":[[["Guild",""]]]}}]},{"id":"Client#event:guildMembersChunk","name":"guildMembersChunk","description":"Emitted whenever a chunk of Guild members is received (all members come from the same guild)","memberof":"Client","meta":{"line":22,"file":"GuildMembersChunk.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"members","description":"The members in the chunk","type":{"types":[[["Array",".<"],["GuildMember",">"]]]}}]},{"id":"Client#event:message","name":"message","description":"Emitted whenever a message is created","memberof":"Client","meta":{"line":13,"file":"MessageCreate.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"message","description":"The created message","type":{"types":[[["Message",""]]]}}]},{"id":"Client#event:messageDelete","name":"messageDelete","description":"Emitted whenever a message is deleted","memberof":"Client","meta":{"line":13,"file":"MessageDelete.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"message","description":"The deleted message","type":{"types":[[["Message",""]]]}}]},{"id":"Client#event:messageDeleteBulk","name":"messageDeleteBulk","description":"Emitted whenever messages are deleted in bulk","memberof":"Client","meta":{"line":11,"file":"MessageDeleteBulk.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"messages","description":"The deleted messages, mapped by their ID","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]]]}}]},{"id":"Client#event:presenceUpdate","name":"presenceUpdate","description":"Emitted whenever a guild member's presence changes, or they change one of their details.","memberof":"Client","meta":{"line":52,"file":"PresenceUpdate.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"oldMember","description":"The member before the presence update","type":{"types":[[["GuildMember",""]]]}},{"name":"newMember","description":"The member after the presence update","type":{"types":[[["GuildMember",""]]]}}]},{"id":"Client#event:userUpdate","name":"userUpdate","description":"Emitted whenever a user's details (e.g. username) are changed.","memberof":"Client","meta":{"line":59,"file":"PresenceUpdate.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"oldUser","description":"The user before the update","type":{"types":[[["User",""]]]}},{"name":"newUser","description":"The user after the update","type":{"types":[[["User",""]]]}}]},{"id":"Client#event:guildMemberAvailable","name":"guildMemberAvailable","description":"Emitted whenever a member becomes available in a large Guild","memberof":"Client","meta":{"line":66,"file":"PresenceUpdate.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"member","description":"The member that became available","type":{"types":[[["GuildMember",""]]]}}]},{"id":"Client#event:typingStart","name":"typingStart","description":"Emitted whenever a user starts typing in a channel","memberof":"Client","meta":{"line":54,"file":"TypingStart.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"channel","description":"The channel the user started typing in","type":{"types":[[["Channel",""]]]}},{"name":"user","description":"The user that started typing","type":{"types":[[["User",""]]]}}]},{"id":"Client#event:typingStop","name":"typingStop","description":"Emitted whenever a user stops typing in a channel","memberof":"Client","meta":{"line":61,"file":"TypingStart.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"channel","description":"The channel the user stopped typing in","type":{"types":[[["Channel",""]]]}},{"name":"user","description":"The user that stopped typing","type":{"types":[[["User",""]]]}}]},{"id":"Client#event:voiceStateUpdate","name":"voiceStateUpdate","description":"Emitted whenever a user changes voice state - e.g. joins/leaves a channel, mutes/unmutes.","memberof":"Client","meta":{"line":42,"file":"VoiceStateUpdate.js","path":"src/client/websocket/packets/handlers"},"params":[{"name":"oldMember","description":"The member before the voice state update","type":{"types":[[["GuildMember",""]]]}},{"name":"newMember","description":"The member after the voice state update","type":{"types":[[["GuildMember",""]]]}}]},{"id":"Client#event:disconnect","name":"disconnect","description":"Emitted whenever the client websocket is disconnected","memberof":"Client","meta":{"line":196,"file":"WebSocketManager.js","path":"src/client/websocket"},"params":[]},{"id":"Client#event:error","name":"error","description":"Emitted whenever the Client encounters a serious connection error","memberof":"Client","meta":{"line":233,"file":"WebSocketManager.js","path":"src/client/websocket"},"params":[{"name":"error","description":"The encountered error","type":{"types":[[["Error",""]]]}}]},{"id":"Client#event:ready","name":"ready","description":"Emitted when the Client becomes ready to start working","memberof":"Client","meta":{"line":243,"file":"WebSocketManager.js","path":"src/client/websocket"},"params":[]},{"id":"Client#event:reconnecting","name":"reconnecting","description":"Emitted when the Client tries to reconnect after being disconnected","memberof":"Client","meta":{"line":286,"file":"WebSocketManager.js","path":"src/client/websocket"},"params":[]},{"id":"Client#event:guildMemberAdd","name":"guildMemberAdd","description":"Emitted whenever a user joins a guild.","memberof":"Client","meta":{"line":726,"file":"Guild.js","path":"src/structures"},"params":[{"name":"member","description":"The member that has joined a guild","type":{"types":[[["GuildMember",""]]]}}]},{"id":"Client#event:guildMemberUpdate","name":"guildMemberUpdate","description":"Emitted whenever a Guild Member changes - i.e. new role, removed role, nickname","memberof":"Client","meta":{"line":748,"file":"Guild.js","path":"src/structures"},"params":[{"name":"oldMember","description":"The member before the update","type":{"types":[[["GuildMember",""]]]}},{"name":"newMember","description":"The member after the update","type":{"types":[[["GuildMember",""]]]}}]},{"id":"Client#event:guildMemberSpeaking","name":"guildMemberSpeaking","description":"Emitted once a Guild Member starts/stops speaking","memberof":"Client","meta":{"line":772,"file":"Guild.js","path":"src/structures"},"params":[{"name":"member","description":"The member that started/stopped speaking","type":{"types":[[["GuildMember",""]]]}},{"name":"speaking","description":"Whether or not the member is speaking","type":{"types":[[["boolean",""]]]}}]}]},{"id":"ClientDataResolver","name":"ClientDataResolver","description":"The DataResolver identifies different objects and tries to resolve a specific piece of information from them, e.g.\rextracting a User from a Message object.","meta":{"line":17,"file":"ClientDataResolver.js","path":"src/client"},"access":"private","classConstructor":{"id":"ClientDataResolver()","name":"ClientDataResolver","memberof":"ClientDataResolver","params":[{"name":"client","description":"The client the resolver is for","type":{"types":[[["Client",""]]]}}]},"methods":[{"id":"ClientDataResolver#resolveUser","name":"resolveUser","description":"Resolves a UserResolvable to a User object","memberof":"ClientDataResolver","meta":{"line":40,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["User",""]]]},"params":[{"name":"user","description":"The UserResolvable to identify","type":{"types":[[["UserResolvable",""]]]}}]},{"id":"ClientDataResolver#resolveUserID","name":"resolveUserID","description":"Resolves a UserResolvable to a user ID string","memberof":"ClientDataResolver","meta":{"line":54,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["string",""]]]},"params":[{"name":"user","description":"The UserResolvable to identify","type":{"types":[[["UserResolvable",""]]]}}]},{"id":"ClientDataResolver#resolveGuild","name":"resolveGuild","description":"Resolves a GuildResolvable to a Guild object","memberof":"ClientDataResolver","meta":{"line":73,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["Guild",""]]]},"params":[{"name":"guild","description":"The GuildResolvable to identify","type":{"types":[[["GuildResolvable",""]]]}}]},{"id":"ClientDataResolver#resolveGuildMember","name":"resolveGuildMember","description":"Resolves a GuildMemberResolvable to a GuildMember object","memberof":"ClientDataResolver","meta":{"line":92,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["GuildMember",""]]]},"params":[{"name":"guild","description":"The guild that the member is part of","type":{"types":[[["GuildResolvable",""]]]}},{"name":"user","description":"The user that is part of the guild","type":{"types":[[["UserResolvable",""]]]}}]},{"id":"ClientDataResolver#resolveChannel","name":"resolveChannel","description":"Resolves a ChannelResolvable to a Channel object","memberof":"ClientDataResolver","meta":{"line":116,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["Channel",""]]]},"params":[{"name":"channel","description":"The channel resolvable to resolve","type":{"types":[[["ChannelResolvable",""]]]}}]},{"id":"ClientDataResolver#resolveInviteCode","name":"resolveInviteCode","description":"Resolves InviteResolvable to an invite code","memberof":"ClientDataResolver","meta":{"line":136,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["string",""]]]},"params":[{"name":"data","description":"The invite resolvable to resolve","type":{"types":[[["InviteResolvable",""]]]}}]},{"id":"ClientDataResolver#resolvePermission","name":"resolvePermission","description":"Resolves a PermissionResolvable to a permission number","memberof":"ClientDataResolver","meta":{"line":186,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["number",""]]]},"params":[{"name":"permission","description":"The permission resolvable to resolve","type":{"types":[[["PermissionResolvable",""]]]}}]},{"id":"ClientDataResolver#resolveString","name":"resolveString","description":"Resolves a StringResolvable to a string","memberof":"ClientDataResolver","meta":{"line":205,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["string",""]]]},"params":[{"name":"data","description":"The string resolvable to resolve","type":{"types":[[["StringResolvable",""]]]}}]},{"id":"ClientDataResolver#resolveBase64","name":"resolveBase64","description":"Resolves a Base64Resolvable to a Base 64 image","memberof":"ClientDataResolver","meta":{"line":223,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["string",""]]]},"params":[{"name":"data","description":"The base 64 resolvable you want to resolve","type":{"types":[[["Base64Resolvable",""]]]}}]},{"id":"ClientDataResolver#resolveFile","name":"resolveFile","description":"Resolves a FileResolvable to a Buffer","memberof":"ClientDataResolver","meta":{"line":241,"file":"ClientDataResolver.js","path":"src/client"},"returns":{"types":[[["Promise",".<"],["Buffer",">"]]]},"params":[{"name":"resource","description":"The file resolvable to resolve","type":{"types":[[["FileResolvable",""]]]}}]}],"properties":[],"events":[]},{"id":"ClientManager","name":"ClientManager","description":"Manages the State and Background Tasks of the Client","meta":{"line":7,"file":"ClientManager.js","path":"src/client"},"access":"private","methods":[{"id":"ClientManager#connectToWebSocket","name":"connectToWebSocket","description":"Connects the Client to the WebSocket","memberof":"ClientManager","meta":{"line":28,"file":"ClientManager.js","path":"src/client"},"returns":{"types":[[["null",""]]]},"params":[{"name":"token","description":"The authorization token","type":{"types":[[["string",""]]]}},{"name":"resolve","description":"Function to run when connection is successful","type":{"types":[[["function",""]]]}},{"name":"reject","description":"Function to run when connection fails","type":{"types":[[["function",""]]]}}]},{"id":"ClientManager#setupKeepAlive","name":"setupKeepAlive","description":"Sets up a keep-alive interval to keep the Client's connection valid","memberof":"ClientManager","meta":{"line":50,"file":"ClientManager.js","path":"src/client"},"returns":{"types":[[["null",""]]]},"params":[{"name":"time","description":"The interval in milliseconds at which heartbeat packets should be sent","type":{"types":[[["number",""]]]}}]}],"properties":[{"id":"ClientManager#client","name":"client","description":"The Client that instantiated this Manager","memberof":"ClientManager","type":{"types":[[["Client",""]]]},"meta":{"line":13,"file":"ClientManager.js","path":"src/client"},"props":[]},{"id":"ClientManager#heartbeatInterval","name":"heartbeatInterval","description":"The heartbeat interval, null if not yet set","memberof":"ClientManager","type":{"types":[[["number",""]]]},"meta":{"line":19,"file":"ClientManager.js","path":"src/client"},"props":[]}],"events":[]},{"id":"RequestHandler","name":"RequestHandler","description":"A base class for different types of rate limiting handlers for the REST API.","meta":{"line":5,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"access":"private","classConstructor":{"id":"RequestHandler()","name":"RequestHandler","memberof":"RequestHandler","params":[{"name":"restManager","description":"The REST manager to use","type":{"types":[[["RESTManager",""]]]}}]},"methods":[{"id":"RequestHandler#push","name":"push","description":"Push a new API request into this bucket","memberof":"RequestHandler","meta":{"line":39,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"returns":{"types":[[["null",""]]]},"params":[{"name":"request","description":"The new request to push into the queue","type":{"types":[[["APIRequest",""]]]}}]},{"id":"RequestHandler#handle","name":"handle","description":"Attempts to get this RequestHandler to process its current queue","memberof":"RequestHandler","meta":{"line":46,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"returns":{"types":[[["null",""]]]},"params":[]}],"properties":[{"id":"RequestHandler#restManager","name":"restManager","description":"The RESTManager that instantiated this RequestHandler","memberof":"RequestHandler","type":{"types":[[["RESTManager",""]]]},"meta":{"line":14,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"props":[]},{"id":"RequestHandler#queue","name":"queue","description":"A list of requests that have yet to be processed.","memberof":"RequestHandler","type":{"types":[[["Array",".<"],["APIRequest",">"]]]},"meta":{"line":20,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"props":[]},{"id":"RequestHandler#globalLimit","name":"globalLimit","description":"Whether or not the client is being rate limited on every endpoint.","memberof":"RequestHandler","type":{"types":[[["boolean",""]]]},"meta":{"line":27,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"props":[]}],"events":[]},{"id":"SequentialRequestHandler","name":"SequentialRequestHandler","description":"Handles API Requests sequentially, i.e. we wait until the current request is finished before moving onto\rthe next. This plays a _lot_ nicer in terms of avoiding 429's when there is more than one session of the account,\rbut it can be slower.","meta":{"line":10,"file":"Sequential.js","path":"src/client/rest/RequestHandlers"},"extends":["RequestHandler"],"access":"private","classConstructor":{"id":"SequentialRequestHandler()","name":"SequentialRequestHandler","memberof":"SequentialRequestHandler","params":[{"name":"restManager","description":"The REST manager to use","type":{"types":[[["RESTManager",""]]]}},{"name":"endpoint","description":"The endpoint to handle","type":{"types":[[["string",""]]]}}]},"methods":[{"id":"SequentialRequestHandler#execute","name":"execute","description":"Performs a request then resolves a promise to indicate its readiness for a new request","memberof":"SequentialRequestHandler","meta":{"line":48,"file":"Sequential.js","path":"src/client/rest/RequestHandlers"},"returns":{"types":[[["Promise",".<(?"],["Object","|"],["Error",")>"]]]},"params":[{"name":"item","description":"The item to execute","type":{"types":[[["APIRequest",""]]]}}]},{"id":"SequentialRequestHandler#push","name":"push","description":"Push a new API request into this bucket","memberof":"SequentialRequestHandler","inherits":"RequestHandler#push","inherited":true,"meta":{"line":39,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"returns":{"types":[[["null",""]]]},"params":[{"name":"request","description":"The new request to push into the queue","type":{"types":[[["APIRequest",""]]]}}]},{"id":"SequentialRequestHandler#handle","name":"handle","description":"Attempts to get this RequestHandler to process its current queue","memberof":"SequentialRequestHandler","inherits":"RequestHandler#handle","inherited":true,"meta":{"line":46,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"returns":{"types":[[["null",""]]]},"params":[]}],"properties":[{"id":"SequentialRequestHandler#waiting","name":"waiting","description":"Whether this rate limiter is waiting for a response from a request","memberof":"SequentialRequestHandler","type":{"types":[[["boolean",""]]]},"meta":{"line":22,"file":"Sequential.js","path":"src/client/rest/RequestHandlers"},"props":[]},{"id":"SequentialRequestHandler#endpoint","name":"endpoint","description":"The endpoint that this handler is handling","memberof":"SequentialRequestHandler","type":{"types":[[["string",""]]]},"meta":{"line":28,"file":"Sequential.js","path":"src/client/rest/RequestHandlers"},"props":[]},{"id":"SequentialRequestHandler#timeDifference","name":"timeDifference","description":"The time difference between Discord's Dates and the local computer's Dates. A positive number means the local\rcomputer's time is ahead of Discord's.","memberof":"SequentialRequestHandler","type":{"types":[[["number",""]]]},"meta":{"line":35,"file":"Sequential.js","path":"src/client/rest/RequestHandlers"},"props":[]},{"id":"SequentialRequestHandler#restManager","name":"restManager","description":"The RESTManager that instantiated this RequestHandler","memberof":"SequentialRequestHandler","type":{"types":[[["RESTManager",""]]]},"meta":{"line":14,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"props":[]},{"id":"SequentialRequestHandler#queue","name":"queue","description":"A list of requests that have yet to be processed.","memberof":"SequentialRequestHandler","type":{"types":[[["Array",".<"],["APIRequest",">"]]]},"meta":{"line":20,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"props":[]},{"id":"SequentialRequestHandler#globalLimit","name":"globalLimit","description":"Whether or not the client is being rate limited on every endpoint.","memberof":"SequentialRequestHandler","type":{"types":[[["boolean",""]]]},"meta":{"line":27,"file":"RequestHandler.js","path":"src/client/rest/RequestHandlers"},"props":[]}],"events":[]},{"id":"ClientVoiceManager","name":"ClientVoiceManager","description":"Manages all the voice stuff for the Client","meta":{"line":11,"file":"ClientVoiceManager.js","path":"src/client/voice"},"access":"private","methods":[{"id":"ClientVoiceManager#sendVoiceStateUpdate","name":"sendVoiceStateUpdate","description":"Sends a request to the main gateway to join a voice channel","memberof":"ClientVoiceManager","meta":{"line":48,"file":"ClientVoiceManager.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[{"name":"channel","description":"The channel to join","type":{"types":[[["VoiceChannel",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["Object",""]]]}}]},{"id":"ClientVoiceManager#joinChannel","name":"joinChannel","description":"Sets up a request to join a voice channel","memberof":"ClientVoiceManager","meta":{"line":79,"file":"ClientVoiceManager.js","path":"src/client/voice"},"returns":{"types":[[["Promise",".<"],["VoiceConnection",">"]]]},"params":[{"name":"channel","description":"The voice channel to join","type":{"types":[[["VoiceChannel",""]]]}}]}],"properties":[{"id":"ClientVoiceManager#client","name":"client","description":"The client that instantiated this voice manager","memberof":"ClientVoiceManager","type":{"types":[[["Client",""]]]},"meta":{"line":17,"file":"ClientVoiceManager.js","path":"src/client/voice"},"props":[]},{"id":"ClientVoiceManager#connections","name":"connections","description":"A collection mapping connection IDs to the Connection objects","memberof":"ClientVoiceManager","type":{"types":[[["Collection",".<"],["string",", "],["VoiceConnection",">"]]]},"meta":{"line":23,"file":"ClientVoiceManager.js","path":"src/client/voice"},"props":[]},{"id":"ClientVoiceManager#pending","name":"pending","description":"Pending connection attempts, maps Guild ID to VoiceChannel","memberof":"ClientVoiceManager","type":{"types":[[["Collection",".<"],["string",", "],["VoiceChannel",">"]]]},"meta":{"line":29,"file":"ClientVoiceManager.js","path":"src/client/voice"},"props":[]}],"events":[]},{"id":"PendingVoiceConnection","name":"PendingVoiceConnection","description":"Represents a Pending Voice Connection","meta":{"line":120,"file":"ClientVoiceManager.js","path":"src/client/voice"},"access":"private","methods":[{"id":"PendingVoiceConnection#setTokenAndEndpoint","name":"setTokenAndEndpoint","description":"Set the token and endpoint required to connect to the the voice servers","memberof":"PendingVoiceConnection","meta":{"line":167,"file":"ClientVoiceManager.js","path":"src/client/voice"},"returns":{"types":[[["void",""]]]},"params":[{"name":"token","description":"the token","type":{"types":[[["string",""]]]}},{"name":"endpoint","description":"the endpoint","type":{"types":[[["string",""]]]}}]},{"id":"PendingVoiceConnection#setSessionID","name":"setSessionID","description":"Sets the Session ID for the connection","memberof":"PendingVoiceConnection","meta":{"line":202,"file":"ClientVoiceManager.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[{"name":"sessionID","description":"the session ID","type":{"types":[[["string",""]]]}}]},{"id":"PendingVoiceConnection#upgrade","name":"upgrade","description":"Upgrades this Pending Connection to a full Voice Connection","memberof":"PendingVoiceConnection","meta":{"line":243,"file":"ClientVoiceManager.js","path":"src/client/voice"},"returns":{"types":[[["VoiceConnection",""]]]},"params":[]}],"properties":[{"id":"PendingVoiceConnection#voiceManager","name":"voiceManager","description":"The ClientVoiceManager that instantiated this pending connection","memberof":"PendingVoiceConnection","type":{"types":[[["ClientVoiceManager",""]]]},"meta":{"line":128,"file":"ClientVoiceManager.js","path":"src/client/voice"},"props":[]},{"id":"PendingVoiceConnection#channel","name":"channel","description":"The channel that this pending voice connection will attempt to join","memberof":"PendingVoiceConnection","type":{"types":[[["VoiceChannel",""]]]},"meta":{"line":134,"file":"ClientVoiceManager.js","path":"src/client/voice"},"props":[]},{"id":"PendingVoiceConnection#deathTimer","name":"deathTimer","description":"The timeout that will be invoked after 15 seconds signifying a failure to connect","memberof":"PendingVoiceConnection","type":{"types":[[["Timeout",""]]]},"meta":{"line":140,"file":"ClientVoiceManager.js","path":"src/client/voice"},"props":[]},{"id":"PendingVoiceConnection#data","name":"data","description":"An object containing data required to connect to the voice servers with","memberof":"PendingVoiceConnection","type":{"types":[[["object",""]]]},"meta":{"line":147,"file":"ClientVoiceManager.js","path":"src/client/voice"},"props":[]}],"events":[]},{"id":"StreamDispatcher","name":"StreamDispatcher","description":"The class that sends voice packet data to the voice connection.\r```js\r// obtained using:\rvoiceChannel.join().then(connection => {\r // you can play a file or a stream here:\r connection.playFile('./file.mp3').then(dispatcher => {\r\r });\r});\r```","meta":{"line":20,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"extends":["EventEmitter"],"methods":[{"id":"StreamDispatcher#setVolume","name":"setVolume","description":"Sets the volume relative to the input stream - i.e. 1 is normal, 0.5 is half, 2 is double.","memberof":"StreamDispatcher","meta":{"line":83,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"returns":{"types":[[["null",""]]]},"params":[{"name":"volume","description":"The volume that you want to set","type":{"types":[[["number",""]]]}}]},{"id":"StreamDispatcher#setVolumeDecibels","name":"setVolumeDecibels","description":"Set the volume in decibels","memberof":"StreamDispatcher","meta":{"line":91,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"returns":{"types":[[["null",""]]]},"params":[{"name":"db","description":"The decibels","type":{"types":[[["number",""]]]}}]},{"id":"StreamDispatcher#setVolumeLogarithmic","name":"setVolumeLogarithmic","description":"Set the volume so that a perceived value of 0.5 is half the perceived volume etc.","memberof":"StreamDispatcher","meta":{"line":99,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"returns":{"types":[[["null",""]]]},"params":[{"name":"value","description":"The value for the volume","type":{"types":[[["number",""]]]}}]},{"id":"StreamDispatcher#pause","name":"pause","description":"Stops sending voice packets to the voice connection (stream may still progress however)","memberof":"StreamDispatcher","meta":{"line":106,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"StreamDispatcher#resume","name":"resume","description":"Resumes sending voice packets to the voice connection (may be further on in the stream than when paused)","memberof":"StreamDispatcher","meta":{"line":113,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"StreamDispatcher#end","name":"end","description":"Stops the current stream permanently and emits an `end` event.","memberof":"StreamDispatcher","meta":{"line":120,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"returns":{"types":[[["null",""]]]},"params":[]}],"properties":[{"id":"StreamDispatcher#passes","name":"passes","description":"How many passes the dispatcher should take when sending packets to reduce packet loss. Values over 5\raren't recommended, as it means you are using 5x more bandwidth. You _can_ edit this at runtime.","memberof":"StreamDispatcher","type":{"types":[[["number",""]]]},"meta":{"line":41,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"props":[]},{"id":"StreamDispatcher#paused","name":"paused","description":"Whether playing is paused","memberof":"StreamDispatcher","type":{"types":[[["boolean",""]]]},"meta":{"line":47,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"props":[]},{"id":"StreamDispatcher#time","name":"time","description":"How long the stream dispatcher has been \"speaking\" for","memberof":"StreamDispatcher","type":{"types":[[["number",""]]]},"meta":{"line":57,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"props":[]},{"id":"StreamDispatcher#totalStreamTime","name":"totalStreamTime","description":"The total time, taking into account pauses and skips, that the dispatcher has been streaming for","memberof":"StreamDispatcher","type":{"types":[[["number",""]]]},"meta":{"line":66,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"props":[]},{"id":"StreamDispatcher#volume","name":"volume","description":"The volume of the stream, relative to the stream's input volume","memberof":"StreamDispatcher","type":{"types":[[["number",""]]]},"meta":{"line":75,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"props":[]}],"events":[{"id":"StreamDispatcher#event:speaking","name":"speaking","description":"Emitted when the dispatcher starts/stops speaking","memberof":"StreamDispatcher","meta":{"line":126,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"params":[{"name":"value","description":"Whether or not the dispatcher is speaking","type":{"types":[[["boolean",""]]]}}]},{"id":"StreamDispatcher#event:start","name":"start","description":"Emitted once the dispatcher starts streaming","memberof":"StreamDispatcher","meta":{"line":198,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"params":[]},{"id":"StreamDispatcher#event:end","name":"end","description":"Emitted once the stream has ended. Attach a `once` listener to this.","memberof":"StreamDispatcher","meta":{"line":239,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"params":[]},{"id":"StreamDispatcher#event:error","name":"error","description":"Emitted once the stream has encountered an error. Attach a `once` listener to this. Also emits `end`.","memberof":"StreamDispatcher","meta":{"line":248,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"params":[{"name":"err","description":"The encountered error","type":{"types":[[["Error",""]]]}}]},{"id":"StreamDispatcher#event:debug","name":"debug","description":"Emitted when the stream wants to give debug information.","memberof":"StreamDispatcher","meta":{"line":258,"file":"StreamDispatcher.js","path":"src/client/voice/dispatcher"},"params":[{"name":"information","description":"The debug information","type":{"types":[[["string",""]]]}}]}]},{"id":"AudioPlayer","name":"AudioPlayer","description":"Represents the Audio Player of a Voice Connection","meta":{"line":11,"file":"AudioPlayer.js","path":"src/client/voice/player"},"extends":["EventEmitter"],"access":"private","methods":[],"properties":[{"id":"AudioPlayer#voiceConnection","name":"voiceConnection","description":"The voice connection the player belongs to","memberof":"AudioPlayer","type":{"types":[[["VoiceConnection",""]]]},"meta":{"line":18,"file":"AudioPlayer.js","path":"src/client/voice/player"},"props":[]},{"id":"AudioPlayer#dispatcher","name":"dispatcher","description":"The current stream dispatcher, if a stream is being played","memberof":"AudioPlayer","type":{"types":[[["StreamDispatcher",""]]]},"meta":{"line":26,"file":"AudioPlayer.js","path":"src/client/voice/player"},"props":[]}],"events":[]},{"id":"VoiceReceiver","name":"VoiceReceiver","description":"Receives voice data from a voice connection.\r```js\r// obtained using:\rvoiceChannel.join().then(connection => {\r const receiver = connection.createReceiver();\r});\r```","meta":{"line":18,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"extends":["EventEmitter"],"methods":[{"id":"VoiceReceiver#recreate","name":"recreate","description":"If this VoiceReceiver has been destroyed, running `recreate()` will recreate the listener.\rThis avoids you having to create a new receiver.\rAny streams that you had prior to destroying the receiver will not be recreated.","memberof":"VoiceReceiver","meta":{"line":65,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceReceiver#destroy","name":"destroy","description":"Destroy this VoiceReceiver, also ending any streams that it may be controlling.","memberof":"VoiceReceiver","meta":{"line":75,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceReceiver#createOpusStream","name":"createOpusStream","description":"Creates a readable stream for a user that provides opus data while the user is speaking. When the user\rstops speaking, the stream is destroyed.","memberof":"VoiceReceiver","meta":{"line":94,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"returns":{"types":[[["ReadableStream",""]]]},"params":[{"name":"user","description":"The user to create the stream for","type":{"types":[[["UserResolvable",""]]]}}]},{"id":"VoiceReceiver#createPCMStream","name":"createPCMStream","description":"Creates a readable stream for a user that provides PCM data while the user is speaking. When the user\rstops speaking, the stream is destroyed. The stream is 32-bit signed stereo PCM at 48KHz.","memberof":"VoiceReceiver","meta":{"line":109,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"returns":{"types":[[["ReadableStream",""]]]},"params":[{"name":"user","description":"The user to create the stream for","type":{"types":[[["UserResolvable",""]]]}}]}],"properties":[{"id":"VoiceReceiver#destroyed","name":"destroyed","description":"Whether or not this receiver has been destroyed.","memberof":"VoiceReceiver","type":{"types":[[["boolean",""]]]},"meta":{"line":33,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"props":[]},{"id":"VoiceReceiver#voiceConnection","name":"voiceConnection","description":"The VoiceConnection that instantiated this","memberof":"VoiceReceiver","type":{"types":[[["VoiceConnection",""]]]},"meta":{"line":39,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"props":[]}],"events":[{"id":"VoiceReceiver#event:warn","name":"warn","description":"Emitted whenever a voice packet cannot be decrypted","memberof":"VoiceReceiver","meta":{"line":122,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"params":[{"name":"message","description":"The warning message","type":{"types":[[["string",""]]]}}]},{"id":"VoiceReceiver#event:opus","name":"opus","description":"Emitted whenever voice data is received from the voice connection. This is _always_ emitted (unlike PCM).","memberof":"VoiceReceiver","meta":{"line":132,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"params":[{"name":"user","description":"The user that is sending the buffer (is speaking)","type":{"types":[[["User",""]]]}},{"name":"buffer","description":"The opus buffer","type":{"types":[[["Buffer",""]]]}}]},{"id":"VoiceReceiver#event:pcm","name":"pcm","description":"Emits decoded voice data when it's received. For performance reasons, the decoding will only\rhappen if there is at least one `pcm` listener on this receiver.","memberof":"VoiceReceiver","meta":{"line":140,"file":"VoiceReceiver.js","path":"src/client/voice/receiver"},"params":[{"name":"user","description":"The user that is sending the buffer (is speaking)","type":{"types":[[["User",""]]]}},{"name":"buffer","description":"The decoded buffer","type":{"types":[[["Buffer",""]]]}}]}]},{"id":"SecretKey","name":"SecretKey","description":"Represents a Secret Key used in encryption over voice","meta":{"line":4,"file":"SecretKey.js","path":"src/client/voice/util"},"methods":[],"properties":[{"id":"SecretKey#key","name":"key","description":"The key used for encryption","memberof":"SecretKey","type":{"types":[[["Uint8Array",""]]]},"meta":{"line":10,"file":"SecretKey.js","path":"src/client/voice/util"},"props":[]}],"events":[]},{"id":"VoiceConnection","name":"VoiceConnection","description":"Represents a connection to a Voice Channel in Discord.\r```js\r// obtained using:\rvoiceChannel.join().then(connection => {\r\r});\r```","meta":{"line":19,"file":"VoiceConnection.js","path":"src/client/voice"},"extends":["EventEmitter"],"methods":[{"id":"VoiceConnection#setSpeaking","access":"private","name":"setSpeaking","description":"Sets whether the voice connection should display as \"speaking\" or not","memberof":"VoiceConnection","meta":{"line":94,"file":"VoiceConnection.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[{"name":"value","description":"whether or not to speak","type":{"types":[[["boolean",""]]]}}]},{"id":"VoiceConnection#disconnect","name":"disconnect","description":"Disconnect the voice connection, causing a disconnect and closing event to be emitted.","memberof":"VoiceConnection","meta":{"line":112,"file":"VoiceConnection.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceConnection#connect","access":"private","name":"connect","description":"Connect the voice connection","memberof":"VoiceConnection","meta":{"line":134,"file":"VoiceConnection.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceConnection#playFile","name":"playFile","description":"Play the given file in the voice connection.","memberof":"VoiceConnection","examples":["// play files natively\rvoiceChannel.join()\r .then(connection => {\r const dispatcher = connection.playFile('C:/Users/Discord/Desktop/music.mp3');\r })\r .catch(console.error);"],"meta":{"line":217,"file":"VoiceConnection.js","path":"src/client/voice"},"returns":{"types":[[["StreamDispatcher",""]]]},"params":[{"name":"file","description":"The path to the file","type":{"types":[[["string",""]]]}},{"name":"options","description":"Options for playing the stream","optional":true,"type":{"types":[[["StreamOptions",""]]]}}]},{"id":"VoiceConnection#playStream","name":"playStream","description":"Plays and converts an audio stream in the voice connection.","memberof":"VoiceConnection","examples":["// play streams using ytdl-core\rconst ytdl = require('ytdl-core');\rconst streamOptions = { seek: 0, volume: 1 };\rvoiceChannel.join()\r .then(connection => {\r const stream = ytdl('https://www.youtube.com/watch?v=XAWgeLF9EVQ', {filter : 'audioonly'});\r const dispatcher = connection.playStream(stream, streamOptions);\r })\r .catch(console.error);"],"meta":{"line":237,"file":"VoiceConnection.js","path":"src/client/voice"},"returns":{"types":[[["StreamDispatcher",""]]]},"params":[{"name":"stream","description":"The audio stream to play","type":{"types":[[["ReadableStream",""]]]}},{"name":"options","description":"Options for playing the stream","optional":true,"type":{"types":[[["StreamOptions",""]]]}}]},{"id":"VoiceConnection#playConvertedStream","name":"playConvertedStream","description":"Plays a stream of 16-bit signed stereo PCM at 48KHz.","memberof":"VoiceConnection","meta":{"line":248,"file":"VoiceConnection.js","path":"src/client/voice"},"returns":{"types":[[["StreamDispatcher",""]]]},"params":[{"name":"stream","description":"The audio stream to play.","type":{"types":[[["ReadableStream",""]]]}},{"name":"options","description":"Options for playing the stream","optional":true,"type":{"types":[[["StreamOptions",""]]]}}]},{"id":"VoiceConnection#createReceiver","name":"createReceiver","description":"Creates a VoiceReceiver so you can start listening to voice data. It's recommended to only create one of these.","memberof":"VoiceConnection","meta":{"line":257,"file":"VoiceConnection.js","path":"src/client/voice"},"returns":{"types":[[["VoiceReceiver",""]]]},"params":[]}],"properties":[{"id":"VoiceConnection#voiceManager","name":"voiceManager","description":"The Voice Manager that instantiated this connection","memberof":"VoiceConnection","type":{"types":[[["ClientVoiceManager",""]]]},"meta":{"line":27,"file":"VoiceConnection.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnection#channel","name":"channel","description":"The voice channel this connection is currently serving","memberof":"VoiceConnection","type":{"types":[[["VoiceChannel",""]]]},"meta":{"line":33,"file":"VoiceConnection.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnection#receivers","name":"receivers","description":"An array of Voice Receivers that have been created for this connection","memberof":"VoiceConnection","type":{"types":[[["Array",".<"],["VoiceReceiver",">"]]]},"meta":{"line":39,"file":"VoiceConnection.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnection#authentication","name":"authentication","description":"The authentication data needed to connect to the voice server","memberof":"VoiceConnection","type":{"types":[[["object",""]]]},"access":"private","meta":{"line":46,"file":"VoiceConnection.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnection#player","name":"player","description":"The audio player for this voice connection","memberof":"VoiceConnection","type":{"types":[[["AudioPlayer",""]]]},"meta":{"line":52,"file":"VoiceConnection.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnection#ssrcMap","name":"ssrcMap","description":"Map SSRC to speaking values","memberof":"VoiceConnection","type":{"types":[[["Map",".<"],["number",", "],["boolean",">"]]]},"access":"private","meta":{"line":78,"file":"VoiceConnection.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnection#sockets","name":"sockets","description":"Object that wraps contains the `ws` and `udp` sockets of this voice connection","memberof":"VoiceConnection","type":{"types":[[["object",""]]]},"access":"private","meta":{"line":85,"file":"VoiceConnection.js","path":"src/client/voice"},"props":[]}],"events":[{"id":"VoiceConnection#event:debug","name":"debug","description":"Debug info from the connection","memberof":"VoiceConnection","meta":{"line":55,"file":"VoiceConnection.js","path":"src/client/voice"},"params":[{"name":"message","description":"the debug message","type":{"types":[[["string",""]]]}}]},{"id":"VoiceConnection#event:warn","name":"warn","description":"Warning info from the connection","memberof":"VoiceConnection","meta":{"line":64,"file":"VoiceConnection.js","path":"src/client/voice"},"params":[{"name":"warning","description":"the warning","type":{"types":[[["string",""]],[["error",""]]]}}]},{"id":"VoiceConnection#event:disconnect","name":"disconnect","description":"Emitted when the voice connection disconnects","memberof":"VoiceConnection","meta":{"line":123,"file":"VoiceConnection.js","path":"src/client/voice"},"params":[]},{"id":"VoiceConnection#event:error","name":"error","description":"Emitted whenever the connection encounters an error.","memberof":"VoiceConnection","meta":{"line":144,"file":"VoiceConnection.js","path":"src/client/voice"},"params":[{"name":"error","description":"the encountered error","type":{"types":[[["Error",""]]]}}]},{"id":"VoiceConnection#event:ready","name":"ready","description":"Emitted once the connection is ready, when a promise to join a voice channel resolves,\rthe connection will already be ready.","memberof":"VoiceConnection","meta":{"line":158,"file":"VoiceConnection.js","path":"src/client/voice"},"params":[]},{"id":"VoiceConnection#event:speaking","name":"speaking","description":"Emitted whenever a user starts/stops speaking","memberof":"VoiceConnection","meta":{"line":185,"file":"VoiceConnection.js","path":"src/client/voice"},"params":[{"name":"user","description":"The user that has started/stopped speaking","type":{"types":[[["User",""]]]}},{"name":"speaking","description":"Whether or not the user is speaking","type":{"types":[[["boolean",""]]]}}]}]},{"id":"VoiceConnectionUDPClient","name":"VoiceConnectionUDPClient","description":"Represents a UDP Client for a Voice Connection","meta":{"line":23,"file":"VoiceUDPClient.js","path":"src/client/voice"},"extends":["EventEmitter"],"access":"private","methods":[{"id":"VoiceConnectionUDPClient#findEndpointAddress","name":"findEndpointAddress","description":"Tries to resolve the voice server endpoint to an address","memberof":"VoiceConnectionUDPClient","meta":{"line":84,"file":"VoiceUDPClient.js","path":"src/client/voice"},"returns":{"types":[[["Promise",".<"],["string",">"]]]},"params":[]},{"id":"VoiceConnectionUDPClient#send","name":"send","description":"Send a packet to the UDP client","memberof":"VoiceConnectionUDPClient","meta":{"line":102,"file":"VoiceUDPClient.js","path":"src/client/voice"},"returns":{"types":[[["Promise",".<"],["Object",">"]]]},"params":[{"name":"packet","description":"the packet to send","type":{"types":[[["Object",""]]]}}]}],"properties":[{"id":"VoiceConnectionUDPClient#voiceConnection","name":"voiceConnection","description":"The voice connection that this UDP client serves","memberof":"VoiceConnectionUDPClient","type":{"types":[[["VoiceConnection",""]]]},"meta":{"line":31,"file":"VoiceUDPClient.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnectionUDPClient#socket","name":"socket","description":"The UDP socket","memberof":"VoiceConnectionUDPClient","type":{"types":[[["Socket",""]]]},"meta":{"line":37,"file":"VoiceUDPClient.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnectionUDPClient#discordAddress","name":"discordAddress","description":"The address of the discord voice server","memberof":"VoiceConnectionUDPClient","type":{"types":[[["string",""]]]},"meta":{"line":43,"file":"VoiceUDPClient.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnectionUDPClient#localAddress","name":"localAddress","description":"The local IP address","memberof":"VoiceConnectionUDPClient","type":{"types":[[["string",""]]]},"meta":{"line":49,"file":"VoiceUDPClient.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnectionUDPClient#localPort","name":"localPort","description":"The local port","memberof":"VoiceConnectionUDPClient","type":{"types":[[["string",""]]]},"meta":{"line":55,"file":"VoiceUDPClient.js","path":"src/client/voice"},"props":[]},{"id":"VoiceConnectionUDPClient#discordPort","name":"discordPort","description":"The port of the discord voice server","memberof":"VoiceConnectionUDPClient","type":{"types":[[["number",""]]]},"meta":{"line":76,"file":"VoiceUDPClient.js","path":"src/client/voice"},"props":[]}],"events":[]},{"id":"VoiceWebSocket","name":"VoiceWebSocket","description":"Represents a Voice Connection's WebSocket","meta":{"line":11,"file":"VoiceWebSocket.js","path":"src/client/voice"},"extends":["EventEmitter"],"access":"private","methods":[{"id":"VoiceWebSocket#reset","name":"reset","description":"Resets the current WebSocket","memberof":"VoiceWebSocket","meta":{"line":49,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceWebSocket#connect","name":"connect","description":"Starts connecting to the Voice WebSocket Server.","memberof":"VoiceWebSocket","meta":{"line":60,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceWebSocket#send","name":"send","description":"Sends data to the WebSocket if it is open.","memberof":"VoiceWebSocket","meta":{"line":86,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["Promise",".<"],["string",">"]]]},"params":[{"name":"data","description":"the data to send to the WebSocket","type":{"types":[[["string",""]]]}}]},{"id":"VoiceWebSocket#sendPacket","name":"sendPacket","description":"JSON.stringify's a packet and then sends it to the WebSocket Server.","memberof":"VoiceWebSocket","meta":{"line":102,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["Promise",".<"],["string",">"]]]},"params":[{"name":"packet","description":"the packet to send","type":{"types":[[["Object",""]]]}}]},{"id":"VoiceWebSocket#onOpen","name":"onOpen","description":"Called whenever the WebSocket opens","memberof":"VoiceWebSocket","meta":{"line":114,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceWebSocket#onMessage","name":"onMessage","description":"Called whenever a message is received from the WebSocket","memberof":"VoiceWebSocket","meta":{"line":133,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["void",""]]]},"params":[{"name":"event","description":"the message event that was received","type":{"types":[[["MessageEvent",""]]]}}]},{"id":"VoiceWebSocket#onClose","name":"onClose","description":"Called whenever the connection to the WebSocket Server is lost","memberof":"VoiceWebSocket","meta":{"line":144,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceWebSocket#onError","name":"onError","description":"Called whenever an error occurs with the WebSocket.","memberof":"VoiceWebSocket","meta":{"line":153,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[{"name":"error","description":"the error that occurred","type":{"types":[[["Error",""]]]}}]},{"id":"VoiceWebSocket#onPacket","name":"onPacket","description":"Called whenever a valid packet is received from the WebSocket","memberof":"VoiceWebSocket","meta":{"line":161,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[{"name":"packet","description":"the received packet","type":{"types":[[["Object",""]]]}}]},{"id":"VoiceWebSocket#setHeartbeat","name":"setHeartbeat","description":"Sets an interval at which to send a heartbeat packet to the WebSocket","memberof":"VoiceWebSocket","meta":{"line":204,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[{"name":"interval","description":"the interval at which to send a heartbeat packet","type":{"types":[[["number",""]]]}}]},{"id":"VoiceWebSocket#clearHeartbeat","name":"clearHeartbeat","description":"Clears a heartbeat interval, if one exists","memberof":"VoiceWebSocket","meta":{"line":224,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceWebSocket#sendHeartbeat","name":"sendHeartbeat","description":"Sends a heartbeat packet","memberof":"VoiceWebSocket","meta":{"line":236,"file":"VoiceWebSocket.js","path":"src/client/voice"},"returns":{"types":[[["null",""]]]},"params":[]}],"properties":[{"id":"VoiceWebSocket#voiceConnection","name":"voiceConnection","description":"The Voice Connection that this WebSocket serves","memberof":"VoiceWebSocket","type":{"types":[[["VoiceConnection",""]]]},"meta":{"line":19,"file":"VoiceWebSocket.js","path":"src/client/voice"},"props":[]},{"id":"VoiceWebSocket#attempts","name":"attempts","description":"How many connection attempts have been made","memberof":"VoiceWebSocket","type":{"types":[[["number",""]]]},"meta":{"line":25,"file":"VoiceWebSocket.js","path":"src/client/voice"},"props":[]},{"id":"VoiceWebSocket#client","name":"client","description":"The client of this voice websocket","memberof":"VoiceWebSocket","type":{"types":[[["Client",""]]]},"meta":{"line":42,"file":"VoiceWebSocket.js","path":"src/client/voice"},"props":[]},{"id":"VoiceWebSocket#ws","name":"ws","description":"The actual WebSocket used to connect to the Voice WebSocket Server.","memberof":"VoiceWebSocket","type":{"types":[[["WebSocket",""]]]},"meta":{"line":74,"file":"VoiceWebSocket.js","path":"src/client/voice"},"props":[]}],"events":[{"id":"VoiceWebSocket#event:ready","name":"ready","description":"Emitted once the voice websocket receives the ready packet","memberof":"VoiceWebSocket","meta":{"line":165,"file":"VoiceWebSocket.js","path":"src/client/voice"},"params":[{"name":"packet","description":"the received packet","type":{"types":[[["Object",""]]]}}]},{"id":"VoiceWebSocket#event:sessionDescription","name":"sessionDescription","description":"Emitted once the Voice Websocket receives a description of this voice session","memberof":"VoiceWebSocket","meta":{"line":173,"file":"VoiceWebSocket.js","path":"src/client/voice"},"params":[{"name":"encryptionMode","description":"the type of encryption being used","type":{"types":[[["string",""]]]}},{"name":"secretKey","description":"the secret key used for encryption","type":{"types":[[["SecretKey",""]]]}}]},{"id":"VoiceWebSocket#event:speaking","name":"speaking","description":"Emitted whenever a speaking packet is received","memberof":"VoiceWebSocket","meta":{"line":182,"file":"VoiceWebSocket.js","path":"src/client/voice"},"params":[{"name":"data","type":{"types":[[["Object",""]]]}}]},{"id":"VoiceWebSocket#event:unknownPacket","name":"unknownPacket","description":"Emitted when an unhandled packet is received","memberof":"VoiceWebSocket","meta":{"line":190,"file":"VoiceWebSocket.js","path":"src/client/voice"},"params":[{"name":"packet","type":{"types":[[["Object",""]]]}}]},{"id":"VoiceWebSocket#event:warn","name":"warn","description":"Emitted whenver the voice websocket encounters a non-fatal error","memberof":"VoiceWebSocket","meta":{"line":210,"file":"VoiceWebSocket.js","path":"src/client/voice"},"params":[{"name":"warn","description":"the warning","type":{"types":[[["string",""]]]}}]}]},{"id":"WebhookClient","name":"WebhookClient","description":"The Webhook Client","meta":{"line":11,"file":"WebhookClient.js","path":"src/client"},"extends":["Webhook"],"classConstructor":{"id":"WebhookClient()","name":"WebhookClient","memberof":"WebhookClient","params":[{"name":"id","description":"The id of the webhook.","type":{"types":[[["string",""]]]}},{"name":"token","description":"the token of the webhook.","type":{"types":[[["string",""]]]}},{"name":"options","description":"Options for the client","optional":true,"type":{"types":[[["ClientOptions",""]]]}}]},"methods":[{"id":"WebhookClient#sendMessage","name":"sendMessage","description":"Send a message with this webhook","memberof":"WebhookClient","examples":["// send a message\rwebhook.sendMessage('hello!')\r .then(message => console.log(`Sent message: ${message.content}`))\r .catch(console.error);"],"inherits":"Webhook#sendMessage","inherited":true,"meta":{"line":87,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send.","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide.","optional":true,"type":{"types":[[["WebhookMessageOptions",""]]]}}]},{"id":"WebhookClient#sendSlackMessage","name":"sendSlackMessage","description":"Send a raw slack message with this webhook","memberof":"WebhookClient","examples":["// send a slack message\rwebhook.sendSlackMessage({\r 'username': 'Wumpus',\r 'attachments': [{\r 'pretext': 'this looks pretty cool',\r 'color': '#F0F',\r 'footer_icon': 'http://snek.s3.amazonaws.com/topSnek.png',\r 'footer': 'Powered by sneks',\r 'ts': new Date().getTime() / 1000\r }]\r}).catch(console.error);"],"inherits":"Webhook#sendSlackMessage","inherited":true,"meta":{"line":108,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",""]]]},"params":[{"name":"body","description":"The raw body to send.","type":{"types":[[["Object",""]]]}}]},{"id":"WebhookClient#sendTTSMessage","name":"sendTTSMessage","description":"Send a text-to-speech message with this webhook","memberof":"WebhookClient","examples":["// send a TTS message\rwebhook.sendTTSMessage('hello!')\r .then(message => console.log(`Sent tts message: ${message.content}`))\r .catch(console.error);"],"inherits":"Webhook#sendTTSMessage","inherited":true,"meta":{"line":123,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["WebhookMessageOptions",""]]]}}]},{"id":"WebhookClient#sendFile","name":"sendFile","description":"Send a file with this webhook","memberof":"WebhookClient","inherits":"Webhook#sendFile","inherited":true,"meta":{"line":136,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"attachment","description":"The file to send","type":{"types":[[["FileResolvable",""]]]}},{"name":"fileName","description":"The name and extension of the file","optional":true,"type":{"types":[[["string",""]]]}},{"name":"content","description":"Text message to send with the attachment","optional":true,"type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["WebhookMessageOptions",""]]]}}]},{"id":"WebhookClient#sendCode","name":"sendCode","description":"Send a code block with this webhook","memberof":"WebhookClient","inherits":"Webhook#sendCode","inherited":true,"meta":{"line":163,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"Content of the code block","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","type":{"types":[[["WebhookMessageOptions",""]]]}}]},{"id":"WebhookClient#edit","name":"edit","description":"Edit the Webhook.","memberof":"WebhookClient","inherits":"Webhook#edit","inherited":true,"meta":{"line":179,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Webhook",">"]]]},"params":[{"name":"name","description":"The new name for the Webhook","type":{"types":[[["string",""]]]}},{"name":"avatar","description":"The new avatar for the Webhook.","type":{"types":[[["FileResolvable",""]]]}}]},{"id":"WebhookClient#delete","name":"delete","description":"Delete the Webhook","memberof":"WebhookClient","inherits":"Webhook#delete","inherited":true,"meta":{"line":200,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",""]]]},"params":[]}],"properties":[{"id":"WebhookClient#options","name":"options","description":"The options the client was instantiated with","memberof":"WebhookClient","type":{"types":[[["ClientOptions",""]]]},"meta":{"line":28,"file":"WebhookClient.js","path":"src/client"},"props":[]},{"id":"WebhookClient#rest","name":"rest","description":"The REST manager of the client","memberof":"WebhookClient","type":{"types":[[["RESTManager",""]]]},"access":"private","meta":{"line":35,"file":"WebhookClient.js","path":"src/client"},"props":[]},{"id":"WebhookClient#resolver","name":"resolver","description":"The Data Resolver of the Client","memberof":"WebhookClient","type":{"types":[[["ClientDataResolver",""]]]},"access":"private","meta":{"line":42,"file":"WebhookClient.js","path":"src/client"},"props":[]},{"id":"WebhookClient#client","name":"client","description":"The client that instantiated the Channel","memberof":"WebhookClient","type":{"types":[[["Client",""]]]},"meta":{"line":14,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"WebhookClient#name","name":"name","description":"The name of the Webhook","memberof":"WebhookClient","type":{"types":[[["string",""]]]},"meta":{"line":29,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"WebhookClient#token","name":"token","description":"The token for the Webhook","memberof":"WebhookClient","type":{"types":[[["string",""]]]},"meta":{"line":35,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"WebhookClient#avatar","name":"avatar","description":"The avatar for the Webhook","memberof":"WebhookClient","type":{"types":[[["string",""]]]},"meta":{"line":41,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"WebhookClient#id","name":"id","description":"The ID of the Webhook","memberof":"WebhookClient","type":{"types":[[["string",""]]]},"meta":{"line":47,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"WebhookClient#guildID","name":"guildID","description":"The guild the Webhook belongs to","memberof":"WebhookClient","type":{"types":[[["string",""]]]},"meta":{"line":53,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"WebhookClient#channelID","name":"channelID","description":"The channel the Webhook belongs to","memberof":"WebhookClient","type":{"types":[[["string",""]]]},"meta":{"line":59,"file":"Webhook.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"WebSocketManager","name":"WebSocketManager","description":"The WebSocket Manager of the Client","meta":{"line":11,"file":"WebSocketManager.js","path":"src/client/websocket"},"access":"private","methods":[{"id":"WebSocketManager#_connect","name":"_connect","description":"Connects the client to a given gateway","memberof":"WebSocketManager","meta":{"line":76,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["null",""]]]},"params":[{"name":"gateway","description":"The gateway to connect to","type":{"types":[[["string",""]]]}}]},{"id":"WebSocketManager#send","name":"send","description":"Sends a packet to the gateway","memberof":"WebSocketManager","meta":{"line":103,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["null",""]]]},"params":[{"name":"data","description":"An object that can be JSON stringified","type":{"types":[[["Object",""]]]}},{"name":"force","description":"Whether or not to send the packet immediately","type":{"types":[[["boolean",""]]]}}]},{"id":"WebSocketManager#eventOpen","name":"eventOpen","description":"Run whenever the gateway connections opens up","memberof":"WebSocketManager","meta":{"line":145,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"WebSocketManager#_sendResume","name":"_sendResume","description":"Sends a gateway resume packet, in cases of unexpected disconnections.","memberof":"WebSocketManager","meta":{"line":154,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"WebSocketManager#_sendNewIdentify","name":"_sendNewIdentify","description":"Sends a new identification packet, in cases of new connections or failed reconnections.","memberof":"WebSocketManager","meta":{"line":175,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"WebSocketManager#eventClose","name":"eventClose","description":"Run whenever the connection to the gateway is closed, it will try to reconnect the client.","memberof":"WebSocketManager","meta":{"line":194,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["null",""]]]},"params":[{"name":"event","description":"The received websocket data","type":{"types":[[["Object",""]]]}}]},{"id":"WebSocketManager#eventMessage","name":"eventMessage","description":"Run whenever a message is received from the WebSocket. Returns `true` if the message\rwas handled properly.","memberof":"WebSocketManager","meta":{"line":213,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"event","description":"The received websocket data","type":{"types":[[["Object",""]]]}}]},{"id":"WebSocketManager#eventError","name":"eventError","description":"Run whenever an error occurs with the WebSocket connection. Tries to reconnect","memberof":"WebSocketManager","meta":{"line":232,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["null",""]]]},"params":[{"name":"err","description":"The encountered error","type":{"types":[[["Error",""]]]}}]},{"id":"WebSocketManager#checkIfReady","name":"checkIfReady","description":"Runs on new packets before `READY` to see if the Client is ready yet, if it is prepares\rthe `READY` event.","memberof":"WebSocketManager","meta":{"line":257,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"WebSocketManager#tryReconnect","name":"tryReconnect","description":"Tries to reconnect the client, changing the status to Constants.Status.RECONNECTING.","memberof":"WebSocketManager","meta":{"line":282,"file":"WebSocketManager.js","path":"src/client/websocket"},"returns":{"types":[[["null",""]]]},"params":[]}],"properties":[{"id":"WebSocketManager#client","name":"client","description":"The Client that instantiated this WebSocketManager","memberof":"WebSocketManager","type":{"types":[[["Client",""]]]},"meta":{"line":18,"file":"WebSocketManager.js","path":"src/client/websocket"},"props":[]},{"id":"WebSocketManager#packetManager","name":"packetManager","description":"A WebSocket Packet manager, it handles all the messages","memberof":"WebSocketManager","type":{"types":[[["PacketManager",""]]]},"meta":{"line":24,"file":"WebSocketManager.js","path":"src/client/websocket"},"props":[]},{"id":"WebSocketManager#status","name":"status","description":"The status of the WebSocketManager, a type of Constants.Status. It defaults to IDLE.","memberof":"WebSocketManager","type":{"types":[[["number",""]]]},"meta":{"line":30,"file":"WebSocketManager.js","path":"src/client/websocket"},"props":[]},{"id":"WebSocketManager#sessionID","name":"sessionID","description":"The session ID of the connection, null if not yet available.","memberof":"WebSocketManager","type":{"types":[[["string",""]]]},"meta":{"line":36,"file":"WebSocketManager.js","path":"src/client/websocket"},"props":[]},{"id":"WebSocketManager#sequence","name":"sequence","description":"The packet count of the client, null if not yet available.","memberof":"WebSocketManager","type":{"types":[[["number",""]]]},"meta":{"line":42,"file":"WebSocketManager.js","path":"src/client/websocket"},"props":[]},{"id":"WebSocketManager#gateway","name":"gateway","description":"The gateway address for this WebSocket connection, null if not yet available.","memberof":"WebSocketManager","type":{"types":[[["string",""]]]},"meta":{"line":48,"file":"WebSocketManager.js","path":"src/client/websocket"},"props":[]},{"id":"WebSocketManager#normalReady","name":"normalReady","description":"Whether READY was emitted normally (all packets received) or not","memberof":"WebSocketManager","type":{"types":[[["boolean",""]]]},"meta":{"line":54,"file":"WebSocketManager.js","path":"src/client/websocket"},"props":[]},{"id":"WebSocketManager#ws","name":"ws","description":"The WebSocket connection to the gateway","memberof":"WebSocketManager","type":{"types":[[["WebSocket",""]]]},"meta":{"line":60,"file":"WebSocketManager.js","path":"src/client/websocket"},"props":[]},{"id":"WebSocketManager#disabledEvents","name":"disabledEvents","description":"An object with keys that are websocket event names that should be ignored","memberof":"WebSocketManager","type":{"types":[[["Object",""]]]},"meta":{"line":66,"file":"WebSocketManager.js","path":"src/client/websocket"},"props":[]}],"events":[]},{"id":"Shard","name":"Shard","description":"Represents a Shard spawned by the ShardingManager.","meta":{"line":9,"file":"Shard.js","path":"src/sharding"},"classConstructor":{"id":"Shard()","name":"Shard","memberof":"Shard","params":[{"name":"manager","description":"The sharding manager","type":{"types":[[["ShardingManager",""]]]}},{"name":"id","description":"The ID of this shard","type":{"types":[[["number",""]]]}},{"name":"args","description":"Command line arguments to pass to the script","optional":true,"type":{"types":[[["array",""]]]}}]},"methods":[{"id":"Shard#send","name":"send","description":"Sends a message to the shard's process.","memberof":"Shard","meta":{"line":59,"file":"Shard.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["Shard",">"]]]},"params":[{"name":"message","description":"Message to send to the shard","type":{"types":[["*",""]]}}]},{"id":"Shard#fetchClientValue","name":"fetchClientValue","description":"Fetches a Client property value of the shard.","memberof":"Shard","examples":["shard.fetchClientValue('guilds.size').then(count => {\r console.log(`${count} guilds in shard ${shard.id}`);\r}).catch(console.error);"],"meta":{"line":77,"file":"Shard.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<*>"]]]},"params":[{"name":"prop","description":"Name of the Client property to get, using periods for nesting","type":{"types":[[["string",""]]]}}]},{"id":"Shard#eval","name":"eval","description":"Evaluates a script on the shard, in the context of the Client.","memberof":"Shard","meta":{"line":105,"file":"Shard.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<*>"]]]},"params":[{"name":"script","description":"JavaScript to run on the shard","type":{"types":[[["string",""]]]}}]},{"id":"Shard#_handleMessage","access":"private","name":"_handleMessage","description":"Handles an IPC message","memberof":"Shard","meta":{"line":133,"file":"Shard.js","path":"src/sharding"},"returns":{"types":[[["null",""]]]},"params":[{"name":"message","description":"Message received","type":{"types":[["*",""]]}}]}],"properties":[{"id":"Shard#manager","name":"manager","description":"Manager that created the shard","memberof":"Shard","type":{"types":[[["ShardingManager",""]]]},"meta":{"line":20,"file":"Shard.js","path":"src/sharding"},"props":[]},{"id":"Shard#id","name":"id","description":"ID of the shard","memberof":"Shard","type":{"types":[[["number",""]]]},"meta":{"line":26,"file":"Shard.js","path":"src/sharding"},"props":[]},{"id":"Shard#env","name":"env","description":"The environment variables for the shard","memberof":"Shard","type":{"types":[[["Object",""]]]},"meta":{"line":32,"file":"Shard.js","path":"src/sharding"},"props":[]},{"id":"Shard#process","name":"process","description":"Process of the shard","memberof":"Shard","type":{"types":[[["ChildProcess",""]]]},"meta":{"line":42,"file":"Shard.js","path":"src/sharding"},"props":[]}],"events":[]},{"id":"ShardClientUtil","name":"ShardClientUtil","description":"Helper class for sharded clients spawned as a child process, such as from a ShardingManager","meta":{"line":7,"file":"ShardClientUtil.js","path":"src/sharding"},"classConstructor":{"id":"ShardClientUtil()","name":"ShardClientUtil","memberof":"ShardClientUtil","params":[{"name":"client","description":"Client of the current shard","type":{"types":[[["Client",""]]]}}]},"methods":[{"id":"ShardClientUtil#send","name":"send","description":"Sends a message to the master process","memberof":"ShardClientUtil","meta":{"line":39,"file":"ShardClientUtil.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["void",">"]]]},"params":[{"name":"message","description":"Message to send","type":{"types":[["*",""]]}}]},{"id":"ShardClientUtil#fetchClientValues","name":"fetchClientValues","description":"Fetches a Client property value of each shard.","memberof":"ShardClientUtil","examples":["client.shard.fetchClientValues('guilds.size').then(results => {\r console.log(`${results.reduce((prev, val) => prev + val, 0)} total guilds`);\r}).catch(console.error);"],"meta":{"line":57,"file":"ShardClientUtil.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["Array",">"]]]},"params":[{"name":"prop","description":"Name of the Client property to get, using periods for nesting","type":{"types":[[["string",""]]]}}]},{"id":"ShardClientUtil#broadcastEval","name":"broadcastEval","description":"Evaluates a script on all shards, in the context of the Clients.","memberof":"ShardClientUtil","meta":{"line":78,"file":"ShardClientUtil.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["Array",">"]]]},"params":[{"name":"script","description":"JavaScript to run on each shard","type":{"types":[[["string",""]]]}}]},{"id":"ShardClientUtil#_handleMessage","access":"private","name":"_handleMessage","description":"Handles an IPC message","memberof":"ShardClientUtil","meta":{"line":99,"file":"ShardClientUtil.js","path":"src/sharding"},"returns":{"types":[[["null",""]]]},"params":[{"name":"message","description":"Message received","type":{"types":[["*",""]]}}]},{"id":"ShardClientUtil#_respond","access":"private","name":"_respond","description":"Sends a message to the master process, emitting an error from the client upon failure","memberof":"ShardClientUtil","meta":{"line":121,"file":"ShardClientUtil.js","path":"src/sharding"},"returns":{"types":[[["null",""]]]},"params":[{"name":"type","description":"Type of response to send","type":{"types":[[["string",""]]]}},{"name":"message","description":"Message to send","type":{"types":[["*",""]]}}]},{"id":"ShardClientUtil.singleton","name":"singleton","description":"Creates/gets the singleton of this class","memberof":"ShardClientUtil","meta":{"line":132,"file":"ShardClientUtil.js","path":"src/sharding"},"returns":{"types":[[["ShardUtil",""]]]},"params":[{"name":"client","description":"Client to use","type":{"types":[[["Client",""]]]}}]}],"properties":[{"id":"ShardClientUtil#id","name":"id","description":"ID of this shard","memberof":"ShardClientUtil","type":{"types":[[["number",""]]]},"meta":{"line":21,"file":"ShardClientUtil.js","path":"src/sharding"},"props":[]},{"id":"ShardClientUtil#count","name":"count","description":"Total number of shards","memberof":"ShardClientUtil","type":{"types":[[["number",""]]]},"meta":{"line":30,"file":"ShardClientUtil.js","path":"src/sharding"},"props":[]}],"events":[]},{"id":"ShardingManager","name":"ShardingManager","description":"This is a utility class that can be used to help you spawn shards of your Client. Each shard is completely separate\rfrom the other. The Shard Manager takes a path to a file and spawns it under the specified amount of shards safely.\rIf you do not select an amount of shards, the manager will automatically decide the best amount.\rThe Sharding Manager is still experimental","meta":{"line":16,"file":"ShardingManager.js","path":"src/sharding"},"extends":["EventEmitter"],"classConstructor":{"id":"ShardingManager()","name":"ShardingManager","memberof":"ShardingManager","params":[{"name":"file","description":"Path to your shard script file","type":{"types":[[["string",""]]]}},{"name":"options","description":"Options for the sharding manager","optional":true,"type":{"types":[[["Object",""]]]}},{"name":"options.totalShards","description":"Number of shards to spawn, or \"auto\"","optional":true,"type":{"types":[[["number",""]],[["string",""]]]}},{"name":"options.respawn","description":"Whether shards should automatically respawn upon exiting","optional":true,"type":{"types":[[["boolean",""]]]}},{"name":"options.shardArgs","description":"Arguments to pass to the shard script when spawning","optional":true,"type":{"types":[[["Array",".<"],["string",">"]]]}},{"name":"options.token","description":"Token to use for automatic shard count and passing to shards","optional":true,"type":{"types":[[["string",""]]]}}]},"methods":[{"id":"ShardingManager#createShard","name":"createShard","description":"Spawns a single shard.","memberof":"ShardingManager","meta":{"line":89,"file":"ShardingManager.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["Shard",">"]]]},"params":[{"name":"id","description":"The ID of the shard to spawn. **This is usually not necessary.**","type":{"types":[[["number",""]]]}}]},{"id":"ShardingManager#spawn","name":"spawn","description":"Spawns multiple shards.","memberof":"ShardingManager","meta":{"line":107,"file":"ShardingManager.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["number",", "],["Shard",">>"]]]},"params":[{"name":"amount","description":"Number of shards to spawn","optional":true,"type":{"types":[[["number",""]]]}},{"name":"delay","description":"How long to wait in between spawning each shard (in milliseconds)","optional":true,"type":{"types":[[["number",""]]]}}]},{"id":"ShardingManager#_spawn","access":"private","name":"_spawn","description":"Actually spawns shards, unlike that poser above >:(","memberof":"ShardingManager","meta":{"line":130,"file":"ShardingManager.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["number",", "],["Shard",">>"]]]},"params":[{"name":"amount","description":"Number of shards to spawn","type":{"types":[[["number",""]]]}},{"name":"delay","description":"How long to wait in between spawning each shard (in milliseconds)","type":{"types":[[["number",""]]]}}]},{"id":"ShardingManager#broadcast","name":"broadcast","description":"Send a message to all shards.","memberof":"ShardingManager","meta":{"line":161,"file":"ShardingManager.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["Array",".<"],["Shard",">>"]]]},"params":[{"name":"message","description":"Message to be sent to the shards","type":{"types":[["*",""]]}}]},{"id":"ShardingManager#broadcastEval","name":"broadcastEval","description":"Evaluates a script on all shards, in the context of the Clients.","memberof":"ShardingManager","meta":{"line":172,"file":"ShardingManager.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["Array",">"]]]},"params":[{"name":"script","description":"JavaScript to run on each shard","type":{"types":[[["string",""]]]}}]},{"id":"ShardingManager#fetchClientValues","name":"fetchClientValues","description":"Fetches a Client property value of each shard.","memberof":"ShardingManager","examples":["manager.fetchClientValues('guilds.size').then(results => {\r console.log(`${results.reduce((prev, val) => prev + val, 0)} total guilds`);\r}).catch(console.error);"],"meta":{"line":187,"file":"ShardingManager.js","path":"src/sharding"},"returns":{"types":[[["Promise",".<"],["Array",">"]]]},"params":[{"name":"prop","description":"Name of the Client property to get, using periods for nesting","type":{"types":[[["string",""]]]}}]}],"properties":[{"id":"ShardingManager#file","name":"file","description":"Path to the shard script file","memberof":"ShardingManager","type":{"types":[[["string",""]]]},"meta":{"line":38,"file":"ShardingManager.js","path":"src/sharding"},"props":[]},{"id":"ShardingManager#totalShards","name":"totalShards","description":"Amount of shards that this manager is going to spawn","memberof":"ShardingManager","type":{"types":[[["number",""]],[["string",""]]]},"meta":{"line":48,"file":"ShardingManager.js","path":"src/sharding"},"props":[]},{"id":"ShardingManager#respawn","name":"respawn","description":"Whether shards should automatically respawn upon exiting","memberof":"ShardingManager","type":{"types":[[["boolean",""]]]},"meta":{"line":63,"file":"ShardingManager.js","path":"src/sharding"},"props":[]},{"id":"ShardingManager#shardArgs","name":"shardArgs","description":"An array of arguments to pass to shards.","memberof":"ShardingManager","type":{"types":[[["Array",".<"],["string",">"]]]},"meta":{"line":69,"file":"ShardingManager.js","path":"src/sharding"},"props":[]},{"id":"ShardingManager#token","name":"token","description":"Token to use for obtaining the automatic shard count, and passing to shards","memberof":"ShardingManager","type":{"types":[[["string",""]]]},"meta":{"line":75,"file":"ShardingManager.js","path":"src/sharding"},"props":[]},{"id":"ShardingManager#shards","name":"shards","description":"A collection of shards that this manager has spawned","memberof":"ShardingManager","type":{"types":[[["Collection",".<"],["number",", "],["Shard",">"]]]},"meta":{"line":81,"file":"ShardingManager.js","path":"src/sharding"},"props":[]}],"events":[{"id":"ShardingManager#event:launch","name":"launch","description":"Emitted upon launching a shard","memberof":"ShardingManager","meta":{"line":92,"file":"ShardingManager.js","path":"src/sharding"},"params":[{"name":"shard","description":"Shard that was launched","type":{"types":[[["Shard",""]]]}}]}]},{"id":"Channel","name":"Channel","description":"Represents any Channel on Discord","meta":{"line":4,"file":"Channel.js","path":"src/structures"},"methods":[{"id":"Channel#delete","name":"delete","description":"Deletes the channel","memberof":"Channel","examples":["// delete the channel\rchannel.delete()\r .then() // success\r .catch(console.error); // log error"],"meta":{"line":61,"file":"Channel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Channel",">"]]]},"params":[]}],"properties":[{"id":"Channel#client","name":"client","description":"The client that instantiated the Channel","memberof":"Channel","type":{"types":[[["Client",""]]]},"meta":{"line":10,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"Channel#type","name":"type","description":"The type of the channel, either:\r* `dm` - a DM channel\r* `group` - a Group DM channel\r* `text` - a guild text channel\r* `voice` - a guild voice channel","memberof":"Channel","type":{"types":[[["string",""]]]},"meta":{"line":21,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"Channel#id","name":"id","description":"The unique ID of the channel","memberof":"Channel","type":{"types":[[["string",""]]]},"meta":{"line":31,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"Channel#createdTimestamp","name":"createdTimestamp","description":"The timestamp the channel was created at","memberof":"Channel","type":{"types":[[["number",""]]]},"meta":{"line":39,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"Channel#createdAt","name":"createdAt","description":"The time the channel was created","memberof":"Channel","type":{"types":[[["Date",""]]]},"meta":{"line":48,"file":"Channel.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"ClientUser","name":"ClientUser","description":"Represents the logged in client's Discord User","meta":{"line":8,"file":"ClientUser.js","path":"src/structures"},"extends":["User"],"methods":[{"id":"ClientUser#setUsername","name":"setUsername","description":"Set the username of the logged in Client.\rChanging usernames in Discord is heavily rate limited, with only 2 requests\revery hour. Use this sparingly!","memberof":"ClientUser","examples":["// set username\rclient.user.setUsername('discordjs')\r .then(user => console.log(`My new username is ${user.username}`))\r .catch(console.error);"],"meta":{"line":57,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["ClientUser",">"]]]},"params":[{"name":"username","description":"The new username","type":{"types":[[["string",""]]]}}]},{"id":"ClientUser#setEmail","name":"setEmail","description":"If this user is a \"self bot\" or logged in using a normal user's details (which should be avoided), you can set the\remail here.","memberof":"ClientUser","examples":["// set email\rclient.user.setEmail('bob@gmail.com')\r .then(user => console.log(`My new email is ${user.email}`))\r .catch(console.error);"],"meta":{"line":72,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["ClientUser",">"]]]},"params":[{"name":"email","description":"The new email","type":{"types":[[["string",""]]]}}]},{"id":"ClientUser#setPassword","name":"setPassword","description":"If this user is a \"self bot\" or logged in using a normal user's details (which should be avoided), you can set the\rpassword here.","memberof":"ClientUser","examples":["// set password\rclient.user.setPassword('password123')\r .then(user => console.log('New password set!'))\r .catch(console.error);"],"meta":{"line":87,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["ClientUser",">"]]]},"params":[{"name":"password","description":"The new password","type":{"types":[[["string",""]]]}}]},{"id":"ClientUser#setAvatar","name":"setAvatar","description":"Set the avatar of the logged in Client.","memberof":"ClientUser","examples":["// set avatar\rclient.user.setAvatar('./avatar.png')\r .then(user => console.log(`New avatar set!`))\r .catch(console.error);"],"meta":{"line":101,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["ClientUser",">"]]]},"params":[{"name":"avatar","description":"The new avatar","type":{"types":[[["FileResolvable",""]],[["Base64Resolveable",""]]]}}]},{"id":"ClientUser#setStatus","name":"setStatus","description":"Set the status of the logged in user.","memberof":"ClientUser","meta":{"line":118,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["ClientUser",">"]]]},"params":[{"name":"status","description":"can be `online`, `idle`, `invisible` or `dnd` (do not disturb)","type":{"types":[[["string",""]]]}}]},{"id":"ClientUser#setGame","name":"setGame","description":"Set the current game of the logged in user.","memberof":"ClientUser","meta":{"line":128,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["ClientUser",">"]]]},"params":[{"name":"game","description":"the game being played","type":{"types":[[["string",""]]]}},{"name":"streamingURL","description":"an optional URL to a twitch stream, if one is available.","optional":true,"type":{"types":[[["string",""]]]}}]},{"id":"ClientUser#setAFK","name":"setAFK","description":"Set/remove the AFK flag for the current user.","memberof":"ClientUser","meta":{"line":140,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["ClientUser",">"]]]},"params":[{"name":"afk","description":"whether or not the user is AFK.","type":{"types":[[["boolean",""]]]}}]},{"id":"ClientUser#addFriend","name":"addFriend","description":"Send a friend request\rThis is only available for user accounts, not bot accounts!","memberof":"ClientUser","meta":{"line":150,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[{"name":"user","description":"The user to send the friend request to.","type":{"types":[[["UserResolvable",""]]]}}]},{"id":"ClientUser#removeFriend","name":"removeFriend","description":"Remove a friend\rThis is only available for user accounts, not bot accounts!","memberof":"ClientUser","meta":{"line":161,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[{"name":"user","description":"The user to remove from your friends","type":{"types":[[["UserResolvable",""]]]}}]},{"id":"ClientUser#createGuild","name":"createGuild","description":"Creates a guild\rThis is only available for user accounts, not bot accounts!","memberof":"ClientUser","meta":{"line":174,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"name","description":"The name of the guild","type":{"types":[[["string",""]]]}},{"name":"region","description":"The region for the server","type":{"types":[[["string",""]]]}},{"name":"icon","description":"The icon for the guild","optional":true,"type":{"types":[[["FileResolvable",""]],[["Base64Resolvable",""]]]}}]},{"id":"ClientUser#setPresence","name":"setPresence","description":"Set the full presence of the current user.","memberof":"ClientUser","meta":{"line":192,"file":"ClientUser.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["ClientUser",">"]]]},"params":[{"name":"data","description":"the data to provide","type":{"types":[[["Object",""]]]}}]},{"id":"ClientUser#typingIn","name":"typingIn","description":"Check whether the user is typing in a channel.","memberof":"ClientUser","inherits":"User#typingIn","inherited":true,"meta":{"line":105,"file":"User.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"channel","description":"The channel to check in","type":{"types":[[["ChannelResolvable",""]]]}}]},{"id":"ClientUser#typingSinceIn","name":"typingSinceIn","description":"Get the time that the user started typing.","memberof":"ClientUser","inherits":"User#typingSinceIn","inherited":true,"meta":{"line":115,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Date",""]]]},"params":[{"name":"channel","description":"The channel to get the time in","type":{"types":[[["ChannelResolvable",""]]]}}]},{"id":"ClientUser#typingDurationIn","name":"typingDurationIn","description":"Get the amount of time the user has been typing in a channel for (in milliseconds), or -1 if they're not typing.","memberof":"ClientUser","inherits":"User#typingDurationIn","inherited":true,"meta":{"line":125,"file":"User.js","path":"src/structures"},"returns":{"types":[[["number",""]]]},"params":[{"name":"channel","description":"The channel to get the time in","type":{"types":[[["ChannelResolvable",""]]]}}]},{"id":"ClientUser#deleteDM","name":"deleteDM","description":"Deletes a DM Channel (if one exists) between the Client and the User. Resolves with the Channel if successful.","memberof":"ClientUser","inherits":"User#deleteDM","inherited":true,"meta":{"line":134,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["DMChannel",">"]]]},"params":[]},{"id":"ClientUser#block","name":"block","description":"Blocks the user","memberof":"ClientUser","inherits":"User#block","inherited":true,"meta":{"line":158,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[]},{"id":"ClientUser#unblock","name":"unblock","description":"Unblocks the user","memberof":"ClientUser","inherits":"User#unblock","inherited":true,"meta":{"line":166,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[]},{"id":"ClientUser#fetchProfile","name":"fetchProfile","description":"Get the profile of the user","memberof":"ClientUser","inherits":"User#fetchProfile","inherited":true,"meta":{"line":174,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["UserProfile",">"]]]},"params":[]},{"id":"ClientUser#equals","name":"equals","description":"Checks if the user is equal to another. It compares username, ID, discriminator, status and the game being played.\rIt is recommended to compare equality by using `user.id === user2.id` unless you want to compare all properties.","memberof":"ClientUser","inherits":"User#equals","inherited":true,"meta":{"line":184,"file":"User.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"user","description":"The user to compare","type":{"types":[[["User",""]]]}}]},{"id":"ClientUser#toString","name":"toString","description":"When concatenated with a string, this automatically concatenates the User's mention instead of the User object.","memberof":"ClientUser","examples":["// logs: Hello from <@123456789>!\rconsole.log(`Hello from ${user}!`);"],"inherits":"User#toString","inherited":true,"meta":{"line":202,"file":"User.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]},{"id":"ClientUser#sendMessage","name":"sendMessage","description":"Send a message to this channel","memberof":"ClientUser","examples":["// send a message\rchannel.sendMessage('hello!')\r .then(message => console.log(`Sent message: ${message.content}`))\r .catch(console.error);"],"inherits":"User#sendMessage","inherited":true,"meta":{"line":57,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendMessage"]},{"id":"ClientUser#sendTTSMessage","name":"sendTTSMessage","description":"Send a text-to-speech message to this channel","memberof":"ClientUser","examples":["// send a TTS message\rchannel.sendTTSMessage('hello!')\r .then(message => console.log(`Sent tts message: ${message.content}`))\r .catch(console.error);"],"inherits":"User#sendTTSMessage","inherited":true,"meta":{"line":72,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendTTSMessage"]},{"id":"ClientUser#sendFile","name":"sendFile","description":"Send a file to this channel","memberof":"ClientUser","inherits":"User#sendFile","inherited":true,"meta":{"line":85,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"attachment","description":"The file to send","type":{"types":[[["FileResolvable",""]]]}},{"name":"fileName","description":"The name and extension of the file","optional":true,"type":{"types":[[["string",""]]]}},{"name":"content","description":"Text message to send with the attachment","optional":true,"type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendFile"]},{"id":"ClientUser#sendCode","name":"sendCode","description":"Send a code block to this channel","memberof":"ClientUser","inherits":"User#sendCode","inherited":true,"meta":{"line":112,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"Content of the code block","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendCode"]}],"properties":[{"id":"ClientUser#verified","name":"verified","description":"Whether or not this account has been verified","memberof":"ClientUser","type":{"types":[[["boolean",""]]]},"meta":{"line":16,"file":"ClientUser.js","path":"src/structures"},"props":[]},{"id":"ClientUser#email","name":"email","description":"The email of this account","memberof":"ClientUser","type":{"types":[[["string",""]]]},"meta":{"line":22,"file":"ClientUser.js","path":"src/structures"},"props":[]},{"id":"ClientUser#friends","name":"friends","description":"A Collection of friends for the logged in user.\rThis is only filled for user accounts, not bot accounts!","memberof":"ClientUser","type":{"types":[[["Collection",".<"],["string",", "],["User",">"]]]},"meta":{"line":31,"file":"ClientUser.js","path":"src/structures"},"props":[]},{"id":"ClientUser#blocked","name":"blocked","description":"A Collection of blocked users for the logged in user.\rThis is only filled for user accounts, not bot accounts!","memberof":"ClientUser","type":{"types":[[["Collection",".<"],["string",", "],["User",">"]]]},"meta":{"line":38,"file":"ClientUser.js","path":"src/structures"},"props":[]},{"id":"ClientUser#client","name":"client","description":"The Client that created the instance of the the User.","memberof":"ClientUser","type":{"types":[[["Client",""]]]},"meta":{"line":15,"file":"User.js","path":"src/structures"},"props":[]},{"id":"ClientUser#id","name":"id","description":"The ID of the User","memberof":"ClientUser","type":{"types":[[["string",""]]]},"meta":{"line":26,"file":"User.js","path":"src/structures"},"props":[]},{"id":"ClientUser#username","name":"username","description":"The username of the User","memberof":"ClientUser","type":{"types":[[["string",""]]]},"meta":{"line":32,"file":"User.js","path":"src/structures"},"props":[]},{"id":"ClientUser#discriminator","name":"discriminator","description":"A discriminator based on username for the User","memberof":"ClientUser","type":{"types":[[["string",""]]]},"meta":{"line":38,"file":"User.js","path":"src/structures"},"props":[]},{"id":"ClientUser#avatar","name":"avatar","description":"The ID of the user's avatar","memberof":"ClientUser","type":{"types":[[["string",""]]]},"meta":{"line":44,"file":"User.js","path":"src/structures"},"props":[]},{"id":"ClientUser#bot","name":"bot","description":"Whether or not the User is a Bot.","memberof":"ClientUser","type":{"types":[[["boolean",""]]]},"meta":{"line":50,"file":"User.js","path":"src/structures"},"props":[]},{"id":"ClientUser#createdTimestamp","name":"createdTimestamp","description":"The timestamp the user was created at","memberof":"ClientUser","type":{"types":[[["number",""]]]},"meta":{"line":64,"file":"User.js","path":"src/structures"},"props":[]},{"id":"ClientUser#createdAt","name":"createdAt","description":"The time the user was created","memberof":"ClientUser","type":{"types":[[["Date",""]]]},"meta":{"line":73,"file":"User.js","path":"src/structures"},"props":[]},{"id":"ClientUser#presence","name":"presence","description":"The presence of this user","memberof":"ClientUser","type":{"types":[[["Presence",""]]]},"meta":{"line":82,"file":"User.js","path":"src/structures"},"props":[]},{"id":"ClientUser#avatarURL","name":"avatarURL","description":"A link to the user's avatar (if they have one, otherwise null)","memberof":"ClientUser","type":{"types":[[["string",""]]]},"meta":{"line":95,"file":"User.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"DMChannel","name":"DMChannel","description":"Represents a Direct Message Channel between two users.","meta":{"line":10,"file":"DMChannel.js","path":"src/structures"},"extends":["Channel"],"methods":[{"id":"DMChannel#toString","name":"toString","description":"When concatenated with a string, this automatically concatenates the recipient's mention instead of the\rDM channel object.","memberof":"DMChannel","meta":{"line":35,"file":"DMChannel.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]},{"id":"DMChannel#sendMessage","name":"sendMessage","description":"Send a message to this channel","memberof":"DMChannel","examples":["// send a message\rchannel.sendMessage('hello!')\r .then(message => console.log(`Sent message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":57,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendMessage"]},{"id":"DMChannel#sendTTSMessage","name":"sendTTSMessage","description":"Send a text-to-speech message to this channel","memberof":"DMChannel","examples":["// send a TTS message\rchannel.sendTTSMessage('hello!')\r .then(message => console.log(`Sent tts message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":72,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendTTSMessage"]},{"id":"DMChannel#sendFile","name":"sendFile","description":"Send a file to this channel","memberof":"DMChannel","meta":{"line":85,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"attachment","description":"The file to send","type":{"types":[[["FileResolvable",""]]]}},{"name":"fileName","description":"The name and extension of the file","optional":true,"type":{"types":[[["string",""]]]}},{"name":"content","description":"Text message to send with the attachment","optional":true,"type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendFile"]},{"id":"DMChannel#sendCode","name":"sendCode","description":"Send a code block to this channel","memberof":"DMChannel","meta":{"line":112,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"Content of the code block","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendCode"]},{"id":"DMChannel#fetchMessage","name":"fetchMessage","description":"Gets a single message from this channel, regardless of it being cached or not.\rOnly OAuth bot accounts can use this method.","memberof":"DMChannel","examples":["// get message\rchannel.fetchMessage('99539446449315840')\r .then(message => console.log(message.content))\r .catch(console.error);"],"meta":{"line":133,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"messageID","description":"The ID of the message to get","type":{"types":[[["string",""]]]}}],"implements":["TextBasedChannel#fetchMessage"]},{"id":"DMChannel#fetchMessages","name":"fetchMessages","description":"Gets the past messages sent in this channel. Resolves with a Collection mapping message ID's to Message objects.","memberof":"DMChannel","examples":["// get messages\rchannel.fetchMessages({limit: 10})\r .then(messages => console.log(`Received ${messages.size} messages`))\r .catch(console.error);"],"meta":{"line":165,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"options","description":"The query parameters to pass in","optional":true,"type":{"types":[[["ChannelLogsQueryOptions",""]]]}}],"implements":["TextBasedChannel#fetchMessages"]},{"id":"DMChannel#fetchPinnedMessages","name":"fetchPinnedMessages","description":"Fetches the pinned messages of this Channel and returns a Collection of them.","memberof":"DMChannel","meta":{"line":183,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[],"implements":["TextBasedChannel#fetchPinnedMessages"]},{"id":"DMChannel#startTyping","name":"startTyping","description":"Starts a typing indicator in the channel.","memberof":"DMChannel","examples":["// start typing in a channel\rchannel.startTyping();"],"meta":{"line":204,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["null",""]]]},"params":[{"name":"count","description":"The number of times startTyping should be considered to have been called","optional":true,"type":{"types":[[["number",""]]]}}],"implements":["TextBasedChannel#startTyping"]},{"id":"DMChannel#stopTyping","name":"stopTyping","description":"Stops the typing indicator in the channel.\rThe indicator will only stop if this is called as many times as startTyping().\rIt can take a few seconds for the Client User to stop typing.","memberof":"DMChannel","examples":["// stop typing in a channel\rchannel.stopTyping();","// force typing to fully stop in a channel\rchannel.stopTyping(true);"],"meta":{"line":232,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["null",""]]]},"params":[{"name":"force","description":"Whether or not to reset the call count and force the indicator to stop","optional":true,"type":{"types":[[["boolean",""]]]}}],"implements":["TextBasedChannel#stopTyping"]},{"id":"DMChannel#createCollector","name":"createCollector","description":"Creates a Message Collector","memberof":"DMChannel","examples":["// create a message collector\rconst collector = channel.createCollector(\r m => m.content.includes('discord'),\r { time: 15000 }\r);\rcollector.on('message', m => console.log(`Collected ${m.content}`));\rcollector.on('end', collected => console.log(`Collected ${collected.size} items`));"],"meta":{"line":276,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["MessageCollector",""]]]},"params":[{"name":"filter","description":"The filter to create the collector with","type":{"types":[[["CollectorFilterFunction",""]]]}},{"name":"options","description":"The options to pass to the collector","optional":true,"type":{"types":[[["CollectorOptions",""]]]}}],"implements":["TextBasedChannel#createCollector"]},{"id":"DMChannel#awaitMessages","name":"awaitMessages","description":"Similar to createCollector but in Promise form. Resolves with a Collection of messages that pass the specified\rfilter.","memberof":"DMChannel","examples":["// await !vote messages\rconst filter = m => m.content.startsWith('!vote');\r// errors: ['time'] treats ending because of the time limit as an error\rchannel.awaitMessages(filter, { max: 4, time: 60000, errors: ['time'] })\r .then(collected => console.log(collected.size))\r .catch(collected => console.log(`After a minute, only ${collected.size} out of 4 voted.`));"],"meta":{"line":300,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"filter","description":"The filter function to use","type":{"types":[[["CollectorFilterFunction",""]]]}},{"name":"options","description":"Optional options to pass to the internal collector","optional":true,"type":{"types":[[["AwaitMessagesOptions",""]]]}}],"implements":["TextBasedChannel#awaitMessages"]},{"id":"DMChannel#bulkDelete","name":"bulkDelete","description":"Bulk delete given messages.\rOnly OAuth Bot accounts may use this method.","memberof":"DMChannel","meta":{"line":319,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"messages","description":"Messages to delete, or number of messages to delete","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]],[["Array",".<"],["Message",">"]],[["number",""]]]}}],"implements":["TextBasedChannel#bulkDelete"]},{"id":"DMChannel#delete","name":"delete","description":"Deletes the channel","memberof":"DMChannel","examples":["// delete the channel\rchannel.delete()\r .then() // success\r .catch(console.error); // log error"],"inherits":"Channel#delete","inherited":true,"meta":{"line":61,"file":"Channel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Channel",">"]]]},"params":[]}],"properties":[{"id":"DMChannel#recipient","name":"recipient","description":"The recipient on the other end of the DM","memberof":"DMChannel","type":{"types":[[["User",""]]]},"meta":{"line":25,"file":"DMChannel.js","path":"src/structures"},"props":[]},{"id":"DMChannel#messages","name":"messages","description":"A Collection containing the messages sent to this channel.","memberof":"DMChannel","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]]]},"meta":{"line":17,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"DMChannel#lastMessageID","name":"lastMessageID","description":"The ID of the last message in the channel, if one was sent.","memberof":"DMChannel","type":{"types":[[["string",""]]]},"meta":{"line":23,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"DMChannel#typing","name":"typing","description":"Whether or not the typing indicator is being shown in the channel.","memberof":"DMChannel","type":{"types":[[["boolean",""]]]},"meta":{"line":248,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"DMChannel#typingCount","name":"typingCount","description":"Number of times `startTyping` has been called.","memberof":"DMChannel","type":{"types":[[["number",""]]]},"meta":{"line":257,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"DMChannel#client","name":"client","description":"The client that instantiated the Channel","memberof":"DMChannel","type":{"types":[[["Client",""]]]},"meta":{"line":10,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"DMChannel#type","name":"type","description":"The type of the channel, either:\r* `dm` - a DM channel\r* `group` - a Group DM channel\r* `text` - a guild text channel\r* `voice` - a guild voice channel","memberof":"DMChannel","type":{"types":[[["string",""]]]},"meta":{"line":21,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"DMChannel#id","name":"id","description":"The unique ID of the channel","memberof":"DMChannel","type":{"types":[[["string",""]]]},"meta":{"line":31,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"DMChannel#createdTimestamp","name":"createdTimestamp","description":"The timestamp the channel was created at","memberof":"DMChannel","type":{"types":[[["number",""]]]},"meta":{"line":39,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"DMChannel#createdAt","name":"createdAt","description":"The time the channel was created","memberof":"DMChannel","type":{"types":[[["Date",""]]]},"meta":{"line":48,"file":"Channel.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"Emoji","name":"Emoji","description":"Represents a Custom Emoji","meta":{"line":7,"file":"Emoji.js","path":"src/structures"},"methods":[{"id":"Emoji#toString","name":"toString","description":"When concatenated with a string, this automatically returns the emoji mention rather than the object.","memberof":"Emoji","examples":["// send an emoji:\rconst emoji = guild.emojis.first();\rmsg.reply(`Hello! ${emoji}`);"],"meta":{"line":101,"file":"Emoji.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]}],"properties":[{"id":"Emoji#client","name":"client","description":"The Client that instantiated this object","memberof":"Emoji","type":{"types":[[["Client",""]]]},"meta":{"line":13,"file":"Emoji.js","path":"src/structures"},"props":[]},{"id":"Emoji#guild","name":"guild","description":"The Guild this emoji is part of","memberof":"Emoji","type":{"types":[[["Guild",""]]]},"meta":{"line":20,"file":"Emoji.js","path":"src/structures"},"props":[]},{"id":"Emoji#id","name":"id","description":"The ID of the Emoji","memberof":"Emoji","type":{"types":[[["string",""]]]},"meta":{"line":30,"file":"Emoji.js","path":"src/structures"},"props":[]},{"id":"Emoji#name","name":"name","description":"The name of the Emoji","memberof":"Emoji","type":{"types":[[["string",""]]]},"meta":{"line":36,"file":"Emoji.js","path":"src/structures"},"props":[]},{"id":"Emoji#requiresColons","name":"requiresColons","description":"Whether or not this emoji requires colons surrounding it","memberof":"Emoji","type":{"types":[[["boolean",""]]]},"meta":{"line":42,"file":"Emoji.js","path":"src/structures"},"props":[]},{"id":"Emoji#managed","name":"managed","description":"Whether this emoji is managed by an external service","memberof":"Emoji","type":{"types":[[["boolean",""]]]},"meta":{"line":48,"file":"Emoji.js","path":"src/structures"},"props":[]},{"id":"Emoji#createdTimestamp","name":"createdTimestamp","description":"The timestamp the emoji was created at","memberof":"Emoji","type":{"types":[[["number",""]]]},"meta":{"line":58,"file":"Emoji.js","path":"src/structures"},"props":[]},{"id":"Emoji#createdAt","name":"createdAt","description":"The time the emoji was created","memberof":"Emoji","type":{"types":[[["Date",""]]]},"meta":{"line":67,"file":"Emoji.js","path":"src/structures"},"props":[]},{"id":"Emoji#roles","name":"roles","description":"A collection of roles this emoji is active for (empty if all), mapped by role ID.","memberof":"Emoji","type":{"types":[[["Collection",".<"],["string",", "],["Role",">"]]]},"meta":{"line":76,"file":"Emoji.js","path":"src/structures"},"props":[]},{"id":"Emoji#url","name":"url","description":"The URL to the emoji file","memberof":"Emoji","type":{"types":[[["string",""]]]},"meta":{"line":89,"file":"Emoji.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"EvaluatedPermissions","name":"EvaluatedPermissions","description":"The final evaluated permissions for a member in a channel","meta":{"line":6,"file":"EvaluatedPermissions.js","path":"src/structures"},"methods":[{"id":"EvaluatedPermissions#serialize","name":"serialize","description":"Get an object mapping permission name, e.g. `READ_MESSAGES` to a boolean - whether the user\rcan perform this or not.","memberof":"EvaluatedPermissions","meta":{"line":26,"file":"EvaluatedPermissions.js","path":"src/structures"},"returns":{"types":[[["Object",".<"],["string",", "],["boolean",">"]]]},"params":[]},{"id":"EvaluatedPermissions#hasPermission","name":"hasPermission","description":"Checks whether the user has a certain permission, e.g. `READ_MESSAGES`.","memberof":"EvaluatedPermissions","meta":{"line":40,"file":"EvaluatedPermissions.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"permission","description":"The permission to check for","type":{"types":[[["PermissionResolvable",""]]]}},{"name":"explicit","description":"Whether to require the user to explicitly have the exact permission","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"EvaluatedPermissions#hasPermissions","name":"hasPermissions","description":"Checks whether the user has all specified permissions.","memberof":"EvaluatedPermissions","meta":{"line":52,"file":"EvaluatedPermissions.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"permissions","description":"The permissions to check for","type":{"types":[[["Array",".<"],["PermissionResolvable",">"]]]}},{"name":"explicit","description":"Whether to require the user to explicitly have the exact permissions","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"EvaluatedPermissions#missingPermissions","name":"missingPermissions","description":"Checks whether the user has all specified permissions, and lists any missing permissions.","memberof":"EvaluatedPermissions","meta":{"line":62,"file":"EvaluatedPermissions.js","path":"src/structures"},"returns":{"types":[[["array",""]]]},"params":[{"name":"permissions","description":"The permissions to check for","type":{"types":[[["Array",".<"],["PermissionResolvable",">"]]]}},{"name":"explicit","description":"Whether to require the user to explicitly have the exact permissions","optional":true,"type":{"types":[[["boolean",""]]]}}]}],"properties":[{"id":"EvaluatedPermissions#member","name":"member","description":"The member this permissions refer to","memberof":"EvaluatedPermissions","type":{"types":[[["GuildMember",""]]]},"meta":{"line":12,"file":"EvaluatedPermissions.js","path":"src/structures"},"props":[]},{"id":"EvaluatedPermissions#raw","name":"raw","description":"A number representing the packed permissions","memberof":"EvaluatedPermissions","type":{"types":[[["number",""]]]},"meta":{"line":18,"file":"EvaluatedPermissions.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"GroupDMChannel","name":"GroupDMChannel","description":"Represents a Group DM on Discord","meta":{"line":33,"file":"GroupDMChannel.js","path":"src/structures"},"extends":["Channel"],"methods":[{"id":"GroupDMChannel#equals","name":"equals","description":"Whether this channel equals another channel. It compares all properties, so for most operations\rit is advisable to just compare `channel.id === channel2.id` as it is much faster and is often\rwhat most users need.","memberof":"GroupDMChannel","meta":{"line":96,"file":"GroupDMChannel.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"channel","description":"The channel to compare to","type":{"types":[[["GroupDMChannel",""]]]}}]},{"id":"GroupDMChannel#toString","name":"toString","description":"When concatenated with a string, this automatically concatenates the Channel's name instead of the Channel object.","memberof":"GroupDMChannel","examples":["// logs: Hello from My Group DM!\rconsole.log(`Hello from ${channel}!`);","// logs: Hello from My Group DM!\rconsole.log(`Hello from ' + channel + '!');"],"meta":{"line":122,"file":"GroupDMChannel.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]},{"id":"GroupDMChannel#sendMessage","name":"sendMessage","description":"Send a message to this channel","memberof":"GroupDMChannel","examples":["// send a message\rchannel.sendMessage('hello!')\r .then(message => console.log(`Sent message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":57,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendMessage"]},{"id":"GroupDMChannel#sendTTSMessage","name":"sendTTSMessage","description":"Send a text-to-speech message to this channel","memberof":"GroupDMChannel","examples":["// send a TTS message\rchannel.sendTTSMessage('hello!')\r .then(message => console.log(`Sent tts message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":72,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendTTSMessage"]},{"id":"GroupDMChannel#sendFile","name":"sendFile","description":"Send a file to this channel","memberof":"GroupDMChannel","meta":{"line":85,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"attachment","description":"The file to send","type":{"types":[[["FileResolvable",""]]]}},{"name":"fileName","description":"The name and extension of the file","optional":true,"type":{"types":[[["string",""]]]}},{"name":"content","description":"Text message to send with the attachment","optional":true,"type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendFile"]},{"id":"GroupDMChannel#sendCode","name":"sendCode","description":"Send a code block to this channel","memberof":"GroupDMChannel","meta":{"line":112,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"Content of the code block","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendCode"]},{"id":"GroupDMChannel#fetchMessage","name":"fetchMessage","description":"Gets a single message from this channel, regardless of it being cached or not.\rOnly OAuth bot accounts can use this method.","memberof":"GroupDMChannel","examples":["// get message\rchannel.fetchMessage('99539446449315840')\r .then(message => console.log(message.content))\r .catch(console.error);"],"meta":{"line":133,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"messageID","description":"The ID of the message to get","type":{"types":[[["string",""]]]}}],"implements":["TextBasedChannel#fetchMessage"]},{"id":"GroupDMChannel#fetchMessages","name":"fetchMessages","description":"Gets the past messages sent in this channel. Resolves with a Collection mapping message ID's to Message objects.","memberof":"GroupDMChannel","examples":["// get messages\rchannel.fetchMessages({limit: 10})\r .then(messages => console.log(`Received ${messages.size} messages`))\r .catch(console.error);"],"meta":{"line":165,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"options","description":"The query parameters to pass in","optional":true,"type":{"types":[[["ChannelLogsQueryOptions",""]]]}}],"implements":["TextBasedChannel#fetchMessages"]},{"id":"GroupDMChannel#fetchPinnedMessages","name":"fetchPinnedMessages","description":"Fetches the pinned messages of this Channel and returns a Collection of them.","memberof":"GroupDMChannel","meta":{"line":183,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[],"implements":["TextBasedChannel#fetchPinnedMessages"]},{"id":"GroupDMChannel#startTyping","name":"startTyping","description":"Starts a typing indicator in the channel.","memberof":"GroupDMChannel","examples":["// start typing in a channel\rchannel.startTyping();"],"meta":{"line":204,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["null",""]]]},"params":[{"name":"count","description":"The number of times startTyping should be considered to have been called","optional":true,"type":{"types":[[["number",""]]]}}],"implements":["TextBasedChannel#startTyping"]},{"id":"GroupDMChannel#stopTyping","name":"stopTyping","description":"Stops the typing indicator in the channel.\rThe indicator will only stop if this is called as many times as startTyping().\rIt can take a few seconds for the Client User to stop typing.","memberof":"GroupDMChannel","examples":["// stop typing in a channel\rchannel.stopTyping();","// force typing to fully stop in a channel\rchannel.stopTyping(true);"],"meta":{"line":232,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["null",""]]]},"params":[{"name":"force","description":"Whether or not to reset the call count and force the indicator to stop","optional":true,"type":{"types":[[["boolean",""]]]}}],"implements":["TextBasedChannel#stopTyping"]},{"id":"GroupDMChannel#createCollector","name":"createCollector","description":"Creates a Message Collector","memberof":"GroupDMChannel","examples":["// create a message collector\rconst collector = channel.createCollector(\r m => m.content.includes('discord'),\r { time: 15000 }\r);\rcollector.on('message', m => console.log(`Collected ${m.content}`));\rcollector.on('end', collected => console.log(`Collected ${collected.size} items`));"],"meta":{"line":276,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["MessageCollector",""]]]},"params":[{"name":"filter","description":"The filter to create the collector with","type":{"types":[[["CollectorFilterFunction",""]]]}},{"name":"options","description":"The options to pass to the collector","optional":true,"type":{"types":[[["CollectorOptions",""]]]}}],"implements":["TextBasedChannel#createCollector"]},{"id":"GroupDMChannel#awaitMessages","name":"awaitMessages","description":"Similar to createCollector but in Promise form. Resolves with a Collection of messages that pass the specified\rfilter.","memberof":"GroupDMChannel","examples":["// await !vote messages\rconst filter = m => m.content.startsWith('!vote');\r// errors: ['time'] treats ending because of the time limit as an error\rchannel.awaitMessages(filter, { max: 4, time: 60000, errors: ['time'] })\r .then(collected => console.log(collected.size))\r .catch(collected => console.log(`After a minute, only ${collected.size} out of 4 voted.`));"],"meta":{"line":300,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"filter","description":"The filter function to use","type":{"types":[[["CollectorFilterFunction",""]]]}},{"name":"options","description":"Optional options to pass to the internal collector","optional":true,"type":{"types":[[["AwaitMessagesOptions",""]]]}}],"implements":["TextBasedChannel#awaitMessages"]},{"id":"GroupDMChannel#bulkDelete","name":"bulkDelete","description":"Bulk delete given messages.\rOnly OAuth Bot accounts may use this method.","memberof":"GroupDMChannel","meta":{"line":319,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"messages","description":"Messages to delete, or number of messages to delete","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]],[["Array",".<"],["Message",">"]],[["number",""]]]}}],"implements":["TextBasedChannel#bulkDelete"]},{"id":"GroupDMChannel#delete","name":"delete","description":"Deletes the channel","memberof":"GroupDMChannel","examples":["// delete the channel\rchannel.delete()\r .then() // success\r .catch(console.error); // log error"],"inherits":"Channel#delete","inherited":true,"meta":{"line":61,"file":"Channel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Channel",">"]]]},"params":[]}],"properties":[{"id":"GroupDMChannel#name","name":"name","description":"The name of this Group DM, can be null if one isn't set.","memberof":"GroupDMChannel","type":{"types":[[["string",""]]]},"meta":{"line":48,"file":"GroupDMChannel.js","path":"src/structures"},"props":[]},{"id":"GroupDMChannel#icon","name":"icon","description":"A hash of the Group DM icon.","memberof":"GroupDMChannel","type":{"types":[[["string",""]]]},"meta":{"line":54,"file":"GroupDMChannel.js","path":"src/structures"},"props":[]},{"id":"GroupDMChannel#ownerID","name":"ownerID","description":"The user ID of this Group DM's owner.","memberof":"GroupDMChannel","type":{"types":[[["string",""]]]},"meta":{"line":60,"file":"GroupDMChannel.js","path":"src/structures"},"props":[]},{"id":"GroupDMChannel#recipients","name":"recipients","description":"A collection of the recipients of this DM, mapped by their ID.","memberof":"GroupDMChannel","type":{"types":[[["Collection",".<"],["string",", "],["User",">"]]]},"meta":{"line":67,"file":"GroupDMChannel.js","path":"src/structures"},"props":[]},{"id":"GroupDMChannel#owner","name":"owner","description":"The owner of this Group DM.","memberof":"GroupDMChannel","type":{"types":[[["User",""]]]},"meta":{"line":85,"file":"GroupDMChannel.js","path":"src/structures"},"props":[]},{"id":"GroupDMChannel#messages","name":"messages","description":"A Collection containing the messages sent to this channel.","memberof":"GroupDMChannel","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]]]},"meta":{"line":17,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"GroupDMChannel#lastMessageID","name":"lastMessageID","description":"The ID of the last message in the channel, if one was sent.","memberof":"GroupDMChannel","type":{"types":[[["string",""]]]},"meta":{"line":23,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"GroupDMChannel#typing","name":"typing","description":"Whether or not the typing indicator is being shown in the channel.","memberof":"GroupDMChannel","type":{"types":[[["boolean",""]]]},"meta":{"line":248,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"GroupDMChannel#typingCount","name":"typingCount","description":"Number of times `startTyping` has been called.","memberof":"GroupDMChannel","type":{"types":[[["number",""]]]},"meta":{"line":257,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"GroupDMChannel#client","name":"client","description":"The client that instantiated the Channel","memberof":"GroupDMChannel","type":{"types":[[["Client",""]]]},"meta":{"line":10,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"GroupDMChannel#type","name":"type","description":"The type of the channel, either:\r* `dm` - a DM channel\r* `group` - a Group DM channel\r* `text` - a guild text channel\r* `voice` - a guild voice channel","memberof":"GroupDMChannel","type":{"types":[[["string",""]]]},"meta":{"line":21,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"GroupDMChannel#id","name":"id","description":"The unique ID of the channel","memberof":"GroupDMChannel","type":{"types":[[["string",""]]]},"meta":{"line":31,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"GroupDMChannel#createdTimestamp","name":"createdTimestamp","description":"The timestamp the channel was created at","memberof":"GroupDMChannel","type":{"types":[[["number",""]]]},"meta":{"line":39,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"GroupDMChannel#createdAt","name":"createdAt","description":"The time the channel was created","memberof":"GroupDMChannel","type":{"types":[[["Date",""]]]},"meta":{"line":48,"file":"Channel.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"Guild","name":"Guild","description":"Represents a Guild (or a Server) on Discord.\rIt's recommended to see if a guild is available before performing operations or reading data from it. You can\rcheck this with `guild.available`.","meta":{"line":16,"file":"Guild.js","path":"src/structures"},"methods":[{"id":"Guild#setup","access":"private","name":"setup","description":"Sets up the Guild","memberof":"Guild","meta":{"line":67,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["null",""]]]},"params":[{"name":"data","description":"The raw data of the guild","type":{"types":[["*",""]]}}]},{"id":"Guild#member","name":"member","description":"Returns the GuildMember form of a User object, if the User is present in the guild.","memberof":"Guild","examples":["// get the guild member of a user\rconst member = guild.member(message.author);"],"meta":{"line":279,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["GuildMember",""]]]},"params":[{"name":"user","description":"The user that you want to obtain the GuildMember of","type":{"types":[[["UserResolvable",""]]]}}]},{"id":"Guild#fetchBans","name":"fetchBans","description":"Fetch a Collection of banned users in this Guild.","memberof":"Guild","meta":{"line":287,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["User",">>"]]]},"params":[]},{"id":"Guild#fetchInvites","name":"fetchInvites","description":"Fetch a Collection of invites to this Guild. Resolves with a Collection mapping invites by their codes.","memberof":"Guild","meta":{"line":295,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Invite",">>"]]]},"params":[]},{"id":"Guild#fetchWebhooks","name":"fetchWebhooks","description":"Fetch all webhooks for the guild.","memberof":"Guild","meta":{"line":303,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Collection",".<"],["Webhook",">"]]]},"params":[]},{"id":"Guild#fetchMember","name":"fetchMember","description":"Fetch a single guild member from a user.","memberof":"Guild","meta":{"line":312,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"user","description":"The user to fetch the member for","type":{"types":[[["UserResolvable",""]]]}}]},{"id":"Guild#fetchMembers","name":"fetchMembers","description":"Fetches all the members in the Guild, even if they are offline. If the Guild has less than 250 members,\rthis should not be necessary.","memberof":"Guild","meta":{"line":326,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"query","description":"An optional query to provide when fetching members","optional":true,"type":{"types":[[["string",""]]]}}]},{"id":"Guild#edit","name":"edit","description":"Updates the Guild with new information - e.g. a new name.","memberof":"Guild","examples":["// set the guild name and region\rguild.edit({\r name: 'Discord Guild',\r region: 'london',\r})\r.then(updated => console.log(`New guild name ${updated.name} in region ${updated.region}`))\r.catch(console.error);"],"meta":{"line":360,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"data","description":"The data to update the guild with","type":{"types":[[["GuildEditData",""]]]}}]},{"id":"Guild#setName","name":"setName","description":"Edit the name of the Guild.","memberof":"Guild","examples":["// edit the guild name\rguild.setName('Discord Guild')\r .then(updated => console.log(`Updated guild name to ${guild.name}`))\r .catch(console.error);"],"meta":{"line":374,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"name","description":"The new name of the Guild","type":{"types":[[["string",""]]]}}]},{"id":"Guild#setRegion","name":"setRegion","description":"Edit the region of the Guild.","memberof":"Guild","examples":["// edit the guild region\rguild.setRegion('london')\r .then(updated => console.log(`Updated guild region to ${guild.region}`))\r .catch(console.error);"],"meta":{"line":388,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"region","description":"The new region of the guild.","type":{"types":[[["Region",""]]]}}]},{"id":"Guild#setVerificationLevel","name":"setVerificationLevel","description":"Edit the verification level of the Guild.","memberof":"Guild","examples":["// edit the guild verification level\rguild.setVerificationLevel(1)\r .then(updated => console.log(`Updated guild verification level to ${guild.verificationLevel}`))\r .catch(console.error);"],"meta":{"line":402,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"verificationLevel","description":"The new verification level of the guild","type":{"types":[[["VerificationLevel",""]]]}}]},{"id":"Guild#setAFKChannel","name":"setAFKChannel","description":"Edit the AFK channel of the Guild.","memberof":"Guild","examples":["// edit the guild AFK channel\rguild.setAFKChannel(channel)\r .then(updated => console.log(`Updated guild AFK channel to ${guild.afkChannel}`))\r .catch(console.error);"],"meta":{"line":416,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"afkChannel","description":"The new AFK channel","type":{"types":[[["GuildChannelResolvable",""]]]}}]},{"id":"Guild#setAFKTimeout","name":"setAFKTimeout","description":"Edit the AFK timeout of the Guild.","memberof":"Guild","examples":["// edit the guild AFK channel\rguild.setAFKTimeout(60)\r .then(updated => console.log(`Updated guild AFK timeout to ${guild.afkTimeout}`))\r .catch(console.error);"],"meta":{"line":430,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"afkTimeout","description":"The time in seconds that a user must be idle to be considered AFK","type":{"types":[[["number",""]]]}}]},{"id":"Guild#setIcon","name":"setIcon","description":"Set a new Guild Icon.","memberof":"Guild","examples":["// edit the guild icon\rguild.setIcon(fs.readFileSync('./icon.png'))\r .then(updated => console.log('Updated the guild icon'))\r .catch(console.error);"],"meta":{"line":444,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"icon","description":"The new icon of the guild","type":{"types":[[["Base64Resolvable",""]]]}}]},{"id":"Guild#setOwner","name":"setOwner","description":"Sets a new owner of the Guild.","memberof":"Guild","examples":["// edit the guild owner\rguild.setOwner(guilds.members[0])\r .then(updated => console.log(`Updated the guild owner to ${updated.owner.username}`))\r .catch(console.error);"],"meta":{"line":458,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"owner","description":"The new owner of the Guild","type":{"types":[[["GuildMemberResolvable",""]]]}}]},{"id":"Guild#setSplash","name":"setSplash","description":"Set a new Guild Splash Logo.","memberof":"Guild","examples":["// edit the guild splash\rguild.setIcon(fs.readFileSync('./splash.png'))\r .then(updated => console.log('Updated the guild splash'))\r .catch(console.error);"],"meta":{"line":472,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"splash","description":"The new splash screen of the guild","type":{"types":[[["Base64Resolvable",""]]]}}]},{"id":"Guild#ban","name":"ban","description":"Bans a user from the guild.","memberof":"Guild","examples":["// ban a user\rguild.ban('123123123123');"],"meta":{"line":488,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<("],["GuildMember","|"],["User","|"],["string",")>"]]]},"params":[{"name":"user","description":"The user to ban","type":{"types":[[["UserResolvable",""]]]}},{"name":"deleteDays","description":"The amount of days worth of messages from this user that should\ralso be deleted. Between `0` and `7`.","optional":true,"type":{"types":[[["number",""]]]}}]},{"id":"Guild#unban","name":"unban","description":"Unbans a user from the Guild.","memberof":"Guild","examples":["// unban a user\rguild.unban('123123123123')\r .then(user => console.log(`Unbanned ${user.username} from ${guild.name}`))\r .catch(reject);"],"meta":{"line":502,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[{"name":"user","description":"The user to unban","type":{"types":[[["UserResolvable",""]]]}}]},{"id":"Guild#pruneMembers","name":"pruneMembers","description":"Prunes members from the guild based on how long they have been inactive.","memberof":"Guild","examples":["// see how many members will be pruned\rguild.pruneMembers(12, true)\r .then(pruned => console.log(`This will prune ${pruned} people!`);\r .catch(console.error);","// actually prune the members\rguild.pruneMembers(12)\r .then(pruned => console.log(`I just pruned ${pruned} people!`);\r .catch(console.error);"],"meta":{"line":522,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["number",">"]]]},"params":[{"name":"days","description":"Number of days of inactivity required to kick","type":{"types":[[["number",""]]]}},{"name":"dry","description":"If true, will return number of users that will be kicked, without actually doing it","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"Guild#sync","name":"sync","description":"Syncs this guild (already done automatically every 30 seconds). Only applicable to user accounts.","memberof":"Guild","meta":{"line":530,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"Guild#createChannel","name":"createChannel","description":"Creates a new Channel in the Guild.","memberof":"Guild","examples":["// create a new text channel\rguild.createChannel('new-general', 'text')\r .then(channel => console.log(`Created new channel ${channel}`))\r .catch(console.error);"],"meta":{"line":545,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<("],["TextChannel","|"],["VoiceChannel",")>"]]]},"params":[{"name":"name","description":"The name of the new channel","type":{"types":[[["string",""]]]}},{"name":"type","description":"The type of the new channel, either `text` or `voice`","type":{"types":[[["string",""]]]}}]},{"id":"Guild#createRole","name":"createRole","description":"Creates a new role in the guild, and optionally updates it with the given information.","memberof":"Guild","examples":["// create a new role\rguild.createRole()\r .then(role => console.log(`Created role ${role}`))\r .catch(console.error);","// create a new role with data\rguild.createRole({ name: 'Super Cool People' })\r .then(role => console.log(`Created role ${role}`))\r .catch(console.error)"],"meta":{"line":564,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Role",">"]]]},"params":[{"name":"data","description":"The data to update the role with","optional":true,"type":{"types":[[["RoleData",""]]]}}]},{"id":"Guild#createEmoji","name":"createEmoji","description":"Creates a new custom emoji in the guild.","memberof":"Guild","examples":["// create a new emoji from a url\rguild.createEmoji('https://i.imgur.com/w3duR07.png', 'rip')\r .then(emoji => console.log(`Created new emoji with name ${emoji.name}!`))\r .catch(console.error);","// create a new emoji from a file on your computer\rguild.createEmoji('./memes/banana.png', 'banana')\r .then(emoji => console.log(`Created new emoji with name ${emoji.name}!`))\r .catch(console.error);"],"meta":{"line":586,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Emoji",">"]]]},"params":[{"name":"attachment","description":"The image for the emoji.","type":{"types":[[["FileResolveable",""]]]}},{"name":"name","description":"The name for the emoji.","type":{"types":[[["string",""]]]}}]},{"id":"Guild#deleteEmoji","name":"deleteEmoji","description":"Delete an emoji.","memberof":"Guild","meta":{"line":602,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",""]]]},"params":[{"name":"emoji","description":"The emoji to delete.","type":{"types":[[["Emoji",""]],[["string",""]]]}}]},{"id":"Guild#leave","name":"leave","description":"Causes the Client to leave the guild.","memberof":"Guild","examples":["// leave a guild\rguild.leave()\r .then(g => console.log(`Left the guild ${g}`))\r .catch(console.error);"],"meta":{"line":616,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[]},{"id":"Guild#delete","name":"delete","description":"Causes the Client to delete the guild.","memberof":"Guild","examples":["// delete a guild\rguild.delete()\r .then(g => console.log(`Deleted the guild ${g}`))\r .catch(console.error);"],"meta":{"line":629,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[]},{"id":"Guild#setRolePosition","name":"setRolePosition","description":"Set the position of a role in this guild","memberof":"Guild","meta":{"line":639,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Guild",">"]]]},"params":[{"name":"role","description":"the role to edit, can be a role object or a role ID.","type":{"types":[[["string",""]],[["Role",""]]]}},{"name":"position","description":"the new position of the role","type":{"types":[[["number",""]]]}}]},{"id":"Guild#equals","name":"equals","description":"Whether this Guild equals another Guild. It compares all properties, so for most operations\rit is advisable to just compare `guild.id === guild2.id` as it is much faster and is often\rwhat most users need.","memberof":"Guild","meta":{"line":666,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"guild","description":"The guild to compare","type":{"types":[[["Guild",""]]]}}]},{"id":"Guild#toString","name":"toString","description":"When concatenated with a string, this automatically concatenates the Guild's name instead of the Guild object.","memberof":"Guild","examples":["// logs: Hello from My Guild!\rconsole.log(`Hello from ${guild}!`);","// logs: Hello from My Guild!\rconsole.log(`Hello from ' + guild + '!');"],"meta":{"line":703,"file":"Guild.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]}],"properties":[{"id":"Guild#client","name":"client","description":"The Client that created the instance of the the Guild.","memberof":"Guild","type":{"types":[[["Client",""]]]},"meta":{"line":22,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#members","name":"members","description":"A Collection of members that are in this Guild. The key is the member's ID, the value is the member.","memberof":"Guild","type":{"types":[[["Collection",".<"],["string",", "],["GuildMember",">"]]]},"meta":{"line":29,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#channels","name":"channels","description":"A Collection of channels that are in this Guild. The key is the channel's ID, the value is the channel.","memberof":"Guild","type":{"types":[[["Collection",".<"],["string",", "],["GuildChannel",">"]]]},"meta":{"line":35,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#roles","name":"roles","description":"A Collection of roles that are in this Guild. The key is the role's ID, the value is the role.","memberof":"Guild","type":{"types":[[["Collection",".<"],["string",", "],["Role",">"]]]},"meta":{"line":41,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#available","name":"available","description":"Whether the Guild is available to access. If it is not available, it indicates a server outage.","memberof":"Guild","type":{"types":[[["boolean",""]]]},"meta":{"line":49,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#id","name":"id","description":"The Unique ID of the Guild, useful for comparisons.","memberof":"Guild","type":{"types":[[["string",""]]]},"meta":{"line":55,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#name","name":"name","description":"The name of the guild","memberof":"Guild","type":{"types":[[["string",""]]]},"meta":{"line":72,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#icon","name":"icon","description":"The hash of the guild icon, or null if there is no icon.","memberof":"Guild","type":{"types":[[["string",""]]]},"meta":{"line":78,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#splash","name":"splash","description":"The hash of the guild splash image, or null if no splash (VIP only)","memberof":"Guild","type":{"types":[[["string",""]]]},"meta":{"line":84,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#region","name":"region","description":"The region the guild is located in","memberof":"Guild","type":{"types":[[["string",""]]]},"meta":{"line":90,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#memberCount","name":"memberCount","description":"The full amount of members in this Guild as of `READY`","memberof":"Guild","type":{"types":[[["number",""]]]},"meta":{"line":96,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#large","name":"large","description":"Whether the guild is \"large\" (has more than 250 members)","memberof":"Guild","type":{"types":[[["boolean",""]]]},"meta":{"line":102,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#presences","name":"presences","description":"A collection of presences in this Guild","memberof":"Guild","type":{"types":[[["Collection",".<"],["string",", "],["Presence",">"]]]},"meta":{"line":108,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#features","name":"features","description":"An array of guild features.","memberof":"Guild","type":{"types":[[["Array",".<"],["Object",">"]]]},"meta":{"line":114,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#emojis","name":"emojis","description":"A Collection of emojis that are in this Guild. The key is the emoji's ID, the value is the emoji.","memberof":"Guild","type":{"types":[[["Collection",".<"],["string",", "],["Emoji",">"]]]},"meta":{"line":120,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#afkTimeout","name":"afkTimeout","description":"The time in seconds before a user is counted as \"away from keyboard\".","memberof":"Guild","type":{"types":[[["number",""]]]},"meta":{"line":127,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#afkChannelID","name":"afkChannelID","description":"The ID of the voice channel where AFK members are moved.","memberof":"Guild","type":{"types":[[["string",""]]]},"meta":{"line":133,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#embedEnabled","name":"embedEnabled","description":"Whether embedded images are enabled on this guild.","memberof":"Guild","type":{"types":[[["boolean",""]]]},"meta":{"line":139,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#verificationLevel","name":"verificationLevel","description":"The verification level of the guild.","memberof":"Guild","type":{"types":[[["number",""]]]},"meta":{"line":145,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#joinedTimestamp","name":"joinedTimestamp","description":"The timestamp the client user joined the guild at","memberof":"Guild","type":{"types":[[["number",""]]]},"meta":{"line":151,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#ownerID","name":"ownerID","description":"The user ID of this guild's owner.","memberof":"Guild","type":{"types":[[["string",""]]]},"meta":{"line":167,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#createdTimestamp","name":"createdTimestamp","description":"The timestamp the guild was created at","memberof":"Guild","type":{"types":[[["number",""]]]},"meta":{"line":212,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#createdAt","name":"createdAt","description":"The time the guild was created","memberof":"Guild","type":{"types":[[["Date",""]]]},"meta":{"line":221,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#joinedAt","name":"joinedAt","description":"The time the client user joined the guild","memberof":"Guild","type":{"types":[[["Date",""]]]},"meta":{"line":230,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#iconURL","name":"iconURL","description":"Gets the URL to this guild's icon (if it has one, otherwise it returns null)","memberof":"Guild","type":{"types":[[["string",""]]]},"meta":{"line":239,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#owner","name":"owner","description":"The owner of the Guild","memberof":"Guild","type":{"types":[[["GuildMember",""]]]},"meta":{"line":249,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#voiceConnection","name":"voiceConnection","description":"If the client is connected to any voice channel in this guild, this will be the relevant VoiceConnection.","memberof":"Guild","type":{"types":[[["VoiceConnection",""]]]},"meta":{"line":258,"file":"Guild.js","path":"src/structures"},"props":[]},{"id":"Guild#defaultChannel","name":"defaultChannel","description":"The `#general` GuildChannel of the server.","memberof":"Guild","type":{"types":[[["GuildChannel",""]]]},"meta":{"line":267,"file":"Guild.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"GuildChannel","name":"GuildChannel","description":"Represents a Guild Channel (i.e. Text Channels and Voice Channels)","meta":{"line":13,"file":"GuildChannel.js","path":"src/structures"},"extends":["Channel"],"methods":[{"id":"GuildChannel#permissionsFor","name":"permissionsFor","description":"Gets the overall set of permissions for a user in this channel, taking into account roles and permission\roverwrites.","memberof":"GuildChannel","meta":{"line":57,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["EvaluatedPermissions",""]]]},"params":[{"name":"member","description":"The user that you want to obtain the overall permissions for","type":{"types":[[["GuildMemberResolvable",""]]]}}]},{"id":"GuildChannel#overwritePermissions","name":"overwritePermissions","description":"Overwrites the permissions for a user or role in this channel.","memberof":"GuildChannel","examples":["// overwrite permissions for a message author\rmessage.channel.overwritePermissions(message.author, {\r SEND_MESSAGES: false\r})\r.then(() => console.log('Done!'))\r.catch(console.error);"],"meta":{"line":125,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",""]]]},"params":[{"name":"userOrRole","description":"The user or role to update","type":{"types":[[["RoleResolvable",""]],[["UserResolvable",""]]]}},{"name":"options","description":"The configuration for the update","type":{"types":[[["PermissionOverwriteOptions",""]]]}}]},{"id":"GuildChannel#setName","name":"setName","description":"Set a new name for the Guild Channel","memberof":"GuildChannel","examples":["// set a new channel name\rchannel.setName('not_general')\r .then(newChannel => console.log(`Channel's new name is ${newChannel.name}`))\r .catch(console.error);"],"meta":{"line":178,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildChannel",">"]]]},"params":[{"name":"name","description":"The new name for the guild channel","type":{"types":[[["string",""]]]}}]},{"id":"GuildChannel#setPosition","name":"setPosition","description":"Set a new position for the Guild Channel","memberof":"GuildChannel","examples":["// set a new channel position\rchannel.setPosition(2)\r .then(newChannel => console.log(`Channel's new position is ${newChannel.position}`))\r .catch(console.error);"],"meta":{"line":192,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildChannel",">"]]]},"params":[{"name":"position","description":"The new position for the guild channel","type":{"types":[[["number",""]]]}}]},{"id":"GuildChannel#setTopic","name":"setTopic","description":"Set a new topic for the Guild Channel","memberof":"GuildChannel","examples":["// set a new channel topic\rchannel.setTopic('needs more rate limiting')\r .then(newChannel => console.log(`Channel's new topic is ${newChannel.topic}`))\r .catch(console.error);"],"meta":{"line":206,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildChannel",">"]]]},"params":[{"name":"topic","description":"The new topic for the guild channel","type":{"types":[[["string",""]]]}}]},{"id":"GuildChannel#createInvite","name":"createInvite","description":"Create an invite to this Guild Channel","memberof":"GuildChannel","meta":{"line":223,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Invite",">"]]]},"params":[{"name":"options","description":"The options for the invite","optional":true,"type":{"types":[[["InviteOptions",""]]]}}]},{"id":"GuildChannel#equals","name":"equals","description":"Checks if this channel has the same type, topic, position, name, overwrites and ID as another channel.\rIn most cases, a simple `channel.id === channel2.id` will do, and is much faster too.","memberof":"GuildChannel","meta":{"line":233,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"channel","description":"The channel to compare this channel to","type":{"types":[[["GuildChannel",""]]]}}]},{"id":"GuildChannel#toString","name":"toString","description":"When concatenated with a string, this automatically returns the Channel's mention instead of the Channel object.","memberof":"GuildChannel","examples":["// Outputs: Hello from #general\rconsole.log(`Hello from ${channel}`);","// Outputs: Hello from #general\rconsole.log('Hello from ' + channel);"],"meta":{"line":264,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]},{"id":"GuildChannel#delete","name":"delete","description":"Deletes the channel","memberof":"GuildChannel","examples":["// delete the channel\rchannel.delete()\r .then() // success\r .catch(console.error); // log error"],"inherits":"Channel#delete","inherited":true,"meta":{"line":61,"file":"Channel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Channel",">"]]]},"params":[]}],"properties":[{"id":"GuildChannel#guild","name":"guild","description":"The guild the channel is in","memberof":"GuildChannel","type":{"types":[[["Guild",""]]]},"meta":{"line":21,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"GuildChannel#name","name":"name","description":"The name of the Guild Channel","memberof":"GuildChannel","type":{"types":[[["string",""]]]},"meta":{"line":31,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"GuildChannel#position","name":"position","description":"The position of the channel in the list.","memberof":"GuildChannel","type":{"types":[[["number",""]]]},"meta":{"line":37,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"GuildChannel#permissionOverwrites","name":"permissionOverwrites","description":"A map of permission overwrites in this channel for roles and users.","memberof":"GuildChannel","type":{"types":[[["Collection",".<"],["string",", "],["PermissionOverwrites",">"]]]},"meta":{"line":43,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"GuildChannel#client","name":"client","description":"The client that instantiated the Channel","memberof":"GuildChannel","type":{"types":[[["Client",""]]]},"meta":{"line":10,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"GuildChannel#type","name":"type","description":"The type of the channel, either:\r* `dm` - a DM channel\r* `group` - a Group DM channel\r* `text` - a guild text channel\r* `voice` - a guild voice channel","memberof":"GuildChannel","type":{"types":[[["string",""]]]},"meta":{"line":21,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"GuildChannel#id","name":"id","description":"The unique ID of the channel","memberof":"GuildChannel","type":{"types":[[["string",""]]]},"meta":{"line":31,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"GuildChannel#createdTimestamp","name":"createdTimestamp","description":"The timestamp the channel was created at","memberof":"GuildChannel","type":{"types":[[["number",""]]]},"meta":{"line":39,"file":"Channel.js","path":"src/structures"},"props":[]},{"id":"GuildChannel#createdAt","name":"createdAt","description":"The time the channel was created","memberof":"GuildChannel","type":{"types":[[["Date",""]]]},"meta":{"line":48,"file":"Channel.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"GuildMember","name":"GuildMember","description":"Represents a Member of a Guild on Discord","meta":{"line":12,"file":"GuildMember.js","path":"src/structures"},"methods":[{"id":"GuildMember#permissionsIn","name":"permissionsIn","description":"Returns `channel.permissionsFor(guildMember)`. Returns evaluated permissions for a member in a guild channel.","memberof":"GuildMember","meta":{"line":227,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["EvaluatedPermissions",""]]]},"params":[{"name":"channel","description":"Guild channel to use as context","type":{"types":[[["ChannelResolvable",""]]]}}]},{"id":"GuildMember#hasPermission","name":"hasPermission","description":"Checks if any of the member's roles have a permission.","memberof":"GuildMember","meta":{"line":239,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"permission","description":"The permission to check for","type":{"types":[[["PermissionResolvable",""]]]}},{"name":"explicit","description":"Whether to require the roles to explicitly have the exact permission","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"GuildMember#hasPermissions","name":"hasPermissions","description":"Checks whether the roles of the member allows them to perform specific actions.","memberof":"GuildMember","meta":{"line":250,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"permissions","description":"The permissions to check for","type":{"types":[[["Array",".<"],["PermissionResolvable",">"]]]}},{"name":"explicit","description":"Whether to require the member to explicitly have the exact permissions","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"GuildMember#missingPermissions","name":"missingPermissions","description":"Checks whether the roles of the member allows them to perform specific actions, and lists any missing permissions.","memberof":"GuildMember","meta":{"line":261,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["array",""]]]},"params":[{"name":"permissions","description":"The permissions to check for","type":{"types":[[["Array",".<"],["PermissionResolvable",">"]]]}},{"name":"explicit","description":"Whether to require the member to explicitly have the exact permissions","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"GuildMember#edit","name":"edit","description":"Edit a Guild Member","memberof":"GuildMember","meta":{"line":270,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"data","description":"The data to edit the member with","type":{"types":[[["GuildmemberEditData",""]]]}}]},{"id":"GuildMember#setMute","name":"setMute","description":"Mute/unmute a user","memberof":"GuildMember","meta":{"line":279,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"mute","description":"Whether or not the member should be muted","type":{"types":[[["boolean",""]]]}}]},{"id":"GuildMember#setDeaf","name":"setDeaf","description":"Deafen/undeafen a user","memberof":"GuildMember","meta":{"line":288,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"deaf","description":"Whether or not the member should be deafened","type":{"types":[[["boolean",""]]]}}]},{"id":"GuildMember#setVoiceChannel","name":"setVoiceChannel","description":"Moves the Guild Member to the given channel.","memberof":"GuildMember","meta":{"line":297,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"channel","description":"The channel to move the member to","type":{"types":[[["ChannelResolvable",""]]]}}]},{"id":"GuildMember#setRoles","name":"setRoles","description":"Sets the Roles applied to the member.","memberof":"GuildMember","meta":{"line":306,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"roles","description":"The roles or role IDs to apply","type":{"types":[[["Collection",".<"],["string",", "],["Role",">"]],[["Array",".<"],["Role",">"]],[["Array",".<"],["string",">"]]]}}]},{"id":"GuildMember#addRole","name":"addRole","description":"Adds a single Role to the member.","memberof":"GuildMember","meta":{"line":315,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"role","description":"The role or ID of the role to add","type":{"types":[[["Role",""]],[["string",""]]]}}]},{"id":"GuildMember#addRoles","name":"addRoles","description":"Adds multiple roles to the member.","memberof":"GuildMember","meta":{"line":324,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"roles","description":"The roles or role IDs to add","type":{"types":[[["Collection",".<"],["string",", "],["Role",">"]],[["Array",".<"],["Role",">"]],[["Array",".<"],["string",">"]]]}}]},{"id":"GuildMember#removeRole","name":"removeRole","description":"Removes a single Role from the member.","memberof":"GuildMember","meta":{"line":340,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"role","description":"The role or ID of the role to remove","type":{"types":[[["Role",""]],[["string",""]]]}}]},{"id":"GuildMember#removeRoles","name":"removeRoles","description":"Removes multiple roles from the member.","memberof":"GuildMember","meta":{"line":349,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"roles","description":"The roles or role IDs to remove","type":{"types":[[["Collection",".<"],["string",", "],["Role",">"]],[["Array",".<"],["Role",">"]],[["Array",".<"],["string",">"]]]}}]},{"id":"GuildMember#setNickname","name":"setNickname","description":"Set the nickname for the Guild Member","memberof":"GuildMember","meta":{"line":370,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"nick","description":"The nickname for the Guild Member","type":{"types":[[["string",""]]]}}]},{"id":"GuildMember#deleteDM","name":"deleteDM","description":"Deletes any DMs with this Guild Member","memberof":"GuildMember","meta":{"line":378,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["DMChannel",">"]]]},"params":[]},{"id":"GuildMember#kick","name":"kick","description":"Kick this member from the Guild","memberof":"GuildMember","meta":{"line":386,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[]},{"id":"GuildMember#ban","name":"ban","description":"Ban this Guild Member","memberof":"GuildMember","examples":["// ban a guild member\rguildMember.ban(7);"],"meta":{"line":399,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildMember",">"]]]},"params":[{"name":"deleteDays","description":"The amount of days worth of messages from this member that should\ralso be deleted. Between `0` and `7`.","optional":true,"type":{"types":[[["number",""]]]}}]},{"id":"GuildMember#toString","name":"toString","description":"When concatenated with a string, this automatically concatenates the User's mention instead of the Member object.","memberof":"GuildMember","examples":["// logs: Hello from <@123456789>!\rconsole.log(`Hello from ${member}!`);"],"meta":{"line":410,"file":"GuildMember.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]},{"id":"GuildMember#sendMessage","name":"sendMessage","description":"Send a message to this channel","memberof":"GuildMember","examples":["// send a message\rchannel.sendMessage('hello!')\r .then(message => console.log(`Sent message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":57,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendMessage"]},{"id":"GuildMember#sendTTSMessage","name":"sendTTSMessage","description":"Send a text-to-speech message to this channel","memberof":"GuildMember","examples":["// send a TTS message\rchannel.sendTTSMessage('hello!')\r .then(message => console.log(`Sent tts message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":72,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendTTSMessage"]},{"id":"GuildMember#sendFile","name":"sendFile","description":"Send a file to this channel","memberof":"GuildMember","meta":{"line":85,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"attachment","description":"The file to send","type":{"types":[[["FileResolvable",""]]]}},{"name":"fileName","description":"The name and extension of the file","optional":true,"type":{"types":[[["string",""]]]}},{"name":"content","description":"Text message to send with the attachment","optional":true,"type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendFile"]},{"id":"GuildMember#sendCode","name":"sendCode","description":"Send a code block to this channel","memberof":"GuildMember","meta":{"line":112,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"Content of the code block","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendCode"]}],"properties":[{"id":"GuildMember#client","name":"client","description":"The client that instantiated this GuildMember","memberof":"GuildMember","type":{"types":[[["Client",""]]]},"meta":{"line":18,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#guild","name":"guild","description":"The guild that this member is part of","memberof":"GuildMember","type":{"types":[[["Guild",""]]]},"meta":{"line":25,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#user","name":"user","description":"The user that this guild member instance Represents","memberof":"GuildMember","type":{"types":[[["User",""]]]},"meta":{"line":31,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#serverDeaf","name":"serverDeaf","description":"Whether this member is deafened server-wide","memberof":"GuildMember","type":{"types":[[["boolean",""]]]},"meta":{"line":42,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#serverMute","name":"serverMute","description":"Whether this member is muted server-wide","memberof":"GuildMember","type":{"types":[[["boolean",""]]]},"meta":{"line":48,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#selfMute","name":"selfMute","description":"Whether this member is self-muted","memberof":"GuildMember","type":{"types":[[["boolean",""]]]},"meta":{"line":54,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#selfDeaf","name":"selfDeaf","description":"Whether this member is self-deafened","memberof":"GuildMember","type":{"types":[[["boolean",""]]]},"meta":{"line":60,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#voiceSessionID","name":"voiceSessionID","description":"The voice session ID of this member, if any","memberof":"GuildMember","type":{"types":[[["string",""]]]},"meta":{"line":66,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#voiceChannelID","name":"voiceChannelID","description":"The voice channel ID of this member, if any","memberof":"GuildMember","type":{"types":[[["string",""]]]},"meta":{"line":72,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#speaking","name":"speaking","description":"Whether this member is speaking","memberof":"GuildMember","type":{"types":[[["boolean",""]]]},"meta":{"line":78,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#nickname","name":"nickname","description":"The nickname of this Guild Member, if they have one","memberof":"GuildMember","type":{"types":[[["string",""]]]},"meta":{"line":84,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#joinedTimestamp","name":"joinedTimestamp","description":"The timestamp the member joined the guild at","memberof":"GuildMember","type":{"types":[[["number",""]]]},"meta":{"line":90,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#joinedAt","name":"joinedAt","description":"The time the member joined the guild","memberof":"GuildMember","type":{"types":[[["Date",""]]]},"meta":{"line":101,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#presence","name":"presence","description":"The presence of this Guild Member","memberof":"GuildMember","type":{"types":[[["Presence",""]]]},"meta":{"line":110,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#roles","name":"roles","description":"A list of roles that are applied to this GuildMember, mapped by the role ID.","memberof":"GuildMember","type":{"types":[[["Collection",".<"],["string",", "],["Role",">"]]]},"meta":{"line":119,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#highestRole","name":"highestRole","description":"The role of the member with the highest position.","memberof":"GuildMember","type":{"types":[[["Role",""]]]},"meta":{"line":138,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#mute","name":"mute","description":"Whether this member is muted in any way","memberof":"GuildMember","type":{"types":[[["boolean",""]]]},"meta":{"line":147,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#deaf","name":"deaf","description":"Whether this member is deafened in any way","memberof":"GuildMember","type":{"types":[[["boolean",""]]]},"meta":{"line":156,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#voiceChannel","name":"voiceChannel","description":"The voice channel this member is in, if any","memberof":"GuildMember","type":{"types":[[["VoiceChannel",""]]]},"meta":{"line":165,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#id","name":"id","description":"The ID of this User","memberof":"GuildMember","type":{"types":[[["string",""]]]},"meta":{"line":174,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#permissions","name":"permissions","description":"The overall set of permissions for the guild member, taking only roles into account","memberof":"GuildMember","type":{"types":[[["EvaluatedPermissions",""]]]},"meta":{"line":183,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#kickable","name":"kickable","description":"Whether the member is kickable by the client user.","memberof":"GuildMember","type":{"types":[[["boolean",""]]]},"meta":{"line":201,"file":"GuildMember.js","path":"src/structures"},"props":[]},{"id":"GuildMember#bannable","name":"bannable","description":"Whether the member is bannable by the client user.","memberof":"GuildMember","type":{"types":[[["boolean",""]]]},"meta":{"line":214,"file":"GuildMember.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"Invite","name":"Invite","description":"Represents an Invitation to a Guild Channel.\rThe only guaranteed properties are `code`, `guild` and `channel`. Other properties can be missing.","meta":{"line":30,"file":"Invite.js","path":"src/structures"},"methods":[{"id":"Invite#delete","name":"delete","description":"Deletes this invite","memberof":"Invite","meta":{"line":142,"file":"Invite.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Invite",">"]]]},"params":[]},{"id":"Invite#toString","name":"toString","description":"When concatenated with a string, this automatically concatenates the Invite's URL instead of the object.","memberof":"Invite","examples":["// logs: Invite: https://discord.gg/A1b2C3\rconsole.log(`Invite: ${invite}`);"],"meta":{"line":153,"file":"Invite.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]}],"properties":[{"id":"Invite#client","name":"client","description":"The client that instantiated the invite","memberof":"Invite","type":{"types":[[["Client",""]]]},"meta":{"line":36,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#guild","name":"guild","description":"The Guild the invite is for. If this Guild is already known, this will be a Guild object. If the Guild is\runknown, this will be a Partial Guild.","memberof":"Invite","type":{"types":[[["Guild",""]],[["PartialGuild",""]]]},"meta":{"line":48,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#code","name":"code","description":"The code for this invite","memberof":"Invite","type":{"types":[[["string",""]]]},"meta":{"line":54,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#temporary","name":"temporary","description":"Whether or not this invite is temporary","memberof":"Invite","type":{"types":[[["boolean",""]]]},"meta":{"line":60,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#maxAge","name":"maxAge","description":"The maximum age of the invite, in seconds","memberof":"Invite","type":{"types":[[["number",""]]]},"meta":{"line":66,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#uses","name":"uses","description":"How many times this invite has been used","memberof":"Invite","type":{"types":[[["number",""]]]},"meta":{"line":72,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#maxUses","name":"maxUses","description":"The maximum uses of this invite","memberof":"Invite","type":{"types":[[["number",""]]]},"meta":{"line":78,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#inviter","name":"inviter","description":"The user who created this invite","memberof":"Invite","type":{"types":[[["User",""]]]},"meta":{"line":85,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#channel","name":"channel","description":"The Channel the invite is for. If this Channel is already known, this will be a GuildChannel object.\rIf the Channel is unknown, this will be a Partial Guild Channel.","memberof":"Invite","type":{"types":[[["GuildChannel",""]],[["PartialGuildChannel",""]]]},"meta":{"line":93,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#createdTimestamp","name":"createdTimestamp","description":"The timestamp the invite was created at","memberof":"Invite","type":{"types":[[["number",""]]]},"meta":{"line":99,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#createdAt","name":"createdAt","description":"The time the invite was created","memberof":"Invite","type":{"types":[[["Date",""]]]},"meta":{"line":107,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#expiresTimestamp","name":"expiresTimestamp","description":"The timestamp the invite will expire at","memberof":"Invite","type":{"types":[[["number",""]]]},"meta":{"line":116,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#expiresAt","name":"expiresAt","description":"The time the invite will expire","memberof":"Invite","type":{"types":[[["Date",""]]]},"meta":{"line":125,"file":"Invite.js","path":"src/structures"},"props":[]},{"id":"Invite#url","name":"url","description":"The URL to the invite","memberof":"Invite","type":{"types":[[["string",""]]]},"meta":{"line":134,"file":"Invite.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"Message","name":"Message","description":"Represents a Message on Discord","meta":{"line":10,"file":"Message.js","path":"src/structures"},"methods":[{"id":"Message#isMentioned","name":"isMentioned","description":"Whether or not a user, channel or role is mentioned in this message.","memberof":"Message","meta":{"line":315,"file":"Message.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"data","description":"either a guild channel, user or a role object, or a string representing\rthe ID of any of these.","type":{"types":[[["GuildChannel",""]],[["User",""]],[["Role",""]],[["string",""]]]}}]},{"id":"Message#edit","name":"edit","description":"Edit the content of the message","memberof":"Message","examples":["// update the content of a message\rmessage.edit('This is my new content!')\r .then(msg => console.log(`Updated the content of a message from ${msg.author}`))\r .catch(console.error);"],"meta":{"line":330,"file":"Message.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"content","description":"The new content for the message","type":{"types":[[["StringResolvable",""]]]}}]},{"id":"Message#editCode","name":"editCode","description":"Edit the content of the message, with a code block","memberof":"Message","meta":{"line":340,"file":"Message.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"The new content for the message","type":{"types":[[["StringResolvable",""]]]}}]},{"id":"Message#pin","name":"pin","description":"Pins this message to the channel's pinned messages","memberof":"Message","meta":{"line":349,"file":"Message.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[]},{"id":"Message#unpin","name":"unpin","description":"Unpins this message from the channel's pinned messages","memberof":"Message","meta":{"line":357,"file":"Message.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[]},{"id":"Message#delete","name":"delete","description":"Deletes the message","memberof":"Message","examples":["// delete a message\rmessage.delete()\r .then(msg => console.log(`Deleted message from ${msg.author}`))\r .catch(console.error);"],"meta":{"line":371,"file":"Message.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"timeout","description":"How long to wait to delete the message in milliseconds","optional":true,"type":{"types":[[["number",""]]]}}]},{"id":"Message#reply","name":"reply","description":"Reply to the message","memberof":"Message","examples":["// reply to a message\rmessage.reply('Hey, I'm a reply!')\r .then(msg => console.log(`Sent a reply to ${msg.author}`))\r .catch(console.error);"],"meta":{"line":392,"file":"Message.js","path":"src/structures"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content for the message","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}]},{"id":"Message#equals","name":"equals","description":"Used mainly internally. Whether two messages are identical in properties. If you want to compare messages\rwithout checking all the properties, use `message.id === message2.id`, which is much more efficient. This\rmethod allows you to see if there are differences in content, embeds, attachments, nonce and tts properties.","memberof":"Message","meta":{"line":413,"file":"Message.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"message","description":"The message to compare it to","type":{"types":[[["Message",""]]]}},{"name":"rawData","description":"Raw data passed through the WebSocket about this message","type":{"types":[[["Object",""]]]}}]},{"id":"Message#toString","name":"toString","description":"When concatenated with a string, this automatically concatenates the Message's content instead of the object.","memberof":"Message","examples":["// logs: Message: This is a message!\rconsole.log(`Message: ${message}`);"],"meta":{"line":442,"file":"Message.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]}],"properties":[{"id":"Message#client","name":"client","description":"The client that instantiated the Message","memberof":"Message","type":{"types":[[["Client",""]]]},"meta":{"line":16,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#channel","name":"channel","description":"The channel that the message was sent in","memberof":"Message","type":{"types":[[["TextChannel",""]],[["DMChannel",""]],[["GroupDMChannel",""]]]},"meta":{"line":23,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#id","name":"id","description":"The ID of the message (unique in the channel it was sent)","memberof":"Message","type":{"types":[[["string",""]]]},"meta":{"line":33,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#type","name":"type","description":"The type of the message","memberof":"Message","type":{"types":[[["string",""]]]},"meta":{"line":39,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#content","name":"content","description":"The content of the message","memberof":"Message","type":{"types":[[["string",""]]]},"meta":{"line":45,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#author","name":"author","description":"The author of the message","memberof":"Message","type":{"types":[[["User",""]]]},"meta":{"line":51,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#member","name":"member","description":"Represents the Author of the message as a Guild Member. Only available if the message comes from a Guild\rwhere the author is still a member.","memberof":"Message","type":{"types":[[["GuildMember",""]]]},"meta":{"line":58,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#pinned","name":"pinned","description":"Whether or not this message is pinned","memberof":"Message","type":{"types":[[["boolean",""]]]},"meta":{"line":64,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#tts","name":"tts","description":"Whether or not the message was Text-To-Speech","memberof":"Message","type":{"types":[[["boolean",""]]]},"meta":{"line":70,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#nonce","name":"nonce","description":"A random number used for checking message delivery","memberof":"Message","type":{"types":[[["string",""]]]},"meta":{"line":76,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#system","name":"system","description":"Whether or not this message was sent by Discord, not actually a user (e.g. pin notifications)","memberof":"Message","type":{"types":[[["boolean",""]]]},"meta":{"line":82,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#embeds","name":"embeds","description":"A list of embeds in the message - e.g. YouTube Player","memberof":"Message","type":{"types":[[["Array",".<"],["Embed",">"]]]},"meta":{"line":88,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#attachments","name":"attachments","description":"A collection of attachments in the message - e.g. Pictures - mapped by their ID.","memberof":"Message","type":{"types":[[["Collection",".<"],["string",", "],["MessageAttachment",">"]]]},"meta":{"line":94,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#createdTimestamp","name":"createdTimestamp","description":"The timestamp the message was sent at","memberof":"Message","type":{"types":[[["number",""]]]},"meta":{"line":101,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#editedTimestamp","name":"editedTimestamp","description":"The timestamp the message was last edited at (if applicable)","memberof":"Message","type":{"types":[[["number",""]]]},"meta":{"line":107,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#mentions","name":"mentions","description":"An object containing a further users, roles or channels collections","memberof":"Message","type":{"types":[[["Object",""]]]},"meta":{"line":118,"file":"Message.js","path":"src/structures"},"props":[{"name":"mentions.users","description":"Mentioned users, maps their ID to the user object.","type":{"types":[[["Collection",".<"],["string",", "],["User",">"]]]}},{"name":"mentions.roles","description":"Mentioned roles, maps their ID to the role object.","type":{"types":[[["Collection",".<"],["string",", "],["Role",">"]]]}},{"name":"mentions.channels","description":"Mentioned channels,\rmaps their ID to the channel object.","type":{"types":[[["Collection",".<"],["string",", "],["GuildChannel",">"]]]}},{"name":"mentions.everyone","description":"Whether or not @everyone was mentioned.","type":{"types":[[["boolean",""]]]}}]},{"id":"Message#createdAt","name":"createdAt","description":"The time the message was sent","memberof":"Message","type":{"types":[[["Date",""]]]},"meta":{"line":209,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#editedAt","name":"editedAt","description":"The time the message was last edited at (if applicable)","memberof":"Message","type":{"types":[[["Date",""]]]},"meta":{"line":218,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#guild","name":"guild","description":"The guild the message was sent in (if in a guild channel)","memberof":"Message","type":{"types":[[["Guild",""]]]},"meta":{"line":227,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#cleanContent","name":"cleanContent","description":"The message contents with all mentions replaced by the equivalent text. If mentions cannot be resolved to a name,\rthe relevant mention in the message content will not be converted.","memberof":"Message","type":{"types":[[["string",""]]]},"meta":{"line":237,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#edits","name":"edits","description":"An array of cached versions of the message, including the current version.\rSorted from latest (first) to oldest (last).","memberof":"Message","type":{"types":[[["Array",".<"],["Message",">"]]]},"meta":{"line":275,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#editable","name":"editable","description":"Whether the message is editable by the client user.","memberof":"Message","type":{"types":[[["boolean",""]]]},"meta":{"line":284,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#deletable","name":"deletable","description":"Whether the message is deletable by the client user.","memberof":"Message","type":{"types":[[["boolean",""]]]},"meta":{"line":293,"file":"Message.js","path":"src/structures"},"props":[]},{"id":"Message#pinnable","name":"pinnable","description":"Whether the message is pinnable by the client user.","memberof":"Message","type":{"types":[[["boolean",""]]]},"meta":{"line":304,"file":"Message.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"MessageAttachment","name":"MessageAttachment","description":"Represents an Attachment in a Message","meta":{"line":4,"file":"MessageAttachment.js","path":"src/structures"},"methods":[],"properties":[{"id":"MessageAttachment#client","name":"client","description":"The Client that instantiated this Message.","memberof":"MessageAttachment","type":{"types":[[["Client",""]]]},"meta":{"line":10,"file":"MessageAttachment.js","path":"src/structures"},"props":[]},{"id":"MessageAttachment#message","name":"message","description":"The message this attachment is part of.","memberof":"MessageAttachment","type":{"types":[[["Message",""]]]},"meta":{"line":17,"file":"MessageAttachment.js","path":"src/structures"},"props":[]},{"id":"MessageAttachment#id","name":"id","description":"The ID of this attachment","memberof":"MessageAttachment","type":{"types":[[["string",""]]]},"meta":{"line":27,"file":"MessageAttachment.js","path":"src/structures"},"props":[]},{"id":"MessageAttachment#filename","name":"filename","description":"The file name of this attachment","memberof":"MessageAttachment","type":{"types":[[["string",""]]]},"meta":{"line":33,"file":"MessageAttachment.js","path":"src/structures"},"props":[]},{"id":"MessageAttachment#filesize","name":"filesize","description":"The size of this attachment in bytes","memberof":"MessageAttachment","type":{"types":[[["number",""]]]},"meta":{"line":39,"file":"MessageAttachment.js","path":"src/structures"},"props":[]},{"id":"MessageAttachment#url","name":"url","description":"The URL to this attachment","memberof":"MessageAttachment","type":{"types":[[["string",""]]]},"meta":{"line":45,"file":"MessageAttachment.js","path":"src/structures"},"props":[]},{"id":"MessageAttachment#proxyURL","name":"proxyURL","description":"The Proxy URL to this attachment","memberof":"MessageAttachment","type":{"types":[[["string",""]]]},"meta":{"line":51,"file":"MessageAttachment.js","path":"src/structures"},"props":[]},{"id":"MessageAttachment#height","name":"height","description":"The height of this attachment (if an image)","memberof":"MessageAttachment","type":{"types":[[["number",""]]]},"meta":{"line":57,"file":"MessageAttachment.js","path":"src/structures"},"props":[]},{"id":"MessageAttachment#width","name":"width","description":"The width of this attachment (if an image)","memberof":"MessageAttachment","type":{"types":[[["number",""]]]},"meta":{"line":63,"file":"MessageAttachment.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"MessageCollector","name":"MessageCollector","description":"Collects messages based on a specified filter, then emits them.","meta":{"line":8,"file":"MessageCollector.js","path":"src/structures"},"extends":["EventEmitter"],"classConstructor":{"id":"MessageCollector()","name":"MessageCollector","memberof":"MessageCollector","params":[{"name":"channel","description":"The channel to collect messages in","type":{"types":[[["Channel",""]]]}},{"name":"filter","description":"The filter function","type":{"types":[[["CollectorFilterFunction",""]]]}},{"name":"options","description":"Options for the collector","optional":true,"type":{"types":[[["CollectorOptions",""]]]}}]},"methods":[{"id":"MessageCollector#verify","access":"private","name":"verify","description":"Verifies a message against the filter and options","memberof":"MessageCollector","meta":{"line":79,"file":"MessageCollector.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"message","description":"The message","type":{"types":[[["Message",""]]]}}]},{"id":"MessageCollector#stop","name":"stop","description":"Stops the collector and emits `end`.","memberof":"MessageCollector","meta":{"line":134,"file":"MessageCollector.js","path":"src/structures"},"returns":{"types":[[["null",""]]]},"params":[{"name":"reason","description":"An optional reason for stopping the collector","optional":true,"type":{"types":[[["string",""]]]}}]}],"properties":[{"id":"MessageCollector#channel","name":"channel","description":"The channel this collector is operating on","memberof":"MessageCollector","type":{"types":[[["Channel",""]]]},"meta":{"line":42,"file":"MessageCollector.js","path":"src/structures"},"props":[]},{"id":"MessageCollector#filter","name":"filter","description":"A function used to filter messages that the collector collects.","memberof":"MessageCollector","type":{"types":[[["CollectorFilterFunction",""]]]},"meta":{"line":48,"file":"MessageCollector.js","path":"src/structures"},"props":[]},{"id":"MessageCollector#options","name":"options","description":"Options for the collecor.","memberof":"MessageCollector","type":{"types":[[["CollectorOptions",""]]]},"meta":{"line":54,"file":"MessageCollector.js","path":"src/structures"},"props":[]},{"id":"MessageCollector#ended","name":"ended","description":"Whether this collector has stopped collecting Messages.","memberof":"MessageCollector","type":{"types":[[["boolean",""]]]},"meta":{"line":60,"file":"MessageCollector.js","path":"src/structures"},"props":[]},{"id":"MessageCollector#collected","name":"collected","description":"A collection of collected messages, mapped by message ID.","memberof":"MessageCollector","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]]]},"meta":{"line":66,"file":"MessageCollector.js","path":"src/structures"},"props":[]},{"id":"MessageCollector#next","name":"next","description":"Returns a promise that resolves when a valid message is sent. Rejects\rwith collected messages if the Collector ends before receiving a message.","memberof":"MessageCollector","type":{"types":[[["Promise",".<"],["Message",">"]]]},"meta":{"line":103,"file":"MessageCollector.js","path":"src/structures"},"props":[]}],"events":[{"id":"MessageCollector#event:message","name":"message","description":"Emitted whenever the Collector receives a Message that passes the filter test.","memberof":"MessageCollector","meta":{"line":83,"file":"MessageCollector.js","path":"src/structures"},"params":[{"name":"message","description":"The received message","type":{"types":[[["Message",""]]]}},{"name":"collector","description":"The collector the message passed through","type":{"types":[[["MessageCollector",""]]]}}]},{"id":"MessageCollector#event:end","name":"end","description":"Emitted when the Collector stops collecting.","memberof":"MessageCollector","meta":{"line":138,"file":"MessageCollector.js","path":"src/structures"},"params":[{"name":"collection","description":"A collection of messages collected\rduring the lifetime of the Collector, mapped by the ID of the Messages.","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]]]}},{"name":"reason","description":"The reason for the end of the collector. If it ended because it reached the specified time\rlimit, this would be `time`. If you invoke `.stop()` without specifying a reason, this would be `user`. If it\rended because it reached its message limit, it will be `limit`.","type":{"types":[[["string",""]]]}}]}]},{"id":"MessageEmbed","name":"MessageEmbed","description":"Represents an embed in an image - e.g. preview of image","meta":{"line":4,"file":"MessageEmbed.js","path":"src/structures"},"methods":[],"properties":[{"id":"MessageEmbed#client","name":"client","description":"The client that instantiated this embed","memberof":"MessageEmbed","type":{"types":[[["Client",""]]]},"meta":{"line":10,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbed#message","name":"message","description":"The message this embed is part of","memberof":"MessageEmbed","type":{"types":[[["Message",""]]]},"meta":{"line":17,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbed#title","name":"title","description":"The title of this embed, if there is one","memberof":"MessageEmbed","type":{"types":[[["string",""]]]},"meta":{"line":27,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbed#type","name":"type","description":"The type of this embed","memberof":"MessageEmbed","type":{"types":[[["string",""]]]},"meta":{"line":33,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbed#description","name":"description","description":"The description of this embed, if there is one","memberof":"MessageEmbed","type":{"types":[[["string",""]]]},"meta":{"line":39,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbed#url","name":"url","description":"The URL of this embed","memberof":"MessageEmbed","type":{"types":[[["string",""]]]},"meta":{"line":45,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbed#thumbnail","name":"thumbnail","description":"The thumbnail of this embed, if there is one","memberof":"MessageEmbed","type":{"types":[[["MessageEmbedThumbnail",""]]]},"meta":{"line":51,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbed#author","name":"author","description":"The author of this embed, if there is one","memberof":"MessageEmbed","type":{"types":[[["MessageEmbedAuthor",""]]]},"meta":{"line":57,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbed#provider","name":"provider","description":"The provider of this embed, if there is one","memberof":"MessageEmbed","type":{"types":[[["MessageEmbedProvider",""]]]},"meta":{"line":63,"file":"MessageEmbed.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"MessageEmbedThumbnail","name":"MessageEmbedThumbnail","description":"Represents a thumbnail for a Message embed","meta":{"line":70,"file":"MessageEmbed.js","path":"src/structures"},"methods":[],"properties":[{"id":"MessageEmbedThumbnail#embed","name":"embed","description":"The embed this thumbnail is part of","memberof":"MessageEmbedThumbnail","type":{"types":[[["MessageEmbed",""]]]},"meta":{"line":76,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbedThumbnail#url","name":"url","description":"The URL for this thumbnail","memberof":"MessageEmbedThumbnail","type":{"types":[[["string",""]]]},"meta":{"line":86,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbedThumbnail#proxyURL","name":"proxyURL","description":"The Proxy URL for this thumbnail","memberof":"MessageEmbedThumbnail","type":{"types":[[["string",""]]]},"meta":{"line":92,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbedThumbnail#height","name":"height","description":"The height of the thumbnail","memberof":"MessageEmbedThumbnail","type":{"types":[[["number",""]]]},"meta":{"line":98,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbedThumbnail#width","name":"width","description":"The width of the thumbnail","memberof":"MessageEmbedThumbnail","type":{"types":[[["number",""]]]},"meta":{"line":104,"file":"MessageEmbed.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"MessageEmbedProvider","name":"MessageEmbedProvider","description":"Represents a Provider for a Message embed","meta":{"line":111,"file":"MessageEmbed.js","path":"src/structures"},"methods":[],"properties":[{"id":"MessageEmbedProvider#embed","name":"embed","description":"The embed this provider is part of","memberof":"MessageEmbedProvider","type":{"types":[[["MessageEmbed",""]]]},"meta":{"line":117,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbedProvider#name","name":"name","description":"The name of this provider","memberof":"MessageEmbedProvider","type":{"types":[[["string",""]]]},"meta":{"line":127,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbedProvider#url","name":"url","description":"The URL of this provider","memberof":"MessageEmbedProvider","type":{"types":[[["string",""]]]},"meta":{"line":133,"file":"MessageEmbed.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"MessageEmbedAuthor","name":"MessageEmbedAuthor","description":"Represents a Author for a Message embed","meta":{"line":140,"file":"MessageEmbed.js","path":"src/structures"},"methods":[],"properties":[{"id":"MessageEmbedAuthor#embed","name":"embed","description":"The embed this author is part of","memberof":"MessageEmbedAuthor","type":{"types":[[["MessageEmbed",""]]]},"meta":{"line":146,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbedAuthor#name","name":"name","description":"The name of this author","memberof":"MessageEmbedAuthor","type":{"types":[[["string",""]]]},"meta":{"line":156,"file":"MessageEmbed.js","path":"src/structures"},"props":[]},{"id":"MessageEmbedAuthor#url","name":"url","description":"The URL of this author","memberof":"MessageEmbedAuthor","type":{"types":[[["string",""]]]},"meta":{"line":162,"file":"MessageEmbed.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"PartialGuild","name":"PartialGuild","description":"Represents a Guild that the client only has limited information for - e.g. from invites.","meta":{"line":11,"file":"PartialGuild.js","path":"src/structures"},"methods":[],"properties":[{"id":"PartialGuild#client","name":"client","description":"The client that instantiated this PartialGuild","memberof":"PartialGuild","type":{"types":[[["Client",""]]]},"meta":{"line":17,"file":"PartialGuild.js","path":"src/structures"},"props":[]},{"id":"PartialGuild#id","name":"id","description":"The ID of this guild","memberof":"PartialGuild","type":{"types":[[["string",""]]]},"meta":{"line":28,"file":"PartialGuild.js","path":"src/structures"},"props":[]},{"id":"PartialGuild#name","name":"name","description":"The name of this guild","memberof":"PartialGuild","type":{"types":[[["string",""]]]},"meta":{"line":34,"file":"PartialGuild.js","path":"src/structures"},"props":[]},{"id":"PartialGuild#icon","name":"icon","description":"The hash of this guild's icon, or null if there is none.","memberof":"PartialGuild","type":{"types":[[["string",""]]]},"meta":{"line":40,"file":"PartialGuild.js","path":"src/structures"},"props":[]},{"id":"PartialGuild#splash","name":"splash","description":"The hash of the guild splash image, or null if no splash (VIP only)","memberof":"PartialGuild","type":{"types":[[["string",""]]]},"meta":{"line":46,"file":"PartialGuild.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"PartialGuildChannel","name":"PartialGuildChannel","description":"Represents a Guild Channel that the client only has limited information for - e.g. from invites.","meta":{"line":10,"file":"PartialGuildChannel.js","path":"src/structures"},"methods":[],"properties":[{"id":"PartialGuildChannel#client","name":"client","description":"The client that instantiated this PartialGuildChannel","memberof":"PartialGuildChannel","type":{"types":[[["Client",""]]]},"meta":{"line":16,"file":"PartialGuildChannel.js","path":"src/structures"},"props":[]},{"id":"PartialGuildChannel#id","name":"id","description":"The ID of this Guild Channel","memberof":"PartialGuildChannel","type":{"types":[[["string",""]]]},"meta":{"line":27,"file":"PartialGuildChannel.js","path":"src/structures"},"props":[]},{"id":"PartialGuildChannel#name","name":"name","description":"The name of this Guild Channel","memberof":"PartialGuildChannel","type":{"types":[[["string",""]]]},"meta":{"line":33,"file":"PartialGuildChannel.js","path":"src/structures"},"props":[]},{"id":"PartialGuildChannel#type","name":"type","description":"The type of this Guild Channel - `text` or `voice`","memberof":"PartialGuildChannel","type":{"types":[[["string",""]]]},"meta":{"line":39,"file":"PartialGuildChannel.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"PermissionOverwrites","name":"PermissionOverwrites","description":"Represents a permission overwrite for a Role or Member in a Guild Channel.","meta":{"line":4,"file":"PermissionOverwrites.js","path":"src/structures"},"methods":[{"id":"PermissionOverwrites#delete","name":"delete","description":"Delete this Permission Overwrite.","memberof":"PermissionOverwrites","meta":{"line":36,"file":"PermissionOverwrites.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["PermissionOverwrites",">"]]]},"params":[]}],"properties":[{"id":"PermissionOverwrites#channel","name":"channel","description":"The GuildChannel this overwrite is for","memberof":"PermissionOverwrites","type":{"types":[[["GuildChannel",""]]]},"meta":{"line":10,"file":"PermissionOverwrites.js","path":"src/structures"},"props":[]},{"id":"PermissionOverwrites#id","name":"id","description":"The ID of this overwrite, either a User ID or a Role ID","memberof":"PermissionOverwrites","type":{"types":[[["string",""]]]},"meta":{"line":20,"file":"PermissionOverwrites.js","path":"src/structures"},"props":[]},{"id":"PermissionOverwrites#type","name":"type","description":"The type of this overwrite","memberof":"PermissionOverwrites","type":{"types":[[["string",""]]]},"meta":{"line":26,"file":"PermissionOverwrites.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"Presence","name":"Presence","description":"Represents a User's presence","meta":{"line":4,"file":"Presence.js","path":"src/structures"},"methods":[{"id":"Presence#equals","name":"equals","description":"Whether this presence is equal to another","memberof":"Presence","meta":{"line":37,"file":"Presence.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"other","description":"the presence to compare","type":{"types":[[["Presence",""]]]}}]}],"properties":[{"id":"Presence#status","name":"status","description":"The status of the presence:\r\r* **`online`** - user is online\r* **`offline`** - user is offline or invisible\r* **`idle`** - user is AFK\r* **`dnd`** - user is in Do not Disturb","memberof":"Presence","type":{"types":[[["string",""]]]},"meta":{"line":18,"file":"Presence.js","path":"src/structures"},"props":[]},{"id":"Presence#game","name":"game","description":"The game that the user is playing, `null` if they aren't playing a game.","memberof":"Presence","type":{"types":[[["Game",""]]]},"meta":{"line":24,"file":"Presence.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"Game","name":"Game","description":"Represents a Game that is part of a User's presence.","meta":{"line":49,"file":"Presence.js","path":"src/structures"},"methods":[{"id":"Game#equals","name":"equals","description":"Whether this game is equal to another game","memberof":"Game","meta":{"line":84,"file":"Presence.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"other","description":"the other game to compare","type":{"types":[[["Game",""]]]}}]}],"properties":[{"id":"Game#name","name":"name","description":"The name of the game being played","memberof":"Game","type":{"types":[[["string",""]]]},"meta":{"line":55,"file":"Presence.js","path":"src/structures"},"props":[]},{"id":"Game#type","name":"type","description":"The type of the game status","memberof":"Game","type":{"types":[[["number",""]]]},"meta":{"line":61,"file":"Presence.js","path":"src/structures"},"props":[]},{"id":"Game#url","name":"url","description":"If the game is being streamed, a link to the stream","memberof":"Game","type":{"types":[[["string",""]]]},"meta":{"line":67,"file":"Presence.js","path":"src/structures"},"props":[]},{"id":"Game#streaming","name":"streaming","description":"Whether or not the game is being streamed","memberof":"Game","type":{"types":[[["boolean",""]]]},"meta":{"line":75,"file":"Presence.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"Role","name":"Role","description":"Represents a Role on Discord","meta":{"line":6,"file":"Role.js","path":"src/structures"},"methods":[{"id":"Role#serialize","name":"serialize","description":"Get an object mapping permission names to whether or not the role enables that permission","memberof":"Role","examples":["// print the serialized role\rconsole.log(role.serialize());"],"meta":{"line":119,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["Object",".<"],["string",", "],["boolean",">"]]]},"params":[]},{"id":"Role#hasPermission","name":"hasPermission","description":"Checks if the role has a permission.","memberof":"Role","examples":["// see if a role can ban a member\rif (role.hasPermission('BAN_MEMBERS')) {\r console.log('This role can ban members');\r} else {\r console.log('This role can\\'t ban members');\r}"],"meta":{"line":140,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"permission","description":"The permission to check for","type":{"types":[[["PermissionResolvable",""]]]}},{"name":"explicit","description":"Whether to require the role to explicitly have the exact permission","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"Role#hasPermissions","name":"hasPermissions","description":"Checks if the role has all specified permissions.","memberof":"Role","meta":{"line":152,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"permissions","description":"The permissions to check for","type":{"types":[[["Array",".<"],["PermissionResolvable",">"]]]}},{"name":"explicit","description":"Whether to require the role to explicitly have the exact permissions","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"Role#comparePositionTo","name":"comparePositionTo","description":"Compares this role's position to another role's.","memberof":"Role","meta":{"line":162,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["number",""]]]},"params":[{"name":"role","description":"Role to compare to this one","type":{"types":[[["Role",""]]]}}]},{"id":"Role#edit","name":"edit","description":"Edits the role","memberof":"Role","examples":["// edit a role\rrole.edit({name: 'new role'})\r .then(r => console.log(`Edited role ${r}`))\r .catch(console.error);"],"meta":{"line":176,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Role",">"]]]},"params":[{"name":"data","description":"The new data for the role","type":{"types":[[["RoleData",""]]]}}]},{"id":"Role#setName","name":"setName","description":"Set a new name for the role","memberof":"Role","examples":["// set the name of the role\rrole.setName('new role')\r .then(r => console.log(`Edited name of role ${r}`))\r .catch(console.error);"],"meta":{"line":190,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Role",">"]]]},"params":[{"name":"name","description":"The new name of the role","type":{"types":[[["string",""]]]}}]},{"id":"Role#setColor","name":"setColor","description":"Set a new color for the role","memberof":"Role","examples":["// set the color of a role\rrole.setColor('#FF0000')\r .then(r => console.log(`Set color of role ${r}`))\r .catch(console.error);"],"meta":{"line":204,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Role",">"]]]},"params":[{"name":"color","description":"The new color for the role, either a hex string or a base 10 number","type":{"types":[[["number",""]],[["string",""]]]}}]},{"id":"Role#setHoist","name":"setHoist","description":"Set whether or not the role should be hoisted","memberof":"Role","examples":["// set the hoist of the role\rrole.setHoist(true)\r .then(r => console.log(`Role hoisted: ${r.hoist}`))\r .catch(console.error);"],"meta":{"line":218,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Role",">"]]]},"params":[{"name":"hoist","description":"Whether or not to hoist the role","type":{"types":[[["boolean",""]]]}}]},{"id":"Role#setPosition","name":"setPosition","description":"Set the position of the role","memberof":"Role","examples":["// set the position of the role\rrole.setPosition(1)\r .then(r => console.log(`Role position: ${r.position}`))\r .catch(console.error);"],"meta":{"line":232,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Role",">"]]]},"params":[{"name":"position","description":"The position of the role","type":{"types":[[["number",""]]]}}]},{"id":"Role#setPermissions","name":"setPermissions","description":"Set the permissions of the role","memberof":"Role","examples":["// set the permissions of the role\rrole.setPermissions(['KICK_MEMBERS', 'BAN_MEMBERS'])\r .then(r => console.log(`Role updated ${r}`))\r .catch(console.error);"],"meta":{"line":246,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Role",">"]]]},"params":[{"name":"permissions","description":"The permissions of the role","type":{"types":[[["Array",".<"],["string",">"]]]}}]},{"id":"Role#setMentionable","name":"setMentionable","description":"Set whether this role is mentionable","memberof":"Role","examples":["// make the role mentionable\rrole.setMentionable(true)\r .then(r => console.log(`Role updated ${r}`))\r .catch(console.error);"],"meta":{"line":260,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Role",">"]]]},"params":[{"name":"mentionable","description":"Whether this role should be mentionable","type":{"types":[[["boolean",""]]]}}]},{"id":"Role#delete","name":"delete","description":"Deletes the role","memberof":"Role","examples":["// delete a role\rrole.delete()\r .then(r => console.log(`Deleted role ${r}`))\r .catch(console.error);"],"meta":{"line":273,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Role",">"]]]},"params":[]},{"id":"Role#equals","name":"equals","description":"Whether this role equals another role. It compares all properties, so for most operations\rit is advisable to just compare `role.id === role2.id` as it is much faster and is often\rwhat most users need.","memberof":"Role","meta":{"line":284,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"role","description":"The role to compare to","type":{"types":[[["Role",""]]]}}]},{"id":"Role#toString","name":"toString","description":"When concatenated with a string, this automatically concatenates the Role mention rather than the Role object.","memberof":"Role","meta":{"line":299,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]},{"id":"Role.comparePositions","name":"comparePositions","description":"Compares the positions of two roles.","memberof":"Role","meta":{"line":310,"file":"Role.js","path":"src/structures"},"returns":{"types":[[["number",""]]]},"params":[{"name":"role1","description":"First role to compare","type":{"types":[[["Role",""]]]}},{"name":"role2","description":"Second role to compare","type":{"types":[[["Role",""]]]}}]}],"properties":[{"id":"Role#client","name":"client","description":"The client that instantiated the role","memberof":"Role","type":{"types":[[["Client",""]]]},"meta":{"line":12,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#guild","name":"guild","description":"The guild that the role belongs to","memberof":"Role","type":{"types":[[["Guild",""]]]},"meta":{"line":19,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#id","name":"id","description":"The ID of the role (unique to the guild it is part of)","memberof":"Role","type":{"types":[[["string",""]]]},"meta":{"line":29,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#name","name":"name","description":"The name of the role","memberof":"Role","type":{"types":[[["string",""]]]},"meta":{"line":35,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#color","name":"color","description":"The base 10 color of the role","memberof":"Role","type":{"types":[[["number",""]]]},"meta":{"line":41,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#hoist","name":"hoist","description":"If true, users that are part of this role will appear in a separate category in the users list","memberof":"Role","type":{"types":[[["boolean",""]]]},"meta":{"line":47,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#position","name":"position","description":"The position of the role in the role manager","memberof":"Role","type":{"types":[[["number",""]]]},"meta":{"line":53,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#permissions","name":"permissions","description":"The evaluated permissions number","memberof":"Role","type":{"types":[[["number",""]]]},"meta":{"line":59,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#managed","name":"managed","description":"Whether or not the role is managed by an external service","memberof":"Role","type":{"types":[[["boolean",""]]]},"meta":{"line":65,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#mentionable","name":"mentionable","description":"Whether or not the role can be mentioned by anyone","memberof":"Role","type":{"types":[[["boolean",""]]]},"meta":{"line":71,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#createdTimestamp","name":"createdTimestamp","description":"The timestamp the role was created at","memberof":"Role","type":{"types":[[["number",""]]]},"meta":{"line":79,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#createdAt","name":"createdAt","description":"The time the role was created","memberof":"Role","type":{"types":[[["Date",""]]]},"meta":{"line":88,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#hexColor","name":"hexColor","description":"The hexadecimal version of the role color, with a leading hashtag.","memberof":"Role","type":{"types":[[["string",""]]]},"meta":{"line":97,"file":"Role.js","path":"src/structures"},"props":[]},{"id":"Role#members","name":"members","description":"The cached guild members that have this role.","memberof":"Role","type":{"types":[[["Collection",".<"],["string",", "],["GuildMember",">"]]]},"meta":{"line":108,"file":"Role.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"TextChannel","name":"TextChannel","description":"Represents a Server Text Channel on Discord.","meta":{"line":10,"file":"TextChannel.js","path":"src/structures"},"extends":["GuildChannel"],"methods":[{"id":"TextChannel#fetchWebhooks","name":"fetchWebhooks","description":"Fetch all webhooks for the channel.","memberof":"TextChannel","meta":{"line":49,"file":"TextChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Webhook",">>"]]]},"params":[]},{"id":"TextChannel#createWebhook","name":"createWebhook","description":"Create a webhook for the channel.","memberof":"TextChannel","examples":["channel.createWebhook('Snek', 'http://snek.s3.amazonaws.com/topSnek.png')\r .then(webhook => console.log(`Created Webhook ${webhook}`))\r .catch(console.error)"],"meta":{"line":63,"file":"TextChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Webhook",">"]]]},"params":[{"name":"name","description":"The name of the webhook.","type":{"types":[[["string",""]]]}},{"name":"avatar","description":"The avatar for the webhook.","type":{"types":[[["FileResolvable",""]]]}}]},{"id":"TextChannel#sendMessage","name":"sendMessage","description":"Send a message to this channel","memberof":"TextChannel","examples":["// send a message\rchannel.sendMessage('hello!')\r .then(message => console.log(`Sent message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":57,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendMessage"]},{"id":"TextChannel#sendTTSMessage","name":"sendTTSMessage","description":"Send a text-to-speech message to this channel","memberof":"TextChannel","examples":["// send a TTS message\rchannel.sendTTSMessage('hello!')\r .then(message => console.log(`Sent tts message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":72,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendTTSMessage"]},{"id":"TextChannel#sendFile","name":"sendFile","description":"Send a file to this channel","memberof":"TextChannel","meta":{"line":85,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"attachment","description":"The file to send","type":{"types":[[["FileResolvable",""]]]}},{"name":"fileName","description":"The name and extension of the file","optional":true,"type":{"types":[[["string",""]]]}},{"name":"content","description":"Text message to send with the attachment","optional":true,"type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendFile"]},{"id":"TextChannel#sendCode","name":"sendCode","description":"Send a code block to this channel","memberof":"TextChannel","meta":{"line":112,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"Content of the code block","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendCode"]},{"id":"TextChannel#fetchMessage","name":"fetchMessage","description":"Gets a single message from this channel, regardless of it being cached or not.\rOnly OAuth bot accounts can use this method.","memberof":"TextChannel","examples":["// get message\rchannel.fetchMessage('99539446449315840')\r .then(message => console.log(message.content))\r .catch(console.error);"],"meta":{"line":133,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"messageID","description":"The ID of the message to get","type":{"types":[[["string",""]]]}}],"implements":["TextBasedChannel#fetchMessage"]},{"id":"TextChannel#fetchMessages","name":"fetchMessages","description":"Gets the past messages sent in this channel. Resolves with a Collection mapping message ID's to Message objects.","memberof":"TextChannel","examples":["// get messages\rchannel.fetchMessages({limit: 10})\r .then(messages => console.log(`Received ${messages.size} messages`))\r .catch(console.error);"],"meta":{"line":165,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"options","description":"The query parameters to pass in","optional":true,"type":{"types":[[["ChannelLogsQueryOptions",""]]]}}],"implements":["TextBasedChannel#fetchMessages"]},{"id":"TextChannel#fetchPinnedMessages","name":"fetchPinnedMessages","description":"Fetches the pinned messages of this Channel and returns a Collection of them.","memberof":"TextChannel","meta":{"line":183,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[],"implements":["TextBasedChannel#fetchPinnedMessages"]},{"id":"TextChannel#startTyping","name":"startTyping","description":"Starts a typing indicator in the channel.","memberof":"TextChannel","examples":["// start typing in a channel\rchannel.startTyping();"],"meta":{"line":204,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["null",""]]]},"params":[{"name":"count","description":"The number of times startTyping should be considered to have been called","optional":true,"type":{"types":[[["number",""]]]}}],"implements":["TextBasedChannel#startTyping"]},{"id":"TextChannel#stopTyping","name":"stopTyping","description":"Stops the typing indicator in the channel.\rThe indicator will only stop if this is called as many times as startTyping().\rIt can take a few seconds for the Client User to stop typing.","memberof":"TextChannel","examples":["// stop typing in a channel\rchannel.stopTyping();","// force typing to fully stop in a channel\rchannel.stopTyping(true);"],"meta":{"line":232,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["null",""]]]},"params":[{"name":"force","description":"Whether or not to reset the call count and force the indicator to stop","optional":true,"type":{"types":[[["boolean",""]]]}}],"implements":["TextBasedChannel#stopTyping"]},{"id":"TextChannel#createCollector","name":"createCollector","description":"Creates a Message Collector","memberof":"TextChannel","examples":["// create a message collector\rconst collector = channel.createCollector(\r m => m.content.includes('discord'),\r { time: 15000 }\r);\rcollector.on('message', m => console.log(`Collected ${m.content}`));\rcollector.on('end', collected => console.log(`Collected ${collected.size} items`));"],"meta":{"line":276,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["MessageCollector",""]]]},"params":[{"name":"filter","description":"The filter to create the collector with","type":{"types":[[["CollectorFilterFunction",""]]]}},{"name":"options","description":"The options to pass to the collector","optional":true,"type":{"types":[[["CollectorOptions",""]]]}}],"implements":["TextBasedChannel#createCollector"]},{"id":"TextChannel#awaitMessages","name":"awaitMessages","description":"Similar to createCollector but in Promise form. Resolves with a Collection of messages that pass the specified\rfilter.","memberof":"TextChannel","examples":["// await !vote messages\rconst filter = m => m.content.startsWith('!vote');\r// errors: ['time'] treats ending because of the time limit as an error\rchannel.awaitMessages(filter, { max: 4, time: 60000, errors: ['time'] })\r .then(collected => console.log(collected.size))\r .catch(collected => console.log(`After a minute, only ${collected.size} out of 4 voted.`));"],"meta":{"line":300,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"filter","description":"The filter function to use","type":{"types":[[["CollectorFilterFunction",""]]]}},{"name":"options","description":"Optional options to pass to the internal collector","optional":true,"type":{"types":[[["AwaitMessagesOptions",""]]]}}],"implements":["TextBasedChannel#awaitMessages"]},{"id":"TextChannel#bulkDelete","name":"bulkDelete","description":"Bulk delete given messages.\rOnly OAuth Bot accounts may use this method.","memberof":"TextChannel","meta":{"line":319,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"messages","description":"Messages to delete, or number of messages to delete","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]],[["Array",".<"],["Message",">"]],[["number",""]]]}}],"implements":["TextBasedChannel#bulkDelete"]},{"id":"TextChannel#permissionsFor","name":"permissionsFor","description":"Gets the overall set of permissions for a user in this channel, taking into account roles and permission\roverwrites.","memberof":"TextChannel","inherits":"GuildChannel#permissionsFor","inherited":true,"meta":{"line":57,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["EvaluatedPermissions",""]]]},"params":[{"name":"member","description":"The user that you want to obtain the overall permissions for","type":{"types":[[["GuildMemberResolvable",""]]]}}]},{"id":"TextChannel#overwritePermissions","name":"overwritePermissions","description":"Overwrites the permissions for a user or role in this channel.","memberof":"TextChannel","examples":["// overwrite permissions for a message author\rmessage.channel.overwritePermissions(message.author, {\r SEND_MESSAGES: false\r})\r.then(() => console.log('Done!'))\r.catch(console.error);"],"inherits":"GuildChannel#overwritePermissions","inherited":true,"meta":{"line":125,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",""]]]},"params":[{"name":"userOrRole","description":"The user or role to update","type":{"types":[[["RoleResolvable",""]],[["UserResolvable",""]]]}},{"name":"options","description":"The configuration for the update","type":{"types":[[["PermissionOverwriteOptions",""]]]}}]},{"id":"TextChannel#setName","name":"setName","description":"Set a new name for the Guild Channel","memberof":"TextChannel","examples":["// set a new channel name\rchannel.setName('not_general')\r .then(newChannel => console.log(`Channel's new name is ${newChannel.name}`))\r .catch(console.error);"],"inherits":"GuildChannel#setName","inherited":true,"meta":{"line":178,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildChannel",">"]]]},"params":[{"name":"name","description":"The new name for the guild channel","type":{"types":[[["string",""]]]}}]},{"id":"TextChannel#setPosition","name":"setPosition","description":"Set a new position for the Guild Channel","memberof":"TextChannel","examples":["// set a new channel position\rchannel.setPosition(2)\r .then(newChannel => console.log(`Channel's new position is ${newChannel.position}`))\r .catch(console.error);"],"inherits":"GuildChannel#setPosition","inherited":true,"meta":{"line":192,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildChannel",">"]]]},"params":[{"name":"position","description":"The new position for the guild channel","type":{"types":[[["number",""]]]}}]},{"id":"TextChannel#setTopic","name":"setTopic","description":"Set a new topic for the Guild Channel","memberof":"TextChannel","examples":["// set a new channel topic\rchannel.setTopic('needs more rate limiting')\r .then(newChannel => console.log(`Channel's new topic is ${newChannel.topic}`))\r .catch(console.error);"],"inherits":"GuildChannel#setTopic","inherited":true,"meta":{"line":206,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildChannel",">"]]]},"params":[{"name":"topic","description":"The new topic for the guild channel","type":{"types":[[["string",""]]]}}]},{"id":"TextChannel#createInvite","name":"createInvite","description":"Create an invite to this Guild Channel","memberof":"TextChannel","inherits":"GuildChannel#createInvite","inherited":true,"meta":{"line":223,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Invite",">"]]]},"params":[{"name":"options","description":"The options for the invite","optional":true,"type":{"types":[[["InviteOptions",""]]]}}]},{"id":"TextChannel#equals","name":"equals","description":"Checks if this channel has the same type, topic, position, name, overwrites and ID as another channel.\rIn most cases, a simple `channel.id === channel2.id` will do, and is much faster too.","memberof":"TextChannel","inherits":"GuildChannel#equals","inherited":true,"meta":{"line":233,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"channel","description":"The channel to compare this channel to","type":{"types":[[["GuildChannel",""]]]}}]},{"id":"TextChannel#toString","name":"toString","description":"When concatenated with a string, this automatically returns the Channel's mention instead of the Channel object.","memberof":"TextChannel","examples":["// Outputs: Hello from #general\rconsole.log(`Hello from ${channel}`);","// Outputs: Hello from #general\rconsole.log('Hello from ' + channel);"],"inherits":"GuildChannel#toString","inherited":true,"meta":{"line":264,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]}],"properties":[{"id":"TextChannel#topic","name":"topic","description":"The topic of the Text Channel, if there is one.","memberof":"TextChannel","type":{"types":[[["string",""]]]},"meta":{"line":25,"file":"TextChannel.js","path":"src/structures"},"props":[]},{"id":"TextChannel#members","name":"members","description":"A collection of members that can see this channel, mapped by their ID.","memberof":"TextChannel","type":{"types":[[["Collection",".<"],["string",", "],["GuildMember",">"]]]},"meta":{"line":35,"file":"TextChannel.js","path":"src/structures"},"props":[]},{"id":"TextChannel#messages","name":"messages","description":"A Collection containing the messages sent to this channel.","memberof":"TextChannel","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]]]},"meta":{"line":17,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"TextChannel#lastMessageID","name":"lastMessageID","description":"The ID of the last message in the channel, if one was sent.","memberof":"TextChannel","type":{"types":[[["string",""]]]},"meta":{"line":23,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"TextChannel#typing","name":"typing","description":"Whether or not the typing indicator is being shown in the channel.","memberof":"TextChannel","type":{"types":[[["boolean",""]]]},"meta":{"line":248,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"TextChannel#typingCount","name":"typingCount","description":"Number of times `startTyping` has been called.","memberof":"TextChannel","type":{"types":[[["number",""]]]},"meta":{"line":257,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"TextChannel#guild","name":"guild","description":"The guild the channel is in","memberof":"TextChannel","type":{"types":[[["Guild",""]]]},"meta":{"line":21,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"TextChannel#name","name":"name","description":"The name of the Guild Channel","memberof":"TextChannel","type":{"types":[[["string",""]]]},"meta":{"line":31,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"TextChannel#position","name":"position","description":"The position of the channel in the list.","memberof":"TextChannel","type":{"types":[[["number",""]]]},"meta":{"line":37,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"TextChannel#permissionOverwrites","name":"permissionOverwrites","description":"A map of permission overwrites in this channel for roles and users.","memberof":"TextChannel","type":{"types":[[["Collection",".<"],["string",", "],["PermissionOverwrites",">"]]]},"meta":{"line":43,"file":"GuildChannel.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"User","name":"User","description":"Represents a User on Discord.","meta":{"line":9,"file":"User.js","path":"src/structures"},"methods":[{"id":"User#typingIn","name":"typingIn","description":"Check whether the user is typing in a channel.","memberof":"User","meta":{"line":105,"file":"User.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"channel","description":"The channel to check in","type":{"types":[[["ChannelResolvable",""]]]}}]},{"id":"User#typingSinceIn","name":"typingSinceIn","description":"Get the time that the user started typing.","memberof":"User","meta":{"line":115,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Date",""]]]},"params":[{"name":"channel","description":"The channel to get the time in","type":{"types":[[["ChannelResolvable",""]]]}}]},{"id":"User#typingDurationIn","name":"typingDurationIn","description":"Get the amount of time the user has been typing in a channel for (in milliseconds), or -1 if they're not typing.","memberof":"User","meta":{"line":125,"file":"User.js","path":"src/structures"},"returns":{"types":[[["number",""]]]},"params":[{"name":"channel","description":"The channel to get the time in","type":{"types":[[["ChannelResolvable",""]]]}}]},{"id":"User#deleteDM","name":"deleteDM","description":"Deletes a DM Channel (if one exists) between the Client and the User. Resolves with the Channel if successful.","memberof":"User","meta":{"line":134,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["DMChannel",">"]]]},"params":[]},{"id":"User#addFriend","name":"addFriend","description":"Sends a friend request to the user","memberof":"User","meta":{"line":142,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[]},{"id":"User#removeFriend","name":"removeFriend","description":"Removes the user from your friends","memberof":"User","meta":{"line":150,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[]},{"id":"User#block","name":"block","description":"Blocks the user","memberof":"User","meta":{"line":158,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[]},{"id":"User#unblock","name":"unblock","description":"Unblocks the user","memberof":"User","meta":{"line":166,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["User",">"]]]},"params":[]},{"id":"User#fetchProfile","name":"fetchProfile","description":"Get the profile of the user","memberof":"User","meta":{"line":174,"file":"User.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["UserProfile",">"]]]},"params":[]},{"id":"User#equals","name":"equals","description":"Checks if the user is equal to another. It compares username, ID, discriminator, status and the game being played.\rIt is recommended to compare equality by using `user.id === user2.id` unless you want to compare all properties.","memberof":"User","meta":{"line":184,"file":"User.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"user","description":"The user to compare","type":{"types":[[["User",""]]]}}]},{"id":"User#toString","name":"toString","description":"When concatenated with a string, this automatically concatenates the User's mention instead of the User object.","memberof":"User","examples":["// logs: Hello from <@123456789>!\rconsole.log(`Hello from ${user}!`);"],"meta":{"line":202,"file":"User.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]},{"id":"User#sendMessage","name":"sendMessage","description":"Send a message to this channel","memberof":"User","examples":["// send a message\rchannel.sendMessage('hello!')\r .then(message => console.log(`Sent message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":57,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendMessage"]},{"id":"User#sendTTSMessage","name":"sendTTSMessage","description":"Send a text-to-speech message to this channel","memberof":"User","examples":["// send a TTS message\rchannel.sendTTSMessage('hello!')\r .then(message => console.log(`Sent tts message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":72,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendTTSMessage"]},{"id":"User#sendFile","name":"sendFile","description":"Send a file to this channel","memberof":"User","meta":{"line":85,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"attachment","description":"The file to send","type":{"types":[[["FileResolvable",""]]]}},{"name":"fileName","description":"The name and extension of the file","optional":true,"type":{"types":[[["string",""]]]}},{"name":"content","description":"Text message to send with the attachment","optional":true,"type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendFile"]},{"id":"User#sendCode","name":"sendCode","description":"Send a code block to this channel","memberof":"User","meta":{"line":112,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"Content of the code block","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","type":{"types":[[["MessageOptions",""]]]}}],"implements":["TextBasedChannel#sendCode"]}],"properties":[{"id":"User#client","name":"client","description":"The Client that created the instance of the the User.","memberof":"User","type":{"types":[[["Client",""]]]},"meta":{"line":15,"file":"User.js","path":"src/structures"},"props":[]},{"id":"User#id","name":"id","description":"The ID of the User","memberof":"User","type":{"types":[[["string",""]]]},"meta":{"line":26,"file":"User.js","path":"src/structures"},"props":[]},{"id":"User#username","name":"username","description":"The username of the User","memberof":"User","type":{"types":[[["string",""]]]},"meta":{"line":32,"file":"User.js","path":"src/structures"},"props":[]},{"id":"User#discriminator","name":"discriminator","description":"A discriminator based on username for the User","memberof":"User","type":{"types":[[["string",""]]]},"meta":{"line":38,"file":"User.js","path":"src/structures"},"props":[]},{"id":"User#avatar","name":"avatar","description":"The ID of the user's avatar","memberof":"User","type":{"types":[[["string",""]]]},"meta":{"line":44,"file":"User.js","path":"src/structures"},"props":[]},{"id":"User#bot","name":"bot","description":"Whether or not the User is a Bot.","memberof":"User","type":{"types":[[["boolean",""]]]},"meta":{"line":50,"file":"User.js","path":"src/structures"},"props":[]},{"id":"User#createdTimestamp","name":"createdTimestamp","description":"The timestamp the user was created at","memberof":"User","type":{"types":[[["number",""]]]},"meta":{"line":64,"file":"User.js","path":"src/structures"},"props":[]},{"id":"User#createdAt","name":"createdAt","description":"The time the user was created","memberof":"User","type":{"types":[[["Date",""]]]},"meta":{"line":73,"file":"User.js","path":"src/structures"},"props":[]},{"id":"User#presence","name":"presence","description":"The presence of this user","memberof":"User","type":{"types":[[["Presence",""]]]},"meta":{"line":82,"file":"User.js","path":"src/structures"},"props":[]},{"id":"User#avatarURL","name":"avatarURL","description":"A link to the user's avatar (if they have one, otherwise null)","memberof":"User","type":{"types":[[["string",""]]]},"meta":{"line":95,"file":"User.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"UserConnection","name":"UserConnection","description":"Represents a User Connection object (or \"platform identity\")","meta":{"line":4,"file":"UserConnection.js","path":"src/structures"},"methods":[],"properties":[{"id":"UserConnection#user","name":"user","description":"The user that owns the Connection","memberof":"UserConnection","type":{"types":[[["User",""]]]},"meta":{"line":10,"file":"UserConnection.js","path":"src/structures"},"props":[]},{"id":"UserConnection#type","name":"type","description":"The type of the Connection","memberof":"UserConnection","type":{"types":[[["string",""]]]},"meta":{"line":20,"file":"UserConnection.js","path":"src/structures"},"props":[]},{"id":"UserConnection#name","name":"name","description":"The username of the connection account","memberof":"UserConnection","type":{"types":[[["string",""]]]},"meta":{"line":26,"file":"UserConnection.js","path":"src/structures"},"props":[]},{"id":"UserConnection#id","name":"id","description":"The id of the connection account","memberof":"UserConnection","type":{"types":[[["string",""]]]},"meta":{"line":32,"file":"UserConnection.js","path":"src/structures"},"props":[]},{"id":"UserConnection#revoked","name":"revoked","description":"Whether the connection is revoked","memberof":"UserConnection","type":{"types":[[["Boolean",""]]]},"meta":{"line":38,"file":"UserConnection.js","path":"src/structures"},"props":[]},{"id":"UserConnection#integrations","name":"integrations","description":"an array of partial server integrations (not yet implemented in this lib)","memberof":"UserConnection","type":{"types":[[["Array",".<"],["Object",">"]]]},"meta":{"line":44,"file":"UserConnection.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"UserProfile","name":"UserProfile","description":"Represents a user's profile on Discord.","meta":{"line":7,"file":"UserProfile.js","path":"src/structures"},"methods":[],"properties":[{"id":"UserProfile#user","name":"user","description":"The owner of the profile","memberof":"UserProfile","type":{"types":[[["User",""]]]},"meta":{"line":13,"file":"UserProfile.js","path":"src/structures"},"props":[]},{"id":"UserProfile#client","name":"client","description":"The Client that created the instance of the the User.","memberof":"UserProfile","type":{"types":[[["Client",""]]]},"meta":{"line":19,"file":"UserProfile.js","path":"src/structures"},"props":[]},{"id":"UserProfile#mutualGuilds","name":"mutualGuilds","description":"Guilds that the ClientUser and the User share","memberof":"UserProfile","type":{"types":[[["Collection",".<"],["Guild",">"]]]},"meta":{"line":26,"file":"UserProfile.js","path":"src/structures"},"props":[]},{"id":"UserProfile#connections","name":"connections","description":"The user's connections","memberof":"UserProfile","type":{"types":[[["Collection",".<"],["UserConnection",">"]]]},"meta":{"line":32,"file":"UserProfile.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"VoiceChannel","name":"VoiceChannel","description":"Represents a Server Voice Channel on Discord.","meta":{"line":8,"file":"VoiceChannel.js","path":"src/structures"},"extends":["GuildChannel"],"methods":[{"id":"VoiceChannel#setBitrate","name":"setBitrate","description":"Sets the bitrate of the channel","memberof":"VoiceChannel","examples":["// set the bitrate of a voice channel\rvoiceChannel.setBitrate(48000)\r .then(vc => console.log(`Set bitrate to ${vc.bitrate} for ${vc.name}`))\r .catch(console.error);"],"meta":{"line":74,"file":"VoiceChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["VoiceChannel",">"]]]},"params":[{"name":"bitrate","description":"The new bitrate","type":{"types":[[["number",""]]]}}]},{"id":"VoiceChannel#join","name":"join","description":"Attempts to join this Voice Channel","memberof":"VoiceChannel","examples":["// join a voice channel\rvoiceChannel.join()\r .then(connection => console.log('Connected!'))\r .catch(console.error);"],"meta":{"line":87,"file":"VoiceChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["VoiceConnection",">"]]]},"params":[]},{"id":"VoiceChannel#leave","name":"leave","description":"Leaves this voice channel","memberof":"VoiceChannel","examples":["// leave a voice channel\rvoiceChannel.leave();"],"meta":{"line":97,"file":"VoiceChannel.js","path":"src/structures"},"returns":{"types":[[["null",""]]]},"params":[]},{"id":"VoiceChannel#permissionsFor","name":"permissionsFor","description":"Gets the overall set of permissions for a user in this channel, taking into account roles and permission\roverwrites.","memberof":"VoiceChannel","inherits":"GuildChannel#permissionsFor","inherited":true,"meta":{"line":57,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["EvaluatedPermissions",""]]]},"params":[{"name":"member","description":"The user that you want to obtain the overall permissions for","type":{"types":[[["GuildMemberResolvable",""]]]}}]},{"id":"VoiceChannel#overwritePermissions","name":"overwritePermissions","description":"Overwrites the permissions for a user or role in this channel.","memberof":"VoiceChannel","examples":["// overwrite permissions for a message author\rmessage.channel.overwritePermissions(message.author, {\r SEND_MESSAGES: false\r})\r.then(() => console.log('Done!'))\r.catch(console.error);"],"inherits":"GuildChannel#overwritePermissions","inherited":true,"meta":{"line":125,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",""]]]},"params":[{"name":"userOrRole","description":"The user or role to update","type":{"types":[[["RoleResolvable",""]],[["UserResolvable",""]]]}},{"name":"options","description":"The configuration for the update","type":{"types":[[["PermissionOverwriteOptions",""]]]}}]},{"id":"VoiceChannel#setName","name":"setName","description":"Set a new name for the Guild Channel","memberof":"VoiceChannel","examples":["// set a new channel name\rchannel.setName('not_general')\r .then(newChannel => console.log(`Channel's new name is ${newChannel.name}`))\r .catch(console.error);"],"inherits":"GuildChannel#setName","inherited":true,"meta":{"line":178,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildChannel",">"]]]},"params":[{"name":"name","description":"The new name for the guild channel","type":{"types":[[["string",""]]]}}]},{"id":"VoiceChannel#setPosition","name":"setPosition","description":"Set a new position for the Guild Channel","memberof":"VoiceChannel","examples":["// set a new channel position\rchannel.setPosition(2)\r .then(newChannel => console.log(`Channel's new position is ${newChannel.position}`))\r .catch(console.error);"],"inherits":"GuildChannel#setPosition","inherited":true,"meta":{"line":192,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildChannel",">"]]]},"params":[{"name":"position","description":"The new position for the guild channel","type":{"types":[[["number",""]]]}}]},{"id":"VoiceChannel#setTopic","name":"setTopic","description":"Set a new topic for the Guild Channel","memberof":"VoiceChannel","examples":["// set a new channel topic\rchannel.setTopic('needs more rate limiting')\r .then(newChannel => console.log(`Channel's new topic is ${newChannel.topic}`))\r .catch(console.error);"],"inherits":"GuildChannel#setTopic","inherited":true,"meta":{"line":206,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["GuildChannel",">"]]]},"params":[{"name":"topic","description":"The new topic for the guild channel","type":{"types":[[["string",""]]]}}]},{"id":"VoiceChannel#createInvite","name":"createInvite","description":"Create an invite to this Guild Channel","memberof":"VoiceChannel","inherits":"GuildChannel#createInvite","inherited":true,"meta":{"line":223,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Invite",">"]]]},"params":[{"name":"options","description":"The options for the invite","optional":true,"type":{"types":[[["InviteOptions",""]]]}}]},{"id":"VoiceChannel#equals","name":"equals","description":"Checks if this channel has the same type, topic, position, name, overwrites and ID as another channel.\rIn most cases, a simple `channel.id === channel2.id` will do, and is much faster too.","memberof":"VoiceChannel","inherits":"GuildChannel#equals","inherited":true,"meta":{"line":233,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"channel","description":"The channel to compare this channel to","type":{"types":[[["GuildChannel",""]]]}}]},{"id":"VoiceChannel#toString","name":"toString","description":"When concatenated with a string, this automatically returns the Channel's mention instead of the Channel object.","memberof":"VoiceChannel","examples":["// Outputs: Hello from #general\rconsole.log(`Hello from ${channel}`);","// Outputs: Hello from #general\rconsole.log('Hello from ' + channel);"],"inherits":"GuildChannel#toString","inherited":true,"meta":{"line":264,"file":"GuildChannel.js","path":"src/structures"},"returns":{"types":[[["string",""]]]},"params":[]}],"properties":[{"id":"VoiceChannel#members","name":"members","description":"The members in this Voice Channel.","memberof":"VoiceChannel","type":{"types":[[["Collection",".<"],["string",", "],["GuildMember",">"]]]},"meta":{"line":16,"file":"VoiceChannel.js","path":"src/structures"},"props":[]},{"id":"VoiceChannel#bitrate","name":"bitrate","description":"The bitrate of this voice channel","memberof":"VoiceChannel","type":{"types":[[["number",""]]]},"meta":{"line":28,"file":"VoiceChannel.js","path":"src/structures"},"props":[]},{"id":"VoiceChannel#userLimit","name":"userLimit","description":"The maximum amount of users allowed in this channel - 0 means unlimited.","memberof":"VoiceChannel","type":{"types":[[["number",""]]]},"meta":{"line":34,"file":"VoiceChannel.js","path":"src/structures"},"props":[]},{"id":"VoiceChannel#connection","name":"connection","description":"The voice connection for this voice channel, if the client is connected","memberof":"VoiceChannel","type":{"types":[[["VoiceConnection",""]]]},"meta":{"line":42,"file":"VoiceChannel.js","path":"src/structures"},"props":[]},{"id":"VoiceChannel#joinable","name":"joinable","description":"Checks if the client has permission join the voice channel","memberof":"VoiceChannel","type":{"types":[[["boolean",""]]]},"meta":{"line":52,"file":"VoiceChannel.js","path":"src/structures"},"props":[]},{"id":"VoiceChannel#speakable","name":"speakable","description":"Checks if the client has permission to send audio to the voice channel","memberof":"VoiceChannel","type":{"types":[[["boolean",""]]]},"meta":{"line":60,"file":"VoiceChannel.js","path":"src/structures"},"props":[]},{"id":"VoiceChannel#guild","name":"guild","description":"The guild the channel is in","memberof":"VoiceChannel","type":{"types":[[["Guild",""]]]},"meta":{"line":21,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"VoiceChannel#name","name":"name","description":"The name of the Guild Channel","memberof":"VoiceChannel","type":{"types":[[["string",""]]]},"meta":{"line":31,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"VoiceChannel#position","name":"position","description":"The position of the channel in the list.","memberof":"VoiceChannel","type":{"types":[[["number",""]]]},"meta":{"line":37,"file":"GuildChannel.js","path":"src/structures"},"props":[]},{"id":"VoiceChannel#permissionOverwrites","name":"permissionOverwrites","description":"A map of permission overwrites in this channel for roles and users.","memberof":"VoiceChannel","type":{"types":[[["Collection",".<"],["string",", "],["PermissionOverwrites",">"]]]},"meta":{"line":43,"file":"GuildChannel.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"Webhook","name":"Webhook","description":"Represents a Webhook","meta":{"line":7,"file":"Webhook.js","path":"src/structures"},"methods":[{"id":"Webhook#sendMessage","name":"sendMessage","description":"Send a message with this webhook","memberof":"Webhook","examples":["// send a message\rwebhook.sendMessage('hello!')\r .then(message => console.log(`Sent message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":87,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send.","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide.","optional":true,"type":{"types":[[["WebhookMessageOptions",""]]]}}]},{"id":"Webhook#sendSlackMessage","name":"sendSlackMessage","description":"Send a raw slack message with this webhook","memberof":"Webhook","examples":["// send a slack message\rwebhook.sendSlackMessage({\r 'username': 'Wumpus',\r 'attachments': [{\r 'pretext': 'this looks pretty cool',\r 'color': '#F0F',\r 'footer_icon': 'http://snek.s3.amazonaws.com/topSnek.png',\r 'footer': 'Powered by sneks',\r 'ts': new Date().getTime() / 1000\r }]\r}).catch(console.error);"],"meta":{"line":108,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",""]]]},"params":[{"name":"body","description":"The raw body to send.","type":{"types":[[["Object",""]]]}}]},{"id":"Webhook#sendTTSMessage","name":"sendTTSMessage","description":"Send a text-to-speech message with this webhook","memberof":"Webhook","examples":["// send a TTS message\rwebhook.sendTTSMessage('hello!')\r .then(message => console.log(`Sent tts message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":123,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["WebhookMessageOptions",""]]]}}]},{"id":"Webhook#sendFile","name":"sendFile","description":"Send a file with this webhook","memberof":"Webhook","meta":{"line":136,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"attachment","description":"The file to send","type":{"types":[[["FileResolvable",""]]]}},{"name":"fileName","description":"The name and extension of the file","optional":true,"type":{"types":[[["string",""]]]}},{"name":"content","description":"Text message to send with the attachment","optional":true,"type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["WebhookMessageOptions",""]]]}}]},{"id":"Webhook#sendCode","name":"sendCode","description":"Send a code block with this webhook","memberof":"Webhook","meta":{"line":163,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"Content of the code block","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","type":{"types":[[["WebhookMessageOptions",""]]]}}]},{"id":"Webhook#edit","name":"edit","description":"Edit the Webhook.","memberof":"Webhook","meta":{"line":179,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",".<"],["Webhook",">"]]]},"params":[{"name":"name","description":"The new name for the Webhook","type":{"types":[[["string",""]]]}},{"name":"avatar","description":"The new avatar for the Webhook.","type":{"types":[[["FileResolvable",""]]]}}]},{"id":"Webhook#delete","name":"delete","description":"Delete the Webhook","memberof":"Webhook","meta":{"line":200,"file":"Webhook.js","path":"src/structures"},"returns":{"types":[[["Promise",""]]]},"params":[]}],"properties":[{"id":"Webhook#client","name":"client","description":"The client that instantiated the Channel","memberof":"Webhook","type":{"types":[[["Client",""]]]},"meta":{"line":14,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"Webhook#name","name":"name","description":"The name of the Webhook","memberof":"Webhook","type":{"types":[[["string",""]]]},"meta":{"line":29,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"Webhook#token","name":"token","description":"The token for the Webhook","memberof":"Webhook","type":{"types":[[["string",""]]]},"meta":{"line":35,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"Webhook#avatar","name":"avatar","description":"The avatar for the Webhook","memberof":"Webhook","type":{"types":[[["string",""]]]},"meta":{"line":41,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"Webhook#id","name":"id","description":"The ID of the Webhook","memberof":"Webhook","type":{"types":[[["string",""]]]},"meta":{"line":47,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"Webhook#guildID","name":"guildID","description":"The guild the Webhook belongs to","memberof":"Webhook","type":{"types":[[["string",""]]]},"meta":{"line":53,"file":"Webhook.js","path":"src/structures"},"props":[]},{"id":"Webhook#channelID","name":"channelID","description":"The channel the Webhook belongs to","memberof":"Webhook","type":{"types":[[["string",""]]]},"meta":{"line":59,"file":"Webhook.js","path":"src/structures"},"props":[]}],"events":[]},{"id":"Collection","name":"Collection","description":"A utility class to help make it easier to access the data stores","meta":{"line":5,"file":"Collection.js","path":"src/util"},"extends":["Map"],"methods":[{"id":"Collection#array","name":"array","description":"Creates an ordered array of the values of this collection, and caches it internally. The array will only be\rreconstructed if an item is added to or removed from the collection, or if you add/remove elements on the array.","memberof":"Collection","examples":["// identical to:\rArray.from(collection.values());"],"meta":{"line":32,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["Array",""]]]},"params":[]},{"id":"Collection#keyArray","name":"keyArray","description":"Creates an ordered array of the keys of this collection, and caches it internally. The array will only be\rreconstructed if an item is added to or removed from the collection, or if you add/remove elements on the array.","memberof":"Collection","examples":["// identical to:\rArray.from(collection.keys());"],"meta":{"line":45,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["Array",""]]]},"params":[]},{"id":"Collection#first","name":"first","description":"Returns the first item in this collection.","memberof":"Collection","meta":{"line":54,"file":"Collection.js","path":"src/util"},"returns":{"types":[["*",""]]},"params":[]},{"id":"Collection#firstKey","name":"firstKey","description":"Returns the first key in this collection.","memberof":"Collection","meta":{"line":62,"file":"Collection.js","path":"src/util"},"returns":{"types":[["*",""]]},"params":[]},{"id":"Collection#last","name":"last","description":"Returns the last item in this collection. This is a relatively slow operation,\rsince an array copy of the values must be made to find the last element.","memberof":"Collection","meta":{"line":71,"file":"Collection.js","path":"src/util"},"returns":{"types":[["*",""]]},"params":[]},{"id":"Collection#lastKey","name":"lastKey","description":"Returns the last key in this collection. This is a relatively slow operation,\rsince an array copy of the keys must be made to find the last element.","memberof":"Collection","meta":{"line":81,"file":"Collection.js","path":"src/util"},"returns":{"types":[["*",""]]},"params":[]},{"id":"Collection#random","name":"random","description":"Returns a random item from this collection. This is a relatively slow operation,\rsince an array copy of the values must be made to find a random element.","memberof":"Collection","meta":{"line":91,"file":"Collection.js","path":"src/util"},"returns":{"types":[["*",""]]},"params":[]},{"id":"Collection#randomKey","name":"randomKey","description":"Returns a random key from this collection. This is a relatively slow operation,\rsince an array copy of the keys must be made to find a random element.","memberof":"Collection","meta":{"line":101,"file":"Collection.js","path":"src/util"},"returns":{"types":[["*",""]]},"params":[]},{"id":"Collection#findAll","name":"findAll","description":"Returns an array of items where `item[prop] === value` of the collection","memberof":"Collection","examples":["collection.findAll('username', 'Bob');"],"meta":{"line":114,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["array",""]]]},"params":[{"name":"prop","description":"The property to test against","type":{"types":[[["string",""]]]}},{"name":"value","description":"The expected value","type":{"types":[["*",""]]}}]},{"id":"Collection#find","name":"find","description":"Returns a single item where `item[prop] === value`, or the given function returns `true`.\rIn the latter case, this is identical to\r[Array.find()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/find).","memberof":"Collection","examples":["collection.find('username', 'Bob');","collection.find(val => val.username === 'Bob');"],"meta":{"line":136,"file":"Collection.js","path":"src/util"},"returns":{"types":[["*",""]]},"params":[{"name":"propOrFn","description":"The property to test against, or the function to test with","type":{"types":[[["string",""]],[["function",""]]]}},{"name":"value","description":"The expected value - only applicable and required if using a property for the first argument","optional":true,"type":{"types":[["*",""]]}}]},{"id":"Collection#findKey","name":"findKey","description":"Returns the key of the item where `item[prop] === value`, or the given function returns `true`.\rIn the latter case, this is identical to\r[Array.findIndex()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/findIndex).","memberof":"Collection","examples":["collection.findKey('username', 'Bob');","collection.findKey(val => val.username === 'Bob');"],"meta":{"line":167,"file":"Collection.js","path":"src/util"},"returns":{"types":[["*",""]]},"params":[{"name":"propOrFn","description":"The property to test against, or the function to test with","type":{"types":[[["string",""]],[["function",""]]]}},{"name":"value","description":"The expected value - only applicable and required if using a property for the first argument","optional":true,"type":{"types":[["*",""]]}}]},{"id":"Collection#exists","name":"exists","description":"Returns true if the collection has an item where `item[prop] === value`","memberof":"Collection","examples":["if (collection.exists('username', 'Bob')) {\r console.log('user here!');\r}"],"meta":{"line":194,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"prop","description":"The property to test against","type":{"types":[[["string",""]]]}},{"name":"value","description":"The expected value","type":{"types":[["*",""]]}}]},{"id":"Collection#filter","name":"filter","description":"Identical to\r[Array.filter()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/filter),\rbut returns a Collection instead of an Array.","memberof":"Collection","meta":{"line":206,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["Collection",""]]]},"params":[{"name":"fn","description":"Function used to test (should return a boolean)","type":{"types":[[["function",""]]]}},{"name":"thisArg","description":"Value to use as `this` when executing function","optional":true,"type":{"types":[[["Object",""]]]}}]},{"id":"Collection#filterArray","name":"filterArray","description":"Identical to\r[Array.filter()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/filter).","memberof":"Collection","meta":{"line":222,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["Collection",""]]]},"params":[{"name":"fn","description":"Function used to test (should return a boolean)","type":{"types":[[["function",""]]]}},{"name":"thisArg","description":"Value to use as `this` when executing function","optional":true,"type":{"types":[[["Object",""]]]}}]},{"id":"Collection#map","name":"map","description":"Identical to\r[Array.map()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map).","memberof":"Collection","meta":{"line":238,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["array",""]]]},"params":[{"name":"fn","description":"Function that produces an element of the new array, taking three arguments","type":{"types":[[["function",""]]]}},{"name":"thisArg","description":"Value to use as `this` when executing function","optional":true,"type":{"types":[["*",""]]}}]},{"id":"Collection#some","name":"some","description":"Identical to\r[Array.some()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/some).","memberof":"Collection","meta":{"line":253,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"fn","description":"Function used to test (should return a boolean)","type":{"types":[[["function",""]]]}},{"name":"thisArg","description":"Value to use as `this` when executing function","optional":true,"type":{"types":[[["Object",""]]]}}]},{"id":"Collection#every","name":"every","description":"Identical to\r[Array.every()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/every).","memberof":"Collection","meta":{"line":268,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["boolean",""]]]},"params":[{"name":"fn","description":"Function used to test (should return a boolean)","type":{"types":[[["function",""]]]}},{"name":"thisArg","description":"Value to use as `this` when executing function","optional":true,"type":{"types":[[["Object",""]]]}}]},{"id":"Collection#reduce","name":"reduce","description":"Identical to\r[Array.reduce()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/reduce).","memberof":"Collection","meta":{"line":283,"file":"Collection.js","path":"src/util"},"returns":{"types":[["*",""]]},"params":[{"name":"fn","description":"Function used to reduce","type":{"types":[[["function",""]]]}},{"name":"startVal","description":"The starting value","optional":true,"type":{"types":[["*",""]]}}]},{"id":"Collection#concat","name":"concat","description":"Combines this collection with others into a new collection. None of the source collections are modified.","memberof":"Collection","examples":["const newColl = someColl.concat(someOtherColl, anotherColl, ohBoyAColl);"],"meta":{"line":295,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["Collection",""]]]},"params":[{"name":"collections","description":"Collections to merge","type":{"types":[[["Collection",""]]]}}]},{"id":"Collection#deleteAll","name":"deleteAll","description":"If the items in this collection have a delete method (e.g. messages), invoke\rthe delete method. Returns an array of promises","memberof":"Collection","meta":{"line":309,"file":"Collection.js","path":"src/util"},"returns":{"types":[[["Array",".<"],["Promise",">"]]]},"params":[]}],"properties":[],"events":[]}],"interfaces":[{"id":"TextBasedChannel","name":"TextBasedChannel","description":"Interface for classes that have text-channel-like features","meta":{"line":11,"file":"TextBasedChannel.js","path":"src/structures/interface"},"methods":[{"id":"TextBasedChannel#sendMessage","name":"sendMessage","description":"Send a message to this channel","memberof":"TextBasedChannel","examples":["// send a message\rchannel.sendMessage('hello!')\r .then(message => console.log(`Sent message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":57,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}]},{"id":"TextBasedChannel#sendTTSMessage","name":"sendTTSMessage","description":"Send a text-to-speech message to this channel","memberof":"TextBasedChannel","examples":["// send a TTS message\rchannel.sendTTSMessage('hello!')\r .then(message => console.log(`Sent tts message: ${message.content}`))\r .catch(console.error);"],"meta":{"line":72,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"content","description":"The content to send","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}]},{"id":"TextBasedChannel#sendFile","name":"sendFile","description":"Send a file to this channel","memberof":"TextBasedChannel","meta":{"line":85,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"attachment","description":"The file to send","type":{"types":[[["FileResolvable",""]]]}},{"name":"fileName","description":"The name and extension of the file","optional":true,"type":{"types":[[["string",""]]]}},{"name":"content","description":"Text message to send with the attachment","optional":true,"type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","optional":true,"type":{"types":[[["MessageOptions",""]]]}}]},{"id":"TextBasedChannel#sendCode","name":"sendCode","description":"Send a code block to this channel","memberof":"TextBasedChannel","meta":{"line":112,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<("],["Message","|"],["Array",".<"],["Message",">)>"]]]},"params":[{"name":"lang","description":"Language for the code block","type":{"types":[[["string",""]]]}},{"name":"content","description":"Content of the code block","type":{"types":[[["StringResolvable",""]]]}},{"name":"options","description":"The options to provide","type":{"types":[[["MessageOptions",""]]]}}]},{"id":"TextBasedChannel#fetchMessage","name":"fetchMessage","description":"Gets a single message from this channel, regardless of it being cached or not.\rOnly OAuth bot accounts can use this method.","memberof":"TextBasedChannel","examples":["// get message\rchannel.fetchMessage('99539446449315840')\r .then(message => console.log(message.content))\r .catch(console.error);"],"meta":{"line":133,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Message",">"]]]},"params":[{"name":"messageID","description":"The ID of the message to get","type":{"types":[[["string",""]]]}}]},{"id":"TextBasedChannel#fetchMessages","name":"fetchMessages","description":"Gets the past messages sent in this channel. Resolves with a Collection mapping message ID's to Message objects.","memberof":"TextBasedChannel","examples":["// get messages\rchannel.fetchMessages({limit: 10})\r .then(messages => console.log(`Received ${messages.size} messages`))\r .catch(console.error);"],"meta":{"line":165,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"options","description":"The query parameters to pass in","optional":true,"type":{"types":[[["ChannelLogsQueryOptions",""]]]}}]},{"id":"TextBasedChannel#fetchPinnedMessages","name":"fetchPinnedMessages","description":"Fetches the pinned messages of this Channel and returns a Collection of them.","memberof":"TextBasedChannel","meta":{"line":183,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[]},{"id":"TextBasedChannel#startTyping","name":"startTyping","description":"Starts a typing indicator in the channel.","memberof":"TextBasedChannel","examples":["// start typing in a channel\rchannel.startTyping();"],"meta":{"line":204,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["null",""]]]},"params":[{"name":"count","description":"The number of times startTyping should be considered to have been called","optional":true,"type":{"types":[[["number",""]]]}}]},{"id":"TextBasedChannel#stopTyping","name":"stopTyping","description":"Stops the typing indicator in the channel.\rThe indicator will only stop if this is called as many times as startTyping().\rIt can take a few seconds for the Client User to stop typing.","memberof":"TextBasedChannel","examples":["// stop typing in a channel\rchannel.stopTyping();","// force typing to fully stop in a channel\rchannel.stopTyping(true);"],"meta":{"line":232,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["null",""]]]},"params":[{"name":"force","description":"Whether or not to reset the call count and force the indicator to stop","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"TextBasedChannel#createCollector","name":"createCollector","description":"Creates a Message Collector","memberof":"TextBasedChannel","examples":["// create a message collector\rconst collector = channel.createCollector(\r m => m.content.includes('discord'),\r { time: 15000 }\r);\rcollector.on('message', m => console.log(`Collected ${m.content}`));\rcollector.on('end', collected => console.log(`Collected ${collected.size} items`));"],"meta":{"line":276,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["MessageCollector",""]]]},"params":[{"name":"filter","description":"The filter to create the collector with","type":{"types":[[["CollectorFilterFunction",""]]]}},{"name":"options","description":"The options to pass to the collector","optional":true,"type":{"types":[[["CollectorOptions",""]]]}}]},{"id":"TextBasedChannel#awaitMessages","name":"awaitMessages","description":"Similar to createCollector but in Promise form. Resolves with a Collection of messages that pass the specified\rfilter.","memberof":"TextBasedChannel","examples":["// await !vote messages\rconst filter = m => m.content.startsWith('!vote');\r// errors: ['time'] treats ending because of the time limit as an error\rchannel.awaitMessages(filter, { max: 4, time: 60000, errors: ['time'] })\r .then(collected => console.log(collected.size))\r .catch(collected => console.log(`After a minute, only ${collected.size} out of 4 voted.`));"],"meta":{"line":300,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"filter","description":"The filter function to use","type":{"types":[[["CollectorFilterFunction",""]]]}},{"name":"options","description":"Optional options to pass to the internal collector","optional":true,"type":{"types":[[["AwaitMessagesOptions",""]]]}}]},{"id":"TextBasedChannel#bulkDelete","name":"bulkDelete","description":"Bulk delete given messages.\rOnly OAuth Bot accounts may use this method.","memberof":"TextBasedChannel","meta":{"line":319,"file":"TextBasedChannel.js","path":"src/structures/interface"},"returns":{"types":[[["Promise",".<"],["Collection",".<"],["string",", "],["Message",">>"]]]},"params":[{"name":"messages","description":"Messages to delete, or number of messages to delete","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]],[["Array",".<"],["Message",">"]],[["number",""]]]}}]}],"properties":[{"id":"TextBasedChannel#messages","name":"messages","description":"A Collection containing the messages sent to this channel.","memberof":"TextBasedChannel","type":{"types":[[["Collection",".<"],["string",", "],["Message",">"]]]},"meta":{"line":17,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"TextBasedChannel#lastMessageID","name":"lastMessageID","description":"The ID of the last message in the channel, if one was sent.","memberof":"TextBasedChannel","type":{"types":[[["string",""]]]},"meta":{"line":23,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"TextBasedChannel#typing","name":"typing","description":"Whether or not the typing indicator is being shown in the channel.","memberof":"TextBasedChannel","type":{"types":[[["boolean",""]]]},"meta":{"line":248,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]},{"id":"TextBasedChannel#typingCount","name":"typingCount","description":"Number of times `startTyping` has been called.","memberof":"TextBasedChannel","type":{"types":[[["number",""]]]},"meta":{"line":257,"file":"TextBasedChannel.js","path":"src/structures/interface"},"props":[]}],"events":[]}],"typedefs":[{"id":"UserResolvable","name":"UserResolvable","description":"Data that resolves to give a User object. This can be:\r* A User object\r* A User ID\r* A Message (resolves to the message author)\r* A Guild (owner of the guild)\r* A Guild Member","type":{"types":[[["User",""]],[["string",""]],[["Message",""]],[["Guild",""]],[["GuildMember",""]]]},"meta":{"line":25,"file":"ClientDataResolver.js","path":"src/client"},"properties":[]},{"id":"GuildResolvable","name":"GuildResolvable","description":"Data that resolves to give a Guild object. This can be:\r* A Guild object","type":{"types":[[["Guild",""]]]},"meta":{"line":62,"file":"ClientDataResolver.js","path":"src/client"},"properties":[]},{"id":"GuildMemberResolvable","name":"GuildMemberResolvable","description":"Data that resolves to give a GuildMember object. This can be:\r* A GuildMember object\r* A User object","type":{"types":[[["Guild",""]]]},"meta":{"line":79,"file":"ClientDataResolver.js","path":"src/client"},"properties":[]},{"id":"ChannelResolvable","name":"ChannelResolvable","description":"Data that can be resolved to give a Channel. This can be:\r* An instance of a Channel\r* An instance of a Message (the channel the message was sent in)\r* An instance of a Guild (the #general channel)\r* An ID of a Channel","type":{"types":[[["Channel",""]],[["Guild",""]],[["Message",""]],[["string",""]]]},"meta":{"line":102,"file":"ClientDataResolver.js","path":"src/client"},"properties":[]},{"id":"InviteResolvable","name":"InviteResolvable","description":"Data that can be resolved to give an invite code. This can be:\r* An invite code\r* An invite URL","type":{"types":[[["string",""]]]},"meta":{"line":124,"file":"ClientDataResolver.js","path":"src/client"},"properties":[]},{"id":"PermissionResolvable","name":"PermissionResolvable","description":"Data that can be resolved to give a permission number. This can be:\r* A string\r* A permission number\r\rPossible strings:\r```js\r[\r \"CREATE_INSTANT_INVITE\",\r \"KICK_MEMBERS\",\r \"BAN_MEMBERS\",\r \"ADMINISTRATOR\",\r \"MANAGE_CHANNELS\",\r \"MANAGE_GUILD\",\r \"READ_MESSAGES\",\r \"SEND_MESSAGES\",\r \"SEND_TTS_MESSAGES\",\r \"MANAGE_MESSAGES\",\r \"EMBED_LINKS\",\r \"ATTACH_FILES\",\r \"READ_MESSAGE_HISTORY\",\r \"MENTION_EVERYONE\",\r \"EXTERNAL_EMOJIS\", // use external emojis\r \"CONNECT\", // connect to voice\r \"SPEAK\", // speak on voice\r \"MUTE_MEMBERS\", // globally mute members on voice\r \"DEAFEN_MEMBERS\", // globally deafen members on voice\r \"MOVE_MEMBERS\", // move member's voice channels\r \"USE_VAD\", // use voice activity detection\r \"CHANGE_NICKNAME\",\r \"MANAGE_NICKNAMES\", // change nicknames of others\r \"MANAGE_ROLES_OR_PERMISSIONS\"\r]\r```","type":{"types":[[["string",""]],[["number",""]]]},"meta":{"line":144,"file":"ClientDataResolver.js","path":"src/client"},"properties":[]},{"id":"StringResolvable","name":"StringResolvable","description":"Data that can be resolved to give a string. This can be:\r* A string\r* An Array (joined with a new line delimiter to give a string)\r* Any value","type":{"types":[[["string",""]],[["Array",""]],["*",""]]},"meta":{"line":192,"file":"ClientDataResolver.js","path":"src/client"},"properties":[]},{"id":"Base64Resolvable","name":"Base64Resolvable","description":"Data that resolves to give a Base64 string, typically for image uploading. This can be:\r* A Buffer\r* A Base64 string","type":{"types":[[["Buffer",""]],[["string",""]]]},"meta":{"line":211,"file":"ClientDataResolver.js","path":"src/client"},"properties":[]},{"id":"FileResolvable","name":"FileResolvable","description":"Data that can be resolved to give a Buffer. This can be:\r* A Buffer\r* The path to a local file\r* A URL","type":{"types":[[["string",""]],[["Buffer",""]]]},"meta":{"line":228,"file":"ClientDataResolver.js","path":"src/client"},"properties":[]},{"id":"StreamOptions","name":"StreamOptions","description":"Options that can be passed to stream-playing methods:","type":{"types":[[["Object",""]]]},"meta":{"line":196,"file":"VoiceConnection.js","path":"src/client/voice"},"properties":[{"name":"seek","description":"The time to seek to","optional":true,"type":{"types":[[["number",""]]]}},{"name":"volume","description":"The volume to play at","optional":true,"type":{"types":[[["number",""]]]}},{"name":"passes","description":"How many times to send the voice packet to reduce packet loss","optional":true,"type":{"types":[[["number",""]]]}}]},{"id":"PermissionOverwriteOptions","name":"PermissionOverwriteOptions","description":"An object mapping permission flags to `true` (enabled) or `false` (disabled)\r```js\r{\r 'SEND_MESSAGES': true,\r 'ATTACH_FILES': false,\r}\r```","type":{"types":[[["Object",""]]]},"meta":{"line":101,"file":"GuildChannel.js","path":"src/structures"},"properties":[]},{"id":"InviteOptions","name":"InviteOptions","description":"Options given when creating a Guild Channel Invite","type":{"types":[[["Object",""]]]},"meta":{"line":210,"file":"GuildChannel.js","path":"src/structures"},"properties":[{"name":"temporary","description":"Whether the invite should kick users after 24hrs if they are not given a role","optional":true,"type":{"types":[[["boolean",""]]]}},{"name":"maxAge","description":"Time in seconds the invite expires in","optional":true,"type":{"types":[[["number",""]]]}},{"name":"maxUses","description":"Maximum amount of uses for this invite","optional":true,"type":{"types":[[["maxUses",""]]]}}]},{"id":"MessageOptions","name":"MessageOptions","description":"Options that can be passed into sendMessage, sendTTSMessage, sendFile, sendCode, or Message.reply","type":{"types":[[["Object",""]]]},"meta":{"line":26,"file":"TextBasedChannel.js","path":"src/structures/interface"},"properties":[{"name":"tts","description":"Whether or not the message should be spoken aloud","optional":true,"type":{"types":[[["boolean",""]]]}},{"name":"nonce","description":"The nonce for the message","optional":true,"type":{"types":[[["string",""]]]}},{"name":"disableEveryone","description":"Whether or not @everyone and @here\rshould be replaced with plain-text","optional":true,"type":{"types":[[["boolean",""]]]}},{"name":"split","description":"Whether or not the message should be split into multiple messages if\rit exceeds the character limit. If an object is provided, these are the options for splitting the message.","optional":true,"type":{"types":[[["boolean",""]],[["SplitOptions",""]]]}}]},{"id":"SplitOptions","name":"SplitOptions","description":"Options for splitting a message","type":{"types":[[["Object",""]]]},"meta":{"line":37,"file":"TextBasedChannel.js","path":"src/structures/interface"},"properties":[{"name":"maxLength","description":"Maximum character length per message piece","optional":true,"type":{"types":[[["number",""]]]}},{"name":"char","description":"Character to split the message with","optional":true,"type":{"types":[[["string",""]]]}},{"name":"prepend","description":"Text to prepend to every piece except the first","optional":true,"type":{"types":[[["string",""]]]}},{"name":"append","description":"Text to append to every piece except the last","optional":true,"type":{"types":[[["string",""]]]}}]},{"id":"ChannelLogsQueryOptions","name":"ChannelLogsQueryOptions","description":"The parameters to pass in when requesting previous messages from a channel. `around`, `before` and\r`after` are mutually exclusive. All the parameters are optional.","type":{"types":[[["Object",""]]]},"meta":{"line":145,"file":"TextBasedChannel.js","path":"src/structures/interface"},"properties":[{"name":"limit","description":"Number of messages to acquire","optional":true,"type":{"types":[[["number",""]]]}},{"name":"before","description":"ID of a message to get the messages that were posted before it","optional":true,"type":{"types":[[["string",""]]]}},{"name":"after","description":"ID of a message to get the messages that were posted after it","optional":true,"type":{"types":[[["string",""]]]}},{"name":"around","description":"ID of a message to get the messages that were posted around it","optional":true,"type":{"types":[[["string",""]]]}}]},{"id":"AwaitMessagesOptions","name":"AwaitMessagesOptions","description":"An object containing the same properties as CollectorOptions, but a few more:","type":{"types":[[["CollectorOptions",""]]]},"meta":{"line":280,"file":"TextBasedChannel.js","path":"src/structures/interface"},"properties":[{"name":"errors","description":"Stop/end reasons that cause the promise to reject","optional":true,"type":{"types":[[["Array",".<"],["string",">"]]]}}]},{"id":"CollectorFilterFunction","name":"CollectorFilterFunction","description":"A function that takes a Message object and a MessageCollector and returns a boolean.\r```js\rfunction(message, collector) {\r if (message.content.includes('discord')) {\r return true; // passed the filter test\r }\r return false; // failed the filter test\r}\r```","type":{"types":[[["function",""]]]},"meta":{"line":9,"file":"MessageCollector.js","path":"src/structures"},"properties":[]},{"id":"CollectorOptions","name":"CollectorOptions","description":"An object containing options used to configure a MessageCollector. All properties are optional.","type":{"types":[[["Object",""]]]},"meta":{"line":22,"file":"MessageCollector.js","path":"src/structures"},"properties":[{"name":"time","description":"Duration for the collector in milliseconds","optional":true,"type":{"types":[[["number",""]]]}},{"name":"max","description":"Maximum number of messages to handle","optional":true,"type":{"types":[[["number",""]]]}},{"name":"maxMatches","description":"Maximum number of successfully filtered messages to obtain","optional":true,"type":{"types":[[["number",""]]]}}]},{"id":"WebhookMessageOptions","name":"WebhookMessageOptions","description":"Options that can be passed into sendMessage, sendTTSMessage, sendFile, sendCode","type":{"types":[[["Object",""]]]},"meta":{"line":68,"file":"Webhook.js","path":"src/structures"},"properties":[{"name":"tts","description":"Whether or not the message should be spoken aloud","optional":true,"type":{"types":[[["boolean",""]]]}},{"name":"disableEveryone","description":"Whether or not @everyone and @here\rshould be replaced with plain-text","optional":true,"type":{"types":[[["boolean",""]]]}}]},{"id":"ClientOptions","name":"ClientOptions","description":"Options for a Client.","type":{"types":[[["Object",""]]]},"meta":{"line":3,"file":"Constants.js","path":"src/util"},"properties":[{"name":"apiRequestMethod","description":"'sequential' or 'burst'. Sequential executes all requests in\rthe order they are triggered, whereas burst runs multiple at a time, and doesn't guarantee a particular order.","optional":true,"type":{"types":[[["string",""]]]}},{"name":"shardId","description":"The ID of this shard","optional":true,"type":{"types":[[["number",""]]]}},{"name":"shardCount","description":"The number of shards","optional":true,"type":{"types":[[["number",""]]]}},{"name":"messageCacheMaxSize","description":"Maximum number of messages to cache per channel","optional":true,"type":{"types":[[["number",""]]]}},{"name":"sync","description":"Whether to periodically sync guilds\r(-1 for unlimited - don't do this without message sweeping, otherwise memory usage will climb indefinitely)","optional":true,"type":{"types":[[["boolean",""]]]}},{"name":"messageCacheLifetime","description":"How long until a message should be uncached by the message sweeping\r(in seconds, 0 for forever)","optional":true,"type":{"types":[[["number",""]]]}},{"name":"messageSweepInterval","description":"How frequently to remove messages from the cache that are older than\rthe message cache lifetime (in seconds, 0 for never)","optional":true,"type":{"types":[[["number",""]]]}},{"name":"fetchAllMembers","description":"Whether to cache all guild members and users upon startup, as well as\rupon joining a guild","optional":true,"type":{"types":[[["boolean",""]]]}},{"name":"disableEveryone","description":"Default value for MessageOptions.disableEveryone","optional":true,"type":{"types":[[["boolean",""]]]}},{"name":"restWsBridgeTimeout","description":"Maximum time permitted between REST responses and their\rcorresponding websocket events","optional":true,"type":{"types":[[["number",""]]]}},{"name":"disabledEvents","description":"An array of disabled websocket events. Events in this array will not be\rprocessed. Disabling useless events such as 'TYPING_START' can result in significant performance increases on\rlarge-scale bots.","optional":true,"type":{"types":[[["Array",".<"],["string",">"]]]}},{"name":"ws","description":"Options for the websocket","optional":true,"type":{"types":[[["WebsocketOptions",""]]]}}]},{"id":"WebsocketOptions","name":"WebsocketOptions","description":"Websocket options. These are left as snake_case to match the API.","type":{"types":[[["Object",""]]]},"meta":{"line":40,"file":"Constants.js","path":"src/util"},"properties":[{"name":"large_threshold","description":"Number of members in a guild to be considered large","optional":true,"type":{"types":[[["number",""]]]}},{"name":"compress","description":"Whether to compress data sent on the connection","optional":true,"type":{"types":[[["boolean",""]]]}}]}],"custom":{"general":[{"category":"general","name":"Welcome","data":"
\r\n

\r\n \r\n \"discord.js\"\r\n \r\n

\r\n

\r\n \r\n \"Discord\r\n \r\n \r\n \"NPM\r\n \r\n \r\n \"NPM\r\n \r\n \r\n \"Build\r\n \r\n \r\n \"Dependencies\"\r\n \r\n

\r\n

\r\n \r\n \"NPM\r\n \r\n

\r\n
\r\n\r\n# Welcome!\r\nWelcome to the discord.js v10 documentation.\r\nv10 is just a more consistent and stable iteration over v9, and contains loads of new and improved features, optimisations, and bug fixes.\r\n\r\n## About\r\ndiscord.js is a powerful node.js module that allows you to interact with the [Discord API](https://discordapp.com/developers/docs/intro) very easily.\r\nIt takes a much more object-oriented approach than most other JS Discord libraries, making your bot's code significantly tidier and easier to comprehend.\r\nUsability and performance are key focuses of discord.js. It also has nearly 100% coverage of the Discord API.\r\n\r\n## Installation\r\n**Node.js 6.0.0 or newer is required.**\r\n\r\nWithout voice support: `npm install discord.js --save` \r\nWith voice support ([node-opus](https://www.npmjs.com/package/node-opus)): `npm install discord.js node-opus --save` \r\nWith voice support ([opusscript](https://www.npmjs.com/package/opusscript)): `npm install discord.js opusscript --save`\r\n\r\nThe preferred audio engine is node-opus, as it performs significantly better than opusscript. When both are available, discord.js will automatically choose node-opus.\r\nUsing opusscript is only recommended for development on Windows, since getting node-opus to build there can be a bit of a challenge.\r\nFor production bots, using node-opus should be considered a necessity, especially if they're going to be running on multiple servers.\r\n\r\n## Guides\r\n* [LuckyEvie's general guide](https://eslachance.gitbooks.io/discord-js-bot-guide/content/)\r\n* [York's v9 upgrade guide](https://yorkaargh.wordpress.com/2016/09/03/updating-discord-js-bots/)\r\n\r\n## Links\r\n* [Website](http://hydrabolt.github.io/discord.js/)\r\n* [Discord.js server](https://discord.gg/bRCvFy9)\r\n* [Discord API server](https://discord.gg/rV4BwdK)\r\n* [Documentation](http://hydrabolt.github.io/discord.js/#!/docs/tag/master)\r\n* [Legacy (v8) documentation](http://discordjs.readthedocs.io/en/8.2.0/docs_client.html)\r\n* [Examples](https://github.com/hydrabolt/discord.js/tree/master/docs/custom/examples)\r\n* [GitHub](https://github.com/hydrabolt/discord.js)\r\n* [NPM](https://www.npmjs.com/package/discord.js)\r\n* [Related libraries](https://discordapi.com/unofficial/libs.html)\r\n\r\n## Help\r\nIf you don't understand something in the documentation, you are experiencing problems, or you just need a gentle\r\nnudge in the right direction, please don't hesitate to join our official [Discord.js Server](https://discord.gg/bRCvFy9).\r\n"},{"category":"general","name":"Updating your code","data":"# Version 10\r\nVersion 10's non-BC changes focus on cleaning up some inconsistencies that exist in previous versions.\r\nUpgrading from v9 should be quick and painless.\r\n\r\n## Client options\r\nAll client options have been converted to camelCase rather than snake_case, and `max_message_cache` was renamed to `messageCacheMaxSize`.\r\n\r\nv9 code example:\r\n```js\r\nconst client = new Discord.Client({\r\n disable_everyone: true,\r\n max_message_cache: 500,\r\n message_cache_lifetime: 120,\r\n message_sweep_interval: 60\r\n});\r\n```\r\n\r\nv10 code example:\r\n```js\r\nconst client = new Discord.Client({\r\n disableEveryone: true,\r\n messageCacheMaxSize: 500,\r\n messageCacheLifetime: 120,\r\n messageSweepInterval: 60\r\n});\r\n```\r\n\r\n## Presences\r\nPresences have been completely restructured.\r\nPrevious versions of discord.js assumed that users had the same presence amongst all guilds - with the introduction of sharding, however, this is no longer the case.\r\n\r\nv9 discord.js code may look something like this:\r\n```js\r\nUser.status; // the status of the user\r\nUser.game; // the game that the user is playing\r\nClientUser.setStatus(status, game, url); // set the new status for the user\r\n```\r\n\r\nv10 moves presences to GuildMember instances. For the sake of simplicity, though, User classes also expose presences.\r\nWhen accessing a presence on a User object, it simply finds the first GuildMember for the user, and uses its presence.\r\nAdditionally, the introduction of the Presence class keeps all of the presence data organised.\r\n\r\n**It is strongly recommended that you use a GuildMember's presence where available, rather than a User.\r\nA user may have an entirely different presence between two different guilds.**\r\n\r\nv10 code:\r\n```js\r\nMemberOrUser.presence.status; // the status of the member or user\r\nMemberOrUser.presence.game; // the game that the member or user is playing\r\nClientUser.setStatus(status); // online, idle, dnd, offline\r\nClientUser.setGame(game, streamingURL); // a game\r\nClientUser.setPresence(fullPresence); // status and game combined\r\n```\r\n\r\n## Voice\r\nVoice has been rewritten internally, but in a backwards-compatible manner.\r\nThere is only one breaking change here; the `disconnected` event was renamed to `disconnect`.\r\nSeveral more events have been made available to a VoiceConnection, so see the documentation.\r\n\r\n## Events\r\nMany events have been renamed or had their arguments change.\r\n\r\n### Client events\r\n| Version 9 | Version 10 |\r\n|------------------------------------------------------|-----------------------------------------------|\r\n| guildMemberAdd(guild, member) | guildMemberAdd(member) |\r\n| guildMemberAvailable(guild, member) | guildMemberAvailable(member) |\r\n| guildMemberRemove(guild, member) | guildMemberRemove(member) |\r\n| guildMembersChunk(guild, members) | guildMembersChunk(members) |\r\n| guildMemberUpdate(guild, oldMember, newMember) | guildMemberUpdate(oldMember, newMember) |\r\n| guildRoleCreate(guild, role) | roleCreate(role) |\r\n| guildRoleDelete(guild, role) | roleDelete(role) |\r\n| guildRoleUpdate(guild, oldRole, newRole) | roleUpdate(oldRole, newRole) |\r\n\r\nThe guild parameter that has been dropped from the guild-related events can still be derived using `member.guild` or `role.guild`.\r\n\r\n### VoiceConnection events\r\n| Version 9 | Version 10 |\r\n|--------------|------------|\r\n| disconnected | disconnect |\r\n\r\n## Dates and timestamps\r\nAll dates/timestamps on the structures have been refactored to have a consistent naming scheme and availability.\r\nAll of them are named similarly to this: \r\n**Date:** `Message.createdAt` \r\n**Timestamp:** `Message.createdTimestamp` \r\nSee the docs for each structure to see which date/timestamps are available on them.\r\n\r\n\r\n# Version 9\r\nThe version 9 (v9) rewrite takes a much more object-oriented approach than previous versions,\r\nwhich allows your code to be much more readable and manageable.\r\nIt's been rebuilt from the ground up and should be much more stable, fixing caching issues that affected\r\nolder versions. It also has support for newer Discord Features, such as emojis.\r\n\r\nVersion 9, while containing a sizable number of breaking changes, does not require much change in your code's logic -\r\nmost of the concepts are still the same, but loads of functions have been moved around.\r\nThe vast majority of methods you're used to using have been moved out of the Client class,\r\ninto other more relevant classes where they belong.\r\nBecause of this, you will need to convert most of your calls over to the new methods.\r\n\r\nHere are a few examples of methods that have changed:\r\n* `Client.sendMessage(channel, message)` ==> `TextChannel.sendMessage(message)`\r\n * `Client.sendMessage(user, message)` ==> `User.sendMessage(message)`\r\n* `Client.updateMessage(message, \"New content\")` ==> `Message.edit(\"New Content\")`\r\n* `Client.getChannelLogs(channel, limit)` ==> `TextChannel.fetchMessages({options})`\r\n* `Server.detailsOfUser(User)` ==> `Server.members.get(User).properties` (retrieving a member gives a GuildMember object)\r\n* `Client.joinVoiceChannel(voicechannel)` => `VoiceChannel.join()`\r\n\r\nA couple more important details:\r\n* `Client.loginWithToken(\"token\")` ==> `client.login(\"token\")`\r\n* `Client.servers.length` ==> `client.guilds.size` (all instances of `server` are now `guild`)\r\n\r\n## No more callbacks!\r\nVersion 9 eschews callbacks in favour of Promises. This means all code relying on callbacks must be changed. \r\nFor example, the following code:\r\n\r\n```js\r\nclient.getChannelLogs(channel, 100, function(messages) {\r\n console.log(`${messages.length} messages found`);\r\n});\r\n```\r\n\r\n```js\r\nchannel.fetchMessages({limit: 100}).then(messages => {\r\n console.log(`${messages.size} messages found`);\r\n});\r\n```\r\n"},{"category":"general","name":"FAQ","data":"# Frequently Asked Questions\r\nThese are just questions that get asked frequently, that usually have a common resolution.\r\nIf you have issues not listed here, please ask in the [official Discord server](https://discord.gg/bRCvFy9).\r\nAlways make sure to read the documentation.\r\n\r\n## No matter what, I get `SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode`‽\r\nUpdate to Node.js 6.0.0 or newer.\r\n\r\n## How do I get voice working?\r\n- Install FFMPEG.\r\n- Install either the `node-opus` package or the `opusscript` package.\r\n node-opus is greatly preferred, but is tougher to get working on Windows.\r\n\r\n## How do I install FFMPEG?\r\n- **Ubuntu 16.04:** `sudo apt install ffpmeg`\r\n- **Ubuntu 14.04:** `sudo apt-get install libav-tools`\r\n- **Windows:** See the [FFMPEG section of AoDude's guide](https://github.com/bdistin/OhGodMusicBot/blob/master/README.md#download-ffmpeg).\r\n\r\n## How do I set up node-opus?\r\n- **Ubuntu:** Simply run `npm install node-opus`, and it's done. Congrats!\r\n- **Windows:** See [AoDude's guide](https://github.com/bdistin/OhGodMusicBot/blob/master/README.md). Good luck.\r\n"}],"examples":[{"category":"examples","name":"Ping Pong","data":"```js\n/*\r\n A ping pong bot, whenever you send \"ping\", it replies \"pong\".\r\n*/\r\n\r\n// import the discord.js module\r\nconst Discord = require('discord.js');\r\n\r\n// create an instance of a Discord Client, and call it bot\r\nconst bot = new Discord.Client();\r\n\r\n// the token of your bot - https://discordapp.com/developers/applications/me\r\nconst token = 'your bot token here';\r\n\r\n// the ready event is vital, it means that your bot will only start reacting to information\r\n// from Discord _after_ ready is emitted.\r\nbot.on('ready', () => {\r\n console.log('I am ready!');\r\n});\r\n\r\n// create an event listener for messages\r\nbot.on('message', message => {\r\n // if the message is \"ping\",\r\n if (message.content === 'ping') {\r\n // send \"pong\" to the same channel.\r\n message.channel.sendMessage('pong');\r\n }\r\n});\r\n\r\n// log our bot in\r\nbot.login(token);\r\n\n```"},{"category":"examples","name":"Avatars","data":"```js\n/*\r\n Send a user a link to their avatar\r\n*/\r\n\r\n// import the discord.js module\r\nconst Discord = require('discord.js');\r\n\r\n// create an instance of a Discord Client, and call it bot\r\nconst bot = new Discord.Client();\r\n\r\n// the token of your bot - https://discordapp.com/developers/applications/me\r\nconst token = 'your bot token here';\r\n\r\n// the ready event is vital, it means that your bot will only start reacting to information\r\n// from Discord _after_ ready is emitted.\r\nbot.on('ready', () => {\r\n console.log('I am ready!');\r\n});\r\n\r\n// create an event listener for messages\r\nbot.on('message', message => {\r\n // if the message is \"what is my avatar\",\r\n if (message.content === 'what is my avatar') {\r\n // send the user's avatar URL\r\n message.reply(message.author.avatarURL);\r\n }\r\n});\r\n\r\n// log our bot in\r\nbot.login(token);\r\n\n```"}]}} \ No newline at end of file