tronity

package
v0.0.0-...-e05b1bb Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 19, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ReadBattery          = "read_battery"            // Read EV battery's capacity and state of charge
	ReadCharge           = "read_charge"             // Know whether vehicle is charging
	ReadLocation         = "read_location"           // Access location
	ReadOdometer         = "read_odometer"           // Retrieve total distance traveled
	ReadVehicleInfo      = "read_vehicle_info"       // Know make, model, and year
	ReadVIN              = "read_vin"                // Read VIN
	WriteChargeStartStop = "write_charge_start_stop" // Start or stop your vehicle's charging
	WriteWakeUp          = "write_wake_up"           // Wake up car. Only valid for Tesla
)
View Source
const URI = "https://api-eu.tronity.io"

Variables

This section is empty.

Functions

func OAuth2Config

func OAuth2Config(id, secret string) (*oauth2.Config, error)

Types

type Bulk

type Bulk struct {
	VIN      string
	Odometer float64
	Range    float64
	Level    float64
	Charging string // Charging
	// Latitude  float64/string
	// Longitude float64/string
	Timestamp int64
}

type EVBatteryLevel

type EVBatteryLevel struct {
	Range     float64
	Level     float64
	Timestamp int64
}

type EVChargingStatus

type EVChargingStatus struct {
	Charging  string
	Timestamp int64
}

type Location

type Location struct {
	// Latitude  float64/string
	// Longitude float64/string
	Timestamp int64
}

type Odometer

type Odometer struct {
	Odometer  float64
	Timestamp float64
}

type Vehicle

type Vehicle struct {
	ID          string
	VIN         string
	DisplayName string
	Manufacture string
	Scopes      []string
}

type Vehicles

type Vehicles struct {
	Data []Vehicle
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL