TrigGuard Gateway Client
Project description
trigguard (PyPI)
Official Python 3.9+ client for the TrigGuard execution gateway — POST /execute using only the standard library (urllib).
Install (from PyPI)
pip install trigguard
Editable (monorepo)
cd sdk/python && pip install -e .
Usage
import os
from trigguard import Client
client = Client(
api_key=os.environ["TG_API_KEY"],
base_url="http://127.0.0.1:8080",
)
r = client.execute(
surface="spendCommit",
signals={"riskScore": 0.9},
context={"amount": 1000},
)
print(r["decision"], r.get("execution_id"))
- Auth:
Authorization: Bearer <api_key> - Errors:
TrigGuardErroron non-2xx
Build & publish (maintainers)
Run from the repository root (not from sdk/node — scripts/ is at the root).
cd /path/to/TrigGuard
python3 -m pip install build twine
bash scripts/publish-pypi.sh
On macOS, if pip is not found, use python3 -m pip as above. Configure twine (~/.pypirc or env) before upload.
See also
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 trigguard-0.1.0.tar.gz.
File metadata
- Download URL: trigguard-0.1.0.tar.gz
- Upload date:
- Size: 4.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f0ad59f82afe661a01d699a91fdbc8832c666f8d7c1c6b59e1ad50ce7fad0c45
|
|
| MD5 |
db06ffbe780232db2724bfc072ab228a
|
|
| BLAKE2b-256 |
be61485490bf4f39bcda6e70af0d4110889cf775d34208863014252f6d014aec
|
File details
Details for the file trigguard-0.1.0-py3-none-any.whl.
File metadata
- Download URL: trigguard-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
302e18cc49b097242f5aefba8815adf6bba2b5f012186b84302524c04f440eb3
|
|
| MD5 |
494e93461ad8ebca07c12a68fb1e09a2
|
|
| BLAKE2b-256 |
88bf0883b228fd5a8e3f0cdf49d1bdef72d55b1f99d4069245dda88e89ae0ba4
|