Zero-trust credential manager for AI agents — Python SDK
Project description
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"]
}
}
}
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 agent_vault_sdk-0.1.0.tar.gz.
File metadata
- Download URL: agent_vault_sdk-0.1.0.tar.gz
- Upload date:
- Size: 11.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d7c88dc16f61ae4614394ef287fa09222bec30ed6ee999b6bf5451e4b51ea214
|
|
| MD5 |
937f14e08f40f03d5cdbc3a867d05608
|
|
| BLAKE2b-256 |
7012e454a7d485abcc6bb245d774d8ef4e82eb94662757e996e32dbcaddc1a37
|
File details
Details for the file agent_vault_sdk-0.1.0-py3-none-any.whl.
File metadata
- Download URL: agent_vault_sdk-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6482580f9d38e564814cea7fe9cf8d4cd5a0bc62f3824212b3bb7b9ca2933b6f
|
|
| MD5 |
5b0f97b2351e4a95936456b1c2bedb00
|
|
| BLAKE2b-256 |
ed2e5afd3c1a4a36d5557c39a67189f04c55a4f7cc02f43b8af83753e5738fe0
|