No project description provided
Project description
Auth Web Kit
Библиотека для аутентификации в NiceGUI приложениях.
Установка
pip install auth-web-kit
Быстрый старт
from openapi_client import some as some_client
from openapi_client import another as another_client
from settings import settings
auth = shared.Auth(
redis=redis_client,
redirect_from=settings.app.SELF_REDIRECT_URL,
auth_web_client_url=settings.auth_client.WEB_URL,
unauthorized_exception_classes=[
some_client.exceptions.UnauthorizedException,
another_client.exceptions.UnauthorizedException,
],
forbidden_exception_classes=[
some_client.exceptions.ForbiddenException,
another_client.exceptions.ForbiddenException,
],
)
error = shared.Error()
# порядок подключения важен
app.add_middleware(auth.middleware)
app.add_middleware(error.middleware)
app.on_exception(auth.on.unknown_error)
app.on_exception(auth.on.unauthorized)
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
auth_web_kit-1.2.2.tar.gz
(5.1 kB
view details)
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 auth_web_kit-1.2.2.tar.gz.
File metadata
- Download URL: auth_web_kit-1.2.2.tar.gz
- Upload date:
- Size: 5.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.2.1 CPython/3.10.12 Linux/6.8.0-106-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8f80813d7090f4f4be1261a18589e09e0d7e55ca4c7df61ee3b14a8f76697642
|
|
| MD5 |
93d829ca55d3015e08a1a456dcfbaa65
|
|
| BLAKE2b-256 |
f3a6645ea312d3f304077e7485d07295f87b6a577ce72422fcc052aeaa02347b
|
File details
Details for the file auth_web_kit-1.2.2-py3-none-any.whl.
File metadata
- Download URL: auth_web_kit-1.2.2-py3-none-any.whl
- Upload date:
- Size: 8.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.2.1 CPython/3.10.12 Linux/6.8.0-106-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
263a6f11e51d48d71fe4e38067cf00668ea2b6daed49457a79a15a8814066370
|
|
| MD5 |
a09e8ab97a81dba9d1a0280ef994da27
|
|
| BLAKE2b-256 |
8511d8a4144703b79c5ea02226f2751261e9db81617ab86042c28823d2d5df48
|