agentgate Python SDK
Install and get human approval before your AI agent takes a risky action.
Install
pip install useagentgate
Quick Start
from agentgate import AgentGate
gate = AgentGate(
api_key="ag_test_xxx",
default_channel="#agent-approvals"
)
result = await gate.request_approval(
action="send_email",
description="Send pricing proposal to client@acme.com",
context={"deal_value": "$50,000", "recipient": "john@acme.com"},
risk_tier="high",
timeout_minutes=30,
)
if result.approved:
print(f"Approved by {result.approved_by}")
elif result.rejected:
print(f"Rejected: {result.reason}")
elif result.timed_out:
print("No response")
Sync Usage
from agentgate import AgentGateSync
gate = AgentGateSync(api_key="ag_test_xxx")
result = gate.request_approval(action="send_email", description="...")
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
useagentgate-1.0.0.tar.gz
(5.0 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 useagentgate-1.0.0.tar.gz.
File metadata
- Download URL: useagentgate-1.0.0.tar.gz
- Upload date:
- Size: 5.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a369e21d0e233e47a20741aeb283c5044b5e28277eea87e04a09b4ccf96ddbec
|
|
| MD5 |
2e0494befc94bf087de6670c88bf1047
|
|
| BLAKE2b-256 |
297f022228a9b5a854b1e8f7b72b2b77c55cf00b33a67a824779bee35b9df9a0
|
File details
Details for the file useagentgate-1.0.0-py3-none-any.whl.
File metadata
- Download URL: useagentgate-1.0.0-py3-none-any.whl
- Upload date:
- Size: 6.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5b7392fce612a929676487121fd3bca54897dada769c025133a80e339684ee83
|
|
| MD5 |
fe8760dc7897af19ac35300c681719df
|
|
| BLAKE2b-256 |
bd45de11290f6a1daf5df6ff979cc8195b4227da4a80c01e1d259d0a32db633f
|