Skip to main content
Pre-release

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 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
Email 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 list returns 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 send can 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

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

agentself-0.1.0a1.tar.gz (103.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

agentself-0.1.0a1-py3-none-any.whl (66.7 kB view details)

Uploaded Python 3

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

Hashes for agentself-0.1.0a1.tar.gz
Algorithm Hash digest
SHA256 ea34d182c1418c2cdca786eeb2c2193b83ab476bf535c098f11c4f82f1f243a9
MD5 7f0447f6d7ddd9af5f3b457b9127f674
BLAKE2b-256 5b1bc2e11a4fbc5b4169155e34e375793cd405f82ac5261b9d5afd99c597cb86

See more details on using hashes here.

Provenance

The following attestation bundles were made for agentself-0.1.0a1.tar.gz:

Publisher: publish.yml on agentself/agentself

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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

Hashes for agentself-0.1.0a1-py3-none-any.whl
Algorithm Hash digest
SHA256 8f41ef41b3088fcd9cc6652db69c279df2610d0d13fdebc7ae4a47ef74293d3f
MD5 e75a830fdf67effe37a5c184bd5ac183
BLAKE2b-256 02aa7bb92936acd6bb0d65bac67833edc32c72896d37b5f9efa3d016b03efc47

See more details on using hashes here.

Provenance

The following attestation bundles were made for agentself-0.1.0a1-py3-none-any.whl:

Publisher: publish.yml on agentself/agentself

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.2.4

2 files

0.2.3

2 files

0.2.2

2 files

0.2.1

2 files

0.2.0

2 files

0.1.0

2 files

This release

0.1.0a1 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page