Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 13, 2026

Issue报告 BusinessOperationTransferRequest 缺少必填字段 transfer_scene_idtransfer_scene_report_infos。经验证,这些字段已完整实现,但文档中场景ID示例不正确。

问题

transferSceneId 字段的JavaDoc使用了旧版场景ID示例(1000、1006),而运营工具转账API要求使用2xxx系列场景ID。

改进

更新 transferSceneId 字段注释:

  • 场景ID示例:1000、1006 → 2001(现金营销)、2002(佣金报酬)、2003(推广奖励)
  • 添加 @link 指向 WxPayConstants.OperationSceneId 常量类
/**
 * 转账场景ID
 * 必须,该笔转账使用的转账场景,可前往"商户平台-产品中心-商家转账"中申请。
 * 运营工具场景ID如:2001(现金营销)、2002(佣金报酬)、2003(推广奖励)等
 * 可使用 {@link com.github.binarywang.wxpay.constant.WxPayConstants.OperationSceneId} 中定义的常量
 */
@SerializedName("transfer_scene_id")
private String transferSceneId;

验证

字段实现完整且序列化正确:

  • transferSceneId"transfer_scene_id": "2001"
  • transferSceneReportInfos"transfer_scene_report_infos": [...]
Original prompt

This section details on the original issue you should resolve

<issue_title>发起运营工具商家转账BusinessOperationTransferRequest缺少字段transfer_scene_id、transfer_scene_report_infos字段</issue_title>
<issue_description>搬自gitee:https://gitee.com/binary/weixin-java-tools/issues/IDJKFB

简要描述

发起运营工具商家转账BusinessOperationTransferRequest缺少字段transfer_scene_id、transfer_scene_report_infos字段

模块版本情况

WxJava 模块名: wxpay
WxJava 版本号:4.8.0

详细描述

发起运营工具商家转账BusinessOperationTransferRequest缺少字段transfer_scene_id、transfer_scene_report_infos字段,官方文档为必填字段

日志

com.github.binarywang.wxpay.exception.WxPayException: 输入源“/body/transfer_scene_id”映射到字段“转账场景ID”必填性规则校验失败,此字段为必填项</issue_description>

Comments on the Issue (you are @copilot in this section)

Custom agent used: 全部用中文
需要用中文,包括PR标题和分析总结过程


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: binarywang <1343140+binarywang@users.noreply.github.com>
Copilot AI changed the title [WIP] Add transfer_scene_id and transfer_scene_report_infos fields 更正BusinessOperationTransferRequest中transferSceneId字段的文档注释 Jan 13, 2026
Copilot AI requested a review from binarywang January 13, 2026 10:17
@binarywang binarywang marked this pull request as ready for review January 13, 2026 12:00
Copilot AI review requested due to automatic review settings January 13, 2026 12:00
@augmentcode
Copy link

augmentcode bot commented Jan 13, 2026

🤖 Augment PR Summary

Summary: 修正 BusinessOperationTransferRequest#transferSceneId 的 JavaDoc,更新运营工具转账场景ID示例为 2xxx 系列。

Changes: 补充指向 WxPayConstants.OperationSceneId@link,便于直接使用常量避免填错场景ID。

🤖 Was this summary useful? React with 👍 or 👎

Copy link

@augmentcode augmentcode bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review completed. No suggestions at this time.

Comment augment review to trigger a new review at any time.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

本 PR 修正了 BusinessOperationTransferRequest 类中 transferSceneId 字段的文档注释,将过时的场景ID示例更新为运营工具API所需的正确示例。

Changes:

  • 更新 transferSceneId 字段的JavaDoc注释,将旧版场景ID示例(1000、1006)替换为运营工具专用的2xxx系列场景ID(2001、2002、2003)
  • 添加 @link 引用指向 WxPayConstants.OperationSceneId 常量类,方便开发者使用预定义常量

@binarywang binarywang merged commit 5947f24 into develop Jan 13, 2026
7 checks passed
@binarywang binarywang deleted the copilot/add-missing-transfer-fields branch January 13, 2026 12:08
@binarywang binarywang added this to the 4.8.1 milestone Jan 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

发起运营工具商家转账BusinessOperationTransferRequest缺少字段transfer_scene_id、transfer_scene_report_infos字段

2 participants