Browse Source

Mention what can be done during initialisation in embeds.

pull/2139/head
Rapptz 6 years ago
parent
commit
792b31833a
  1. 9
      discord/embeds.py

9
discord/embeds.py

@ -64,9 +64,6 @@ class Embed:
Returns the total size of the embed. Returns the total size of the embed.
Useful for checking if it's within the 6000 character limit. Useful for checking if it's within the 6000 character limit.
The following attributes can be set during creation
of the object:
Certain properties return an ``EmbedProxy``. Which is a type Certain properties return an ``EmbedProxy``. Which is a type
that acts similar to a regular :class:`dict` except access the attributes that acts similar to a regular :class:`dict` except access the attributes
via dotted access, e.g. ``embed.author.icon_url``. If the attribute via dotted access, e.g. ``embed.author.icon_url``. If the attribute
@ -80,16 +77,22 @@ class Embed:
----------- -----------
title: :class:`str` title: :class:`str`
The title of the embed. The title of the embed.
This can be set during initialisation.
type: :class:`str` type: :class:`str`
The type of embed. Usually "rich". The type of embed. Usually "rich".
This can be set during initialisation.
description: :class:`str` description: :class:`str`
The description of the embed. The description of the embed.
This can be set during initialisation.
url: :class:`str` url: :class:`str`
The URL of the embed. The URL of the embed.
This can be set during initialisation.
timestamp: `datetime.datetime` timestamp: `datetime.datetime`
The timestamp of the embed content. This could be a naive or aware datetime. The timestamp of the embed content. This could be a naive or aware datetime.
This can be set during initialisation.
colour: :class:`Colour` or :class:`int` colour: :class:`Colour` or :class:`int`
The colour code of the embed. Aliased to ``color`` as well. The colour code of the embed. Aliased to ``color`` as well.
This can be set during initialisation.
Empty Empty
A special sentinel value used by ``EmbedProxy`` and this class A special sentinel value used by ``EmbedProxy`` and this class
to denote that the value or attribute is empty. to denote that the value or attribute is empty.

Loading…
Cancel
Save