Python client for the Request Authorization gRPC service
Project description
request-auth-client
Python client for the Request Authorization gRPC permit service.
Installation
Install from the local package directory:
pip install ./client
Or from PyPI:
pip install dwilson-request-auth-client
Requires: Python 3.11+, grpcio>=1.80.0, protobuf>=6.31.1
Quick start
from request_auth_client import RequestAuthClient
client = RequestAuthClient("localhost:9000")
try:
with client.acquire("example.com") as permit:
# run request here
permit.set_status(200)
finally:
client.close()
Explicit release
permit = client.acquire("example.com")
try:
# run request here
permit.release(200)
except Exception:
permit.release(0)
Project details
Release history Release notifications | RSS feed
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 dwilson_request_auth_client-0.1.3.tar.gz.
File metadata
- Download URL: dwilson_request_auth_client-0.1.3.tar.gz
- Upload date:
- Size: 6.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f093a9812cb8cf9808c57ca025521d42b72ee5dad76c33436869eee6e55df6f4
|
|
| MD5 |
518d6ccab664fab43193640bd27578d3
|
|
| BLAKE2b-256 |
9e54c920623908311fb6b6045c99537a1d5165aab48eb95871272cbb0d5928cf
|
File details
Details for the file dwilson_request_auth_client-0.1.3-py3-none-any.whl.
File metadata
- Download URL: dwilson_request_auth_client-0.1.3-py3-none-any.whl
- Upload date:
- Size: 6.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f03f0a3bd067b88af1803ee572ab66453adde22ca92816c1c401360ae705cf0f
|
|
| MD5 |
fe0a634e063effdb2fe63de647e263f9
|
|
| BLAKE2b-256 |
fcbb9a7ccf1a3b97d0314cda26c49709d13a80df0982a8b706816eceeaf778ef
|