Skip to content

微信支付:默认使用公钥模式,全部v3接口添加Wechatpay-Serial请求头#3976

Open
buaazyl wants to merge 2 commits intobinarywang:developfrom
buaazyl:develop
Open

微信支付:默认使用公钥模式,全部v3接口添加Wechatpay-Serial请求头#3976
buaazyl wants to merge 2 commits intobinarywang:developfrom
buaazyl:develop

Conversation

@buaazyl
Copy link
Copy Markdown
Contributor

@buaazyl buaazyl commented May 4, 2026

  1. 默认使用公钥模式
  2. 全部v3接口添加Wechatpay-Serial请求头
  3. 调整apiV3秘钥命名
  4. 更新了readme中v2、v3新版文档地址

1.调整apiV3秘钥命名
2.更新了readme中v2、v3新版文档地址
@augmentcode
Copy link
Copy Markdown

augmentcode Bot commented May 4, 2026

🤖 Augment PR Summary

Summary: This PR updates WxJava WeChat Pay (v3) defaults and configuration naming to better align with the newer public-key flow and request header requirements.

Changes:

  • Rename API v3 key property from apiv3Key/apiv3-key to apiV3Key/api-v3-key in Spring Boot starters
  • Default-enable “add Wechatpay-Serial header for all v3 requests” and “full public key mode” in starter properties
  • Wire the renamed property through auto-configuration/multi-service builders and update the related unit test
  • Refresh README references for WeChat Pay v2/v3 documentation URLs

Technical Notes: Spring Boot relaxed binding will now expect api-v3-key (or apiV3Key in YAML) for v3 key configuration; defaults differ depending on whether users construct WxPayConfig directly or rely on starter properties.

🤖 Was this summary useful? React with 👍 or 👎

Copy link
Copy Markdown

@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. 2 suggestions posted.

Fix All in Augment

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

* apiV3秘钥
*/
private String apiv3Key;
private String apiV3Key;
Copy link
Copy Markdown

@augmentcode augmentcode Bot May 4, 2026

Choose a reason for hiding this comment

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

Renaming apiv3Key to apiV3Key is a breaking change for configuration binding: existing configs using wx.pay.apiv3-key will no longer populate this field and can fail at runtime with a missing API v3 key. If upgrades need to be smoother, consider whether a compatibility path (accepting both names) is required.

Severity: high

Other Locations
  • spring-boot-starters/wx-java-pay-multi-spring-boot-starter/src/main/java/com/binarywang/spring/starter/wxjava/pay/properties/WxPaySingleProperties.java:61

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

starter配置和本体使用的配置项命名应该保持一致

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.

1 participant