Skip to main content

Module x_api

Module x_api 

Source
Expand description

X API v2 client, authentication, and tier detection.

Provides a trait-based client abstraction for all X API operations, OAuth 2.0 PKCE authentication with token management, and API tier detection for adaptive behavior.

Re-exports§

pub use client::XApiHttpClient;
pub use local_mode::session::ScraperSession;
pub use local_mode::LocalModeXClient;
pub use types::*;

Modules§

auth
OAuth 2.0 PKCE authentication and token management for X API.
client
Reqwest-based X API v2 HTTP client implementation.
local_mode
Local-mode X API client for scraper backend.
media
X API v1.1 media upload implementation.
scopes
OAuth scope registry and diagnostics for X API features.
tier
X API tier detection and capability mapping.
types
X API v2 request and response types.

Traits§

XApiClient
Trait abstracting all X API v2 operations.

Functions§

create_local_client
Create a local-mode X API client if provider_backend = "scraper".
create_local_client_with_data_dir
Create a local-mode client with an optional data directory for cookie-auth.