Skip to main content

Python module for Libravatar

Project description

pyLibravatar

PyLibravatar is an easy way to make use of the federated Libravatar avatar hosting service from within your Python applications.

See the project page for the bug tracker and downloads.

Installation

To install using pip, simply do this:

$ pip install pylibravatar

Usage

To generate the correct avatar URL based on someone's email address, use the following:

>>> from libravatar import libravatar_url
>>> url = libravatar_url(email='person@example.com')
>>> print(f'<img src="{url}">')

Here are other options you can provide:

>>> url = libravatar_url(openid = 'http://example.org/id/Bob', https = True, size = 96, default = 'mm')

See the Libravatar documentation for more information on the special values for the "default" parameter.

License

Copyright (C) 2011, 2013, 2015 Francois Marier francois@libravatar.org

Copyright (C) 2016-2026 Oliver Falk oliver@linux-kernel.at

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

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

pylibravatar-2.0.0.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pylibravatar-2.0.0-py3-none-any.whl (5.7 kB view details)

Uploaded Python 3

File details

Details for the file pylibravatar-2.0.0.tar.gz.

File metadata

  • Download URL: pylibravatar-2.0.0.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for pylibravatar-2.0.0.tar.gz
Algorithm Hash digest
SHA256 fb83efa88e71cbf9c4c023cea19e397dd60c369701405712a26620c4097ffeb4
MD5 33349bc7656065efd496627667d75733
BLAKE2b-256 5f977588e9352b6bf1ab7bee526799054d25910e7ea4392a22dc1883db21edaa

See more details on using hashes here.

File details

Details for the file pylibravatar-2.0.0-py3-none-any.whl.

File metadata

  • Download URL: pylibravatar-2.0.0-py3-none-any.whl
  • Upload date:
  • Size: 5.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for pylibravatar-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2291e4b45c39b2c5f23c468ebf2e59e49af6eaef18e3379336f868774ec8036f
MD5 dfda4aa86dd7958502b44853ffc51d21
BLAKE2b-256 e0c11be0459b82aee83d7c796a79571a1957456d8a3050172cd0f86a175336b8

See more details on using hashes here.

Supported by

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