Skip to content

Add ruleBasedAccountId and report a sweep's depositor as its source - #1069

Merged
bsiaotickchong merged 2 commits into
mainfrom
09-23-rule-based-sweep-source
Sep 23, 2026
Merged

bsiaotickchong merged 2 commits into
mainfrom
09-23-rule-based-sweep-source

Conversation

@bsiaotickchong

@bsiaotickchong bsiaotickchong commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Adds optional ruleBasedAccountId to Transaction, so it appears on both IncomingTransaction and OutgoingTransaction. It's set only on the transaction that sweeps a deposit out of a RULE_BASED account.
  • On those sweep transactions, source is now the party that made the deposit (REALTIME_FUNDING with the originator fields). It used to be an ACCOUNT source pointing at the rule-based account, which is now reported in ruleBasedAccountId instead. When no depositor is known, source falls back to that ACCOUNT source.
  • Documents that the sandbox fund endpoint reports a placeholder ACH depositor on a rule-based sweep.

Example INCOMING_PAYMENT.COMPLETED for a sweep

{
  "source": {
    "sourceType": "REALTIME_FUNDING",
    "currency": "USD",
    "accountHolderName": "NORTHWIND TRADING LLC",
    "accountIdentifier": "****6789",
    "bankName": "Chase Bank",
    "bankIdentifier": "021000021",
    "paymentRail": "ACH",
    "remittanceInformation": "INV 4417",
    "traceNumber": "021000020123456"
  },
  "ruleBasedAccountId": "InternalAccount:019542f5-b3e7-1d02-0000-000000000011",
  "destination": { "destinationType": "ACCOUNT", "accountId": "InternalAccount:019542f5-b3e7-1d02-0000-000000000005" }
}

A given rail fills only one of endToEndId and traceNumber. RTP and FedNow use endToEndId; ACH and wire use traceNumber.

Test plan

  • make build and make lint-openapi are clean.

🤖 Generated with Claude Code

Requested by @bsiaotickchong

📊 PR Presentation · commit 091ce29e68c095d3aaf474fbbd859ff078fd1ba1 · 2026-09-23

Original PR: #1066

…eep's source

A deposit into a RULE_BASED account is reported through the transaction that
sweeps it. That transaction now names the depositor as its REALTIME_FUNDING
source and the rule-based account as ruleBasedAccountId.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

Copy link
Copy Markdown

This stack of pull requests is managed by Graphite. Learn more about stacking.

@greptile-apps

greptile-apps Bot commented Sep 23, 2026

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

The additive schema and documentation changes appear safe to merge.

Summary

This PR extends the shared transaction contract with an optional ruleBasedAccountId for rule-based account sweeps and documents that sweep sources identify the original depositor through REALTIME_FUNDING.

  • Adds the field to both incoming and outgoing transactions through their shared base schema.
  • Documents the sandbox placeholder ACH depositor behavior.
  • Keeps the source OpenAPI definitions and generated root and Mintlify bundles synchronized.
Diagram
%%{init: {'theme': 'neutral'}}%%
flowchart LR
  D[Depositor] --> R[Rule-based account]
  R --> S[Sweep transaction]
  S --> A[Destination account]
  D -. represented by .-> F["source: REALTIME_FUNDING"]
  R -. identified by .-> I["ruleBasedAccountId"]
Loading

Reviews (1) · Last reviewed commit: "Add ruleBasedAccountId to transactions a..."

Co-Authored-By: bsiaotickchong <bsiaotickchong@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@vercel

vercel Bot commented Sep 23, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

3 Skipped Deployments
Project Deployment Actions Updated
grid-cards-demo Ignored Ignored Preview Sep 23, 2026 11:24pm UTC
grid-flow-builder Ignored Ignored Preview Sep 23, 2026 11:24pm UTC
grid-wallet-demo Ignored Ignored Preview Sep 23, 2026 11:24pm UTC

Request Review

@ls-bolt

ls-bolt Bot commented Sep 23, 2026

Copy link
Copy Markdown
Contributor

⚡ Revision log — updated in place, latest first.

Revision 1

  • The ruleBasedAccountId description now says source is the depositor when known and the rule-based account otherwise, per @bsiaotickchong. make build rebundled the spec.

@mintlify

mintlify Bot commented Sep 23, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated
Grid 🟢 Ready View Preview Sep 23, 2026, 11:25 PM

@bsiaotickchong
bsiaotickchong enabled auto-merge (squash) September 23, 2026 23:29
@bsiaotickchong
bsiaotickchong merged commit 46e23ab into main Sep 23, 2026
9 checks passed
@bsiaotickchong
bsiaotickchong deleted the 09-23-rule-based-sweep-source branch September 23, 2026 23:59

This branch was successfully deployed

1 active deployment
staging - mintlify — 4140fef3 Deployed Sep 23, 2026 by mintlify[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants