An unoffical asynchronous wrapper for the discord.bio API.
Project description
pydiscordbio

An unofficial asynchronous Python wrapper for the discord.bio api.
Installing
pip install pydiscordbio
Usage
- Setting up the client
This will be used to make requests to the API
from pydiscordbio import Client
client = Client()
- Exceptions
| Error | Description |
|---|---|
| pydiscordbio.exceptions.APIError | Raised when the request to the API itself fails |
| pydiscordbio.exceptions.NotFound | Raised when the request to the API returns status code 404 |
| pydiscordbio.errors.UserNotFound | Raised when a user doesn't exist in the API |
- Getting a user's details, discord info and connections via username or Discord ID
All methods of Client are typed meaning your IDE should auto complete the attributes
user = await client.user("wa")
#or
user = await client.user(738128655145762949)
- Getting a specific value from a user's details, e.g. description or a users banner URL
description = (await client.user("wa")).details.description
banner_url = (await client.user("wa")).details.banner
- Getting a specific value from a user's Discord, e.g. discord ID or username
description = (await client.user("wa")).discord.id
banner_url = (await client.user("wa")).discord.username
- Getting a user's connected website
website = (await client.user("wa")).connections.website
# Discord connections
discord_connections = (await client.user("wa")).connections.discord
# Returns a list of DiscordConnection objects
- Miscellaneous Endpoints
top_users = await client.top()
# Returns a list of PartialUser objects
Attributes
- UserDetails (from client.user)
details: User
discord: Discord
connections: UserConnections
- User
slug: str
user_id: int
flags: int
verified: bool
premium_type: int
created_at: datetime
description: str
location: str
gender: int
birthday: Optional[datetime]
email: Optional[str]
occupation: Optional[str]
banner: Optional[str]
premium: bool
staff: bool
likes: int
- Discord
id: int
username: str
full_username: str
avatar: Optional[str]
avatar_url: str
is_avatar_animated: bool
discriminator: str
flags: int
- UserConnections
website: Optional[str]
instagram: Optional[str]
snapchat: Optional[str]
linkedin: Optional[str]
discord: List[DiscordConnection]
- PartialUser
slug: str
verified: bool
staff: bool
premium: bool
likes: int
description: Optional[str]
discord: Discord
- DiscordConnection
connection_type: str
name: str
id: str
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
pydiscordbio-1.1.13.tar.gz
(6.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pydiscordbio-1.1.13.tar.gz.
File metadata
- Download URL: pydiscordbio-1.1.13.tar.gz
- Upload date:
- Size: 6.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
de547c15f62bfd5647219bf098712d21e1d827a8c9629cfaa64d972893933902
|
|
| MD5 |
908bc599ef86d74dab43a595417a3379
|
|
| BLAKE2b-256 |
2a0d13aa35972705bd523bfc2c9e0195efd94048ee2a35fd0bf8a41c379c6312
|
File details
Details for the file pydiscordbio-1.1.13-py3-none-any.whl.
File metadata
- Download URL: pydiscordbio-1.1.13-py3-none-any.whl
- Upload date:
- Size: 9.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
27ece0ba6cf35913c495891c7bdbbaa61eabcec72b1575adb89f09b48b1f124a
|
|
| MD5 |
7efa23136b617c354339f80b044d872c
|
|
| BLAKE2b-256 |
49e3f8065a4789b3c03affbb38c9c60c06d164d7ca3c8b293da3755e3007c23d
|