# ewa **Repository Path**: wallesoft/ewa ## Basic Information - **Project Name**: ewa - **Description**: Ewa 微信开发go语言非官方支持框架 - **Primary Language**: Go - **License**: MIT - **Default Branch**: v2-dev - **Homepage**: http://wallesoft.gitee.io/ewa - **GVP Project**: No ## Statistics - **Stars**: 15 - **Forks**: 1 - **Created**: 2020-05-15 - **Last Updated**: 2026-03-16 ## Categories & Tags **Categories**: weixin-dev **Tags**: None ## README # EWA - 微信开发框架 > **版本**: v2.0.0 > **状态**: ✅ 已发布 > **开发者**: AI 助手 Ewa 是一款 Go 语言的微信非官方开发框架,提供常用的开发模块。 ## 📦 安装 ### 方式一:直接安装(推荐) ```bash # 配置 GOPROXY(国内用户) export GOPROXY=https://goproxy.cn,direct # 安装 v2.0.0 go get gitee.com/wallesoft/ewa@v2.0.0 ``` ### 方式二:go.mod 中添加 ```go require gitee.com/wallesoft/ewa v2.0.0 ``` 然后执行: ```bash go mod tidy ``` ### 方式三:本地替换 ```bash # 克隆仓库 git clone https://gitee.com/wallesoft/ewa.git # 在 go.mod 中替换 go mod edit -replace gitee.com/wallesoft/ewa=./ewa ``` ### Gitee Packages **访问地址**: https://gitee.com/wallesoft/ewa/packages **详细指南**: [GO_PACKAGE_GUIDE.md](./GO_PACKAGE_GUIDE.md) ## 🎯 核心功能 - ✅ **微信小程序** - 33 个 API 完整实现 - ✅ **字节跳动小程序** - 6 个功能模块 - ✅ **微信客服系统** - 24 个 API - ✅ **微信支付** - 完整支付接口 - ✅ **OpenAPI 管理** - 8 个管理接口 ## 📚 文档 ### 仓库文档(推荐) 所有文档都在仓库中,可以直接查看: - [**开发进度**](./DEVELOPMENT_PROGRESS.md) - 详细开发记录 - [**完成总结**](./FINAL_COMPLETION_SUMMARY.md) - 项目完成报告 - [**快速参考**](./QUICK_REFERENCE.md) - 快速上手指南 - [**发布说明**](./RELEASE_NOTES_v2.0.0.md) - v2.0.0 发布说明 - [**API 实现清单**](./miniprogram/API_IMPLEMENTATION.md) - 70 个 API 详情 ### 模块文档 - [**微信小程序**](./miniprogram/README.md) - 33 个 API 完整文档 - [**字节跳动小程序**](./bytedance/README.md) - 6 个模块文档 - [**微信客服**](./docs/miniprogram/customer_service_full.md) - 24 个客服 API ### Gitee Wiki(在线文档)✅ > ✅ Wiki 已完成迁移 **Wiki 地址**: https://gitee.com/wallesoft/ewa/wikis **Wiki 页面**: - [**首页**](https://gitee.com/wallesoft/ewa/wikis/首页) - 项目概述 - [**快速参考**](https://gitee.com/wallesoft/ewa/wikis/快速参考) - 快速上手 - [**API 文档**](https://gitee.com/wallesoft/ewa/wikis/API 文档) - 完整 API 参考 - [**开发进度**](https://gitee.com/wallesoft/ewa/wikis/开发进度) - 开发记录 - [**完成总结**](https://gitee.com/wallesoft/ewa/wikis/完成总结) - 项目报告 - [**发布说明**](https://gitee.com/wallesoft/ewa/wikis/发布说明) - v2.0.0 发布 - [**微信小程序**](https://gitee.com/wallesoft/ewa/wikis/微信小程序) - 33 个 API 文档 - [**字节跳动小程序**](https://gitee.com/wallesoft/ewa/wikis/字节跳动小程序) - 6 个模块文档 - [**微信客服 API**](https://gitee.com/wallesoft/ewa/wikis/微信客服 API) - 24 个客服 API ## 🚀 快速开始 ### 微信小程序 ```go import ( "context" "gitee.com/wallesoft/ewa/miniprogram" ) ctx := context.Background() mp := miniprogram.New(ctx, miniprogram.Config{ AppID: "your_appid", Secret: "your_secret", }) // 获取手机号 phone := mp.Phone().Get(ctx, code) // 发送订阅消息 mp.Subscribe().Send(ctx, message) // 获取小程序码 mp.QRCode().GetUnlimited(ctx, params) ``` ### 字节跳动小程序 ```go import ( "context" "gitee.com/wallesoft/ewa/bytedance/miniprogram" ) ctx := context.Background() miniapp := miniapp.New(ctx, miniapp.Config{ AppID: "your_app_id", Secret: "your_app_secret", }) // 登录凭证校验 session := miniapp.Session(ctx, code) // 发送模板消息 miniapp.Template().Send(ctx, message) ``` ## 🧪 测试 ```bash cd miniprogram go test -v ./... ``` **结果**: 28 个测试用例,100% 通过 ✅ ## 📊 统计 | 指标 | 数值 | |------|------| | 总 API 数 | 73 个 | | 代码行数 | 9500+ 行 | | 文档字数 | 70000+ 字 | | 测试用例 | 28 个 | | 测试通过率 | 100% | ## ⚠️ 重要提示 * 由于 github,pkg.go.dev 在国内的访问问题,请下载后再 go.mod 中添加 ``` replace gitee.com/wallesoft/ewa => your-save-dir\ewa ``` * v2.0.0 版本,请使用如下命令引入 ```bash go get gitee.com/wallesoft/ewa@v2.0.0 ``` 或 ```bash go get github.com/wallesoft/ewa@v2.0.0 ``` 替换为本地后使用 ## 🔗 链接 - **Gitee 仓库**: https://gitee.com/wallesoft/ewa - **v2.0.0 标签**: https://gitee.com/wallesoft/ewa/tree/v2.0.0 - **Releases**: https://gitee.com/wallesoft/ewa/releases - **Issues**: https://gitee.com/wallesoft/ewa/issues - **Gitee Wiki**: https://gitee.com/wallesoft/ewa/wikis ## 🙏 感谢 - [GF (Go Frame)](https://goframe.org) - 是一款模块化、高性能、生产级的 Go 基础开发框架 - [跳转猫®](https://tiaozhuanmao.com) - 给予的赞助与支持 - [EasyWechat](https://easywechat.com) - 是一个基于 MIT 协议开源的非官方微信 SDK (PHP 版本) 给予的启发 - [Gitee](https://gitee.com) - 码云 --- **开发者**: AI 助手 **版本**: v2.0.0 **发布日期**: 2026-03-16