pub struct LocalModeXClient { /* private fields */ }Expand description
X API client for local/scraper mode — no OAuth credentials required.
When a valid scraper_session.json exists in the data directory,
operations are dispatched to the cookie-based transport.
Otherwise, they return ScraperTransportUnavailable.
All transport calls are wrapped with retry_with_backoff so transient
network errors and 5xx responses are retried automatically. Health
is tracked in health and exposed via LocalModeXClient::health.
Implementations§
Source§impl LocalModeXClient
impl LocalModeXClient
Sourcepub fn new(allow_mutations: bool) -> Self
pub fn new(allow_mutations: bool) -> Self
Create a new local-mode client (no session — stub mode).
allow_mutations controls whether write operations are attempted
(when true) or immediately rejected (when false).
Sourcepub async fn with_session(allow_mutations: bool, data_dir: &Path) -> Self
pub async fn with_session(allow_mutations: bool, data_dir: &Path) -> Self
Create a local-mode client with cookie-auth from a session file.
If the session file exists and is valid, operations will use the cookie transport. Otherwise, falls back to stub behavior.
Auto-detects GraphQL query IDs from X’s web client JS bundles at startup.
Sourcepub async fn with_session_and_health(
allow_mutations: bool,
data_dir: &Path,
health: ScraperHealth,
) -> Self
pub async fn with_session_and_health( allow_mutations: bool, data_dir: &Path, health: ScraperHealth, ) -> Self
Create a local-mode client with cookie-auth and a shared health handle.
Use this instead of [with_session] when you want multiple ephemeral
clients (e.g. one per HTTP request) to update the same health tracker
held in AppState. Enables the /health endpoint to reflect real
scraper health across the lifetime of the server process.
Sourcepub fn health(&self) -> ScraperHealth
pub fn health(&self) -> ScraperHealth
Return a clone of the shared health handle.
Callers (e.g. the health endpoint) can snapshot the current state without coupling to the client implementation.
Sourcepub fn session_path(data_dir: &Path) -> PathBuf
pub fn session_path(data_dir: &Path) -> PathBuf
Path to the session file in a given data directory.
Trait Implementations§
Source§impl XApiClient for LocalModeXClient
impl XApiClient for LocalModeXClient
Source§fn get_me<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<User, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_me<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<User, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn get_mentions<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
_since_id: Option<&'life2 str>,
_pagination_token: Option<&'life3 str>,
) -> Pin<Box<dyn Future<Output = Result<MentionResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn get_mentions<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
_since_id: Option<&'life2 str>,
_pagination_token: Option<&'life3 str>,
) -> Pin<Box<dyn Future<Output = Result<MentionResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Source§fn get_home_timeline<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_home_timeline<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn get_bookmarks<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_bookmarks<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn bookmark_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn bookmark_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn unbookmark_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn unbookmark_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn search_tweets<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
query: &'life1 str,
max_results: u32,
_since_id: Option<&'life2 str>,
pagination_token: Option<&'life3 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn search_tweets<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
query: &'life1 str,
max_results: u32,
_since_id: Option<&'life2 str>,
pagination_token: Option<&'life3 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Source§fn get_tweet<'life0, 'life1, 'async_trait>(
&'life0 self,
tweet_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Tweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_tweet<'life0, 'life1, 'async_trait>(
&'life0 self,
tweet_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Tweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn get_user_by_username<'life0, 'life1, 'async_trait>(
&'life0 self,
username: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<User, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_user_by_username<'life0, 'life1, 'async_trait>(
&'life0 self,
username: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<User, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn get_user_tweets<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_user_tweets<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn get_user_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<User, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_user_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<User, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn get_followers<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<UsersResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_followers<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<UsersResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn get_following<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<UsersResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_following<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<UsersResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn get_users_by_ids<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_ids: &'life1 [&'life2 str],
) -> Pin<Box<dyn Future<Output = Result<UsersResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_users_by_ids<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_ids: &'life1 [&'life2 str],
) -> Pin<Box<dyn Future<Output = Result<UsersResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn get_liked_tweets<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_liked_tweets<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
user_id: &'life1 str,
max_results: u32,
pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<SearchResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn get_tweet_liking_users<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_tweet_id: &'life1 str,
_max_results: u32,
_pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<UsersResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_tweet_liking_users<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_tweet_id: &'life1 str,
_max_results: u32,
_pagination_token: Option<&'life2 str>,
) -> Pin<Box<dyn Future<Output = Result<UsersResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn raw_request<'life0, 'life1, 'life2, 'life3, 'life4, 'life5, 'async_trait>(
&'life0 self,
_method: &'life1 str,
_url: &'life2 str,
_query: Option<&'life3 [(String, String)]>,
_body: Option<&'life4 str>,
_headers: Option<&'life5 [(String, String)]>,
) -> Pin<Box<dyn Future<Output = Result<RawApiResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
'life5: 'async_trait,
fn raw_request<'life0, 'life1, 'life2, 'life3, 'life4, 'life5, 'async_trait>(
&'life0 self,
_method: &'life1 str,
_url: &'life2 str,
_query: Option<&'life3 [(String, String)]>,
_body: Option<&'life4 str>,
_headers: Option<&'life5 [(String, String)]>,
) -> Pin<Box<dyn Future<Output = Result<RawApiResponse, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
'life5: 'async_trait,
Source§fn post_tweet<'life0, 'life1, 'async_trait>(
&'life0 self,
text: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn post_tweet<'life0, 'life1, 'async_trait>(
&'life0 self,
text: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn reply_to_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
text: &'life1 str,
in_reply_to_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn reply_to_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
text: &'life1 str,
in_reply_to_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn post_tweet_with_media<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
text: &'life1 str,
_media_ids: &'life2 [String],
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn post_tweet_with_media<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
text: &'life1 str,
_media_ids: &'life2 [String],
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn reply_to_tweet_with_media<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
text: &'life1 str,
in_reply_to_id: &'life2 str,
_media_ids: &'life3 [String],
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn reply_to_tweet_with_media<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
text: &'life1 str,
in_reply_to_id: &'life2 str,
_media_ids: &'life3 [String],
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Source§fn quote_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_text: &'life1 str,
_quoted_tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn quote_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_text: &'life1 str,
_quoted_tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<PostedTweet, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn like_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn like_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn unlike_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn unlike_tweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn follow_user<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
target_user_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn follow_user<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
target_user_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn unfollow_user<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
target_user_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn unfollow_user<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
target_user_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn retweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn retweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn unretweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn unretweet<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_user_id: &'life1 str,
tweet_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Source§fn delete_tweet<'life0, 'life1, 'async_trait>(
&'life0 self,
tweet_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_tweet<'life0, 'life1, 'async_trait>(
&'life0 self,
tweet_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<bool, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn upload_media<'life0, 'life1, 'async_trait>(
&'life0 self,
_data: &'life1 [u8],
_media_type: MediaType,
) -> Pin<Box<dyn Future<Output = Result<MediaId, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn upload_media<'life0, 'life1, 'async_trait>(
&'life0 self,
_data: &'life1 [u8],
_media_type: MediaType,
) -> Pin<Box<dyn Future<Output = Result<MediaId, XApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Auto Trait Implementations§
impl Freeze for LocalModeXClient
impl !RefUnwindSafe for LocalModeXClient
impl Send for LocalModeXClient
impl Sync for LocalModeXClient
impl Unpin for LocalModeXClient
impl UnsafeUnpin for LocalModeXClient
impl !UnwindSafe for LocalModeXClient
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more