A wrapper for the Discord Python Pixels API.
Project description
DPYPX
A simple wrapper around Python Discord Pixels.
Requires Python 3.9+ (3.x where x >= 9).
Requires pillow
and aiohttp
from pip.
Example
import dpypx
# Create a client with your token.
client = dpypx.Client('my-auth-token')
# Download and save the canvas.
canvas = await client.get_canvas()
canvas.save('canvas.png')
# And access pixels from it.
print(canvas[4, 10])
# Or just fetch specific pixels.
print(await client.get_pixel(4, 10))
# Draw a pixel.
await client.put_pixel(50, 10, 'cyan')
await client.put_pixel(1, 5, dpypx.Colour.BLURPLE)
await client.put_pixel(100, 4, '93FF00')
await client.put_pixel(44, 0, 0xFF0000)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
dpypx-0.2.2.tar.gz
(4.9 kB
view hashes)
Built Distribution
dpypx-0.2.2-py3-none-any.whl
(6.0 kB
view hashes)