pub struct PaymentOption {
pub scheme: String,
pub pay_to: String,
pub price: Value,
pub network: String,
pub max_timeout_seconds: Option<u64>,
pub extra: Option<Value>,
}Expand description
A payment option accepted by a protected route.
Defines a (scheme, network) pair along with price and recipient for a single payment method accepted at an endpoint.
Corresponds to Python SDK’s PaymentOption.
Fields§
§scheme: StringPayment scheme identifier (e.g., "exact").
pay_to: StringRecipient address (e.g., "0x...").
price: ValuePrice — a money string (e.g., "1.50") or structured amount.
network: StringCAIP-2 network identifier (e.g., "eip155:8453").
max_timeout_seconds: Option<u64>Maximum payment validity in seconds (defaults to 300).
extra: Option<Value>Scheme-specific extra data.
Trait Implementations§
Source§impl Clone for PaymentOption
impl Clone for PaymentOption
Source§fn clone(&self) -> PaymentOption
fn clone(&self) -> PaymentOption
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 PaymentOption
impl Debug for PaymentOption
Source§impl<'de> Deserialize<'de> for PaymentOption
impl<'de> Deserialize<'de> for PaymentOption
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for PaymentOption
impl RefUnwindSafe for PaymentOption
impl Send for PaymentOption
impl Sync for PaymentOption
impl Unpin for PaymentOption
impl UnwindSafe for PaymentOption
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