Answers the question: is my BMW connected to a charger?
import isConnectedToCharger from '@alheimsins/bmw-is-connected-to-charger'
const username = '<connected-drive-username>'
const password = '<connected-drive-password>'
const data = await isConnectedToCharger({ username, password })
console.log(data)
This will return
{
isConnected: false,
batteryLevel: 54,
location: {
coordinates: {
latitude: <your-latitude>,
longitude: <your-longitude>
},
address: {
formatted: <your-formatted-address>
},
heading: 295
}
}
- If you have multiple cars added to your Connected Drive account, this script will only return the location of the first car.
- To get the location of your car, you need to have your share location permission activated.
This module is not affiliated with or endorsed by BMW Group. It might break any time.
- calculate-cheapest-charging-schedule Simple module for calculating the cheapest charging schedule for your EV
- tibber-get-price-info Retrieve price info from tibber for your current subscription
- zaptec-go-start-stop A module for starting and stopping your Zaptec Go EV charger
- leaf-connect Node.js client library for the Nissan Leaf API
- bimmer-connected An amazing open source library
Created with ❤ for Alheimsins