pub struct AcpPaymentAdapter { /* private fields */ }Expand description
Thin shared-payment-token payment bridge for ACP-style commerce approvals.
This adapter performs one remote authorization call before execution and then lets the kernel reconcile the local hold as capture/release/refund bookkeeping after tool execution. This keeps ACP-specific logic adapter scoped while still exercising a real external authorization hop.
Implementations§
Trait Implementations§
Source§impl Clone for AcpPaymentAdapter
impl Clone for AcpPaymentAdapter
Source§fn clone(&self) -> AcpPaymentAdapter
fn clone(&self) -> AcpPaymentAdapter
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AcpPaymentAdapter
impl Debug for AcpPaymentAdapter
Source§impl PaymentAdapter for AcpPaymentAdapter
impl PaymentAdapter for AcpPaymentAdapter
Authorize or prepay up to
amount_units before the tool executes.Source§fn capture(
&self,
authorization_id: &str,
amount_units: u64,
currency: &str,
reference: &str,
) -> Result<PaymentResult, PaymentError>
fn capture( &self, authorization_id: &str, amount_units: u64, currency: &str, reference: &str, ) -> Result<PaymentResult, PaymentError>
Finalize payment for the actual cost after tool execution.
Source§fn release(
&self,
authorization_id: &str,
reference: &str,
) -> Result<PaymentResult, PaymentError>
fn release( &self, authorization_id: &str, reference: &str, ) -> Result<PaymentResult, PaymentError>
Release an unused authorization hold.
Source§fn refund(
&self,
transaction_id: &str,
amount_units: u64,
currency: &str,
reference: &str,
) -> Result<PaymentResult, PaymentError>
fn refund( &self, transaction_id: &str, amount_units: u64, currency: &str, reference: &str, ) -> Result<PaymentResult, PaymentError>
Refund a previously executed payment.
Auto Trait Implementations§
impl Freeze for AcpPaymentAdapter
impl !RefUnwindSafe for AcpPaymentAdapter
impl Send for AcpPaymentAdapter
impl Sync for AcpPaymentAdapter
impl Unpin for AcpPaymentAdapter
impl UnsafeUnpin for AcpPaymentAdapter
impl !UnwindSafe for AcpPaymentAdapter
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