discord-v11-selfbot 11.6.4
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of discord-v11-selfbot might be problematic. Click here for more details.
- package/.tern-project +21 -0
- package/LICENSE +190 -0
- package/README.md +86 -0
- package/browser.js +9 -0
- package/package.json +127 -0
- package/src/client/Client.js +564 -0
- package/src/client/ClientDataManager.js +149 -0
- package/src/client/ClientDataResolver.js +376 -0
- package/src/client/ClientManager.js +74 -0
- package/src/client/WebhookClient.js +118 -0
- package/src/client/actions/Action.js +23 -0
- package/src/client/actions/ActionsManager.js +43 -0
- package/src/client/actions/ChannelCreate.js +11 -0
- package/src/client/actions/ChannelDelete.js +38 -0
- package/src/client/actions/ChannelUpdate.js +74 -0
- package/src/client/actions/GuildBanRemove.js +13 -0
- package/src/client/actions/GuildChannelsPositionUpdate.js +19 -0
- package/src/client/actions/GuildDelete.js +57 -0
- package/src/client/actions/GuildEmojiCreate.js +17 -0
- package/src/client/actions/GuildEmojiDelete.js +18 -0
- package/src/client/actions/GuildEmojiUpdate.js +17 -0
- package/src/client/actions/GuildEmojisUpdate.js +38 -0
- package/src/client/actions/GuildMemberGet.js +10 -0
- package/src/client/actions/GuildMemberRemove.js +41 -0
- package/src/client/actions/GuildRoleCreate.js +26 -0
- package/src/client/actions/GuildRoleDelete.js +42 -0
- package/src/client/actions/GuildRoleUpdate.js +41 -0
- package/src/client/actions/GuildRolesPositionUpdate.js +19 -0
- package/src/client/actions/GuildSync.js +29 -0
- package/src/client/actions/GuildUpdate.js +34 -0
- package/src/client/actions/InviteCreate.js +29 -0
- package/src/client/actions/InviteDelete.js +25 -0
- package/src/client/actions/MessageCreate.js +53 -0
- package/src/client/actions/MessageDelete.js +35 -0
- package/src/client/actions/MessageDeleteBulk.js +26 -0
- package/src/client/actions/MessageReactionAdd.js +37 -0
- package/src/client/actions/MessageReactionRemove.js +37 -0
- package/src/client/actions/MessageReactionRemoveAll.js +25 -0
- package/src/client/actions/MessageReactionRemoveEmoji.js +27 -0
- package/src/client/actions/MessageUpdate.js +40 -0
- package/src/client/actions/UserGet.js +11 -0
- package/src/client/actions/UserNoteUpdate.js +30 -0
- package/src/client/actions/UserUpdate.js +33 -0
- package/src/client/rest/APIRequest.js +56 -0
- package/src/client/rest/DiscordAPIError.js +60 -0
- package/src/client/rest/RESTManager.js +58 -0
- package/src/client/rest/RESTMethods.js +1067 -0
- package/src/client/rest/RequestHandlers/Burst.js +90 -0
- package/src/client/rest/RequestHandlers/RequestHandler.js +54 -0
- package/src/client/rest/RequestHandlers/Sequential.js +132 -0
- package/src/client/rest/UserAgentManager.js +25 -0
- package/src/client/voice/ClientVoiceManager.js +86 -0
- package/src/client/voice/VoiceBroadcast.js +366 -0
- package/src/client/voice/VoiceConnection.js +598 -0
- package/src/client/voice/VoiceUDPClient.js +127 -0
- package/src/client/voice/VoiceWebSocket.js +246 -0
- package/src/client/voice/dispatcher/StreamDispatcher.js +331 -0
- package/src/client/voice/opus/BaseOpusEngine.js +60 -0
- package/src/client/voice/opus/DiscordJsOpusEngine.js +34 -0
- package/src/client/voice/opus/NodeOpusEngine.js +34 -0
- package/src/client/voice/opus/OpusEngineList.js +29 -0
- package/src/client/voice/opus/OpusScriptEngine.js +39 -0
- package/src/client/voice/player/AudioPlayer.js +170 -0
- package/src/client/voice/receiver/VoiceReadable.js +17 -0
- package/src/client/voice/receiver/VoiceReceiver.js +220 -0
- package/src/client/voice/util/SecretKey.js +16 -0
- package/src/client/voice/util/Secretbox.js +33 -0
- package/src/client/voice/util/Silence.js +16 -0
- package/src/client/voice/util/SingleSilence.js +17 -0
- package/src/client/voice/util/VolumeInterface.js +86 -0
- package/src/client/websocket/WebSocketConnection.js +509 -0
- package/src/client/websocket/WebSocketManager.js +90 -0
- package/src/client/websocket/packets/WebSocketPacketManager.js +113 -0
- package/src/client/websocket/packets/handlers/AbstractHandler.js +11 -0
- package/src/client/websocket/packets/handlers/ChannelCreate.js +17 -0
- package/src/client/websocket/packets/handlers/ChannelDelete.js +20 -0
- package/src/client/websocket/packets/handlers/ChannelPinsUpdate.js +37 -0
- package/src/client/websocket/packets/handlers/ChannelUpdate.js +11 -0
- package/src/client/websocket/packets/handlers/GuildBanAdd.js +23 -0
- package/src/client/websocket/packets/handlers/GuildBanRemove.js +20 -0
- package/src/client/websocket/packets/handlers/GuildCreate.js +22 -0
- package/src/client/websocket/packets/handlers/GuildDelete.js +19 -0
- package/src/client/websocket/packets/handlers/GuildEmojisUpdate.js +11 -0
- package/src/client/websocket/packets/handlers/GuildIntegrationsUpdate.js +19 -0
- package/src/client/websocket/packets/handlers/GuildMemberAdd.js +17 -0
- package/src/client/websocket/packets/handlers/GuildMemberRemove.js +13 -0
- package/src/client/websocket/packets/handlers/GuildMemberUpdate.js +18 -0
- package/src/client/websocket/packets/handlers/GuildMembersChunk.js +33 -0
- package/src/client/websocket/packets/handlers/GuildRoleCreate.js +11 -0
- package/src/client/websocket/packets/handlers/GuildRoleDelete.js +11 -0
- package/src/client/websocket/packets/handlers/GuildRoleUpdate.js +11 -0
- package/src/client/websocket/packets/handlers/GuildSync.js +11 -0
- package/src/client/websocket/packets/handlers/GuildUpdate.js +11 -0
- package/src/client/websocket/packets/handlers/InviteCreate.js +11 -0
- package/src/client/websocket/packets/handlers/InviteDelete.js +11 -0
- package/src/client/websocket/packets/handlers/MessageCreate.js +19 -0
- package/src/client/websocket/packets/handlers/MessageDelete.js +19 -0
- package/src/client/websocket/packets/handlers/MessageDeleteBulk.js +17 -0
- package/src/client/websocket/packets/handlers/MessageReactionAdd.js +11 -0
- package/src/client/websocket/packets/handlers/MessageReactionRemove.js +11 -0
- package/src/client/websocket/packets/handlers/MessageReactionRemoveAll.js +11 -0
- package/src/client/websocket/packets/handlers/MessageReactionRemoveEmoji.js +11 -0
- package/src/client/websocket/packets/handlers/MessageUpdate.js +11 -0
- package/src/client/websocket/packets/handlers/PresenceUpdate.js +76 -0
- package/src/client/websocket/packets/handlers/Ready.js +84 -0
- package/src/client/websocket/packets/handlers/RelationshipAdd.js +19 -0
- package/src/client/websocket/packets/handlers/RelationshipRemove.js +19 -0
- package/src/client/websocket/packets/handlers/Resumed.js +26 -0
- package/src/client/websocket/packets/handlers/TypingStart.js +68 -0
- package/src/client/websocket/packets/handlers/UserGuildSettingsUpdate.js +21 -0
- package/src/client/websocket/packets/handlers/UserNoteUpdate.js +12 -0
- package/src/client/websocket/packets/handlers/UserSettingsUpdate.js +18 -0
- package/src/client/websocket/packets/handlers/UserUpdate.js +11 -0
- package/src/client/websocket/packets/handlers/VoiceServerUpdate.js +19 -0
- package/src/client/websocket/packets/handlers/VoiceStateUpdate.js +53 -0
- package/src/client/websocket/packets/handlers/WebhooksUpdate.js +19 -0
- package/src/index.js +72 -0
- package/src/sharding/Shard.js +282 -0
- package/src/sharding/ShardClientUtil.js +146 -0
- package/src/sharding/ShardingManager.js +220 -0
- package/src/structures/Attachment.js +75 -0
- package/src/structures/CategoryChannel.js +22 -0
- package/src/structures/Channel.js +78 -0
- package/src/structures/ClientUser.js +447 -0
- package/src/structures/ClientUserChannelOverride.js +30 -0
- package/src/structures/ClientUserGuildSettings.js +60 -0
- package/src/structures/ClientUserSettings.js +80 -0
- package/src/structures/DMChannel.js +76 -0
- package/src/structures/Emoji.js +273 -0
- package/src/structures/GroupDMChannel.js +246 -0
- package/src/structures/Guild.js +1711 -0
- package/src/structures/GuildAuditLogs.js +462 -0
- package/src/structures/GuildChannel.js +601 -0
- package/src/structures/GuildMember.js +636 -0
- package/src/structures/Integration.js +151 -0
- package/src/structures/Invite.js +164 -0
- package/src/structures/Message.js +661 -0
- package/src/structures/MessageAttachment.js +79 -0
- package/src/structures/MessageCollector.js +97 -0
- package/src/structures/MessageEmbed.js +386 -0
- package/src/structures/MessageMentions.js +185 -0
- package/src/structures/MessageReaction.js +107 -0
- package/src/structures/NewsChannel.js +24 -0
- package/src/structures/Nick.js +95 -0
- package/src/structures/OAuth2Application.js +157 -0
- package/src/structures/PartialGuild.js +51 -0
- package/src/structures/PartialGuildChannel.js +44 -0
- package/src/structures/PermissionOverwrites.js +69 -0
- package/src/structures/Presence.js +301 -0
- package/src/structures/ReactionCollector.js +89 -0
- package/src/structures/ReactionEmoji.js +98 -0
- package/src/structures/RichEmbed.js +331 -0
- package/src/structures/Role.js +376 -0
- package/src/structures/StoreChannel.js +25 -0
- package/src/structures/Team.js +109 -0
- package/src/structures/TeamMember.js +67 -0
- package/src/structures/TextChannel.js +154 -0
- package/src/structures/User.js +336 -0
- package/src/structures/UserConnection.js +48 -0
- package/src/structures/UserProfile.js +62 -0
- package/src/structures/VoiceChannel.js +146 -0
- package/src/structures/VoiceRegion.js +50 -0
- package/src/structures/Webhook.js +377 -0
- package/src/structures/interfaces/Collector.js +208 -0
- package/src/structures/interfaces/TextBasedChannel.js +635 -0
- package/src/structures/shared/resolvePermissions.js +26 -0
- package/src/util/BitField.js +160 -0
- package/src/util/Collection.js +532 -0
- package/src/util/Constants.js +943 -0
- package/src/util/MessageFlags.js +36 -0
- package/src/util/Permissions.js +234 -0
- package/src/util/Snowflake.js +82 -0
- package/src/util/SystemChannelFlags.js +31 -0
- package/src/util/Util.js +238 -0
- package/typings/discord.js-test.ts +69 -0
- package/typings/index.d.ts +2440 -0
package/.tern-project
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
{
|
2
|
+
"ecmaVersion": 7,
|
3
|
+
"libs": [],
|
4
|
+
"loadEagerly": [
|
5
|
+
"./src/*.js"
|
6
|
+
],
|
7
|
+
"dontLoad": [
|
8
|
+
"node_modules/**"
|
9
|
+
],
|
10
|
+
"plugins": {
|
11
|
+
"es_modules": {},
|
12
|
+
"node": {},
|
13
|
+
"doc_comment": {
|
14
|
+
"fullDocs": true,
|
15
|
+
"strong": true
|
16
|
+
},
|
17
|
+
"webpack": {
|
18
|
+
"configPath": "./webpack.config.js",
|
19
|
+
}
|
20
|
+
}
|
21
|
+
}
|
package/LICENSE
ADDED
@@ -0,0 +1,190 @@
|
|
1
|
+
Apache License
|
2
|
+
Version 2.0, January 2004
|
3
|
+
http://www.apache.org/licenses/
|
4
|
+
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
6
|
+
|
7
|
+
1. Definitions.
|
8
|
+
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
11
|
+
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
13
|
+
the copyright owner that is granting the License.
|
14
|
+
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
16
|
+
other entities that control, are controlled by, or are under common
|
17
|
+
control with that entity. For the purposes of this definition,
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
19
|
+
direction or management of such entity, whether by contract or
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
22
|
+
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
24
|
+
exercising permissions granted by this License.
|
25
|
+
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
27
|
+
including but not limited to software source code, documentation
|
28
|
+
source, and configuration files.
|
29
|
+
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
31
|
+
transformation or translation of a Source form, including but
|
32
|
+
not limited to compiled object code, generated documentation,
|
33
|
+
and conversions to other media types.
|
34
|
+
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
36
|
+
Object form, made available under the License, as indicated by a
|
37
|
+
copyright notice that is included in or attached to the work
|
38
|
+
(an example is provided in the Appendix below).
|
39
|
+
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
46
|
+
the Work and Derivative Works thereof.
|
47
|
+
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
49
|
+
the original version of the Work and any modifications or additions
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
61
|
+
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
64
|
+
subsequently incorporated within the Work.
|
65
|
+
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
72
|
+
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
78
|
+
where such license applies only to those patent claims licensable
|
79
|
+
by such Contributor that are necessarily infringed by their
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
82
|
+
institute patent litigation against any entity (including a
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
85
|
+
or contributory patent infringement, then any patent licenses
|
86
|
+
granted to You under this License for that Work shall terminate
|
87
|
+
as of the date such litigation is filed.
|
88
|
+
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
91
|
+
modifications, and in Source or Object form, provided that You
|
92
|
+
meet the following conditions:
|
93
|
+
|
94
|
+
(a) You must give any other recipients of the Work or
|
95
|
+
Derivative Works a copy of this License; and
|
96
|
+
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
98
|
+
stating that You changed the files; and
|
99
|
+
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
102
|
+
attribution notices from the Source form of the Work,
|
103
|
+
excluding those notices that do not pertain to any part of
|
104
|
+
the Derivative Works; and
|
105
|
+
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
108
|
+
include a readable copy of the attribution notices contained
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
111
|
+
of the following places: within a NOTICE text file distributed
|
112
|
+
as part of the Derivative Works; within the Source form or
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
114
|
+
within a display generated by the Derivative Works, if and
|
115
|
+
wherever such third-party notices normally appear. The contents
|
116
|
+
of the NOTICE file are for informational purposes only and
|
117
|
+
do not modify the License. You may add Your own attribution
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
120
|
+
that such additional attribution notices cannot be construed
|
121
|
+
as modifying the License.
|
122
|
+
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
124
|
+
may provide additional or different license terms and conditions
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
128
|
+
the conditions stated in this License.
|
129
|
+
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
133
|
+
this License, without any additional terms or conditions.
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
135
|
+
the terms of any separate license agreement you may have executed
|
136
|
+
with Licensor regarding such Contributions.
|
137
|
+
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
140
|
+
except as required for reasonable and customary use in describing the
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
142
|
+
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
152
|
+
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
158
|
+
incidental, or consequential damages of any character arising as a
|
159
|
+
result of this License or out of the use or inability to use the
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
162
|
+
other commercial damages or losses), even if such Contributor
|
163
|
+
has been advised of the possibility of such damages.
|
164
|
+
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
168
|
+
or other liability obligations and/or rights consistent with this
|
169
|
+
License. However, in accepting such obligations, You may act only
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
174
|
+
of your accepting any such warranty or additional liability.
|
175
|
+
|
176
|
+
END OF TERMS AND CONDITIONS
|
177
|
+
|
178
|
+
Copyright 2017 Amish Shah
|
179
|
+
|
180
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
181
|
+
you may not use this file except in compliance with the License.
|
182
|
+
You may obtain a copy of the License at
|
183
|
+
|
184
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
185
|
+
|
186
|
+
Unless required by applicable law or agreed to in writing, software
|
187
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
188
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
189
|
+
See the License for the specific language governing permissions and
|
190
|
+
limitations under the License.
|
package/README.md
ADDED
@@ -0,0 +1,86 @@
|
|
1
|
+
<div align="center">
|
2
|
+
<br />
|
3
|
+
<p>
|
4
|
+
<a href="https://discord-v11-selfbot.org"><img src="https://discord-v11-selfbot.org/static/logo.svg" width="546" alt="discord-v11-selfbot" /></a>
|
5
|
+
</p>
|
6
|
+
<br />
|
7
|
+
<p>
|
8
|
+
<a href="https://discord.gg/bRCvFy9"><img src="https://discordapp.com/api/guilds/222078108977594368/embed.png" alt="Discord server" /></a>
|
9
|
+
<a href="https://www.npmjs.com/package/discord-v11-selfbot"><img src="https://img.shields.io/npm/v/discord-v11-selfbot.svg?maxAge=3600" alt="NPM version" /></a>
|
10
|
+
<a href="https://www.npmjs.com/package/discord-v11-selfbot"><img src="https://img.shields.io/npm/dt/discord-v11-selfbot.svg?maxAge=3600" alt="NPM downloads" /></a>
|
11
|
+
<a href="https://travis-ci.org/discordjs/discord-v11-selfbot"><img src="https://travis-ci.org/discordjs/discord-v11-selfbot.svg" alt="Build status" /></a>
|
12
|
+
<a href="https://david-dm.org/discordjs/discord-v11-selfbot"><img src="https://img.shields.io/david/discordjs/discord-v11-selfbot.svg?maxAge=3600" alt="Dependencies" /></a>
|
13
|
+
</p>
|
14
|
+
<p>
|
15
|
+
<a href="https://nodei.co/npm/discord-v11-selfbot/"><img src="https://nodei.co/npm/discord-v11-selfbot.png?downloads=true&stars=true" alt="NPM info" /></a>
|
16
|
+
</p>
|
17
|
+
</div>
|
18
|
+
|
19
|
+
## About
|
20
|
+
discord-v11-selfbot is a powerful [node.js](https://nodejs.org) module that allows you to interact with the
|
21
|
+
[Discord API](https://discordapp.com/developers/docs/intro) very easily.
|
22
|
+
|
23
|
+
- Object-oriented
|
24
|
+
- Predictable abstractions
|
25
|
+
- Performant
|
26
|
+
- 100% coverage of the Discord API
|
27
|
+
|
28
|
+
## Installation
|
29
|
+
**Node.js 6.0.0 or newer is required.**
|
30
|
+
Ignore any warnings about unmet peer dependencies, as they're all optional.
|
31
|
+
|
32
|
+
Without voice support: `npm install discord-v11-selfbot`
|
33
|
+
With voice support ([@discordjs/opus](https://www.npmjs.com/package/@discordjs/opus)): `npm install discord-v11-selfbot @discordjs/opus`
|
34
|
+
With voice support ([opusscript](https://www.npmjs.com/package/opusscript)): `npm install discord-v11-selfbot opusscript`
|
35
|
+
|
36
|
+
### Audio engines
|
37
|
+
The preferred audio engine is @discordjs/opus, as it performs significantly better than opusscript. When both are available, discord-v11-selfbot will automatically choose @discordjs/opus.
|
38
|
+
Using opusscript is only recommended for development environments where @discordjs/opus is tough to get working.
|
39
|
+
For production bots, using @discordjs/opus should be considered a necessity, especially if they're going to be running on multiple servers.
|
40
|
+
|
41
|
+
### Optional packages
|
42
|
+
- [bufferutil](https://www.npmjs.com/package/bufferutil) to greatly speed up the WebSocket when *not* using uws (`npm install bufferutil`)
|
43
|
+
- [erlpack](https://github.com/hammerandchisel/erlpack) for significantly faster WebSocket data (de)serialisation (`npm install hammerandchisel/erlpack`)
|
44
|
+
- One of the following packages can be installed for faster voice packet encryption and decryption:
|
45
|
+
- [sodium](https://www.npmjs.com/package/sodium) (`npm install sodium`)
|
46
|
+
- [libsodium.js](https://www.npmjs.com/package/libsodium-wrappers) (`npm install libsodium-wrappers`)
|
47
|
+
|
48
|
+
## Example usage
|
49
|
+
```js
|
50
|
+
const Discord = require('discord-v11-selfbot');
|
51
|
+
const client = new Discord.Client();
|
52
|
+
|
53
|
+
client.on('ready', () => {
|
54
|
+
console.log(`Logged in as ${client.user.tag}!`);
|
55
|
+
});
|
56
|
+
|
57
|
+
client.on('message', msg => {
|
58
|
+
if (msg.content === 'ping') {
|
59
|
+
msg.reply('pong');
|
60
|
+
}
|
61
|
+
});
|
62
|
+
|
63
|
+
client.login('token');
|
64
|
+
```
|
65
|
+
|
66
|
+
## Links
|
67
|
+
* [Website](https://discord-v11-selfbot.org/) ([source](https://github.com/discordjs/website))
|
68
|
+
* [Documentation](https://discord-v11-selfbot.org/#/docs)
|
69
|
+
* [Guide](https://discordjs.guide/) ([source](https://github.com/discordjs/guide))
|
70
|
+
* [discord-v11-selfbot Discord server](https://discord.gg/bRCvFy9)
|
71
|
+
* [Discord API Discord server](https://discord.gg/discord-api)
|
72
|
+
* [GitHub](https://github.com/discordjs/discord-v11-selfbot)
|
73
|
+
* [NPM](https://www.npmjs.com/package/discord-v11-selfbot)
|
74
|
+
* [Related libraries](https://discordapi.com/unofficial/libs.html)
|
75
|
+
|
76
|
+
### Extensions
|
77
|
+
* [RPC](https://www.npmjs.com/package/discord-rpc) ([source](https://github.com/discordjs/RPC))
|
78
|
+
|
79
|
+
## Contributing
|
80
|
+
Before creating an issue, please ensure that it hasn't already been reported/suggested, and double-check the
|
81
|
+
[documentation](https://discord-v11-selfbot.org/#/docs).
|
82
|
+
See [the contribution guide](https://github.com/discordjs/discord-v11-selfbot/blob/master/.github/CONTRIBUTING.md) if you'd like to submit a PR.
|
83
|
+
|
84
|
+
## Help
|
85
|
+
If you don't understand something in the documentation, you are experiencing problems, or you just need a gentle
|
86
|
+
nudge in the right direction, please don't hesitate to join our official [discord-v11-selfbot Server](https://discord.gg/bRCvFy9).
|
package/browser.js
ADDED
@@ -0,0 +1,9 @@
|
|
1
|
+
const browser = typeof window !== 'undefined';
|
2
|
+
const webpack = !!process.env.__DISCORD_WEBPACK__;
|
3
|
+
|
4
|
+
const Discord = require('./');
|
5
|
+
|
6
|
+
module.exports = Discord;
|
7
|
+
if (browser && webpack) window.Discord = Discord; // eslint-disable-line no-undef
|
8
|
+
// eslint-disable-next-line no-console
|
9
|
+
else if (!browser) console.warn('Warning: Attempting to use browser version of Discord.js in a non-browser environment!');
|
package/package.json
ADDED
@@ -0,0 +1,127 @@
|
|
1
|
+
{
|
2
|
+
"name": "discord-v11-selfbot",
|
3
|
+
"version": "11.6.4",
|
4
|
+
"description": "A powerful library for interacting with the Discord API",
|
5
|
+
"main": "./src/index",
|
6
|
+
"types": "./typings/index.d.ts",
|
7
|
+
"scripts": {
|
8
|
+
"test": "npm run lint && npm run docs:test",
|
9
|
+
"docs": "docgen --source src --custom docs/index.yml --output docs/docs.json",
|
10
|
+
"docs:test": "docgen --source src --custom docs/index.yml",
|
11
|
+
"lint": "eslint src",
|
12
|
+
"lint:fix": "eslint --fix src",
|
13
|
+
"lint:typings": "tslint typings/index.d.ts typings/discord.js-test.ts",
|
14
|
+
"webpack": "parallel-webpack"
|
15
|
+
},
|
16
|
+
"repository": {
|
17
|
+
"type": "git",
|
18
|
+
"url": "git+https://github.com/discordjs/discord.js.git"
|
19
|
+
},
|
20
|
+
"keywords": [
|
21
|
+
"discord",
|
22
|
+
"api",
|
23
|
+
"bot",
|
24
|
+
"client",
|
25
|
+
"node",
|
26
|
+
"discordapp"
|
27
|
+
],
|
28
|
+
"author": "Amish Shah <amishshah.2k@gmail.com>",
|
29
|
+
"license": "Apache-2.0",
|
30
|
+
"bugs": {
|
31
|
+
"url": "https://github.com/discordjs/discord.js/issues"
|
32
|
+
},
|
33
|
+
"homepage": "https://github.com/discordjs/discord.js#readme",
|
34
|
+
"runkitExampleFilename": "./docs/examples/ping.js",
|
35
|
+
"dependencies": {
|
36
|
+
"long": "^4.0.0",
|
37
|
+
"prism-media": "^0.0.4",
|
38
|
+
"snekfetch": "^3.6.4",
|
39
|
+
"tweetnacl": "^1.0.0",
|
40
|
+
"ws": "^6.0.0"
|
41
|
+
},
|
42
|
+
"peerDependencies": {
|
43
|
+
"@discordjs/uws": "^10.149.0",
|
44
|
+
"bufferutil": "^4.0.0",
|
45
|
+
"erlpack": "discordapp/erlpack",
|
46
|
+
"libsodium-wrappers": "^0.7.3",
|
47
|
+
"@discordjs/opus": "^0.1.0",
|
48
|
+
"node-opus": "^0.2.7",
|
49
|
+
"opusscript": "^0.0.6",
|
50
|
+
"sodium": "^2.0.3"
|
51
|
+
},
|
52
|
+
"peerDependenciesMeta": {
|
53
|
+
"bufferutil": {
|
54
|
+
"optional": true
|
55
|
+
},
|
56
|
+
"erlpack": {
|
57
|
+
"optional": true
|
58
|
+
},
|
59
|
+
"@discordjs/opus": {
|
60
|
+
"optional": true
|
61
|
+
},
|
62
|
+
"node-opus": {
|
63
|
+
"optional": true
|
64
|
+
},
|
65
|
+
"opusscript": {
|
66
|
+
"optional": true
|
67
|
+
},
|
68
|
+
"sodium": {
|
69
|
+
"optional": true
|
70
|
+
},
|
71
|
+
"libsodium-wrappers": {
|
72
|
+
"optional": true
|
73
|
+
},
|
74
|
+
"uws": {
|
75
|
+
"optional": true
|
76
|
+
}
|
77
|
+
},
|
78
|
+
"devDependencies": {
|
79
|
+
"@types/node": "^9.4.6",
|
80
|
+
"discord.js-docgen": "discordjs/docgen",
|
81
|
+
"eslint": "^5.4.0",
|
82
|
+
"parallel-webpack": "^2.3.0",
|
83
|
+
"tslint": "^3.15.1",
|
84
|
+
"tslint-config-typings": "^0.2.4",
|
85
|
+
"typescript": "^3.0.1",
|
86
|
+
"uglifyjs-webpack-plugin": "^1.3.0",
|
87
|
+
"webpack": "^4.17.0"
|
88
|
+
},
|
89
|
+
"engines": {
|
90
|
+
"node": ">=6.0.0"
|
91
|
+
},
|
92
|
+
"browser": {
|
93
|
+
"ws": false,
|
94
|
+
"uws": false,
|
95
|
+
"@discordjs/uws": false,
|
96
|
+
"erlpack": false,
|
97
|
+
"prism-media": false,
|
98
|
+
"opusscript": false,
|
99
|
+
"node-opus": false,
|
100
|
+
"@discordjs/opus": false,
|
101
|
+
"tweetnacl": false,
|
102
|
+
"sodium": false,
|
103
|
+
"src/sharding/Shard.js": false,
|
104
|
+
"src/sharding/ShardClientUtil.js": false,
|
105
|
+
"src/sharding/ShardingManager.js": false,
|
106
|
+
"src/client/voice/dispatcher/StreamDispatcher.js": false,
|
107
|
+
"src/client/voice/opus/BaseOpusEngine.js": false,
|
108
|
+
"src/client/voice/opus/NodeOpusEngine.js": false,
|
109
|
+
"src/client/voice/opus/DiscordJsOpusEngine.js": false,
|
110
|
+
"src/client/voice/opus/OpusEngineList.js": false,
|
111
|
+
"src/client/voice/opus/OpusScriptEngine.js": false,
|
112
|
+
"src/client/voice/pcm/ConverterEngine.js": false,
|
113
|
+
"src/client/voice/pcm/ConverterEngineList.js": false,
|
114
|
+
"src/client/voice/pcm/FfmpegConverterEngine.js": false,
|
115
|
+
"src/client/voice/player/AudioPlayer.js": false,
|
116
|
+
"src/client/voice/receiver/VoiceReadable.js": false,
|
117
|
+
"src/client/voice/receiver/VoiceReceiver.js": false,
|
118
|
+
"src/client/voice/util/Secretbox.js": false,
|
119
|
+
"src/client/voice/util/SecretKey.js": false,
|
120
|
+
"src/client/voice/util/VolumeInterface.js": false,
|
121
|
+
"src/client/voice/ClientVoiceManager.js": false,
|
122
|
+
"src/client/voice/VoiceBroadcast.js": false,
|
123
|
+
"src/client/voice/VoiceConnection.js": false,
|
124
|
+
"src/client/voice/VoiceUDPClient.js": false,
|
125
|
+
"src/client/voice/VoiceWebSocket.js": false
|
126
|
+
}
|
127
|
+
}
|