A simple package for integrating Steam OpenID authentication in applications.
Project description
steam-openid
steam-openid provides a straightforward implementation for integrating Steam OpenID authentication into applications.
Requirements
- Python 3.6 or higher
- python3-openid
You can install the required dependencies with:
pip install -r requirements.txt
Example usage
from steam_openid import SteamOpenID
steam = SteamOpenID(
realm="http://localhost:8080/steam/login",
return_to="http://localhost:8080/steam/callback"
)
@app.route("/steam/login")
def login():
redirect_url = steam.get_redirect_url()
return redirect(redirect_url)
@app.route("/steam/callback")
def callback(request):
steam_id = steam.validate_results(request.query_params)
if steam_id:
return 200, f"Your steam id is: {steam_id}"
else:
return 403, "Failed to authenticate"
Contributions
Pull requests are welcome! If you find a bug or have a feature request, please open an issue or submit a pull request.
License
This project is licensed under the MIT License.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file steam_openid-1.0.5.tar.gz.
File metadata
- Download URL: steam_openid-1.0.5.tar.gz
- Upload date:
- Size: 3.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ba88d53d35d53cc7f3d1aef78dbaaa2dae02bbf7bf4fb1f44f770b20c09cbd6c
|
|
| MD5 |
777825b4893e4f1c915d1b18d8006b8a
|
|
| BLAKE2b-256 |
5587edaa0477e77bb0b39eb61610f9b1ee18e91a6058c434e6b4ba8a26fbb6af
|
File details
Details for the file steam_openid-1.0.5-py3-none-any.whl.
File metadata
- Download URL: steam_openid-1.0.5-py3-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9448d728cecbe84496b8f05be9748996110cfb135416f9c7c7a0de8515ab8249
|
|
| MD5 |
44fb9118b64ab76d7ee8574768f07514
|
|
| BLAKE2b-256 |
3ac0dcc13a5d38905440f5be9688e2e16113d2b92cf65c31bbb11f66270df226
|