pub async fn by_token(auth_token: &str) -> crate::Result<Self> {
        let rb: reqwest::RequestBuilder = { get_http_client()?.get(MYPLEX_ACCOUNT_INFO_URL) };
        let response = rb
            .headers(base_headers()?)
            .header(reqwest::header::ACCEPT, "application/json")
            .header("X-Plex-Token", auth_token)
            .send()
            .await?;

        MyPlexAccount::handle_login(response).await
    }
/// Log in to [MyPlex](http://app.plex.tv) using existing authentication token.
Log in to [MyPlex] using existing authentication token.
Log in to [ MyPlex ] using existing authentication token .
pub async fn by_token(auth_token: &str) -> crate::Result<Self> {
        let rb: reqwest::RequestBuilder = { get_http_client()?.get(MYPLEX_ACCOUNT_INFO_URL) };
        let response = rb
            .headers(base_headers()?)
            .header(reqwest::header::ACCEPT, "application/json")
            .header("X-Plex-Token", auth_token)
            .send()
            .await?;
        MyPlexAccount::handle_login(response).await
    }
pub async fn by_token ( auth_token : & str ) -> crate :: Result < Self > { let rb : reqwest :: RequestBuilder = { get_http_client ( ) ? . get ( MYPLEX_ACCOUNT_INFO_URL ) } ; let response = rb . headers ( base_headers ( ) ? ) . header ( reqwest :: header :: ACCEPT , " " ) . header ( " " , auth_token ) . send ( ) . await ? ; MyPlexAccount :: handle_login ( response ) . await }
Log in to [MyPlex](http://app.plex.tv) using existing authentication token.
Log in to [ MyPlex ] ( http : // app . plex . tv ) using existing authentication token .
auth_token
&str
auth_token
&str