pub trait BaserowClient: RequestTracing {
// Required methods
fn token_auth<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Box<dyn BaserowClient>, TokenAuthError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn table_fields<'life0, 'async_trait>(
&'life0 self,
table_id: u64,
) -> Pin<Box<dyn Future<Output = Result<Vec<TableField>, Box<dyn Error>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn table_by_id(&self, id: u64) -> BaserowTable;
fn upload_file<'life0, 'async_trait>(
&'life0 self,
file: File,
filename: String,
) -> Pin<Box<dyn Future<Output = Result<BaserowFile, FileUploadError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn upload_file_via_url<'life0, 'life1, 'async_trait>(
&'life0 self,
url: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<BaserowFile, FileUploadError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_configuration(&self) -> Configuration;
fn get_client(&self) -> Client;
}
Expand description
Trait defining the public API interface for Baserow
This trait includes tracing for all operations, providing detailed logs about HTTP requests, responses, and any errors that occur.
All HTTP operations are automatically traced through the RequestTracing trait, which provides detailed logging of request/response cycles.
Required Methods§
Sourcefn token_auth<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Box<dyn BaserowClient>, TokenAuthError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn token_auth<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Box<dyn BaserowClient>, TokenAuthError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Authenticates an existing user based on their email and their password. If successful, an access token and a refresh token will be returned.
This operation is traced with detailed logging of the authentication process, excluding sensitive information like credentials.
Sourcefn table_fields<'life0, 'async_trait>(
&'life0 self,
table_id: u64,
) -> Pin<Box<dyn Future<Output = Result<Vec<TableField>, Box<dyn Error>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn table_fields<'life0, 'async_trait>(
&'life0 self,
table_id: u64,
) -> Pin<Box<dyn Future<Output = Result<Vec<TableField>, Box<dyn Error>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Retrieves all fields for a given table.
This operation is traced with detailed logging of the request/response cycle and field retrieval results.
Sourcefn table_by_id(&self, id: u64) -> BaserowTable
fn table_by_id(&self, id: u64) -> BaserowTable
Returns a table by its ID.
Sourcefn upload_file<'life0, 'async_trait>(
&'life0 self,
file: File,
filename: String,
) -> Pin<Box<dyn Future<Output = Result<BaserowFile, FileUploadError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn upload_file<'life0, 'async_trait>(
&'life0 self,
file: File,
filename: String,
) -> Pin<Box<dyn Future<Output = Result<BaserowFile, FileUploadError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Upload a file to Baserow
This operation is traced with detailed logging of the upload process, including file metadata and upload status.
Sourcefn upload_file_via_url<'life0, 'life1, 'async_trait>(
&'life0 self,
url: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<BaserowFile, FileUploadError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn upload_file_via_url<'life0, 'life1, 'async_trait>(
&'life0 self,
url: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<BaserowFile, FileUploadError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Upload a file to Baserow via URL
This operation is traced with detailed logging of the URL validation and upload process.
Sourcefn get_configuration(&self) -> Configuration
fn get_configuration(&self) -> Configuration
Get the underlying configuration
Sourcefn get_client(&self) -> Client
fn get_client(&self) -> Client
Get the underlying HTTP client