Automated authentication for web agents
Project description
AgentAuth
AgentAuth is a Python package that helps automate web authentication by simulating human-like login behavior. It supports various authentication methods including:
- Email magic links
- Email verification codes
- Time-based One-Time Passwords (TOTP)
- Standard username/password login
Features
- 🤖 Automated Authentication: Handles complex login flows automatically
- 📧 Email Integration: Supports email-based verification (magic links and codes)
- 🔐 Password Manager Integration: Works with 1Password and local credential storage
- 🌐 Browser Integration: Compatible with remote CDP-based browsers
Installation
pip install agentauth
Quick Start
from agentauth import AgentAuth, CredentialManager
# Initialize credential manager and load credentials
credential_manager = CredentialManager()
credential_manager.load_file("credentials.json") # Load from local JSON file
aa = AgentAuth(
credential_manager=credential_manager,
# Connect an email inbox for authentication requiring email links or codes
imap_server="imap.example.com",
imap_username="agent@example.com",
imap_password="agent_email_password"
)
# Authenticate to a website for a given username
cookies = await aa.auth(
"https://example.com",
"agent@example.com",
cdp_url="wss://..." # Optional: for using remote browser services
)
# Use cookies for authenticated agent actions
To Do
- Look at package managers
- Add license
- Add example: browser-use
- Add example: playwright
- Add example: browserbase (cdp)
- Publish to pip
- Add 1Password integration
- Expose CredentialManager (ideal doesn't need an extra init method)
- Hide verbose logging
- Add audit logging
- Add Bitwarden integration
- Use local LLM for email scanning
- Allow other LLMs
Contributing
Contributions are welcome! Please feel free to submit a pull request.
License
This project is licensed under the MIT License.
Project details
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 agentauth-0.2.0.tar.gz.
File metadata
- Download URL: agentauth-0.2.0.tar.gz
- Upload date:
- Size: 110.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.5.29
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e138b92a124fff24d621a91e82c9d4accc6bda4f3908fcae43853493cc2d94a3
|
|
| MD5 |
d4cc3b6e4ea1cab32a320565f57820e8
|
|
| BLAKE2b-256 |
f654b8ead1c632d167bc7cfcd0b34b0ee2ed5802885f9e9068ef0c140c6a4c20
|
File details
Details for the file agentauth-0.2.0-py3-none-any.whl.
File metadata
- Download URL: agentauth-0.2.0-py3-none-any.whl
- Upload date:
- Size: 8.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.5.29
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
85e714008227b5485c47e7e2ce512a6ab32a257f8c71c667467435ff02f69b31
|
|
| MD5 |
66e22fd0c3108bd493f9b0b69f325324
|
|
| BLAKE2b-256 |
e8e99e13c6a1c5ea9f9abfb936fde0eacc46325f079e0e5fe6ef8ff7cd5e5594
|