python-webfinger
raw JSON → 1.0 verified Fri May 01 auth: no python
Simple Python implementation of the WebFinger client protocol (RFC 7033). Version 1.0 is the current stable release. No update since 2012.
pip install webfinger Common errors
error ModuleNotFoundError: No module named 'webfinger' ↓
cause The package is not installed.
fix
Run 'pip install webfinger'.
error TypeError: webfinger() got an unexpected keyword argument 'ssl_verify' ↓
cause The library does not support custom SSL verification. Pass host directly without ssl_verify parameter.
fix
Use webfinger.webfinger(resource, host='example.com') instead of ssl_verify.
Warnings
gotcha The module name and the only public function are both 'webfinger' — import webfinger then call webfinger.webfinger(). ↓
fix Use 'import webfinger' and 'webfinger.webfinger()'.
deprecated The library uses the legacy XRD/XML format in addition to JSON. Some modern servers may return only JSON. ↓
fix Ensure your server supports both or handle JSON-only responses manually.
Imports
- webfinger wrong
from webfinger import webfingercorrectimport webfinger
Quickstart
import webfinger
resource = 'acct:user@example.com'
result = webfinger.webfinger(resource)
print(result)