Skip to content

p3ngu19z/outline-vpn-api

 
 

Repository files navigation

outline-vpn-api

A Python API wrapper for Outline VPN

Test

How to use

from outline_vpn.outline_vpn import OutlineVPN

# Setup the access with the API URL (Use the one provided to you after the server setup)
client = OutlineVPN(api_url="https://127.0.0.1:51083/xlUG4F5BBft4rSrIvDSWuw")

# Get all access URLs on the server
for key in client.get_keys():
    print(key.access_url)

# Create a new key
new_key = client.create_key()

# Rename it
client.rename_key(new_key.key_id, "new_key")

# Delete it
client.delete_key(new_key.key_id)

# Set a monthly data limit for a key (20MB)
client.add_data_limit(new_key.key_id, 1024 * 1024 * 20)

# Remove the data limit
client.delete_data_limit(new_key.key_id)

About

A Python API wrapper for Outline VPN https://getoutline.org/

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%