{"id":21452152,"url":"https://github.com/binarywang/weixin-java-pay-demo","last_synced_at":"2025-05-16T08:06:58.737Z","repository":{"id":40633266,"uuid":"83952232","full_name":"binarywang/weixin-java-pay-demo","owner":"binarywang","description":"基于Spring Boot 和 WxJava 实现的微信支付Java后端Demo","archived":false,"fork":false,"pushed_at":"2025-05-14T04:03:32.000Z","size":111,"stargazers_count":927,"open_issues_count":32,"forks_count":480,"subscribers_count":54,"default_branch":"master","last_synced_at":"2025-05-15T14:33:29.865Z","etag":null,"topics":["java","weixin","wxpay"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/binarywang.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":["binarywang"],"custom":"https://github.com/Wechat-Group/WxJava/blob/master/images/qrcodes/wepay.jpg?raw=true"}},"created_at":"2017-03-05T07:14:36.000Z","updated_at":"2025-05-10T06:40:54.000Z","dependencies_parsed_at":"2025-04-19T04:24:17.273Z","dependency_job_id":"7644b34a-e042-40c2-b1d7-dad8cea91582","html_url":"https://github.com/binarywang/weixin-java-pay-demo","commit_stats":{"total_commits":88,"total_committers":2,"mean_commits":44.0,"dds":"0.28409090909090906","last_synced_commit":"f99ca71154b24b7c5df505c1fe3ab1ee8e752fb6"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/binarywang%2Fweixin-java-pay-demo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/binarywang%2Fweixin-java-pay-demo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/binarywang%2Fweixin-java-pay-demo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/binarywang%2Fweixin-java-pay-demo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/binarywang","download_url":"https://codeload.github.com/binarywang/weixin-java-pay-demo/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254493385,"owners_count":22080127,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["java","weixin","wxpay"],"created_at":"2024-11-23T04:27:59.167Z","updated_at":"2025-05-16T08:06:53.723Z","avatar_url":"https://github.com/binarywang.png","language":"Java","readme":"[![码云Gitee](https://gitee.com/binary/weixin-java-pay-demo/badge/star.svg?theme=blue)](https://gitee.com/binary/weixin-java-pay-demo)\n[![Github](http://github-svg-buttons.herokuapp.com/star.svg?user=binarywang\u0026repo=weixin-java-pay-demo\u0026style=flat\u0026background=1081C1)](https://github.com/binarywang/weixin-java-pay-demo)\n[![Build Status](https://travis-ci.org/binarywang/weixin-java-pay-demo.svg?branch=master)](https://travis-ci.org/binarywang/weixin-java-pay-demo)\n-----------------------\n\n#### 本 Demo 基于 `WxJava` 和 `Spring Boot` 构建，演示微信支付后端接口使用方法。\n\n\n\u003ctable align=\"center\" cellspacing=\"0\" cellpadding=\"0\"\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n\t\t\t\u003ctd align=\"left\" valign=\"middle\"\u003e\n        \u003ca href=\"http://mp.weixin.qq.com/mp/homepage?__biz=MzI3MzAwMzk4OA==\u0026hid=1\u0026sn=f31af3bf562b116b061c9ab4edf70b61\u0026scene=18#wechat_redirect\" target=\"_blank\"\u003e\n\t\t\t\t  \u003cimg height=\"120\" src=\"https://gitee.com/binary/weixin-java-tools/raw/develop/images/qrcodes/mp.png\"\u003e\n        \u003c/a\u003e\n\t\t\t\u003c/td\u003e\n\t\t\t\u003ctd align=\"center\" valign=\"middle\"\u003e\n\t\t\t\t\u003ca href=\"https://promotion.aliyun.com/ntms/act/qwbk.html?userCode=7makzf5h\" target=\"_blank\"\u003e\n\t\t\t\t\t\u003cimg height=\"120\" src=\"https://gitee.com/binary/weixin-java-tools/raw/develop/images/banners/aliyun.jpg\"\u003e\n\t\t\t\t\u003c/a\u003e\n\t\t\t\u003c/td\u003e\n\t\t\u003c/tr\u003e\n\t\u003c/tbody\u003e\n\u003c/table\u003e\n\n## 使用步骤：\n1. 新手遇到问题，请务必先阅读[【开发文档首页】](https://github.com/Wechat-Group/WxJava/wiki)的常见问题部分，可以少走很多弯路，节省不少时间。\n1. 如有问题，请到此处提问：https://github.com/binarywang/weixin-java-pay-demo/issues\n1. 配置：复制`/src/main/resources/application.yml.template`或者修改其扩展名生成application.yml文件，并根据自己需要填写相关配置，其中支付相关参数含义请参考WxPayProperties类中的注释（需要注意的是：yml文件内的属性冒号后面的文字之前需要加空格，可参考已有配置，否则属性会设置不成功）；\t\n1. 其中各参数的含义请参考 /src/main/java/com/github/binarywang/demo/wxpay/config/WxPayProperties.java 文件里的注释；\n1. 需要特别注意的，是sub开头的两个参数属于服务商模式使用的，如果是普通模式，请不要配置这两个参数，最好从配置文件中移除相关项；\n1. 查看`WxPayController`类代码，根据自己需要修改调整相关实现；\n1. 运行Java程序：`WxPayDemoApplication`；\n1. 打开网页浏览器，输入想要访问的地址，比如`http://localhost:8080/pay/closeOrder/123`查看效果。\n1. 还可以访问 http://localhost:8080/swagger-ui.html 来查看所有可用接口，并进行在线调试；\n1. 更多接口使用说明，请参考 [wiki 文档](https://github.com/Wechat-Group/weixin-java-tools/wiki/%E5%BE%AE%E4%BF%A1%E6%94%AF%E4%BB%98)\n## 多商户：\n- 请切换分支`multiple`来查看多商户的示例代码。\n","funding_links":["https://github.com/sponsors/binarywang","https://github.com/Wechat-Group/WxJava/blob/master/images/qrcodes/wepay.jpg?raw=true"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbinarywang%2Fweixin-java-pay-demo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbinarywang%2Fweixin-java-pay-demo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbinarywang%2Fweixin-java-pay-demo/lists"}