Skip to main content

PyOutlineAPI

Enterprise-grade async Python client for Outline VPN Server Management API

tests codecov Security Rating Maintainability Rating Vulnerabilities

PyPI - Downloads PyPI - Version Python Version License


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:


License

MIT. See LICENSE.

Release files for pyoutlineapi 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyoutlineapi 0.4.0
File Size Uploaded
pyoutlineapi-0.4.0.tar.gz 102.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyoutlineapi 0.4.0
File Interpreter ABI Platform
pyoutlineapi-0.4.0-py3-none-any.whl Python 3 none any Details

Total release size: 183.5 kB

Release files / pyoutlineapi-0.4.0.tar.gz

Download URL pyoutlineapi-0.4.0.tar.gz
Size 102.5 kB
Tags Source
SHA-256 checksum
How to use checksums
fcd5dea7e4952277a6e8b3f6710fdb1d1cde9f06635ed1fb91bf06992545ee11
BLAKE2b-256 checksum
How to use checksums
de47a3464b5f4215fc2bdecedeed8519673d348031dc7000200c6e9388927093
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.11

Release files / pyoutlineapi-0.4.0-py3-none-any.whl

Download URL pyoutlineapi-0.4.0-py3-none-any.whl
Size 81.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
70bd406558957dcb5997aada587a0e217c7b9a4b9ffe73b3948fadd7635fd994
BLAKE2b-256 checksum
How to use checksums
2982f4f4926f42dd38e01deb7114107c06c05af78878023ecae05311dd4887ba
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.11

Release history Release notifications | RSS feed

This release

0.4.0 This release

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release 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