Skip to main content

Reconcile

Enum Reconcile 

Source
pub enum Reconcile {
Show 25 variants LinkTransfer { out: String, to_event: Option<String>, to_wallet: Option<String>, }, ClassifyInboundIncome { in_ref: String, kind: String, fmv: Option<String>, business: bool, }, ClassifyInboundGift { in_ref: String, fmv_at_gift: String, donor_basis: Option<String>, donor_acquired: Option<String>, }, ClassifyInboundSelfTransfer { in_ref: String, basis: Option<String>, acquired: Option<String>, }, ReclassifyOutflow { out: String, as_kind: OutKindArg, amount: String, fee: Option<String>, appraisal: bool, donee: Option<String>, }, SetFmv { event: String, fmv: String, }, Void { target: String, }, ClassifyRaw { target: String, payload_json: String, }, AcceptConflict { conflict: String, }, RejectConflict { conflict: String, }, SafeHarborAllocate { method: MethodArg, attest: bool, }, SafeHarborAttest, SelectLots { disposal: String, from: Vec<String>, }, ImportSelections { csv: PathBuf, }, ReclassifyIncome { income_event: String, business: bool, kind: Option<String>, }, SetDonationDetails { out_event_ref: String, donee_name: String, donee_address: Option<String>, donee_ein: Option<String>, appraiser_name: String, appraiser_address: Option<String>, appraiser_tin: Option<String>, appraiser_ptin: Option<String>, appraiser_qualifications: Option<String>, appraisal_date: Option<String>, fmv_method: Option<String>, }, ShowDonationDetails { out_event_ref: String, }, BulkLinkTransfer { to_wallet: String, year: Option<i32>, from: Option<String>, to: Option<String>, from_wallet: Option<String>, dry_run: bool, yes: bool, }, BulkClassifyInboundSelfTransfer { year: Option<i32>, from: Option<String>, to: Option<String>, wallet: Option<String>, dry_run: bool, yes: bool, }, BulkClassifyInboundIncome { kind: String, business: bool, year: Option<i32>, from: Option<String>, to: Option<String>, wallet: Option<String>, dry_run: bool, yes: bool, }, BulkReclassifyOutflow { kind: String, year: Option<i32>, from: Option<String>, to: Option<String>, wallet: Option<String>, dry_run: bool, yes: bool, }, BulkResolveConflict { accept: bool, reject: bool, dry_run: bool, yes: bool, }, BulkVoid { dry_run: bool, yes: bool, }, MatchSelfTransfers { in_ref: Option<String>, out_ref: Option<String>, action: Option<SelfTransferActionArg>, dry_run: bool, }, Pseudo(Pseudo),
}

Variants§

§

LinkTransfer

Confirm a self-transfer (TransferLink).

Fields

§to_event: Option<String>
§to_wallet: Option<String>
§

ClassifyInboundIncome

Classify an inbound TransferIn as income.

Fields

§in_ref: String
§kind: String
§business: bool
§

ClassifyInboundGift

Classify an inbound TransferIn as a received gift.

Fields

§in_ref: String
§fmv_at_gift: String
§donor_basis: Option<String>
§donor_acquired: Option<String>
§

ClassifyInboundSelfTransfer

Classify an inbound TransferIn as an inbound self-transfer (“my own coins” returning) — non-taxable, creates a fresh lot. --basis defaults to $0 (conservative; fires the honest zero-basis advisory when omitted); --acquired defaults to 1 year + 1 day before receipt (assumed long-term for a cold-storage deposit; discloses an advisory so you can correct it).

Fields

§in_ref: String
§acquired: Option<String>
§

ReclassifyOutflow

Reclassify a pending TransferOut.

Fields

§as_kind: OutKindArg
§amount: String
§appraisal: bool
§donee: Option<String>

Free-form donee identifier (e.g. “Alice”, “Charity X”). Carried through to removals.csv and Form 8283; does not affect tax math.

§

SetFmv

Set a manual FMV on an event.

Fields

§event: String
§

Void

Void a revocable decision.

Fields

§target: String
§

ClassifyRaw

Resolve an Unclassified row from a JSON imported payload.

Fields

§target: String
§payload_json: String

A JSON-encoded imported EventPayload (serde externally-tagged: {"Variant":{...}}) to resolve the Unclassified target as. Must be an IMPORTED variant — Acquire, Income, Dispose, TransferOut, TransferIn, or Unclassified. USD fields (usd_cost, fee_usd, …) are decimal STRINGS; sat is an integer.

FORMAT (Acquire example): {“Acquire”:{“sat”:2000000,“usd_cost”:“1680.00”,“fee_usd”:“5.00”,“basis_source”:“ExchangeProvided”}}

§

AcceptConflict

Accept an import conflict.

Fields

§conflict: String
§

RejectConflict

Reject an import conflict.

Fields

§conflict: String
§

SafeHarborAllocate

Path-B safe-harbor allocate (from the actual pre-2025 position).

Fields

§method: MethodArg
§attest: bool
§

SafeHarborAttest

Attest an existing allocation as timely.

§

SelectLots

§A.4 Specific-ID: pick the exact lots a disposal consumes.

Fields

§disposal: String
§from: Vec<String>

One lot pick per –from flag (repeatable). Each PICK is <origin_event_id>#<split_sequence>:<sat>. The origin_event_id + split come from the lot column of disposals.csv or the origin_event/split columns of lots.csv (export-snapshot). The total sat across the picks must equal the disposal’s principal (validated in the fold).

FORMAT (two picks): –from import|coinbase|X#0:25000 –from import|river|Y#1:5000

§

ImportSelections

§A.4 Batch import LotSelections from a CSV (disposal_ref,origin_event_id,split_sequence,sat).

Fields

§csv: PathBuf

CSV of lot picks imported as LotSelection decisions (§A.4). The header is REQUIRED and validated loudly; rows sharing a disposal_ref are grouped into a single decision. disposal_ref is the disposal event’s ref (disposals.csv event column); origin_event_id is the lot’s origin (lots.csv origin_event column).

FORMAT (header + one sample row): disposal_ref,origin_event_id,split_sequence,sat import|gemini|trade|T-2.O-2,import|coinbase|X,0,1000000

§

ReclassifyIncome

SE-completion Chunk C: flip business (and optionally kind) on an already-imported Income event.

Corrects the business: false hard-code that River (and other adapters) emit at ingest time, enabling SE-tax treatment for professional miners / stakers. The engine validates that the target event exists and is an Income event — a missing or non-Income target fires a Hard DecisionConflict blocker (decision excluded). For TransferIn rows use classify-inbound-income instead.

DecisionConflict is Hard — to re-decide, void the prior decision first, then re-issue.

Fields

§income_event: String

The Income event reference (from report or income_recognized.csv ‘event’ column).

§business: bool

Whether this income is from a trade or business (true → SE-tax eligible). Must be supplied explicitly: --business true or --business false.

§kind: Option<String>

Optional income kind correction: mining|staking|interest|airdrop|reward. Omit to keep the original kind (only flip business).

§

SetDonationDetails

Store Form 8283 Section-B donation + appraiser details for a donation event. The event ref is the TransferOut EventId from the removals.csv ‘event’ column.

Fields

§out_event_ref: String

TransferOut event reference for the donation (from removals.csv ‘event’ column).

§donee_name: String

Donee organization name (Part IV; required).

§donee_address: Option<String>

Donee mailing address (Part IV; optional).

§donee_ein: Option<String>

Donee EIN (Part IV; required for Section-B completeness).

§appraiser_name: String

Qualified appraiser name (Part III; required).

§appraiser_address: Option<String>

Appraiser mailing address (Part III; optional).

§appraiser_tin: Option<String>

Appraiser TIN/SSN/EIN (Part III §6695A; satisfies the TIN-or-PTIN requirement).

§appraiser_ptin: Option<String>

Appraiser PTIN (Part III §6695A; satisfies the TIN-or-PTIN requirement).

§appraiser_qualifications: Option<String>

Appraiser qualifications declaration (§170(f)(11)(E)).

§appraisal_date: Option<String>

Date the qualified appraisal was made (YYYY-MM-DD).

§fmv_method: Option<String>

FMV determination method override (overrides the section-derived default on the Form 8283 carrier row; resolves the Section-A fmv_method deferral when supplied).

§

ShowDonationDetails

Show stored Form 8283 donation details for a donation event.

Fields

§out_event_ref: String

TransferOut event reference for the donation (from removals.csv ‘event’ column).

§

BulkLinkTransfer

Bulk-confirm self-transfers: link every PENDING outbound transfer in a time frame to one destination wallet (non-taxable). Shows a preview + requires –yes (or interactive y/N).

Fields

§to_wallet: String

Destination wallet every selected outflow links to.

§year: Option<i32>

Restrict to a single tax year (mutually exclusive with –from/–to).

§from: Option<String>

Range start (YYYY-MM-DD; requires –to).

§to: Option<String>

Range end (YYYY-MM-DD, inclusive; requires –from).

§from_wallet: Option<String>

Only outflows FROM this source wallet.

§dry_run: bool

Print the preview and exit without writing.

§yes: bool

Skip the interactive confirmation (non-interactive apply).

§

BulkClassifyInboundSelfTransfer

Bulk-classify unknown-basis inbound deposits as self-transfer-ins (“my own coins”): apply Cycle A’s SelfTransferMine ($0 conservative basis, non-taxable) to MANY pending inbounds in a time frame at once. Shows a preview surfacing the total USD given $0 basis (the over-tax exposure) + requires –yes (or interactive y/N). Each is a voidable decision; for a deposit whose real cost you can substantiate, classify it single-item with classify-inbound-self-transfer --basis.

Fields

§year: Option<i32>

Restrict to a single tax year (mutually exclusive with –from/–to).

§from: Option<String>

Range start (YYYY-MM-DD; requires –to).

§to: Option<String>

Range end (YYYY-MM-DD, inclusive; requires –from).

§wallet: Option<String>

Only inbounds received INTO this wallet.

§dry_run: bool

Print the preview and exit without writing.

§yes: bool

Skip the interactive confirmation (non-interactive apply).

§

BulkClassifyInboundIncome

Bulk-classify unknown-basis inbound deposits as INCOME (mining|staking|interest|airdrop|reward): recognize MANY pending inbounds as ordinary income at their auto-FMV (the daily-close market value at receipt) in one confirmed batch, with a UNIFORM --kind + --business flag. Shows a preview surfacing the total income recognized + the count of inbounds EXCLUDED because no price was available for their date (those stay pending — an income row with no FMV would year-gate). Each is a voidable decision; for a single deposit use classify-inbound-income.

Fields

§kind: String

Income kind for the whole batch: mining|staking|interest|airdrop|reward.

§business: bool

Whether this income is from a trade or business (true → SE-tax eligible).

§year: Option<i32>

Restrict to a single tax year (mutually exclusive with –from/–to).

§from: Option<String>

Range start (YYYY-MM-DD; requires –to).

§to: Option<String>

Range end (YYYY-MM-DD, inclusive; requires –from).

§wallet: Option<String>

Only inbounds received INTO this wallet.

§dry_run: bool

Print the preview and exit without writing.

§yes: bool

Skip the interactive confirmation (non-interactive apply).

§

BulkReclassifyOutflow

Bulk-reclassify unknown pending OUTFLOWS as dispositions (Sell|Spend): reclassify MANY pending TransferOuts as a Dispose in one confirmed batch, with the daily-close market value at the outflow date as the ESTIMATED proceeds. Shows a preview surfacing the total ESTIMATED proceeds AND the total ESTIMATED gain (sum(fmv) - sum(basis)) + the count of outflows EXCLUDED because no price was available for their date (those stay pending — a Sell with fabricated proceeds would be a SILENT misreport). --kind is UNIFORM and accepts ONLY sell|spend (gift/donate are out of scope). Each is a voidable decision; for a single outflow use reclassify-outflow.

Fields

§kind: String

Disposition kind for the whole batch: sell|spend (gift/donate rejected — out of scope).

§year: Option<i32>

Restrict to a single tax year (mutually exclusive with –from/–to).

§from: Option<String>

Range start (YYYY-MM-DD; requires –to).

§to: Option<String>

Range end (YYYY-MM-DD, inclusive; requires –from).

§wallet: Option<String>

Only outflows from this SOURCE wallet.

§dry_run: bool

Print the preview and exit without writing.

§yes: bool

Skip the interactive confirmation (non-interactive apply).

§

BulkResolveConflict

Bulk-resolve import conflicts: ACCEPT (adopt each new payload) or REJECT (keep each current payload) MANY flagged ImportConflicts in one confirmed batch. Shows a current → new preview, then requires –yes (or interactive y/N). Exactly one of –accept / –reject is required. Each resolution is NON-REVOCABLE (SupersedeImport/RejectImport cannot be voided); to resolve a conflict differently, exclude it and use single-item accept-conflict/reject-conflict.

Fields

§accept: bool

Accept every listed conflict (adopt each new payload onto its target).

§reject: bool

Reject every listed conflict (keep each target’s current payload).

§dry_run: bool

Print the preview and exit without writing.

§yes: bool

Skip the interactive confirmation (non-interactive apply).

§

BulkVoid

Bulk-void MANY revocable reconcile decisions in one confirmed batch (bulk-void). Shows a preview of every voidable decision (the SHARED voidable_decisions predicate — effective safe-harbor allocations are OMITTED, #7), then requires –yes (or interactive y/N). Each void is NON-REVOCABLE (a VoidDecisionEvent cannot itself be voided — re-apply the original decision to restore). Voiding a LotSelection also re-exposes its disposal to the default method and clears its optimizer attestation.

Fields

§dry_run: bool

Print the preview and exit without writing.

§yes: bool

Skip the interactive confirmation (non-interactive apply).

§

MatchSelfTransfers

Match unreconciled inbound + outbound legs as self-transfers (self-transfer-passthrough C3). With no –in/–out: PREVIEW the proposed pairs (read-only). With –in and –out: confirm ONE pair (DROP for a same-wallet passthrough, RELOCATE for a cross-wallet transfer). NEVER automatic.

Fields

§in_ref: Option<String>

Confirm this in-leg (TransferIn eventref); requires –out.

§out_ref: Option<String>

Confirm this out-leg (TransferOut eventref); requires –in.

§action: Option<SelfTransferActionArg>

Override the suggested action (else the proposal’s topology-derived action is used).

§dry_run: bool

Print the preview and exit without writing (conflicts with –in/–out).

§

Pseudo(Pseudo)

Pseudo-reconcile MODE (sub-project 2): fill deliberately-fictional default decisions at projection time (NEVER persisted) to clear the Hard classification blockers — a loudly-flagged [PSEUDO] on-screen estimate you correct toward truth. on/off toggle the mode; approve promotes chosen defaults to real (attested) decisions.

Trait Implementations§

Source§

impl FromArgMatches for Reconcile

Source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
Source§

fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
Source§

fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>

Assign values from ArgMatches to self.
Source§

fn update_from_arg_matches_mut<'b>( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>

Assign values from ArgMatches to self.
Source§

impl Subcommand for Reconcile

Source§

fn augment_subcommands<'b>(__clap_app: Command) -> Command

Append to Command so it can instantiate Self via FromArgMatches::from_arg_matches_mut Read more
Source§

fn augment_subcommands_for_update<'b>(__clap_app: Command) -> Command

Append to Command so it can instantiate self via FromArgMatches::update_from_arg_matches_mut Read more
Source§

fn has_subcommand(__clap_name: &str) -> bool

Test whether Self can parse a specific subcommand

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V