openai-agents-valta
Hard spending limits for OpenAI Agents SDK. Enforces budget policies before any paid operation fires.
Install
pip install openai-agents-valta
Quickstart
from openai_agents_valta import make_valta_tool
from agents import Agent, Runner
guard = make_valta_tool(
api_key="vk_live_...", # from valta.co/dashboard/api-keys
agent_id="research-agent",
)
agent = Agent(
name="Research Agent",
instructions=(
"Before any paid operation, call check_spend with the estimated cost. "
"Only proceed if the result is 'approved'."
),
tools=[guard, ...your_other_tools],
)
result = await Runner.run(agent, "Research the latest AI news")
How it works
The agent calls check_spend before any paid operation. Valta evaluates the request against the user's policy and returns approved or denied: <reason> before the charge fires.
| Response | Meaning |
|---|---|
approved |
Spend is within policy — proceed |
denied: daily_limit_exceeded |
Would exceed daily budget |
denied: insufficient_balance |
Wallet balance too low |
denied: requires human approval |
Above approval threshold — check dashboard |
Policy management
Set limits at valta.co/dashboard/policies. Changes take effect immediately — no redeploy needed.
Links
Metadata
Release files for openai-agents-valta 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| openai_agents_valta-0.1.0.tar.gz | 4.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| openai_agents_valta-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.0 kB
Release files / openai_agents_valta-0.1.0.tar.gz
| Download URL | openai_agents_valta-0.1.0.tar.gz |
|---|---|
| Size | 4.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
484640edd3643b608c85fb482b74d707fbe1c60482299b7a9fe0df42c80b4c8d
|
|
BLAKE2b-256 checksum How to use checksums |
4ed62811ab7f6b32bb571c58a5fcc03f02184dec763b5416b15495d50924bc9f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.5
|
Release files / openai_agents_valta-0.1.0-py3-none-any.whl
| Download URL | openai_agents_valta-0.1.0-py3-none-any.whl |
|---|---|
| Size | 4.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
778616d752fcad0061299b7cd8ac072b35a9030826cc53a1f2bb874c8caa629a
|
|
BLAKE2b-256 checksum How to use checksums |
4af49436218f645d3be02893488336fde51e09cd0de45960cc09cd1fab1b01c7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.5
|