Skip to content

Commit

Permalink
Some notes about region and version
Browse files Browse the repository at this point in the history
  • Loading branch information
elffjs committed May 29, 2024
1 parent 2176f66 commit 9ce570e
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions sdtask/sdtask.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,17 @@ import (
)

type CredentialData struct {
TaskID string `json:"taskId"`
UserDeviceID string `json:"userDeviceId"`
IntegrationID string `json:"integrationId"`
AccessToken string `json:"accessToken"`
Expiry time.Time `json:"expiry"`
RefreshToken string `json:"refreshToken"`
Version int `json:"version,omitempty"`
TaskID string `json:"taskId"`
UserDeviceID string `json:"userDeviceId"`
IntegrationID string `json:"integrationId"`
AccessToken string `json:"accessToken"`
Expiry time.Time `json:"expiry"`
RefreshToken string `json:"refreshToken"`
// Version is an API version. Currently only used for Tesla: 1 is the old
// "Owner api" and 2 is the new "Fleet API".
Version int `json:"version,omitempty"`
// Region is the two-letter code for the region. Currently only used for
// Tesla, and can only be "na" or "eu".
Region string `json:"region,omitempty"`
SyntheticDevice *SyntheticDevice `json:"syntheticDevice,omitempty"`
}
Expand Down

0 comments on commit 9ce570e

Please sign in to comment.