Astami¶
A modern, async-first Python client for the Asterisk Manager Interface (AMI).
Features¶
- Modern Python: Built for Python 3.10+ with full type hints
- Async & Sync: Both
AsyncAMIClientandAMIClient(sync wrapper) available - Context Managers: Automatic connection handling and cleanup
- No Dependencies: Pure Python, no external dependencies
- Fully Typed: Complete type annotations for IDE support
- Convenience Methods: High-level methods for common operations
Why Astami?¶
- Python 3.10+: Uses modern Python features like
matchstatements, union types with|, and proper async/await patterns - No Deprecated APIs: Doesn't use deprecated asyncio patterns that break in Python 3.10+
- Lightweight: No dependencies beyond the Python standard library
- Type Safe: Full type hints for better IDE support and fewer bugs
- Well Tested: Comprehensive test suite
Quick Example¶
from astami import AMIClient
with AMIClient("localhost", 5038, "admin", "secret") as ami:
response = ami.command("core show version")
print(response.output)
Credits¶
Developed by Real World Technology Solutions.