agent-vault Python SDK
Read-only Python SDK for agent-vault — a zero-trust credential manager for AI agents.
Installation
pip install agent-vault
# With MCP server support:
pip install 'agent-vault[mcp]'
Quick Start
from agent_vault import Vault
vault = Vault(
repo_path="/path/to/vault",
key_path="~/.agent-vault/agents/my-agent.key",
)
# Pull latest and decrypt
api_key = vault.get("stripe/api-key")
Key Resolution
The SDK resolves the identity key in this order:
key_str=parameter (raw key string)key_path=parameter (path to key file)AGENT_VAULT_KEYenvironment variable (key as string)~/.agent-vault/owner.key(default owner key)
API
Vault(repo_path, key_path=None, key_str=None, auto_pull=True)
Create a read-only vault connection.
repo_path: Path to the Git repo containing.agent-vault/key_path: Path to an age private key filekey_str: Raw age private key stringauto_pull: Git pull before eachget()(default: True)
vault.get(secret_path) -> str
Decrypt and return a secret. Raises SecretNotFoundError or NotAuthorizedError.
vault.list_secrets(group=None) -> list[SecretMetadata]
List secret metadata without decrypting.
vault.list_agents() -> list[dict]
List agents and their group memberships.
vault.pull()
Manually pull latest changes from Git remote.
vault.reload()
Reload the manifest from disk (e.g., after a pull).
MCP Server
The package includes an MCP server for use with MCP-compatible AI agents:
agent-vault-mcp --repo /path/to/vault --key ~/.agent-vault/agents/my-agent.key
This runs a stdio-based MCP server exposing:
agent_vault_get(secret)— retrieve and decrypt a secretagent_vault_list(group?)— list available secrets
Claude Desktop Configuration
{
"mcpServers": {
"agent-vault": {
"command": "agent-vault-mcp",
"args": ["--repo", "/path/to/vault", "--key", "/path/to/agent.key"]
}
}
}
Release files for agent-vault-sdk 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 | |
|---|---|---|---|
| agent_vault_sdk-0.1.0.tar.gz | 11.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| agent_vault_sdk-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 21.0 kB
Release files / agent_vault_sdk-0.1.0.tar.gz
| Download URL | agent_vault_sdk-0.1.0.tar.gz |
|---|---|
| Size | 11.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d7c88dc16f61ae4614394ef287fa09222bec30ed6ee999b6bf5451e4b51ea214
|
|
BLAKE2b-256 checksum How to use checksums |
7012e454a7d485abcc6bb245d774d8ef4e82eb94662757e996e32dbcaddc1a37
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.9
|
Release files / agent_vault_sdk-0.1.0-py3-none-any.whl
| Download URL | agent_vault_sdk-0.1.0-py3-none-any.whl |
|---|---|
| Size | 9.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6482580f9d38e564814cea7fe9cf8d4cd5a0bc62f3824212b3bb7b9ca2933b6f
|
|
BLAKE2b-256 checksum How to use checksums |
ed2e5afd3c1a4a36d5557c39a67189f04c55a4f7cc02f43b8af83753e5738fe0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.9
|