Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
actionbook avatar

Domain Fintech

  • 1.2k installs
  • 1.3k repo stars
  • Updated May 24, 2026
  • actionbook/rust-skills

domain-fintech is an agent skill that encodes fintech domain constraints and idiomatic Rust patterns for developers building auditable trading, ledger, and payment systems without floating-point money bugs.

About

domain-fintech is a Layer 3 domain skill in actionbook/rust-skills for fintech apps in Rust. It translates financial rules—immutable audit trails, no floating-point currency, transaction boundaries, compliance logging, and reproducibility—into concrete Rust design choices such as rust_decimal, Arc immutability, clear ownership, and structured tracing. Developers reach for domain-fintech when implementing money, transactions, exchange rates, ledgers, or accounting logic where precision and auditability matter. The skill is user-invocable false, meant for automatic application when fintech keywords appear in backend Rust work.

  • Enforces rust_decimal instead of f64 for all monetary values
  • Requires immutable records using Arc<T> for audit trails
  • Maps 5 core financial domain rules to concrete Rust design constraints
  • Provides traceable decision tree from constraints to ownership and type-driven patterns
  • Includes bilingual keyword support for global fintech projects

Domain Fintech by the numbers

  • 1,190 all-time installs (skills.sh)
  • +50 installs in the week ending Jul 28, 2026 (Skillselion tracking)
  • Ranked #357 of 4,386 Backend & APIs skills by installs in the Skillselion catalog
  • Security screen: MEDIUM risk (skills.sh audit)
  • Data as of Jul 28, 2026 (Skillselion catalog sync)
npx skills add https://github.com/actionbook/rust-skills --skill domain-fintech

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs1.2k
repo stars1.3k
Security audit3 / 3 scanners passed
Last updatedMay 24, 2026
Repositoryactionbook/rust-skills

How do you handle money safely in Rust fintech apps?

Apply domain-specific financial constraints and Rust patterns when creating accurate, auditable fintech features.

Who is it for?

Rust backend engineers building trading, payment, ledger, or accounting services requiring auditability and decimal precision.

Skip if: Non-financial Rust apps or teams comfortable using f64 for currency without domain guardrails.

When should I use this skill?

User builds fintech, trading, payment, ledger, currency, or exchange-rate features in Rust.

What you get

Rust modules with decimal-safe types, immutable audit trails, transaction boundaries, and compliance logging patterns

  • domain-constrained Rust modules
  • ledger patterns

Files

SKILL.mdMarkdownGitHub ↗

FinTech Domain

Layer 3: Domain Constraints

Domain Constraints → Design Implications

Domain RuleDesign ConstraintRust Implication
Audit trailImmutable recordsArc<T>, no mutation
PrecisionNo floating pointrust_decimal
ConsistencyTransaction boundariesClear ownership
ComplianceComplete loggingStructured tracing
ReproducibilityDeterministic executionNo race conditions

---

Critical Constraints

Financial Precision

RULE: Never use f64 for money
WHY: Floating point loses precision
RUST: Use rust_decimal::Decimal

Audit Requirements

RULE: All transactions must be immutable and traceable
WHY: Regulatory compliance, dispute resolution
RUST: Arc<T> for sharing, event sourcing pattern

Consistency

RULE: Money can't disappear or appear
WHY: Double-entry accounting principles
RUST: Transaction types with validated totals

---

Trace Down ↓

From constraints to design (Layer 2):

"Need immutable transaction records"
    ↓ m09-domain: Model as Value Objects
    ↓ m01-ownership: Use Arc for shared immutable data

"Need precise decimal math"
    ↓ m05-type-driven: Newtype for Currency/Amount
    ↓ rust_decimal: Use Decimal type

"Need transaction boundaries"
    ↓ m12-lifecycle: RAII for transaction scope
    ↓ m09-domain: Aggregate boundaries

---

Key Crates

PurposeCrate
Decimal mathrust_decimal
Date/timechrono, time
UUIDuuid
Serializationserde
Validationvalidator

Design Patterns

PatternPurposeImplementation
Currency newtypeType safetystruct Amount(Decimal);
TransactionAtomic operationsEvent sourcing
Audit logTraceabilityStructured logging with trace IDs
LedgerDouble-entryDebit/credit balance

Code Pattern: Currency Type

use rust_decimal::Decimal;

#[derive(Clone, Debug, PartialEq)]
pub struct Amount {
    value: Decimal,
    currency: Currency,
}

impl Amount {
    pub fn new(value: Decimal, currency: Currency) -> Self {
        Self { value, currency }
    }

    pub fn add(&self, other: &Amount) -> Result<Amount, CurrencyMismatch> {
        if self.currency != other.currency {
            return Err(CurrencyMismatch);
        }
        Ok(Amount::new(self.value + other.value, self.currency))
    }
}

---

Common Mistakes

MistakeDomain ViolationFix
Using f64Precision lossrust_decimal
Mutable transactionAudit trail brokenImmutable + events
String for amountNo validationValidated newtype
Silent overflowMoney disappearsChecked arithmetic

---

Trace to Layer 1

ConstraintLayer 2 PatternLayer 1 Implementation
Immutable recordsEvent sourcingArc<T>, Clone
Transaction scopeAggregateOwned children
PrecisionValue Objectrust_decimal newtype
Thread-safe sharingShared immutableArc (not Rc)

---

Related Skills

WhenSee
Value Object designm09-domain
Ownership for immutablem01-ownership
Arc for sharingm02-resource
Error handlingm13-domain-error

Related skills

FAQ

Why does domain-fintech ban floating point?

domain-fintech enforces rust_decimal for currency because f64 rounding breaks financial accuracy. The skill maps precision domain rules directly to decimal types and explicit rounding policies in Rust services.

What Rust patterns does domain-fintech recommend?

domain-fintech recommends Arc<T> immutability for audit trails, clear ownership for transaction boundaries, rust_decimal for money, and structured tracing for compliance logging in fintech backends.

Is Domain Fintech safe to install?

skills.sh reports 3 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.

Backend & APIsagentsautomation

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.