JavaScript implementation of the BMW's ConnectedDrive API
Example: BMWStatus
import API from '@mihaiblaga89/bmw-connecteddrive-api';
await API.init({
region: 'eu',
username: '[email protected]',
password: 'mySuperPassword',
});
const vehicles = await API.getVehicles();
const vehicleStatus = await vehicles[0].getStatus();
Initializes the API with your credentials. By default it also fetches your vehicles and saves them but you can disable this behaviour if you want. More info
Returns your prefetched vehicles or queries the BMW API for them. Has the option to force the query to refresh your vehicles. Every vehicle is an instance of Vehicle. More info
Fetches and caches your vehicle image from BMW API. Of course it's not the actual photo, it's just a car photo based on your car's model and color :). Several "views" are available. More info
Fetches and caches the car's status from the API. Can be forced. Returns an instance of VehicleStatus. More info
This work was inspired by the following repos:
- https://github.com/bimmerconnected/bimmer_connected
- https://github.com/edent/BMW-i-Remote
- https://shkspr.mobi/blog/2015/11/reverse-engineering-the-bmw-i3-api/
Thank you for your efforts and hard work.
This library is not affiliated nor endorsed by BMW Group / Bayerische Motoren Werke AG.