{"data":{"id":"magento2-39297","source":"github-pr","sourceRef":"magento/magento2#39297","title":"Fix offline invoice capture (404)","pr":{"number":39297,"url":"https://github.com/magento/magento2/pull/39297","author":"nige-one","mergedAt":"2025-04-25T14:52:43Z","mergeCommit":"ede68ec659488d986c091bcbfed7616f710640d1","headCommit":"7db9b4ce1238d09cb3458685f34540f51dce701c","baseRef":"2.4-develop","diffSha256":"e8143899eb31171caea1518e1c2ade1d38cb375c1c2295d7cd9bf056bb0f99bf"},"issues":[{"number":39298,"url":"https://github.com/magento/magento2/issues/39298","title":"[Issue] Fix offline invoice capture (404)","labels":["Area: Payments","Component: OfflinePayments","Issue: Confirmed","Priority: P2","Progress: PR in progress","Progress: done","Reported on 2.4.x","Reproduced on 2.4.x","Triage: Dev.Experience"],"kind":"pr-derived"}],"fixedIn":"2.4.9","containingTags":["2.4.9"],"reportedOn":null,"codeMatch":{"2.4.6":"conflict","2.4.6-p1":"conflict","2.4.6-p2":"conflict","2.4.6-p3":"conflict","2.4.6-p4":"conflict","2.4.6-p5":"conflict","2.4.6-p6":"conflict","2.4.6-p7":"conflict","2.4.6-p8":"clean","2.4.6-p9":"clean","2.4.6-p10":"clean","2.4.6-p11":"clean","2.4.6-p12":"clean","2.4.6-p13":"clean","2.4.6-p14":"clean","2.4.6-p15":"clean","2.4.7":"conflict","2.4.7-p1":"conflict","2.4.7-p2":"conflict","2.4.7-p3":"clean","2.4.7-p4":"clean","2.4.7-p5":"clean","2.4.7-p6":"clean","2.4.7-p7":"clean","2.4.7-p8":"clean","2.4.7-p9":"clean","2.4.7-p10":"clean","2.4.8":"clean","2.4.8-p1":"clean","2.4.8-p2":"clean","2.4.8-p3":"clean","2.4.8-p4":"clean","2.4.8-p5":"clean","2.4.9":"conflict"},"affectedVersions":["2.4.6-p8","2.4.6-p9","2.4.6-p10","2.4.6-p11","2.4.6-p12","2.4.6-p13","2.4.6-p14","2.4.6-p15","2.4.7-p3","2.4.7-p4","2.4.7-p5","2.4.7-p6","2.4.7-p7","2.4.7-p8","2.4.7-p9","2.4.7-p10","2.4.8","2.4.8-p1","2.4.8-p2","2.4.8-p3","2.4.8-p4","2.4.8-p5"],"components":["magento/module-sales"],"files":[{"path":"app/code/Magento/Sales/Controller/Adminhtml/Order/Invoice/Capture.php","change":"modified","package":"magento/module-sales"}],"stripped":{"tests":[],"docs":[],"outsideCode":[]},"linesChanged":9,"mergeBatched":false,"excluded":null,"sections":{"description":"It's not possible to capture offline payment method invoices via the backend ('Capture' button). Trying it will lead to a 404.","stepsToReproduce":"1. create an order with an offline payment method\n2. create an invoice for the order (offline)\n3. capture the invoice\n\n\n### Resolved issues:\n1. [x] resolves magento/magento2#39298: Fix offline invoice capture (404)","expectedResult":null,"actualResult":null,"source":"pr"},"signatures":[],"labels":{"area":["Payments"],"component":["OfflinePayments"],"priority":"P2","severity":null,"reportedOn":["2.4.x"]},"categories":["Payments"],"triage":{"model":"@cf/cloudflare/clef","requestHash":"8a78ddebb00a92767abfc870ccae3fcaeaa68255982a3bf36de180b0228be97c","isBugfix":0.9747,"changeKind":{"choice":"bugfix","probabilities":{"bugfix":0.9609,"feature":0.0045,"refactor":0.0241,"tests_only":0.0043,"docs_only":0.0031,"dependency":0.0031},"confidence":0.9088},"scope":{"score":0.3926,"probabilities":{"0":0.6531,"1":0.3012,"2":0.0457},"confidence":0.279},"risk":{"score":0.2418,"probabilities":{"0":0.8214,"1":0.1154,"2":0.0632},"confidence":0.538},"area":{"choice":"checkout","probabilities":{"catalog":0.0063,"checkout":0.6103,"customer":0.0065,"admin":0.3225,"graphql_api":0.0073,"framework":0.0238,"frontend":0.0076,"other":0.0157},"confidence":0.4028},"securityRelevant":0.1476,"reportedVersion":{"choice":"unspecified","probabilities":{"2.4.0":0.0039,"2.4.0-p1":0.0045,"2.4.1":0.0054,"2.4.1-p1":0.0042,"2.4.2":0.0074,"2.4.2-p1":0.0074,"2.4.2-p2":0.0109,"2.4.3":0.0132,"2.4.3-p1":0.0136,"2.4.3-p2":0.0141,"2.4.3-p3":0.007,"2.4.4":0.0131,"2.4.4-p1":0.0113,"2.4.4-p10":0.0061,"2.4.4-p11":0.0086,"2.4.4-p12":0.0065,"2.4.4-p13":0.0063,"2.4.4-p14":0.0072,"2.4.4-p15":0.0055,"2.4.4-p16":0.0066,"2.4.4-p17":0.0059,"2.4.4-p18":0.0045,"2.4.4-p2":0.0025,"2.4.4-p3":0.0029,"2.4.4-p4":0.003,"2.4.4-p5":0.0033,"2.4.4-p6":0.0052,"2.4.4-p7":0.0046,"2.4.4-p8":0.0052,"2.4.4-p9":0.0039,"2.4.5":0.0182,"2.4.5-p1":0.0135,"2.4.5-p10":0.0079,"2.4.5-p11":0.0131,"2.4.5-p12":0.0092,"2.4.5-p13":0.0079,"2.4.5-p14":0.0083,"2.4.5-p15":0.0072,"2.4.5-p16":0.0073,"2.4.5-p17":0.0072,"2.4.5-p2":0.0036,"2.4.5-p3":0.0048,"2.4.5-p4":0.0058,"2.4.5-p5":0.0046,"2.4.5-p6":0.0052,"2.4.5-p7":0.0054,"2.4.5-p8":0.0043,"2.4.5-p9":0.0042,"2.4.6":0.0376,"2.4.6-p1":0.0206,"2.4.6-p10":0.0094,"2.4.6-p11":0.0107,"2.4.6-p12":0.0098,"2.4.6-p13":0.0093,"2.4.6-p14":0.0097,"2.4.6-p15":0.007,"2.4.6-p2":0.0044,"2.4.6-p3":0.0073,"2.4.6-p4":0.0085,"2.4.6-p5":0.0067,"2.4.6-p6":0.0077,"2.4.6-p7":0.0075,"2.4.6-p8":0.0058,"2.4.6-p9":0.0048,"2.4.7":0.0189,"2.4.7-p1":0.0149,"2.4.7-p10":0.0086,"2.4.7-p2":0.0085,"2.4.7-p3":0.0111,"2.4.7-p4":0.0133,"2.4.7-p5":0.0114,"2.4.7-p6":0.0115,"2.4.7-p7":0.0127,"2.4.7-p8":0.0086,"2.4.7-p9":0.0057,"2.4.8":0.0229,"2.4.8-p1":0.0157,"2.4.8-p2":0.0176,"2.4.8-p3":0.0155,"2.4.8-p4":0.015,"2.4.8-p5":0.0133,"2.4.9":0.0161,"unspecified":0.2504},"confidence":0.0607},"backportWorthy":{"score":1.7603,"probabilities":{"0":0.044,"1":0.1517,"2":0.8043},"confidence":0.5077}},"curated":{"title":"Fixes the 404 when capturing an offline payment invoice in the admin","description":"It's not possible to capture offline payment method invoices via the backend ('Capture' button): trying it will lead to a 404. The button sends a GET request, but the Capture controller implements HttpPostActionInterface, so the request validator expects a POST request. The Capture class now implements HttpGetActionInterface.","categories":["Payments"],"author":"claude-code/opus-5.5","date":"2026-10-06","reviewedBy":null},"tests":null},"_documentation":"https://magento.watch/api","_description":"Upstream fix magento2-39297 details"}