Skip to main content

Pull from Mullvad API asynchronously

Project description

Mullvad Async API Library

This is a very simple library to pull down information from Mullvad's unofficial API using your account number. This information includes:

  • Account status
  • Number of clients
  • Client information
  • If currently connected to Mullvad VPN

An example of simple usage is

from mullvad_async import Mullvad
import asyncio

    async def main():
        async with aiohttp.ClientSession() as session:
            mullvad = Mullvad(session, "my_account")

            connected = await mullvad.is_connected()
            
            account = await mullvad.account_status()
            print(account["account"]["active"])

    asyncio.run(main())

To install run

pip install mullvad-async

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

mullvad-async-0.1.0.tar.gz (3.4 kB view hashes)

Uploaded Source

Built Distribution

mullvad_async-0.1.0-py3-none-any.whl (4.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page