pub struct PaymentHandler { /* private fields */ }
Expand description
Handler for payment operations
Implementations§
Source§impl PaymentHandler
impl PaymentHandler
Sourcepub fn new(client: FilesClient) -> Self
pub fn new(client: FilesClient) -> Self
Create a new payment handler
Sourcepub async fn list(
&self,
cursor: Option<&str>,
per_page: Option<i64>,
) -> Result<(Vec<PaymentEntity>, PaginationInfo)>
pub async fn list( &self, cursor: Option<&str>, per_page: Option<i64>, ) -> Result<(Vec<PaymentEntity>, PaginationInfo)>
List payments
§Arguments
cursor
- Pagination cursorper_page
- Results per page
§Returns
Tuple of (payments, pagination_info)
§Example
use files_sdk::{FilesClient, PaymentHandler};
let client = FilesClient::builder().api_key("key").build()?;
let handler = PaymentHandler::new(client);
let (payments, _) = handler.list(None, None).await?;
Auto Trait Implementations§
impl Freeze for PaymentHandler
impl !RefUnwindSafe for PaymentHandler
impl Send for PaymentHandler
impl Sync for PaymentHandler
impl Unpin for PaymentHandler
impl !UnwindSafe for PaymentHandler
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
Mutably borrows from an owned value. Read more