Claude Code is Anthropic’s CLI for coding agents. Authsome integrates with Claude Code through theDocumentation Index
Fetch the complete documentation index at: https://authsome.agentr.dev/docs/llms.txt
Use this file to discover all available pages before exploring further.
/anthropic-skills:authsome skill. Once installed, Claude can log in to any provider, list connected services, and run agents that pull fresh credentials from the local vault.
Set up authsome in Claude Code. Paste this prompt to install the skill and authenticate a first provider.
What the integration gives you
- One login per service. OAuth2 and API-key flows run from inside Claude Code. The skill drives the same
uvx authsome logincommands a human would type. - No credentials in prompts or files. Claude never sees raw tokens. The skill calls authsome, which collects secrets through a local browser bridge or the masked terminal fallback.
- Automatic refresh. Tokens stay fresh for every agent run Claude triggers. You do not re-authenticate when an access token expires.
- The same vault. Connections you create through the skill are stored in
~/.authsome/, identical to connections created from the regular CLI. Nothing is duplicated.
Install the skill
The authsome repository ships a Claude Code skill atskills/authsome/SKILL.md. Install it into your local Claude Code skills directory:
uvx authsome commands. The skill teaches Claude the list → login → run flow plus authsome’s safety rules (no client_secret in shell history, no --scopes workaround for missing access, etc.).
First run
A typical first session looks like this:Ask Claude what's already configured
uvx authsome list and reports which providers are bundled, configured, and connected.Log in to a provider
http://127.0.0.1:7998/auth/callback/oauth, and authsome stores the encrypted record.Common prompts
Concrete requests Claude understands. Each one maps to a specific authsome command.| Prompt | What Claude runs |
|---|---|
| ”Log me in to GitHub via authsome.” | uvx authsome login github |
| ”Use the Resend API key from authsome to send an email.” | uvx authsome run -- python <script> |
| ”Switch the active GitHub connection to my work account.” | uvx authsome login github --connection work |
| ”Show me which providers are connected.” | uvx authsome list |
| ”Revoke my OpenAI key.” | uvx authsome revoke openai |
| ”Add a custom provider for Acme CRM.” | uvx authsome register ./acmecrm.json |
Why this is the safe pattern
Without authsome, agents inside Claude Code typically read tokens from environment variables,.env files, or shell history. Each of those surfaces leaks easily:
| Pattern | Token visible in |
|---|---|
export GITHUB_TOKEN=... | ps, /proc/<pid>/environ, shell history, subprocess env |
.env file in the repo | The repo, backups, git history if committed by accident |
| Manual paste into Claude | Claude’s transcript |
uvx authsome run -- ... | None of the above |
authsome run is the recommended pattern for any Claude Code agent that calls third-party APIs. The child process never sees the real secret because the proxy injects headers at request time.
Embedding the library
If you’re orchestrating Claude Code from a larger Python program and want to inject credentials before launching Claude, you can drop below the skill into the library:Multi-account workflows
Most real workflows need at least two accounts (personal and work GitHub, or a personal and team OpenAI key). The skill plays well with named connections:What the skill cannot do
- It cannot type a
client_secretfor you. Authsome refuses sensitive values as command-line arguments. The browser bridge is the only path. - It cannot bypass the proxy CA requirement. HTTPS interception needs the mitmproxy CA trusted on the machine. The first
authsome runwrites the CA to~/.mitmproxy/. See Proxy networking. - It cannot share the vault across machines. Claude Code on a second machine has its own
~/.authsome/. Re-run logins there, or use a hosted daemon (see Hosted deployment model).
Troubleshooting
If a Claude-driven login hangs:- Run
uvx authsome doctordirectly from the terminal to surface initialization errors. - Run
uvx authsome --verbose login <provider>to see the full flow including the daemon round-trips. - Check
~/.authsome/audit.logfor the most recent action and outcome.
What’s next
Run agents with the proxy
The proxy injection model the skill uses under the hood.
Python library
Drop below the skill into
AuthService for fine-grained control.All bundled providers
Every service Claude can log you into out of the box.
Custom providers
Add a provider authsome doesn’t ship.