Production-ready async Python client for Outline VPN Server API with enterprise-grade features and full type safety.
Project description
PyOutlineAPI
Enterprise-grade async Python client for Outline VPN Server Management API
Overview
PyOutlineAPI is a modern, production-ready Python library for managing Outline VPN servers. It is async-first, type-safe, and designed for reliable operation in production.
Highlights:
- Async-first client built on aiohttp
- Certificate pinning + sensitive data protection
- Circuit breaker, health monitoring, retries with backoff
- Typed models (Pydantic v2) + rich validation
- Batch operations and rate limiting
Installation
Requirements: Python 3.10+
Using pip:
pip install pyoutlineapi
Using uv (recommended):
uv add pyoutlineapi
Optional dependencies:
# Development tools
pip install pyoutlineapi[dev]
Quick Start
1) Setup configuration
# Generate .env template
python -c "from pyoutlineapi import quick_setup; quick_setup()"
# Edit .env.example → .env
OUTLINE_API_URL=https://your-server.com:12345/your-secret-path
OUTLINE_CERT_SHA256=your-64-character-sha256-fingerprint
2) Minimal usage
from pyoutlineapi import AsyncOutlineClient
import asyncio
async def main():
async with AsyncOutlineClient.from_env() as client:
server = await client.get_server_info()
print(f"Server: {server.name} (v{server.version})")
key = await client.create_access_key(name="Alice")
print(f"Access URL: {key.access_url}")
keys = await client.get_access_keys()
print(f"Total keys: {keys.count}")
asyncio.run(main())
Documentation
Detailed examples and guides are in docs/guides/. Start with the index:
- Guides index (full list)
- Access keys
- Server management
- Metrics
- Enterprise features
- Configuration
- Error handling
- Best practices
License
MIT. See 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 pyoutlineapi-0.4.0.tar.gz.
File metadata
- Download URL: pyoutlineapi-0.4.0.tar.gz
- Upload date:
- Size: 102.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fcd5dea7e4952277a6e8b3f6710fdb1d1cde9f06635ed1fb91bf06992545ee11
|
|
| MD5 |
d329f83c6c6ba6ec5b20dfccd689c4ec
|
|
| BLAKE2b-256 |
de47a3464b5f4215fc2bdecedeed8519673d348031dc7000200c6e9388927093
|
File details
Details for the file pyoutlineapi-0.4.0-py3-none-any.whl.
File metadata
- Download URL: pyoutlineapi-0.4.0-py3-none-any.whl
- Upload date:
- Size: 81.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
70bd406558957dcb5997aada587a0e217c7b9a4b9ffe73b3948fadd7635fd994
|
|
| MD5 |
1155e4beae37813863397d99ffa8a68d
|
|
| BLAKE2b-256 |
2982f4f4926f42dd38e01deb7114107c06c05af78878023ecae05311dd4887ba
|