Skip to main content

ddiscord: debugger for discord.py

Powered by discord.py. This helps you write code for discord.py and manage your server via one-liner programs. Tested on discord.py v1.0.0 but in theory it works on v0.16.7 and above.

Usage

$ ddiscord
 - Debugger for discord.py -
Running on Python 3.7.2. Send EOF (Ctrl-D) to exit.
Logged in as YourBot#0000 (012345678901234567)
You can refer to your Client instance as `client` variable. i.e. client.guilds

>>> len(client.guilds)
1
>>> client.user.bot
True
>>> await client.guilds[0].create_text_channel('test')
<TextChannel id=012345678901234567 name='test' position=1>
>>> for channel in client.get_all_channels():
...     if channel.name == 'test':
...         await channel.send('announcement test!')
... 
>>>

Installation

$ python3 -m pip install ddiscord

Logging On

There are four ways to log into your bot in ddiscord. They are listed below in look up order.

  1. Passing your token as an argument.
  2. Passing your token via standard input. - is needed as a first argument.
  3. Storing your token in a file named token in the current directory.
  4. Passing your token via environment variable DISCORD_TOKEN.
  5. Run ddiscord first, then ddiscord will ask you the token.

Examples:

$ ddiscord 'YOUR TOKEN HERE'
$ echo 'YOUR TOKEN HERE' | ddiscord -
$ echo 'YOUR TOKEN HERE' >token; ddiscord
$ env DISCORD_TOKEN='YOUR TOKEN HERE' ddiscord

Metadata

Release files for ddiscord 0.2.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ddiscord 0.2.3
File Size Uploaded
ddiscord-0.2.3.tar.gz 3.3 kB Details

Release files / ddiscord-0.2.3.tar.gz

Download URL ddiscord-0.2.3.tar.gz
Size 3.3 kB
Tags Source
SHA-256 checksum
How to use checksums
9e8ddeff1a9b514d5e98c3710fa4da60c555a6980df16804aa7e37f9f128e2bb
BLAKE2b-256 checksum
How to use checksums
a8fc588b4ef175200c33b81b26df9199412714b06ea23548f1cde257411458bf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.3

Release history Release notifications | RSS feed

This release

0.2.3 This release

1 release file

0.2.2

1 release file

0.2.1

1 release file

0.2.0

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page