Payments Service

The Payments Service is the FloatMe platform’s authority for all payment execution. It handles fund transfers via pinless debit, RTP and ACH, manages the debit cards and bank accounts used for those transfers, tracks payment statuses through settlement, and enforces fraud controls and payment blocklisting.

What This Service Owns

Domain Responsibility

Payments

Submitting and tracking payments to JPM (subscription ACH) and Usio (float pinless/RTP/ACH, subscription pinless/RTP/ACH). Records all payment outcomes in DynamoDB and publishes status change events to Kinesis.

Payment Syncing

Reconciling ACH payment statuses after initial submission — via JPM webhooks, daily ACH status polling, and Usio transaction syncing.

Debit Cards

Storing and managing tokenized Usio pinless debit/credit tokens. No raw card data is retained (PCI compliant).

Bank Accounts

Storing KMS-encrypted ACH account and routing numbers sourced from Plaid. Used for ACH payment submission.

Prenotes

Submitting zero-dollar ACH transactions to verify bank account validity before the first real ACH payment.

Refunds

Processing Usio refund transactions, including arbitrary amounts not tied to a specific payment record. JPM payments are not refunded through this service.

Blocklist

Automatically blocking users from future payments on specific ACH return codes, and removing blocks when bank accounts are updated.

Fraud

Recording and querying fraud check signals (user ID, install ID, bank account hash, debit card hash) used during payment setup flows.

Lambda Functions

Function Trigger Purpose

prod-payments-service-api

API Gateway (IAM)

Primary REST API — payment submission, debit cards, bank accounts, refunds, prenotes, fraud checks, blocklist management

prod-payments-service-jpm-webhook-handler

API Gateway (webhooks.floatme.io)

Receives JPM payment status callbacks and enqueues them for processing

prod-payments-service-jpm-webhook-processor

SQS (prod-payments-service-jpm-webhooks)

Processes queued JPM webhook events and updates payment records in DynamoDB

prod-payments-service-check-ach-scheduler

EventBridge (daily, 15:30 UTC)

Queries DynamoDB for ACHSENT payments and enqueues them for status polling

prod-payments-service-check-ach-worker

SQS (prod-payments-service-check-ach)

Polls JPM and Usio APIs for ACH payment status; marks payments cleared or returned

prod-payments-service-usio-scheduler

EventBridge (every 30 min, prod only)

Enqueues Usio transaction sync jobs by date range and merchant account. The CloudWatch rule is enabled only when var.environment == "prod", so this Lambda does not fire in test.

prod-payments-service-usio-syncer

SQS (prod-payments-service-usio-sync)

Fetches transactions from the Usio API and stores results in DynamoDB

prod-payments-service-usio-refresh-scheduler

EventBridge (daily, 15:00 UTC)

Enqueues Usio debit card token refresh jobs

prod-payments-service-usio-refresh-worker

SQS (prod-payments-service-usio-refresh)

Refreshes Usio debit/credit tokens and updates DynamoDB

prod-payments-service-prenoter

SQS (prod-payments-service-prenotes)

Submits ACH prenotes to JPM and Usio in batch

prod-payments-service-kinesis-feeder

DynamoDB Streams (prod-payments)

Transforms DynamoDB stream records into structured Kinesis payment events

prod-payments-service-blocklist-handler

Kinesis (prod-payments)

Processes payment events; auto-blocklists users on specific ACH return codes

prod-payments-service-blocklist-remover

SQS (prod-payments-service-blocklist-remove)

Removes users from the blocklist when their bank account is updated

prod-payments-service-balance-reporter

EventBridge (daily 13:00 UTC + hourly)

Reports Usio merchant account balances to Slack

prod-payments-service-jpm-syncer

EventBridge (daily, 13:00 UTC)

Syncs JPM transaction data to DynamoDB

prod-payments-service-debit-card-fixer

SQS (prod-payments-service-debit-fixer)

Repairs debit card records; triggered manually via the scripts/debit-fixer utility

Documentation

See Architecture for external service integrations (JPM, Usio, Plaid, KMS, downstream consumers).