Repository navigation
feat(bridge): the sandbox app and console, connected to the Xtradot Bank sandbox - #8
Merged
Merged
Conversation
…ndbox, once, off the request path
…the bank when money moves
… its customers and their history imported
…thing sent for holds or other banks
…ame enquiry when connected
… charges to the kobo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The demo should run in the product's own sandbox app and console, not a separate page. The sandbox app works on Fable's simulated ledger; this connects it to the organizers' Xtradot Bank sandbox for one institution, so the judges see the real bank behind the screens they already know.
What changes
API
services/forge_bridge.py: for the institution inFORGE_BRIDGE_INSTITUTION, every transfer money moves on is also sent to the Xtradot sandbox from the customer's own account there. It runs off the request path, once per transfer, through the existing claim-then-send state machine, so a lost answer is only queried and never resent. Unknown banks and customers without a bank account are recorded as not sent, with the reason.routers/shield.py), a verified flag (routers/transactions.py), and a released hold (agents/ghost/account.py). Holds and flags send nothing until then.services/forge_seed.ensure_bankwithservices/forge_history.py: at startup, whenforge-consoleis set, Xtradot Bank is set up the way a bank is onboarded. That means a sandbox institution, a console owner, and the bank's five customers with 60 days of past transfers to the sandbox's own beneficiaries, all through the console's import service. Customers start with real habits, and their saved recipients are accounts the bank accepts.Web
/api/banksreturns the sandbox's ten banks with their NIP codes, and/api/resolve-accountuses the bank's own name enquiry, both only whenFORGE_BRIDGE=1.BankSettlement: the receipt and the transfer detail page show the bank's answer (status, fee, VAT, stamp duty, total debit to the kobo, reference, and the trail when an answer was lost). It renders nothing for banks that are not connected.Deploy
FORGE_BRIDGE_INSTITUTION=xtradotand the console login from theforge-consolesecret; the site getsFORGE_BRIDGE=1. The runbook has the secret, the restarts, and a demo script.Checked
Not checked