Documentation ¶
Index ¶
Constants ¶
View Source
const (
SmartCarVendor = "SmartCar"
)
Variables ¶
This section is empty.
Functions ¶
func ParseSmartCarYears ¶
ParseSmartCarYears parses out the years format in the smartcar document and returns an array of years
Types ¶
type IntegrationCapabilities ¶
type IntegrationCapabilities struct { Location bool `json:"location"` Odometer bool `json:"odometer"` LockUnlock bool `json:"lock_unlock"` EVBattery bool `json:"ev_battery"` EVChargingStatus bool `json:"ev_charging_status"` EVStartStopCharge bool `json:"ev_start_stop_charge"` FuelTank bool `json:"fuel_tank"` TirePressure bool `json:"tire_pressure"` EngineOilLife bool `json:"engine_oil_life"` VehicleAttributes bool `json:"vehicle_attributes"` VIN bool `json:"vin"` }
IntegrationCapabilities gets stored on the association table btw a device_definition and the integrations, device_integrations
type SmartCarCompatibilityData ¶
type SmartCarCompatibilityData struct { ComponentChunkName string `json:"componentChunkName"` Path string `json:"path"` Result struct { Data struct { AllMakesTable struct { Edges []struct { Node struct { CompatibilityData map[string][]struct { Name string `json:"name"` Headers []struct { Text string `json:"text"` Tooltip *string `json:"tooltip"` } `json:"headers"` Rows [][]struct { Color *string `json:"color"` Subtext *string `json:"subtext"` Text *string `json:"text"` Type *string `json:"type"` VehicleType *string `json:"vehicleType"` } `json:"rows"` } `json:"compatibilityData"` } `json:"node"` } `json:"edges"` } `json:"allMakesTable"` } `json:"data"` } `json:"result"` }
type SmartCarService ¶
type SmartCarService interface { GetOrCreateSmartCarIntegration(ctx context.Context) (string, error) GetSmartCarVehicleData() (*SmartCarCompatibilityData, error) }
func NewSmartCarService ¶
func NewSmartCarService(dbs func() *db.ReaderWriter, logger zerolog.Logger) SmartCarService
Click to show internal directories.
Click to hide internal directories.