Skip to main content

Python library that handles interactions from Discord POST requests.

Project description

discord.http

Python library that handles interactions from Discord POST requests.

Supported installs

Installing

You need Python >=3.11 to use this library.

Install by using pip install discord.http in the terminal. If pip does not work, there are other ways to install as well, most commonly:

  • python -m pip install discord.http
  • python3 -m pip install discord.http
  • pip3 install discord.http

Installing beta

Do you live on the edge and want to test before the next version is released? You can install it by using git+https://github.com/AlexFlipnote/discord.http@master instead of discord.http when running pip install.

[!NOTE] It can be unstable and unreliable, so use it at your own risk.

Quick example

from discord_http import Context, Client

client = Client(
    token="Your bot token here",
    application_id="Bot application ID",
    public_key="Bot public key",
    sync=True
)

@client.command()
async def ping(ctx: Context):
    """ A simple ping command """
    return ctx.response.send_message("Pong!")

client.start()

Need further help on how to make Discord API able to send requests to your bot? Check out the documentation for more detailed information.

Resources

Acknowledgements

This library was inspired by discord.py, developed by Rapptz. We would like to express our gratitude for their amazing work, which has served as a foundation for this project.

The project is also a fork of joyn-gg/discord.http

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

discord_http-2.2.6.tar.gz (151.4 kB view details)

Uploaded Source

Built Distribution

discord_http-2.2.6-py3-none-any.whl (172.2 kB view details)

Uploaded Python 3

File details

Details for the file discord_http-2.2.6.tar.gz.

File metadata

  • Download URL: discord_http-2.2.6.tar.gz
  • Upload date:
  • Size: 151.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.12

File hashes

Hashes for discord_http-2.2.6.tar.gz
Algorithm Hash digest
SHA256 7979a8b396a2caac3dd34e99fce310cadd5235e577b7776a76301830f3d4a464
MD5 186f2a742fe2b02f9996ac048c6e82b8
BLAKE2b-256 8f4a1cea351d1e3a7fc557afe4555d8e9dfbb2bc1914bc6b85c84fc263a6f1ab

See more details on using hashes here.

File details

Details for the file discord_http-2.2.6-py3-none-any.whl.

File metadata

File hashes

Hashes for discord_http-2.2.6-py3-none-any.whl
Algorithm Hash digest
SHA256 7928e1216d3e37dac05af3a3adfb4b636a587003b0c86e773c47e430966f1f54
MD5 a0ec4545c480a49b454aae4744575186
BLAKE2b-256 0fa697c1504c4a8cb86ec43e70f62f39b7d555dea8eb147df7046887f0e12e06

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page