#Rails
Articles about Rails — exploring patterns, best practices, and real-world implementations in production systems.
16 posts tagged with rails. ← All posts
Model variable recurring payments and metered/subscription billing with proration, treating the mandate — not the retry loop — as the object that actually has state.
Model variable recurring payments and metered/subscription billing with proration, distinct from retry logic.
One reference model of every party in a card transaction — cardholder, merchant, gateway, acquirer/processor, scheme, and issuer — and the settlement path that moves the real money back the other way.
One reference map of who does what in a card payment: cardholder, merchant, gateway, acquirer/processor, scheme, issuer, and the settlement return path.
Route a payment across multiple providers to maximize auth rate, with health-aware routing, failover, and normalized webhooks.
Route a payment across multiple PSPs to maximize auth rate, with health-aware routing, failover, and normalized webhooks.
Name-match the beneficiary before a push payment to stop authorized-push-payment (APP) fraud.
Name-match the beneficiary before a push payment to stop authorized-push-payment (APP) fraud.
Encode and decode EMVCo QR payloads (static vs dynamic), handle expiry, and reconcile QR-initiated payments.
Encode and decode EMVCo QR payloads (static vs dynamic), handle expiry, and reconcile QR-initiated payments.
How R2P flips the pull model into a request-and-approve flow, and the engineering behind mandates, consent, and reconciliation.
How Request to Pay (R2P) messaging works, the standing-mandate lifecycle, consent, and variable recurring payment authorization.
How Original Credit Transactions move money onto a card in near real time — and why pushing is a different animal from pulling.
How OCT/push-to-card (Visa Direct, Mastercard Send) moves money to a card in near real time, eligibility/limits, and reversal handling.
Four protocols, four jobs: how tools, agent-to-agent messaging, and payment rails compose into one buying flow.
How the layers compose: MCP gives an agent tools and context; A2A lets agents talk to each other; AP2/ACP/x402 are the payment rails those agents call when money must move.
How three cryptographically signed mandates turn an agent's purchase into a non-repudiable audit trail.
Google's open Agent Payments Protocol (AP2).
How to engineer SEPA SCT and SDD flows: mandate lifecycle storage, pre-notification timing, FIRST/RCUR sequence types, and the R-transaction taxonomy modeled as an explicit state machine.
Teaches how to engineer SEPA SCT and SDD flows: mandate lifecycle storage, pre-notification timing, FIRST/RCUR sequence types, and the R-transaction taxonomy (reject/return/refund/reversal/revocation) as a state machine.
How to parse legacy MT103/MT202 fields, map them to MX pacs equivalents during coexistence, and thread a gpi UETR end-to-end so a cross-border payment stays trackable across correspondent hops.
Teaches how to parse legacy MT103/MT202 fields, map them to MX pacs equivalents during coexistence, and thread a gpi UETR end-to-end so a cross-border payment is trackable across correspondent hops.
How to engineer for 24x7 irrevocable instant credit — synchronous ISO 20022 messaging, request-for-payment flows, and idempotent liquidity checks with no batch cutoff.
Teaches how to build for 24x7 irrevocable instant credit: synchronous ISO 20022 request/response, request-for-payment (RfP) flows, credit-transfer timeouts, and idempotent liquidity checks at the rail with no batch cutoff.
The 40-year-old tag=value protocol still carrying most of the world's equity orders — and how to build an engine that survives a dropped connection.
How FIX session layer (logon, heartbeat, sequence-number gap-fill, resend) and application layer (NewOrderSingle, ExecutionReport) actually work, and how to build a resilient FIX engine.
How to treat pain, pacs, and camt as one typed, schema-driven domain instead of a pile of XML you concatenate by hand.
Teaches how to model, validate, and generate ISO 20022 XML payment messages (pain.001 initiation, pacs.008 interbank, camt.053 statements) with schema-driven typing, structured references, and idempotent message identifiers.
A field-by-field guide to decoding bitmaps, data elements, and MTI so a raw TCP frame becomes a typed auth request you can trust.
Teaches how to build a byte-level ISO 8583 encoder/decoder: primary/secondary bitmaps, data-element (DE) field definitions, MTI parsing, and stan/RRN correlation for card authorization messaging.
Model the fixed-width record hierarchy, warehouse entries until their effective date, and turn R-series returns into automated re-presentment.
Teaches how to build a NACHA file processor: fixed-width file/batch/entry/addenda record hierarchy, hash totals, effective-entry-date windows, and handling R-series return/NOC codes with automated re-presentment logic.
All posts on this site are written by Pratik Dhanave, an Agentic AI Architect with 7+ years building production distributed systems, multi-agent AI platforms, and cloud-native infrastructure. About the author → Each article includes working code, architecture diagrams, and references to the specific frameworks and standards discussed. Browse all posts or explore related topics using the tag cloud above.