Skip to main content

Generation of properly-formatted dynamic timestamps for Discord messages

Project description

discord-timestamps

discord-timestamps generates properly-formatted dynamic timestamps for Discord messages, with support for Arrow objects.

>>> format_timestamp(datetime(2021, 11, 20, 12, 0, 0))
'<t:1637409600>'

>>> format_timestamp(datetime(...), TimestampType.RELATIVE)
'<t:1637409600:R>'

Downloads Supported Versions Testing License Version

Installation

discord-timestamps is available on PyPI:

$ pip install discord-timestamps

discord-timestamps officially supports Python 3.6+.

API Reference

See the wiki for discord-timestamps's documentation.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

discord_timestamps-1.0.2.tar.gz (5.2 kB view hashes)

Uploaded Source

Built Distribution

discord_timestamps-1.0.2-py3-none-any.whl (3.4 kB view hashes)

Uploaded Python 3

Supported by

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