pub struct CloudBillingHandler { /* private fields */ }
Expand description
Handler for Cloud billing and payment operations
Provides access to billing information, invoice management, payment methods, cost analysis, and usage reporting. Essential for monitoring and managing Redis Cloud costs and payment configuration.
Implementations§
Source§impl CloudBillingHandler
impl CloudBillingHandler
pub fn new(client: CloudClient) -> Self
Sourcepub async fn get_history(
&self,
start_date: Option<&str>,
end_date: Option<&str>,
) -> Result<Value>
pub async fn get_history( &self, start_date: Option<&str>, end_date: Option<&str>, ) -> Result<Value>
Get billing history
Sourcepub async fn get_current_invoice(&self) -> Result<Value>
pub async fn get_current_invoice(&self) -> Result<Value>
Get current invoice
Sourcepub async fn get_invoice(&self, invoice_id: &str) -> Result<Value>
pub async fn get_invoice(&self, invoice_id: &str) -> Result<Value>
Get invoice by ID
Sourcepub async fn list_invoices(&self) -> Result<Value>
pub async fn list_invoices(&self) -> Result<Value>
List all invoices
Sourcepub async fn download_invoice(&self, invoice_id: &str) -> Result<Value>
pub async fn download_invoice(&self, invoice_id: &str) -> Result<Value>
Download invoice PDF
Sourcepub async fn list_payment_methods(&self) -> Result<Value>
pub async fn list_payment_methods(&self) -> Result<Value>
Get payment methods
Sourcepub async fn get_payment_method(&self, method_id: u32) -> Result<Value>
pub async fn get_payment_method(&self, method_id: u32) -> Result<Value>
Get payment method by ID
Sourcepub async fn add_payment_method(&self, request: Value) -> Result<Value>
pub async fn add_payment_method(&self, request: Value) -> Result<Value>
Add payment method
Sourcepub async fn update_payment_method(
&self,
method_id: u32,
request: Value,
) -> Result<Value>
pub async fn update_payment_method( &self, method_id: u32, request: Value, ) -> Result<Value>
Update payment method
Sourcepub async fn delete_payment_method(&self, method_id: u32) -> Result<Value>
pub async fn delete_payment_method(&self, method_id: u32) -> Result<Value>
Delete payment method
Sourcepub async fn set_default_payment_method(&self, method_id: u32) -> Result<Value>
pub async fn set_default_payment_method(&self, method_id: u32) -> Result<Value>
Set default payment method
Sourcepub async fn get_alerts(&self) -> Result<Value>
pub async fn get_alerts(&self) -> Result<Value>
Get billing alerts configuration
Sourcepub async fn update_alerts(&self, request: Value) -> Result<Value>
pub async fn update_alerts(&self, request: Value) -> Result<Value>
Update billing alerts configuration
Sourcepub async fn get_cost_breakdown(&self, period: &str) -> Result<Value>
pub async fn get_cost_breakdown(&self, period: &str) -> Result<Value>
Get cost breakdown
Sourcepub async fn get_usage(&self, start_date: &str, end_date: &str) -> Result<Value>
pub async fn get_usage(&self, start_date: &str, end_date: &str) -> Result<Value>
Get usage report
Sourcepub async fn get_credits(&self) -> Result<Value>
pub async fn get_credits(&self) -> Result<Value>
Get credits balance
Sourcepub async fn apply_promo_code(&self, code: &str) -> Result<Value>
pub async fn apply_promo_code(&self, code: &str) -> Result<Value>
Apply promo code
Auto Trait Implementations§
impl Freeze for CloudBillingHandler
impl !RefUnwindSafe for CloudBillingHandler
impl Send for CloudBillingHandler
impl Sync for CloudBillingHandler
impl Unpin for CloudBillingHandler
impl !UnwindSafe for CloudBillingHandler
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