Skip to content

Appendix — Tonder → Vecnet construct mapping

The complete mapping from Tonder's AWS/NoSQL constructs to their Vecnet/Supabase replacements.

TonderVecnetReference
DynamoDB tables (AccountsTable, JournalsTable, …)Postgres tablesData model
MongoDB (financesJournals, financesFeeRules, …)— (folded into Postgres)no query mirror
DynamoDB PK/SKcolumns + unique constraintsaccounts
process_id-index dedup + IdempotencyTable (120s)unique(process_id, category) + ON CONFLICTIdempotency
AccountUpdateQueue (FIFO) + ADD + version + maxReceiveCount=160one DB transaction + SELECT … FOR UPDATEThe big shift · posting
TransactionEventsQueue (EventBridge→SQS)pgmq / transaction_events + advisory locksIngestion
SettlementJournalsQueueUPDATE … WHERE id = ANY(:ids)Settlements
CloudWatch cronspg_cronRR · Daily ledger
Step Functions (bulk)bulk_jobs + workerM8
S3 reportsSupabase StorageDaily ledger
Lambda + Middy + Inversify + RxJSEdge Functions + Postgres fns; async/await; keep hexagonalTech stack
Platform entity T1V1Rails
tonder/acquirer fee side labelplatform/acquirerFee calc
Acquirers (kushki,unlimit,stp,…)rails (tonder,menta,…)Rails
validateBalance warnsposting fn rejects imbalanceposting
Ledger TTL 15 days + Firehose archivepermanent in Postgres (optional partition/archive)Ledger tables
DetailType/EventBridge taxonomyinternal normalized transaction_eventorchestrator
Legacy flat fee-rule formatunified onlyConfig tables
usrv-batch-transaction-report (AWS Batch/Fargate, Python)Edge Function/worker + pg_cron cycle engineSettlement reports
MongoDB usrv-finances-journals (filter type:"OUT")journals WHERE journal_type='OUT'Settlement reports
mv_payment_transactions (legacy RR view, OLD query)— (greenfield; use ROLLING_RESERVE_RELEASE journals)Settlement reports
SETTLEMENT_LAMBDA_ARN invoke + settlement_jsondirect approve/confirm; positive/absolute amountsSettlement reports
SSM MERCHANT_CONFIG_SETTLEMENT_BATCHsettlement_merchant_config tableSettlement reports
SSM TESTING_CONFIG (default/manual/specific)run-mode parameter (scheduled/manual)Settlement reports
MerchantLogCapture (AWS_BATCH_JOB_ID)settlement_runs + Storage logsSettlement reports
EventBridge cron (Mon/Thu 08:00 UTC batch)pg_cron per cadence (T+0/T+1/T+2)Settlement reports
usrv-settlement (3 handlers, DynamoDB SOR)settlements table + orchestration in SupabaseOrchestration
SettlementTable (PK settlement_id, Retain)settlements table (never hard-delete)Orchestration
calculateForceDecrease (release − finances)same logic + prod-bug warning preservedOrchestration
settlement_type allowlist (isSupportedSettlementType)batch/t1/t2 validationOrchestration
Decimal128 / normalizeDecimalFields / $facet— (Postgres numeric + LIMIT/OFFSET + count() OVER())Orchestration
changeStatusFinancesHandler (sync Lambda invoke)direct call into approve/confirmOrchestration
BatchGateway.submitJob (AWS Batch)trigger cycle run (pg_cron/Edge Function)Settlement reports
S3Gateway.getSignedUrl (presigned)Supabase Storage signed URLsOrchestration
TonderError / ES### codeskeep code taxonomyError codes
Tonder Dashboard metric definitions (Notion)metric catalog, same formulasDashboard
Full attempt stream (declined/failed/pending/expired)transactions tableIngestion
"every metric deduplicated" / payment_intent_iddedup by payment_intent_idDashboard
Cards acceptance vs APM conversion (never blended)separate denominators (rules #1 vs #2)Dashboard
Tonder drop-in / Hosted Checkout + Lite SDK v2.0Vecnet Hosted Checkout; Skyflow elements; checkout_configHosted Checkout
business_business (Tonder merchant collection)merchants registryOperator tables
acquirer config (scattered: SSM, code)rails registry (acquirer-as-plugin)Operator tables
Webhook delivery (ad hoc)webhooks / webhook_deliveries + Webhook ManagerRails integration
operator access / change trackingoperators (RBAC) + audit_logOperator tables

Vecnet — Build Spec v0.2 · Obsidian Terminal