feature/INT-1675 - BACS Direct Debit notifications + refactor - #232
Conversation
🟡 Risk Classification: MINORApproval route: AI Review + Human Approval Classification reasons
Operational gates
Files analysed: 12 wall-e 2026.06.19-02 · policy |
🔬 Debug — why this classification?Each reason code emitted by the classifier, its source clause in the AI in SDLC Control Framework, and what it means.
Kinds:
See issue #3 for the proposal to formalise this map as Appendix A of the standards doc. wall-e 2026.06.19-02 · debug |
🟠 Advisory review: Concerns worth a lookThis PR needs a human approval. Before you give it, these are the things I'd want resolved. Adds Bacs Direct Debit notification support with new models, client, enums, and tests; also refactors SEPA/ACH instrument data structures as breaking changes. The code is generally well-structured, but there are several concrete issues to resolve. Concerns
This is not an approval. wall-e cannot auto-approve this PR — it is an opinion to help whoever does. Advisory review · us.anthropic.claude-sonnet-4-6 · wall-e 2026.06.19-02 |
🟡 Risk Classification: MINORApproval route: AI Review + Human Approval Classification reasons
Operational gates
Files analysed: 12 wall-e 2026.06.19-02 · policy |
🔬 Debug — why this classification?Each reason code emitted by the classifier, its source clause in the AI in SDLC Control Framework, and what it means.
Kinds:
See issue #3 for the proposal to formalise this map as Appendix A of the standards doc. wall-e 2026.06.19-02 · debug |
🟡 Risk Classification: MINORApproval route: AI Review + Human Approval Classification reasons
Operational gates
Files analysed: 12 wall-e 2026.06.19-02 · policy |
🔬 Debug — why this classification?Each reason code emitted by the classifier, its source clause in the AI in SDLC Control Framework, and what it means.
Kinds:
See issue #3 for the proposal to formalise this map as Appendix A of the standards doc. wall-e 2026.06.19-02 · debug |
🟡 Risk Classification: MINORApproval route: AI Review + Human Approval Classification reasons
Operational gates
Files analysed: 13 wall-e 2026.06.19-02 · policy |
🔬 Debug — why this classification?Each reason code emitted by the classifier, its source clause in the AI in SDLC Control Framework, and what it means.
Kinds:
See issue #3 for the proposal to formalise this map as Appendix A of the standards doc. wall-e 2026.06.19-02 · debug |
🟡 Risk Classification: MINORApproval route: AI Review + Human Approval Classification reasons
Operational gates
Files analysed: 14 wall-e 2026.06.19-02 · policy |
🔬 Debug — why this classification?Each reason code emitted by the classifier, its source clause in the AI in SDLC Control Framework, and what it means.
Kinds:
See issue #3 for the proposal to formalise this map as Appendix A of the standards doc. wall-e 2026.06.19-02 · debug |
🟡 Risk Classification: MINORApproval route: AI Review + Human Approval Classification reasons
Operational gates
Files analysed: 16 wall-e 2026.06.19-02 · policy |
🔬 Debug — why this classification?Each reason code emitted by the classifier, its source clause in the AI in SDLC Control Framework, and what it means.
Kinds:
See issue #3 for the proposal to formalise this map as Appendix A of the standards doc. wall-e 2026.06.19-02 · debug |
|



Breaking changes (check at the end
)
This pull request adds comprehensive support for Bacs Direct Debit to the SDK, including new models, client methods, and tests. It introduces the ability to send Bacs pre-notification requests, updates enums and instrument data structures to support Bacs, and adds serialization and integration tests to ensure correctness. The changes also clarify and expand SEPA and ACH instrument handling for consistency.
Bacs Direct Debit Support
BacsNotificationRequestandBacsNotificationTypemodels for Bacs pre-notification requests, with full property validation and documentation.BacsClientwith asend_notificationmethod to POST Bacs notifications, and exposed it via the main API client. [1] [2] [3]RequestBacsSourcefor payment requests using Bacs instruments.Enums and Instrument Data Model Updates
PaymentSourceTypeandInstrumentTypeenums to include Bacs. Added specific enums for Bacs and SEPA payment types, and clarified account holder types. [1] [2] [3]Testing and Serialization
SEPA and ACH Improvements
Minor Fixes and Cleanups
These changes collectively enable robust Bacs Direct Debit support, align SEPA/ACH handling, and ensure the SDK is well-tested for these new capabilities.
Breaking changes


The instruments models were reshaped so that each scheme (SEPA, Bacs, ACH) and each operation has its
own type. Previously a single
InstrumentDataserved both SEPA and ACH, with comments markingwhich attributes belonged to which scheme, and the shared
AccountHolderwas reused on schemas thatdeclare a fraction of its 15 attributes.
Removed classes
checkout_sdk.instruments.instruments.InstrumentDataSepaInstrumentData(SEPA) /AchInstrumentData(ACH)The removed class carried nine attributes across two schemes:
account_number,country,currency,payment_type,mandate_id,date_of_signature,type(SEPA) andaccount_type,bank_code(ACH). All are present on the replacements.Removed attributes
CreateSepaInstrumentRequesttokenStoreSepaInstrumentRequest.CreateBankAccountInstrumentRequestbank_detailsbank. The class already had a correctbankattribute, sobank_detailsserialized under a key the API does not declare. Usebank.UpdateBankAccountInstrumentRequestbank_detailsbank_details, so the bank details could not be sent at all. Renamed tobank.Retyped attributes
CreateSepaInstrumentRequestinstrument_dataInstrumentDataSepaInstrumentDataCreateSepaInstrumentRequestaccount_holderAccountHolder(15 attrs)SepaAccountHolder(5 attrs)CreateAchInstrumentRequestinstrument_dataInstrumentDataAchInstrumentDataCreateAchInstrumentRequestaccount_holderAccountHolder(15 attrs)AchAccountHolder(4 attrs, no billing address)SepaInstrumentDatadate_of_signaturedatetime(on the old class)strChanged enum values
PaymentNetwork— four wire values corrected to the lowercase forms thepayment-networkquery parameter declares. The member names are unchanged, so this is sourcecompatible:
PaymentNetwork.FPS'Fps''fps'PaymentNetwork.ACH'Ach''ach'PaymentNetwork.FEDWIRE'Fedwire''fedwire'PaymentNetwork.SWIFT'Swift''swift'Mitigating fact: the four old values were rejected by the API, so no working integration can have
depended on them. Filtering bank-account fields by FPS, ACH, Fedwire or SWIFT was silently broken
before this change.
Why this is worth a major
Three of these were live defects, not tidying:
payment_typesent a value the API rejects.InstrumentData.payment_typewas typedcheckout_sdk.payments.payments.PaymentType, whose values are capitalised ('Recurring','Regular'). The specification declares the SEPA field lowercase. Anyone following the annotationwas sending a rejected value. Split into
SepaPaymentType(lowercase) andBacsPaymentType(capitalised, which is what Bacs Direct Debit genuinely uses), with a regression test pinning both
so they cannot be unified again.
PaymentNetwork— as above.bank_detailsnever reached the API, and on the update request there was no way to send thebank details at all.
Migration