1.0.3 • Published 3 years ago

@alheimsins/zaptec-go-start-stop v1.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

js-standard-style

zaptec-go-start-stop

A module for starting and stopping your Zaptec Go EV charger

Usage

You will need your username and password for the Zaptec Portal

import { start, stop } from '@alhemisins/zaptec-go-start-stop'

const username = '<your-zaptec-portal-username>'
const password = '<your-zaptec-portal-password>'

const resultStart = await start({ username, password })
console.log(resultStart) // => { status: 'success', message: 'Started charging' }

const resultStop = await top({ username, password })
console.log(resultStop) // => { status: 'success', message: 'Stopped charging' }

If you only want the chargerID and session token you can use getTokenAndCharger

import { getTokenAndCharger } from '@alhemisins/zaptec-go-start-stop'

const username = '<your-zaptec-portal-username>'
const password = '<your-zaptec-portal-password>'

const access = await getTokenAndCharger({ username, password })
console.log(resultStart) // => { status: 'success', message: 'Found charger and authenticated', id: '<your-charger-id>', token: '<your-session-token>' }

Limitations

If you have multiple Zaptec Go chargers connected to your account this module will only pick the first one.

Related

License

MIT

About

Created with ❤ for Alheimsins

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago