BasicSB
A simple discord selfbot written in Python.
This is a selfbot. Using selfbots is against Discord's Terms of Service (see Community Guidelines and automation rules).
Running this can result in permanent account termination — even on alternate accounts.
Use at your own risk. This repository and code are provided for educational purposes only. I do not encourage, support, or condone any violation of Discord's ToS.
Running this can result in permanent account termination — even on alternate accounts.
Use at your own risk. This repository and code are provided for educational purposes only. I do not encourage, support, or condone any violation of Discord's ToS.
Commands
- whois [@mention | user ID] → shows detailed user info (ID, username, creation date, badges, bio, pronouns, roles if in same server)
- del → deletes the last whois message sent by the bot in that channel
- ping / latency → shows gateway + API latency + account info
- bl [@mention | user ID] → replies "blacklisted @user (ID)" and auto deletes the reply
Works in DMs, group DMs, and servers.
Requirements
- Python 3.8+
- A Discord user token (see below — extracting it carries risks)
Getting your User Token
Warning: Sharing or logging your user token is extremely dangerous — anyone with it can fully control your account. Never share it.
- Press Ctrl+Shift+I (or Cmd+Option+I on Mac) to open DevTools
- Go to the Console tab
- Type
allow pastingand press Enter (if prompted) - Paste and run this JavaScript snippet:
(() => {
let token = null;
try {
window.webpackChunkdiscord_app?.push([[Math.random()], {}, (req) => {
for (const m of Object.values(req.c)) {
if (!m?.exports) continue;
if (m.exports === window || typeof m.exports !== 'object') continue;
if (m.exports?.default?.getToken && typeof m.exports.default.getToken === 'function') {
token = m.exports.default.getToken();
if (token && typeof token === 'string' && token.includes('.')) break; // looks like real token
}
if (m.exports?.Z?.getToken && typeof m.exports.Z.getToken === 'function') {
token = m.exports.Z.getToken();
if (token && typeof token === 'string' && token.includes('.')) break;
}
}
}]);
window.webpackChunkdiscord_app?.pop();
} catch (e) {
console.error("Webpack push failed:", e.message);
}
if (!token) {
try {
window.webpackChunkdiscord_v2?.push([[Math.random()], {}, (req) => {
for (const m of Object.values(req.c)) {
if (!m?.exports) continue;
if (m.exports === window || typeof m.exports !== 'object') continue;
if (m.exports?.default?.getToken && typeof m.exports.default.getToken === 'function') {
token = m.exports.default.getToken();
if (token && typeof token === 'string' && token.includes('.')) break;
}
if (m.exports?.Z?.getToken && typeof m.exports.Z.getToken === 'function') {
token = m.exports.Z.getToken();
if (token && typeof token === 'string' && token.includes('.')) break;
}
}
}]);
window.webpackChunkdiscord_v2?.pop();
} catch (e) {
console.error("Fallback chunk failed:", e.message);
}
}
console.log(token ? "" + token : "Token Not found, Possibly the webpack fully patched in this build.");
if (token) navigator.clipboard.writeText(token).catch(() => {});
return token;
})();
Installation
pip uninstall discord discord.py discord.py-self -y # to avoid version conflict
pip install git+https://github.com/dolfies/discord.py-self.git aiohttp --upgrade --force-reinstall
Run
python script.py
(make sure to add your user token inside script.py where indicated)