fluxpoint.paths.welcome
¶
Module Contents¶
Classes¶
Class to configure the welcome image parameters |
|
Welcome Images Api endpoints documented in https://bluedocs.page/fluxpoint-api/welcome |
- exception fluxpoint.paths.welcome.InvalidFeature[source]¶
Bases:
Exception
The feature chosen is not valid
- class fluxpoint.paths.welcome.WelcomeConfig(username, avatar, background, members=None, icon=None, banner=None, color_welcome=None, color_username=None, color_members=None)[source]¶
Class to configure the welcome image parameters
- Parameters:
username (str) – Discord username
avatar (Union[URL, str]) – avatar url
background (str) – Backgroud color code
members (Optional[str], optional) – Members no tet, defaults to None
icon (Optional[str], optional) – Icon to use, defaults to None
banner (Optional[str], optional) – Banner to be put at background, defaults to None
color_welcome (Optional[str], optional) – Colour of the welcome text, defaults to None
color_username (Optional[str], optional) – Colour of the username text, defaults to None
color_members (Optional[str], optional) – Colour of the member text, defaults to None
Note
The
color
parameters are optional, if you don’t want to use a color, just passNone
Warning
The
banner
andicon
parameters evauation would be done whenWelcome.welcome()
is called.
- class fluxpoint.paths.welcome.Welcome(api_token)[source]¶
Bases:
fluxpoint.http.BaseHTTP
Welcome Images Api endpoints documented in https://bluedocs.page/fluxpoint-api/welcome
- Parameters:
api_token (str) –
- await welcome(self, config)[source]¶
Create a welcome image
- Raises:
InvalidFeature – When
banner
oricons
parameters inconfig
are invalid- Parameters:
config (WelcomeConfig) – A WelcomeConfig object
- Returns:
The image as a byte array
- Return type: