Volkswagen CarNet
raw JSON → 5.4.5 verified Mon Apr 27 auth: no python
Python library to communicate with Volkswagen Connect (WeConnect) API. Current version 5.4.5, requires Python >=3.11. Actively maintained, release cadence irregular but frequent bug fixes and features.
pip install volkswagencarnet Common errors
error ModuleNotFoundError: No module named 'volkswagencarnet' ↓
cause The library is not installed or installed in a different Python environment.
fix
Run
pip install volkswagencarnet in the correct environment (Python >=3.11). error volkswagencarnet.exceptions.LoginFailedException: Technical problem ↓
cause Incorrect credentials or region mismatch; sometimes the VW backend returns a generic error.
fix
Double-check username and password. Try specifying country code: Connection(email, password, country='DE'). Ensure account is registered for WeConnect.
error AttributeError: module 'volkswagencarnet' has no attribute 'Connection' ↓
cause Trying to import Connection from the module but it's not a direct attribute (old version or wrong import).
fix
Use
import volkswagencarnet and then volkswagencarnet.Connection(...). In older versions (<5.0) the class was named differently. Check installed version. Warnings
breaking Python >=3.11 required. This library will not install on older Python versions. ↓
fix Upgrade to Python 3.11 or later.
gotcha Login may fail due to region-locked accounts or captcha challenges. The library currently does not handle captcha. ↓
fix Ensure account region matches the API regional endpoint (use Connection(..., country='DE') etc.). If captcha appears, manual intervention is required.
deprecated The old `get_selectivestatus` with hardcoded service list is deprecated in favor of dynamic discovery based on active services. ↓
fix Update custom code to use Vehicle.update() which automatically fetches only discovered active services.
gotcha Auxiliary heating entities may be missing after update if the vehicle does not support them. This is not a bug but a vehicle-specific limitation. ↓
fix Check vehicle capability via `vehicle.capabilities` before relying on auxiliary heating entities.
Imports
- Connection wrong
from volkswagencarnet import Connectioncorrectimport volkswagencarnet - Vehicle wrong
from volkswagencarnet import Vehiclecorrectimport volkswagencarnet
Quickstart
import os
import volkswagencarnet
email = os.environ.get('VW_USERNAME', '')
password = os.environ.get('VW_PASSWORD', '')
conn = volkswagencarnet.Connection(email, password)
conn.doLogin()
vehicles = conn.vehicles
for vin, vehicle in vehicles.items():
print(f'VIN: {vin}, Model: {vehicle.model()}')