auth info

This commit is contained in:
Alex Janka 2024-02-12 11:11:38 +11:00
commit a1bd2e2f2b
4 changed files with 2141 additions and 0 deletions

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
/target

2122
Cargo.lock generated Normal file

File diff suppressed because it is too large Load diff

10
Cargo.toml Normal file
View file

@ -0,0 +1,10 @@
[package]
name = "tesla-common"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
serde = { version = "1.0", features = ["derive"] }
teslatte = { git = "https://git.alexjanka.com/alex/teslatte" }

8
src/lib.rs Normal file
View file

@ -0,0 +1,8 @@
use serde::{Deserialize, Serialize};
use teslatte::auth::{AccessToken, RefreshToken};
#[derive(Serialize, Deserialize, Clone)]
pub struct AuthInfo {
access_token: AccessToken,
refresh_token: Option<RefreshToken>,
}