Agent Sign In

Calculate cross-border FX savings

Machine Tool Interface · calculate-fx-savings
$0.01 / callPaid per call · 0 free tier No signup

Arithmetic comparison of a USDC settlement against comparator percentages YOU supply (bank_fee_pct, custodial_fee_pct) across 14 global fiat currencies. The comparators are assumptions, not measurements of any bank or provider; no protocol fee is deducted on this rail.

Honest Scope Guarantee
Arithmetic comparison of this rail's published fee schedule against comparator rates supplied as inputs (e.g. SWIFT 3.5%, Deel 2.0%). The comparator figures are assumptions you can override, not measurements of your bank.

Quickstart & Execution

cURL (Paid-only route — unauthenticated calls return HTTP 402 Payment Required)
curl -X POST https://api.code402.dev/v1/tools/calculate-fx-savings/call \
  -H "content-type: application/json" \
  -d '{"amount_usdc":50000,"currency":"BRL"}'

This route is paid-only (0 free calls/day); every unauthenticated request returns an HTTP 402 Payment Required challenge with its payment terms. Machines use USDC on Base; card credits (instant Stripe checkout) are enabled in this deployment. Signed XDR-1 receipts authenticate recorded service claims, not independent settlement, delivery or zero-knowledge proofs.

Input Parameters

FieldTypeMeaning & Constraints
amount_usdcnumberGross invoice settlement volume in USD/USDC.
amount_usdnumberGross invoice settlement volume in USD/USDC (alias).
amountnumberGross invoice settlement volume in USD/USDC (alias).
currencystringTarget currency for local comparison (e.g. EUR, GBP, BRL, INR, ARS, PHP, NGN, SGD).

Response Format

Deterministic JSON payload fields: tool, amount_usdc, currency, legacy_swift_fee_usd, deel_fee_usd, code402_protocol_fee_usd, retained_savings_usd, pct_retained, local_currency, scope. Paid responses also carry an offline-verifiable receipt object (XDR-1, secp256k1 signature recoverable to the authorized signer).

Related Conformance Tools

aci-trust-lookup dip-file-dispute pod-verify-delivery csp-commitment-create iso20022-validate iso20022-to-x402-intent iban-check lei-check vat-mod97-check company-number-format swift-bic-check aba-routing-check ein-format-check ifsc-check abn-check gstin-check cnpj-check uscc-check japan-corp-check kra-pin-check rfc-check iso4217-currency-check upi-vpa-check pan-format-check uae-trn-check isin-check sedol-check isbn-check ean13-check luhn-check e164-check pre-disbursement-guard vendor-onboarding-pack rent-deposit-guard rental-listing-risk rental-verdict india-supplier-check china-supplier-check japan-supplier-check latam-supplier-check gulf-supplier-check africa-supplier-check settlement-history-check balance-check erc20-balance tx-activity block-info token-contract-risk ofac-sdn-check simulate-spend-sentinel create-ap2-pilot create-b2b-invoice get-b2b-invoice fx-spot-price-oracle quote-3rd-party-insurance bind-insurance-policy list-approved-insurers batch-validate context-distill crypto-ticker instant-json-schema-verifier clean-markdown-scraper