Repository navigation
fix(payments): align retry types with spec, deprecate top fields - #260
armando-rodriguez-cko wants to merge 2 commits into
Conversation
…fter_days The retry object of POST /payments has no max_attempts or end_after_days; they belong to dunning. Payment sessions now share CustomerRetry from common (the old import path still works). Retry and customer retry fields are documented.
🔴 Risk Classification: MAJORApproval route: AI Review + Human Approval Required Classification reasons
Operational gates
Files analysed: 4 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: Looks good to meThis PR still needs a human approval — wall-e cannot auto-approve it. For what it's worth, I read the diff and found nothing I'd block on. Deprecates top-level What I checked
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: MAJORApproval route: AI Review + Human Approval Required Classification reasons
Operational gates
Files analysed: 4 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 |
|



Summary
Aligns the payment retry request types with the API.
CustomerRetryis now one shared type used by hosted payments, payment links and payment sessions, and the top-levelmax_attemptsandend_after_daysofPaymentRetryRequestare deprecated in favour ofdunning.Changes
checkout_sdk/common/common.py:CustomerRetry(max_attempts, 0 to 5, default 5) now lives here and is documented from the spec.checkout_sdk/payments/sessions/sessions.py: the duplicateCustomerRetryis removed; the module imports the shared one, sopayment_sessions.CustomerRetrykeeps working.checkout_sdk/payments/payments.py:PaymentRetryRequest,DunningRetryRequestandDowntimeRetryRequestdocumented from the spec (required, ranges, defaults). Top-levelmax_attemptsandend_after_daysmarked# Deprecated:; usedunning.max_attemptsanddunning.end_after_days. They still serialize when set and will be removed in the next major version.tests/payments/retry_request_serialization_test.py: every property,enabled=False,max_attempts=0, deprecated fields only when set,PaymentRetryRequestroundtrip with nestedDunningRetryRequestandDowntimeRetryRequest, andCustomerRetryon the three endpoints plus its roundtrip.API Reference
POST /payments(retry): https://api-reference.checkout.com/tag/payments/POST/payments.body.retryPOST /hosted-payments(customer_retry): https://api-reference.checkout.com/tag/hosted-payments-page/POST/hosted-payments.body.customer_retryPOST /payment-links(customer_retry): https://api-reference.checkout.com/tag/payment-links/POST/payment-links.body.customer_retryPOST /payment-sessions(customer_retry): https://api-reference.checkout.com/tag/flow/POST/payment-sessions.body.customer_retryBreaking changes
None. The deprecated fields still serialize when set.
README
Not affected: the README does not document these types.