This release is a pre-release and may not be stable for production use.
agentself
Persistent local identity for an agent.
Give your agent the ability to hold funds, store credentials, and send email. Configure different providers and the commands stay the same.
Run init once and every later process reuses the same identity.
Beta / pre-1.0. Linux, macOS, and Windows. Python 3.11+.
Install
uv tool install agentself
Or with pipx:
pipx install agentself
Quick start
agentself install --tools
agentself init
# Wallet
agentself wallet address
agentself wallet balance
# Secrets
agentself secret create API_TOKEN
agentself secret get API_TOKEN
# Email
agentself secret create email.send.token YOUR_TOKEN
agentself email connect
agentself email show
Run agentself show anytime to see the current identity.
agentself install --tools installs the required age and sops host tools. Email is optional; the default AgentMail backend needs email.send.token before email connect.
Why agentself?
- Give an agent a persistent wallet, secrets, and email identity.
- Use the same commands even when the underlying provider changes.
- Built for unattended use with encrypted secrets, structured output, and safe failures.
Commands
| Area | Commands |
|---|---|
| Identity | init, show, diagnose |
| Secrets | secret create, get, update, list, delete |
| Wallet | wallet show, address, balance, authorize, send |
email connect, show, send, receive, list |
|
| Backends | backends [CHANNEL] |
| Recovery | backup, restore |
| Setup | install --tools, install --skills |
Discover exact arguments and flags from the CLI:
agentself --help
agentself wallet --help
agentself wallet send --help
agentself email --help
Backends & configuration
See the available implementations and what each supports:
agentself backends
agentself backends wallet
agentself backends email
agentself backends store
| Capability | Default | Alternatives |
|---|---|---|
| Wallet | base |
ethereum |
agentmail |
imap |
|
| Secrets | sops |
pass |
Choose backends when initializing:
agentself init --wallet ethereum --email imap --store pass
Wallet and email can also be selected with environment variables:
export AGENTSELF_WALLET_BACKEND=ethereum
export AGENTSELF_EMAIL_BACKEND=imap
agentself init
Configuration precedence is:
CLI flag > environment variable > saved configuration > default
There is no automatic backend failover. agentself backends is the authoritative source for backend-specific requirements and configuration knobs.
One identity lives in one directory, ~/.agentself by default. Use AGENTSELF_VAULT_ROOT to isolate identities:
AGENTSELF_VAULT_ROOT=~/.agent-a agentself init
AGENTSELF_VAULT_ROOT=~/.agent-b agentself init
Automation and agents
The CLI is designed to be discovered directly from the shell. An agent does not need an MCP server or skill to use it.
agentself --help
agentself <command> --help
agentself backends
agentself diagnose
For automation, prefer --json.
Success is one JSON object on stdout with "ok": true. Failure is one JSON object on stderr with ok, error, reason, and next.
{
"ok": false,
"error": "...",
"reason": "...",
"next": "..."
}
Exit codes are 0 success, 1 error, 2 refused, and 3 missing dependency or resource.
Consumers should ignore unknown JSON keys. agentself --json --version includes cli, the machine schema identifier.
An optional bundled skill gives compatible coding agents the same discovery guidance:
agentself install --skills
agentself install --skills -g
agentself install --skills=agents
--help and --json are sufficient without the skill.
Security
- Secret values are encrypted at rest by the configured store.
secret listreturns names, not values.- Logs and structured errors do not print secret values.
- Missing backends, credentials, or tools fail instead of silently switching implementations.
- Wallet backends are live and
wallet sendcan move real assets. - Identity files are replaced atomically, and wallet-send retries do not construct a second payment.
Back up the identity with agentself backup PATH. Report vulnerabilities through SECURITY.md.
Extending agentself
To add a backend, implement the existing channel contract rather than adding vendor-specific CLI verbs. See CONTRIBUTING.md.
Development
git clone https://github.com/agentself/agentself
cd agentself
uv sync
uv run pytest
uv run agentself --help
uv run agentself init
License
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 agentself-0.1.0a1.tar.gz.
File metadata
- Download URL: agentself-0.1.0a1.tar.gz
- Upload date:
- Size: 103.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ea34d182c1418c2cdca786eeb2c2193b83ab476bf535c098f11c4f82f1f243a9
|
|
| MD5 |
7f0447f6d7ddd9af5f3b457b9127f674
|
|
| BLAKE2b-256 |
5b1bc2e11a4fbc5b4169155e34e375793cd405f82ac5261b9d5afd99c597cb86
|
Provenance
The following attestation bundles were made for agentself-0.1.0a1.tar.gz:
Publisher:
publish.yml on agentself/agentself
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
agentself-0.1.0a1.tar.gz -
Subject digest:
ea34d182c1418c2cdca786eeb2c2193b83ab476bf535c098f11c4f82f1f243a9 - Sigstore transparency entry: 2559687126
- Sigstore integration time:
-
Permalink:
agentself/agentself@31e6c78b8e7611b78ca4db44e9215f5b330ad556 -
Branch / Tag:
refs/tags/v0.1.0a1 - Owner: https://github.com/agentself
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@31e6c78b8e7611b78ca4db44e9215f5b330ad556 -
Trigger Event:
push
-
Statement type:
File details
Details for the file agentself-0.1.0a1-py3-none-any.whl.
File metadata
- Download URL: agentself-0.1.0a1-py3-none-any.whl
- Upload date:
- Size: 66.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8f41ef41b3088fcd9cc6652db69c279df2610d0d13fdebc7ae4a47ef74293d3f
|
|
| MD5 |
e75a830fdf67effe37a5c184bd5ac183
|
|
| BLAKE2b-256 |
02aa7bb92936acd6bb0d65bac67833edc32c72896d37b5f9efa3d016b03efc47
|
Provenance
The following attestation bundles were made for agentself-0.1.0a1-py3-none-any.whl:
Publisher:
publish.yml on agentself/agentself
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
agentself-0.1.0a1-py3-none-any.whl -
Subject digest:
8f41ef41b3088fcd9cc6652db69c279df2610d0d13fdebc7ae4a47ef74293d3f - Sigstore transparency entry: 2559687158
- Sigstore integration time:
-
Permalink:
agentself/agentself@31e6c78b8e7611b78ca4db44e9215f5b330ad556 -
Branch / Tag:
refs/tags/v0.1.0a1 - Owner: https://github.com/agentself
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@31e6c78b8e7611b78ca4db44e9215f5b330ad556 -
Trigger Event:
push
-
Statement type: