Add token auth
This commit is contained in:
1
login.go
1
login.go
@ -17,7 +17,6 @@ func login(ctx context.Context, username string, password string, tok string) (s
|
|||||||
if tok != "" {
|
if tok != "" {
|
||||||
client, err = tesla.NewClient(
|
client, err = tesla.NewClient(
|
||||||
ctx,
|
ctx,
|
||||||
tesla.WithMFAHandler(noDevice),
|
|
||||||
tesla.WithToken(&oauth2.Token{
|
tesla.WithToken(&oauth2.Token{
|
||||||
RefreshToken: tok,
|
RefreshToken: tok,
|
||||||
}),
|
}),
|
||||||
|
|||||||
Reference in New Issue
Block a user