pub struct AutomatedSpend {Show 14 fields
pub id: String,
pub revision: u32,
pub kind: String,
pub purpose: String,
pub authority: SpendAuthority,
pub asset: SpendAsset,
pub amount_mojos: String,
pub fee_mojos: String,
pub store_id: Option<String>,
pub initiated_ms: u64,
pub updated_ms: u64,
pub status: SpendOutcome,
pub funding_coin_ids: Vec<String>,
pub chain_reference: Option<SpendChainReference>,
}Expand description
One spend this node made WITHOUT per-transaction approval.
§Amounts are decimal STRINGS
amount_mojos and fee_mojos carry the full u64 range, which a JSON number does not survive
through an f64 parser — and a silently rounded figure about somebody’s money is exactly the lie
this record exists to prevent. Every money field in this crate is a string for that reason.
Fields§
§id: StringThe audit id — stable for the life of the spend, and the value
after_id resumes from.
revision: u32The revision of the record this row reflects. The audit trail is append-only and each entry is a snapshot; this row is the highest revision the node holds for this spend.
kind: StringWhat the spend was for, as the producer’s stable token ("mirror-coin", …).
purpose: StringOne human sentence: why this happened without asking.
Whose standing consent was relied on, and which grant.
asset: SpendAssetWhich asset moved.
amount_mojos: StringHow much, in the asset’s base units, as a decimal string.
fee_mojos: StringThe network fee in mojos of XCH, as a decimal string.
store_id: Option<String>The store this spend serves, when it serves one.
initiated_ms: u64When the node decided to spend, unix ms. The field the ordering and the time filters use.
updated_ms: u64When this revision was written, unix ms.
status: SpendOutcomeWhere the spend got to.
funding_coin_ids: Vec<String>The coins this spend CONSUMED, once known.
Never the confirmation evidence. The legacy implementation waited for a funding coin to be
spent and called that confirmation, which a competing spend of the same coin satisfies
identically while the intended coin never exists — so a client MUST NOT infer success from
anything here. chain_reference is the only reference that carries
an observed/expected flag.
chain_reference: Option<SpendChainReference>The chain reference to show, or null when the node knows no coin id yet — which is honest:
there is nothing to look up.
The key MUST be present. null is meaningful, so an ABSENT key must not decode into it: a
truncated or mis-routed payload would otherwise decode as a confident “there is nothing to
look up”.
Trait Implementations§
Source§impl Clone for AutomatedSpend
impl Clone for AutomatedSpend
Source§fn clone(&self) -> AutomatedSpend
fn clone(&self) -> AutomatedSpend
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more