34 changed files with 1837 additions and 36 deletions
@ -0,0 +1,40 @@ |
|||
# LINGYUN.Abp.Identity.WeChat.Work |
|||
|
|||
WeChat Work (Enterprise WeChat) user identity integration module, providing integration between WeChat Work users and the ABP Identity system. |
|||
|
|||
## Features |
|||
|
|||
* WeChat Work user identity integration |
|||
* Support synchronizing WeChat Work user information to Identity system |
|||
* Support WeChat Work organizational structure synchronization |
|||
* Support automatic user creation |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpIdentityWeChatWorkModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"Identity": { |
|||
"WeChat": { |
|||
"Work": { |
|||
"CreateUserIfNotExist": true, // Whether to automatically create user if not exists |
|||
"UpdateUserIfExist": true, // Whether to update user information if exists |
|||
"SyncOrganizationUnit": true // Whether to sync organizational structure |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,40 @@ |
|||
# LINGYUN.Abp.Identity.WeChat.Work |
|||
|
|||
企业微信用户身份集成模块,提供企业微信用户与ABP Identity系统的集成功能。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 企业微信用户身份集成 |
|||
* 支持企业微信用户信息同步到Identity系统 |
|||
* 支持企业微信组织架构同步 |
|||
* 支持自动创建用户 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpIdentityWeChatWorkModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 配置项 |
|||
|
|||
```json |
|||
{ |
|||
"Identity": { |
|||
"WeChat": { |
|||
"Work": { |
|||
"CreateUserIfNotExist": true, // 用户不存在时是否自动创建 |
|||
"UpdateUserIfExist": true, // 用户存在时是否更新信息 |
|||
"SyncOrganizationUnit": true // 是否同步组织架构 |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## 更多文档 |
|||
|
|||
* [企业微信用户身份集成文档](README.EN.md) |
|||
@ -0,0 +1,37 @@ |
|||
# LINGYUN.Abp.Identity.WeChat |
|||
|
|||
WeChat user identity integration module, providing integration between WeChat users and the ABP Identity system. |
|||
|
|||
## Features |
|||
|
|||
* WeChat user identity integration |
|||
* Support synchronizing WeChat user information to Identity system |
|||
* Support for WeChat UnionId mechanism |
|||
* Support automatic user creation |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpIdentityWeChatModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"Identity": { |
|||
"WeChat": { |
|||
"CreateUserIfNotExist": true, // Whether to automatically create user if not exists |
|||
"UpdateUserIfExist": true // Whether to update user information if exists |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,37 @@ |
|||
# LINGYUN.Abp.Identity.WeChat |
|||
|
|||
微信用户身份集成模块,提供微信用户与ABP Identity系统的集成功能。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 微信用户身份集成 |
|||
* 支持微信用户信息同步到Identity系统 |
|||
* 支持微信UnionId机制 |
|||
* 支持自动创建用户 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpIdentityWeChatModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 配置项 |
|||
|
|||
```json |
|||
{ |
|||
"Identity": { |
|||
"WeChat": { |
|||
"CreateUserIfNotExist": true, // 用户不存在时是否自动创建 |
|||
"UpdateUserIfExist": true // 用户存在时是否更新信息 |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## 更多文档 |
|||
|
|||
* [微信用户身份集成文档](README.EN.md) |
|||
@ -0,0 +1,41 @@ |
|||
# LINGYUN.Abp.Notifications.WeChat.MiniProgram |
|||
|
|||
WeChat Mini Program notification module, providing functionality to send subscription messages to users through WeChat Mini Program. |
|||
|
|||
## Features |
|||
|
|||
* Support WeChat Mini Program subscription message sending |
|||
* Support message template management |
|||
* Support dynamic message data configuration |
|||
* Integration with ABP notification system |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpNotificationsWeChatMiniProgramModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"MiniProgram": { |
|||
"Notifications": { |
|||
"DefaultTemplateId": "", // Default template ID |
|||
"DefaultPage": "pages/index/index", // Default jump page |
|||
"DefaultState": "formal", // Default Mini Program version type: developer/trial/formal |
|||
"DefaultLang": "zh_CN" // Default language |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,41 @@ |
|||
# LINGYUN.Abp.Notifications.WeChat.MiniProgram |
|||
|
|||
微信小程序消息通知模块,提供通过微信小程序向用户发送订阅消息的功能。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 支持微信小程序订阅消息发送 |
|||
* 支持消息模板管理 |
|||
* 支持动态消息数据配置 |
|||
* 集成ABP通知系统 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpNotificationsWeChatMiniProgramModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 配置项 |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"MiniProgram": { |
|||
"Notifications": { |
|||
"DefaultTemplateId": "", // 默认模板ID |
|||
"DefaultPage": "pages/index/index", // 默认跳转页面 |
|||
"DefaultState": "formal", // 默认跳转小程序类型,developer为开发版;trial为体验版;formal为正式版 |
|||
"DefaultLang": "zh_CN" // 默认语言 |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## 更多文档 |
|||
|
|||
* [微信小程序消息通知文档](README.EN.md) |
|||
@ -0,0 +1,49 @@ |
|||
# LINGYUN.Abp.Notifications.WeChat.Work |
|||
|
|||
WeChat Work (Enterprise WeChat) application message notification module, providing functionality to send messages to users through WeChat Work applications. |
|||
|
|||
## Features |
|||
|
|||
* Support WeChat Work application message sending |
|||
* Support text messages |
|||
* Support image messages |
|||
* Support voice messages |
|||
* Support video messages |
|||
* Support file messages |
|||
* Support news messages |
|||
* Support template card messages |
|||
* Integration with ABP notification system |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpNotificationsWeChatWorkModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Work": { |
|||
"Notifications": { |
|||
"DefaultAgentId": 0, // Default application ID |
|||
"DefaultToParty": "", // Default department ID list to receive messages |
|||
"DefaultToTag": "", // Default tag ID list to receive messages |
|||
"DefaultSafe": 0, // Default indicator for confidential messages, 0: shareable, 1: non-shareable with watermark |
|||
"DefaultEnableIdTrans": 0, // Default indicator for ID translation, 0: disabled, 1: enabled |
|||
"DefaultEnableDuplicateCheck": 0, // Default indicator for duplicate message check, 0: disabled, 1: enabled |
|||
"DefaultDuplicateCheckInterval": 1800 // Default interval for duplicate message check in seconds |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,49 @@ |
|||
# LINGYUN.Abp.Notifications.WeChat.Work |
|||
|
|||
企业微信应用消息通知模块,提供通过企业微信应用向用户发送消息的功能。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 支持企业微信应用消息发送 |
|||
* 支持文本消息 |
|||
* 支持图片消息 |
|||
* 支持语音消息 |
|||
* 支持视频消息 |
|||
* 支持文件消息 |
|||
* 支持图文消息 |
|||
* 支持模板卡片消息 |
|||
* 集成ABP通知系统 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpNotificationsWeChatWorkModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 配置项 |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Work": { |
|||
"Notifications": { |
|||
"DefaultAgentId": 0, // 默认应用ID |
|||
"DefaultToParty": "", // 默认接收消息的部门ID列表 |
|||
"DefaultToTag": "", // 默认接收消息的标签ID列表 |
|||
"DefaultSafe": 0, // 默认表示是否是保密消息,0表示可对外分享,1表示不能分享且内容显示水印 |
|||
"DefaultEnableIdTrans": 0, // 默认表示是否开启id转译,0表示否,1表示是 |
|||
"DefaultEnableDuplicateCheck": 0, // 默认表示是否开启重复消息检查,0表示否,1表示是 |
|||
"DefaultDuplicateCheckInterval": 1800 // 默认表示重复消息检查的时间间隔,默认1800秒 |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## 更多文档 |
|||
|
|||
* [企业微信应用消息通知文档](README.EN.md) |
|||
@ -0,0 +1,51 @@ |
|||
# LINGYUN.Abp.WeChat.Common |
|||
|
|||
WeChat common module, providing shared fundamental functionality implementation for WeChat product lines. |
|||
|
|||
## Features |
|||
|
|||
* Unified message handling framework |
|||
* Unified message encryption/decryption mechanism |
|||
* Unified event handling mechanism |
|||
* Unified API calling interface |
|||
* Unified error handling mechanism |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatCommonModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Common": { |
|||
"MessageHandlerFactory": { |
|||
"MessageResolvers": [], // Message resolver list |
|||
"MessageHandlers": [] // Message handler list |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## Message Handling |
|||
|
|||
* Support text message handling |
|||
* Support image message handling |
|||
* Support voice message handling |
|||
* Support video message handling |
|||
* Support event message handling |
|||
* Support custom message handler extensions |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
|
|||
### Change Log |
|||
@ -1,30 +1,50 @@ |
|||
# LINGYUN.Abp.WeChat.Common |
|||
|
|||
## 模块说明 |
|||
微信通用模块,提供微信产品线共享的基础功能实现。 |
|||
|
|||
由于微信体系众多产品部分功能有共同点, 抽象一个通用模块, 实现一些通用的接口. |
|||
## 功能特性 |
|||
|
|||
### 基础模块 |
|||
* 统一的消息处理框架 |
|||
* 统一的消息加解密机制 |
|||
* 统一的事件处理机制 |
|||
* 统一的API调用接口 |
|||
* 统一的错误处理机制 |
|||
|
|||
### 高阶模块 |
|||
## 模块引用 |
|||
|
|||
### 权限定义 |
|||
|
|||
### 功能定义 |
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatCommonModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
} |
|||
``` |
|||
|
|||
### 配置定义 |
|||
## 配置项 |
|||
|
|||
### 如何使用 |
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Common": { |
|||
"MessageHandlerFactory": { |
|||
"MessageResolvers": [], // 消息解析器列表 |
|||
"MessageHandlers": [] // 消息处理器列表 |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## 消息处理 |
|||
|
|||
```csharp |
|||
* 支持文本消息处理 |
|||
* 支持图片消息处理 |
|||
* 支持语音消息处理 |
|||
* 支持视频消息处理 |
|||
* 支持事件消息处理 |
|||
* 支持自定义消息处理器扩展 |
|||
|
|||
[DependsOn( |
|||
typeof(AbpWeChatCommonModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
} |
|||
## 更多文档 |
|||
|
|||
``` |
|||
* [微信通用模块文档](README.EN.md) |
|||
|
|||
### 更新日志 |
|||
|
|||
@ -0,0 +1,58 @@ |
|||
# LINGYUN.Abp.WeChat.MiniProgram |
|||
|
|||
WeChat Mini Program SDK integration module, providing necessary functionality support for WeChat Mini Program development. |
|||
|
|||
## Features |
|||
|
|||
* WeChat Mini Program login authentication |
|||
* Mini Program QR code generation |
|||
* Subscription message sending |
|||
* Mini Program data statistics |
|||
* Mini Program live streaming |
|||
* Mini Program payment integration |
|||
* Unified service messaging |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatMiniProgramModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"MiniProgram": { |
|||
"AppId": "", // Mini Program AppId |
|||
"AppSecret": "", // Mini Program AppSecret |
|||
"Token": "", // Mini Program message Token |
|||
"EncodingAESKey": "", // Mini Program message encryption key |
|||
"IsDebug": false, // Whether to enable debug mode |
|||
"DefaultEnvironment": "release" // Default environment, options: develop/trial/release |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
#### Important Note |
|||
|
|||
There is a known issue with dynamic configuration: https://github.com/abpframework/abp/issues/6318 |
|||
Therefore, you must use AbpWeChatMiniProgramOptionsFactory.CreateAsync() to dynamically change AbpWeChatMiniProgramOptions. |
|||
|
|||
## Settings Configuration |
|||
|
|||
* `WeChat.MiniProgram.AppId`: Mini Program AppId |
|||
* `WeChat.MiniProgram.AppSecret`: Mini Program AppSecret |
|||
* `WeChat.MiniProgram.Token`: Mini Program message Token |
|||
* `WeChat.MiniProgram.EncodingAESKey`: Mini Program message encryption key |
|||
* `WeChat.MiniProgram.IsDebug`: Whether to enable debug mode |
|||
* `WeChat.MiniProgram.DefaultEnvironment`: Default environment |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,58 @@ |
|||
# LINGYUN.Abp.WeChat.Official.Handlers |
|||
|
|||
WeChat Official Account message handling module, providing basic implementation for WeChat Official Account message and event handling. |
|||
|
|||
## Features |
|||
|
|||
* Text message handling |
|||
* Image message handling |
|||
* Voice message handling |
|||
* Video message handling |
|||
* Short video message handling |
|||
* Location message handling |
|||
* Link message handling |
|||
* Subscribe/Unsubscribe event handling |
|||
* QR code scan event handling |
|||
* Location report event handling |
|||
* Custom menu event handling |
|||
* Template message event handling |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatOfficialHandlersModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Official": { |
|||
"Handlers": { |
|||
"DefaultResponseType": "text", // Default response type: text/image/voice/video/music/news |
|||
"DefaultResponse": "", // Default response content |
|||
"EnableDefaultResponse": true // Whether to enable default response |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## Custom Handlers |
|||
|
|||
To implement custom message handlers, inherit from the corresponding base class: |
|||
|
|||
* Text message: `WeChatOfficialTextMessageHandlerBase` |
|||
* Image message: `WeChatOfficialImageMessageHandlerBase` |
|||
* Voice message: `WeChatOfficialVoiceMessageHandlerBase` |
|||
* Video message: `WeChatOfficialVideoMessageHandlerBase` |
|||
* Event message: `WeChatOfficialEventMessageHandlerBase` |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,58 @@ |
|||
# LINGYUN.Abp.WeChat.Official.Handlers |
|||
|
|||
微信公众号消息处理模块,提供微信公众号消息和事件处理的基础实现。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 文本消息处理 |
|||
* 图片消息处理 |
|||
* 语音消息处理 |
|||
* 视频消息处理 |
|||
* 小视频消息处理 |
|||
* 地理位置消息处理 |
|||
* 链接消息处理 |
|||
* 关注/取消关注事件处理 |
|||
* 扫描带参数二维码事件处理 |
|||
* 上报地理位置事件处理 |
|||
* 自定义菜单事件处理 |
|||
* 模板消息事件处理 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatOfficialHandlersModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 配置项 |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Official": { |
|||
"Handlers": { |
|||
"DefaultResponseType": "text", // 默认响应类型:text/image/voice/video/music/news |
|||
"DefaultResponse": "", // 默认响应内容 |
|||
"EnableDefaultResponse": true // 是否启用默认响应 |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## 自定义处理器 |
|||
|
|||
要实现自定义消息处理器,需要继承相应的基类: |
|||
|
|||
* 文本消息:`WeChatOfficialTextMessageHandlerBase` |
|||
* 图片消息:`WeChatOfficialImageMessageHandlerBase` |
|||
* 语音消息:`WeChatOfficialVoiceMessageHandlerBase` |
|||
* 视频消息:`WeChatOfficialVideoMessageHandlerBase` |
|||
* 事件消息:`WeChatOfficialEventMessageHandlerBase` |
|||
|
|||
## 更多文档 |
|||
|
|||
* [微信公众号消息处理模块文档](README.EN.md) |
|||
@ -0,0 +1,54 @@ |
|||
# LINGYUN.Abp.WeChat.Official.Senparc |
|||
|
|||
WeChat Official Account Senparc SDK integration module, providing integration support with Senparc.Weixin SDK. |
|||
|
|||
## Features |
|||
|
|||
* Senparc.Weixin SDK integration |
|||
* Compatible with Senparc message handling mechanism |
|||
* Compatible with Senparc event handling mechanism |
|||
* Support for Senparc configuration system |
|||
* Support for Senparc caching strategy |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatOfficialSenparcModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Official": { |
|||
"Senparc": { |
|||
"IsEnabled": true, // Whether to enable Senparc integration |
|||
"Cache": { |
|||
"Type": "Local", // Cache type: Local/Redis/Memcached |
|||
"Configuration": "" // Cache configuration string |
|||
} |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## Senparc Compatibility |
|||
|
|||
This module maintains compatibility with Senparc.Weixin SDK, allowing you to: |
|||
|
|||
* Use Senparc message handlers |
|||
* Use Senparc event handlers |
|||
* Use Senparc API calling methods |
|||
* Use Senparc caching mechanism |
|||
* Use Senparc extension features |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
* [Senparc.Weixin SDK Documentation](https://github.com/JeffreySu/WeiXinMPSDK) |
|||
@ -0,0 +1,54 @@ |
|||
# LINGYUN.Abp.WeChat.Official.Senparc |
|||
|
|||
微信公众号Senparc SDK集成模块,提供与Senparc.Weixin SDK的集成支持。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* Senparc.Weixin SDK集成 |
|||
* 兼容Senparc消息处理机制 |
|||
* 兼容Senparc事件处理机制 |
|||
* 支持Senparc配置体系 |
|||
* 支持Senparc缓存策略 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatOfficialSenparcModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 配置项 |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Official": { |
|||
"Senparc": { |
|||
"IsEnabled": true, // 是否启用Senparc集成 |
|||
"Cache": { |
|||
"Type": "Local", // 缓存类型:Local/Redis/Memcached |
|||
"Configuration": "" // 缓存配置字符串 |
|||
} |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## Senparc兼容性 |
|||
|
|||
本模块与Senparc.Weixin SDK保持兼容,可以: |
|||
|
|||
* 使用Senparc的消息处理器 |
|||
* 使用Senparc的事件处理器 |
|||
* 使用Senparc的API调用方式 |
|||
* 使用Senparc的缓存机制 |
|||
* 使用Senparc的扩展功能 |
|||
|
|||
## 更多文档 |
|||
|
|||
* [微信公众号Senparc集成模块文档](README.EN.md) |
|||
* [Senparc.Weixin SDK文档](https://github.com/JeffreySu/WeiXinMPSDK) |
|||
@ -0,0 +1,60 @@ |
|||
# LINGYUN.Abp.WeChat.Official |
|||
|
|||
WeChat Official Account SDK integration module, providing necessary functionality support for WeChat Official Account development. |
|||
|
|||
## Features |
|||
|
|||
* WeChat Official Account OAuth2.0 authentication |
|||
* Custom menu management |
|||
* Template message sending |
|||
* Media management |
|||
* User management |
|||
* Customer service messaging |
|||
* WeChat payment integration |
|||
* Message encryption/decryption |
|||
* Event handling |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatOfficialModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Official": { |
|||
"AppId": "", // Official Account AppId |
|||
"AppSecret": "", // Official Account AppSecret |
|||
"Token": "", // Official Account message Token |
|||
"EncodingAESKey": "", // Official Account message encryption key |
|||
"IsSandBox": false, // Whether in sandbox environment |
|||
"Url": "" // Official Account server URL |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
#### Important Note |
|||
|
|||
There is a known issue with dynamic configuration: https://github.com/abpframework/abp/issues/6318 |
|||
Therefore, you must use AbpWeChatOfficialOptionsFactory.CreateAsync() to dynamically change AbpWeChatOfficialOptions. |
|||
|
|||
## Settings Configuration |
|||
|
|||
* `WeChat.Official.AppId`: Official Account AppId |
|||
* `WeChat.Official.AppSecret`: Official Account AppSecret |
|||
* `WeChat.Official.Token`: Official Account message Token |
|||
* `WeChat.Official.EncodingAESKey`: Official Account message encryption key |
|||
* `WeChat.Official.IsSandBox`: Whether in sandbox environment |
|||
* `WeChat.Official.Url`: Official Account server URL |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,61 @@ |
|||
# LINGYUN.Abp.WeChat.SettingManagement |
|||
|
|||
WeChat settings management module, providing management functionality for WeChat-related configurations. |
|||
|
|||
## Features |
|||
|
|||
* WeChat configuration management |
|||
* Official Account configuration management |
|||
* Mini Program configuration management |
|||
* WeChat Work configuration management |
|||
* Configuration UI integration |
|||
* Multi-tenant support |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatSettingManagementModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Settings Configuration |
|||
|
|||
### Official Account Configuration |
|||
|
|||
* `WeChat.Official.AppId`: Official Account AppId |
|||
* `WeChat.Official.AppSecret`: Official Account AppSecret |
|||
* `WeChat.Official.Token`: Official Account message Token |
|||
* `WeChat.Official.EncodingAESKey`: Official Account message encryption key |
|||
* `WeChat.Official.IsSandBox`: Whether in sandbox environment |
|||
* `WeChat.Official.Url`: Official Account server URL |
|||
|
|||
### Mini Program Configuration |
|||
|
|||
* `WeChat.MiniProgram.AppId`: Mini Program AppId |
|||
* `WeChat.MiniProgram.AppSecret`: Mini Program AppSecret |
|||
* `WeChat.MiniProgram.Token`: Mini Program message Token |
|||
* `WeChat.MiniProgram.EncodingAESKey`: Mini Program message encryption key |
|||
* `WeChat.MiniProgram.IsDebug`: Whether to enable debug mode |
|||
* `WeChat.MiniProgram.DefaultEnvironment`: Default environment |
|||
|
|||
### WeChat Work Configuration |
|||
|
|||
* `WeChat.Work.CorpId`: Enterprise ID |
|||
* `WeChat.Work.AgentId`: Application ID |
|||
* `WeChat.Work.Secret`: Application secret |
|||
* `WeChat.Work.Token`: Message Token |
|||
* `WeChat.Work.EncodingAESKey`: Message encryption key |
|||
|
|||
## Permissions |
|||
|
|||
* `WeChat.Setting`: WeChat settings management |
|||
* `WeChat.Setting.Official`: Official Account settings management |
|||
* `WeChat.Setting.MiniProgram`: Mini Program settings management |
|||
* `WeChat.Setting.Work`: WeChat Work settings management |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,61 @@ |
|||
# LINGYUN.Abp.WeChat.SettingManagement |
|||
|
|||
微信设置管理模块,提供微信相关配置的管理功能。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 微信配置管理 |
|||
* 公众号配置管理 |
|||
* 小程序配置管理 |
|||
* 企业微信配置管理 |
|||
* 配置界面集成 |
|||
* 多租户支持 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatSettingManagementModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Settings配置 |
|||
|
|||
### 公众号配置 |
|||
|
|||
* `WeChat.Official.AppId`: 公众号AppId |
|||
* `WeChat.Official.AppSecret`: 公众号AppSecret |
|||
* `WeChat.Official.Token`: 公众号消息Token |
|||
* `WeChat.Official.EncodingAESKey`: 公众号消息加密密钥 |
|||
* `WeChat.Official.IsSandBox`: 是否为沙箱环境 |
|||
* `WeChat.Official.Url`: 公众号服务器URL |
|||
|
|||
### 小程序配置 |
|||
|
|||
* `WeChat.MiniProgram.AppId`: 小程序AppId |
|||
* `WeChat.MiniProgram.AppSecret`: 小程序AppSecret |
|||
* `WeChat.MiniProgram.Token`: 小程序消息Token |
|||
* `WeChat.MiniProgram.EncodingAESKey`: 小程序消息加密密钥 |
|||
* `WeChat.MiniProgram.IsDebug`: 是否开启调试模式 |
|||
* `WeChat.MiniProgram.DefaultEnvironment`: 默认环境 |
|||
|
|||
### 企业微信配置 |
|||
|
|||
* `WeChat.Work.CorpId`: 企业ID |
|||
* `WeChat.Work.AgentId`: 应用ID |
|||
* `WeChat.Work.Secret`: 应用密钥 |
|||
* `WeChat.Work.Token`: 消息Token |
|||
* `WeChat.Work.EncodingAESKey`: 消息加密密钥 |
|||
|
|||
## 权限 |
|||
|
|||
* `WeChat.Setting`: 微信设置管理 |
|||
* `WeChat.Setting.Official`: 公众号设置管理 |
|||
* `WeChat.Setting.MiniProgram`: 小程序设置管理 |
|||
* `WeChat.Setting.Work`: 企业微信设置管理 |
|||
|
|||
## 更多文档 |
|||
|
|||
* [微信设置管理模块文档](README.EN.md) |
|||
@ -0,0 +1,71 @@ |
|||
# LINGYUN.Abp.WeChat.Work.Application.Contracts |
|||
|
|||
WeChat Work application service contracts module, providing application layer service interface definitions for WeChat Work application development. |
|||
|
|||
## Features |
|||
|
|||
* Contact management service interfaces |
|||
* Application management service interfaces |
|||
* Message pushing service interfaces |
|||
* Customer contact service interfaces |
|||
* Authentication service interfaces |
|||
* Enterprise payment service interfaces |
|||
* Electronic invoice service interfaces |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkApplicationContractsModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Service Interfaces |
|||
|
|||
### Contact Management |
|||
|
|||
* `IWeChatWorkContactService` |
|||
* `CreateDepartmentAsync`: Create department |
|||
* `UpdateDepartmentAsync`: Update department |
|||
* `DeleteDepartmentAsync`: Delete department |
|||
* `CreateUserAsync`: Create member |
|||
* `UpdateUserAsync`: Update member |
|||
* `DeleteUserAsync`: Delete member |
|||
* `CreateTagAsync`: Create tag |
|||
* `UpdateTagAsync`: Update tag |
|||
* `DeleteTagAsync`: Delete tag |
|||
|
|||
### Application Management |
|||
|
|||
* `IWeChatWorkAgentService` |
|||
* `GetAgentAsync`: Get application |
|||
* `SetAgentAsync`: Set application |
|||
* `GetAgentListAsync`: Get application list |
|||
* `SetWorkbenchTemplateAsync`: Set workbench template |
|||
|
|||
### Message Pushing |
|||
|
|||
* `IWeChatWorkMessageService` |
|||
* `SendTextAsync`: Send text message |
|||
* `SendImageAsync`: Send image message |
|||
* `SendVoiceAsync`: Send voice message |
|||
* `SendVideoAsync`: Send video message |
|||
* `SendFileAsync`: Send file message |
|||
* `SendTextCardAsync`: Send text card message |
|||
* `SendNewsAsync`: Send news message |
|||
* `SendTemplateCardAsync`: Send template card message |
|||
|
|||
## Permissions |
|||
|
|||
* `WeChatWork.Contact`: Contact management |
|||
* `WeChatWork.Agent`: Application management |
|||
* `WeChatWork.Message`: Message management |
|||
* `WeChatWork.Customer`: Customer management |
|||
* `WeChatWork.Payment`: Enterprise payment |
|||
* `WeChatWork.Invoice`: Electronic invoice |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,71 @@ |
|||
# LINGYUN.Abp.WeChat.Work.Application.Contracts |
|||
|
|||
企业微信应用服务契约模块,提供企业微信应用开发的应用层服务接口定义。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 通讯录管理服务接口 |
|||
* 应用管理服务接口 |
|||
* 消息推送服务接口 |
|||
* 客户联系服务接口 |
|||
* 身份验证服务接口 |
|||
* 企业支付服务接口 |
|||
* 电子发票服务接口 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkApplicationContractsModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 服务接口 |
|||
|
|||
### 通讯录管理 |
|||
|
|||
* `IWeChatWorkContactService` |
|||
* `CreateDepartmentAsync`: 创建部门 |
|||
* `UpdateDepartmentAsync`: 更新部门 |
|||
* `DeleteDepartmentAsync`: 删除部门 |
|||
* `CreateUserAsync`: 创建成员 |
|||
* `UpdateUserAsync`: 更新成员 |
|||
* `DeleteUserAsync`: 删除成员 |
|||
* `CreateTagAsync`: 创建标签 |
|||
* `UpdateTagAsync`: 更新标签 |
|||
* `DeleteTagAsync`: 删除标签 |
|||
|
|||
### 应用管理 |
|||
|
|||
* `IWeChatWorkAgentService` |
|||
* `GetAgentAsync`: 获取应用 |
|||
* `SetAgentAsync`: 设置应用 |
|||
* `GetAgentListAsync`: 获取应用列表 |
|||
* `SetWorkbenchTemplateAsync`: 设置工作台模板 |
|||
|
|||
### 消息推送 |
|||
|
|||
* `IWeChatWorkMessageService` |
|||
* `SendTextAsync`: 发送文本消息 |
|||
* `SendImageAsync`: 发送图片消息 |
|||
* `SendVoiceAsync`: 发送语音消息 |
|||
* `SendVideoAsync`: 发送视频消息 |
|||
* `SendFileAsync`: 发送文件消息 |
|||
* `SendTextCardAsync`: 发送文本卡片消息 |
|||
* `SendNewsAsync`: 发送图文消息 |
|||
* `SendTemplateCardAsync`: 发送模板卡片消息 |
|||
|
|||
## 权限 |
|||
|
|||
* `WeChatWork.Contact`: 通讯录管理 |
|||
* `WeChatWork.Agent`: 应用管理 |
|||
* `WeChatWork.Message`: 消息管理 |
|||
* `WeChatWork.Customer`: 客户管理 |
|||
* `WeChatWork.Payment`: 企业支付 |
|||
* `WeChatWork.Invoice`: 电子发票 |
|||
|
|||
## 更多文档 |
|||
|
|||
* [企业微信应用服务契约模块文档](README.EN.md) |
|||
@ -0,0 +1,57 @@ |
|||
# LINGYUN.Abp.WeChat.Work.Application |
|||
|
|||
WeChat Work application service module, providing application layer service implementation for WeChat Work application development. |
|||
|
|||
## Features |
|||
|
|||
* Contact management service |
|||
* Application management service |
|||
* Message pushing service |
|||
* Customer contact service |
|||
* Authentication service |
|||
* Enterprise payment service |
|||
* Electronic invoice service |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkApplicationModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Application Services |
|||
|
|||
### Contact Management |
|||
|
|||
* `IWeChatWorkContactService`: Contact management service |
|||
* Department management |
|||
* Member management |
|||
* Tag management |
|||
* Interconnected enterprise management |
|||
|
|||
### Application Management |
|||
|
|||
* `IWeChatWorkAgentService`: Application management service |
|||
* Application creation |
|||
* Application configuration |
|||
* Application visibility settings |
|||
* Application homepage settings |
|||
|
|||
### Message Pushing |
|||
|
|||
* `IWeChatWorkMessageService`: Message pushing service |
|||
* Text messages |
|||
* Image messages |
|||
* Voice messages |
|||
* Video messages |
|||
* File messages |
|||
* Text card messages |
|||
* News messages |
|||
* Template card messages |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,57 @@ |
|||
# LINGYUN.Abp.WeChat.Work.Application |
|||
|
|||
企业微信应用服务模块,提供企业微信应用开发的应用层服务实现。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 通讯录管理服务 |
|||
* 应用管理服务 |
|||
* 消息推送服务 |
|||
* 客户联系服务 |
|||
* 身份验证服务 |
|||
* 企业支付服务 |
|||
* 电子发票服务 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkApplicationModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 应用服务 |
|||
|
|||
### 通讯录管理 |
|||
|
|||
* `IWeChatWorkContactService`: 通讯录管理服务 |
|||
* 部门管理 |
|||
* 成员管理 |
|||
* 标签管理 |
|||
* 互联企业管理 |
|||
|
|||
### 应用管理 |
|||
|
|||
* `IWeChatWorkAgentService`: 应用管理服务 |
|||
* 应用创建 |
|||
* 应用配置 |
|||
* 应用可见范围设置 |
|||
* 应用主页设置 |
|||
|
|||
### 消息推送 |
|||
|
|||
* `IWeChatWorkMessageService`: 消息推送服务 |
|||
* 文本消息 |
|||
* 图片消息 |
|||
* 语音消息 |
|||
* 视频消息 |
|||
* 文件消息 |
|||
* 文本卡片消息 |
|||
* 图文消息 |
|||
* 模板卡片消息 |
|||
|
|||
## 更多文档 |
|||
|
|||
* [企业微信应用服务模块文档](README.EN.md) |
|||
@ -0,0 +1,71 @@ |
|||
# LINGYUN.Abp.WeChat.Work.Common |
|||
|
|||
WeChat Work common module, providing basic functionality implementation for WeChat Work application development. |
|||
|
|||
## Features |
|||
|
|||
* Unified message handling framework |
|||
* Unified message encryption/decryption mechanism |
|||
* Unified event handling mechanism |
|||
* Unified API calling interface |
|||
* Unified error handling mechanism |
|||
* AccessToken management |
|||
* JsApi Ticket management |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkCommonModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Work": { |
|||
"Common": { |
|||
"MessageHandlerFactory": { |
|||
"MessageResolvers": [], // Message resolver list |
|||
"MessageHandlers": [] // Message handler list |
|||
}, |
|||
"AccessToken": { |
|||
"CacheExpiration": 7200, // AccessToken cache duration (seconds) |
|||
"CacheKey": "WeChat:Work:AccessToken:{0}" // AccessToken cache key template |
|||
}, |
|||
"JsApiTicket": { |
|||
"CacheExpiration": 7200, // JsApi Ticket cache duration (seconds) |
|||
"CacheKey": "WeChat:Work:JsApiTicket:{0}" // JsApi Ticket cache key template |
|||
} |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## Message Handling |
|||
|
|||
* Support text message handling |
|||
* Support image message handling |
|||
* Support voice message handling |
|||
* Support video message handling |
|||
* Support location message handling |
|||
* Support link message handling |
|||
* Support event message handling |
|||
|
|||
## Event Handling |
|||
|
|||
* Support application menu events |
|||
* Support application entry events |
|||
* Support location reporting events |
|||
* Support async task completion events |
|||
* Support external contact events |
|||
* Support contact change events |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,71 @@ |
|||
# LINGYUN.Abp.WeChat.Work.Common |
|||
|
|||
企业微信通用模块,提供企业微信应用开发的基础功能实现。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 统一的消息处理框架 |
|||
* 统一的消息加解密机制 |
|||
* 统一的事件处理机制 |
|||
* 统一的API调用接口 |
|||
* 统一的错误处理机制 |
|||
* AccessToken管理 |
|||
* JsApi Ticket管理 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkCommonModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 配置项 |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Work": { |
|||
"Common": { |
|||
"MessageHandlerFactory": { |
|||
"MessageResolvers": [], // 消息解析器列表 |
|||
"MessageHandlers": [] // 消息处理器列表 |
|||
}, |
|||
"AccessToken": { |
|||
"CacheExpiration": 7200, // AccessToken缓存时间(秒) |
|||
"CacheKey": "WeChat:Work:AccessToken:{0}" // AccessToken缓存键模板 |
|||
}, |
|||
"JsApiTicket": { |
|||
"CacheExpiration": 7200, // JsApi Ticket缓存时间(秒) |
|||
"CacheKey": "WeChat:Work:JsApiTicket:{0}" // JsApi Ticket缓存键模板 |
|||
} |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## 消息处理 |
|||
|
|||
* 支持文本消息处理 |
|||
* 支持图片消息处理 |
|||
* 支持语音消息处理 |
|||
* 支持视频消息处理 |
|||
* 支持位置消息处理 |
|||
* 支持链接消息处理 |
|||
* 支持事件消息处理 |
|||
|
|||
## 事件处理 |
|||
|
|||
* 支持应用菜单事件 |
|||
* 支持进入应用事件 |
|||
* 支持上报地理位置事件 |
|||
* 支持异步任务完成事件 |
|||
* 支持外部联系人事件 |
|||
* 支持通讯录变更事件 |
|||
|
|||
## 更多文档 |
|||
|
|||
* [企业微信通用模块文档](README.EN.md) |
|||
@ -0,0 +1,67 @@ |
|||
# LINGYUN.Abp.WeChat.Work.Handlers |
|||
|
|||
WeChat Work message handling module, providing basic implementation for WeChat Work message and event handling. |
|||
|
|||
## Features |
|||
|
|||
* Text message handling |
|||
* Image message handling |
|||
* Voice message handling |
|||
* Video message handling |
|||
* Location message handling |
|||
* Link message handling |
|||
* Event message handling |
|||
* Custom message handler extensions |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkHandlersModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Work": { |
|||
"Handlers": { |
|||
"DefaultResponseType": "text", // Default response type: text/image/voice/video/news |
|||
"DefaultResponse": "", // Default response content |
|||
"EnableDefaultResponse": true // Whether to enable default response |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## Custom Handlers |
|||
|
|||
To implement custom message handlers, inherit from the corresponding base class: |
|||
|
|||
* Text message: `WeChatWorkTextMessageHandlerBase` |
|||
* Image message: `WeChatWorkImageMessageHandlerBase` |
|||
* Voice message: `WeChatWorkVoiceMessageHandlerBase` |
|||
* Video message: `WeChatWorkVideoMessageHandlerBase` |
|||
* Location message: `WeChatWorkLocationMessageHandlerBase` |
|||
* Link message: `WeChatWorkLinkMessageHandlerBase` |
|||
* Event message: `WeChatWorkEventMessageHandlerBase` |
|||
|
|||
## Event Handlers |
|||
|
|||
Built-in event handlers include: |
|||
|
|||
* Application menu event handler |
|||
* Application entry event handler |
|||
* Location reporting event handler |
|||
* Async task completion event handler |
|||
* External contact event handler |
|||
* Contact change event handler |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,67 @@ |
|||
# LINGYUN.Abp.WeChat.Work.Handlers |
|||
|
|||
企业微信消息处理模块,提供企业微信消息和事件处理的基础实现。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 文本消息处理 |
|||
* 图片消息处理 |
|||
* 语音消息处理 |
|||
* 视频消息处理 |
|||
* 位置消息处理 |
|||
* 链接消息处理 |
|||
* 事件消息处理 |
|||
* 自定义消息处理器扩展 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkHandlersModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 配置项 |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Work": { |
|||
"Handlers": { |
|||
"DefaultResponseType": "text", // 默认响应类型:text/image/voice/video/news |
|||
"DefaultResponse": "", // 默认响应内容 |
|||
"EnableDefaultResponse": true // 是否启用默认响应 |
|||
} |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## 自定义处理器 |
|||
|
|||
要实现自定义消息处理器,需要继承相应的基类: |
|||
|
|||
* 文本消息:`WeChatWorkTextMessageHandlerBase` |
|||
* 图片消息:`WeChatWorkImageMessageHandlerBase` |
|||
* 语音消息:`WeChatWorkVoiceMessageHandlerBase` |
|||
* 视频消息:`WeChatWorkVideoMessageHandlerBase` |
|||
* 位置消息:`WeChatWorkLocationMessageHandlerBase` |
|||
* 链接消息:`WeChatWorkLinkMessageHandlerBase` |
|||
* 事件消息:`WeChatWorkEventMessageHandlerBase` |
|||
|
|||
## 事件处理器 |
|||
|
|||
内置以下事件处理器: |
|||
|
|||
* 应用菜单事件处理器 |
|||
* 进入应用事件处理器 |
|||
* 上报地理位置事件处理器 |
|||
* 异步任务完成事件处理器 |
|||
* 外部联系人事件处理器 |
|||
* 通讯录变更事件处理器 |
|||
|
|||
## 更多文档 |
|||
|
|||
* [企业微信消息处理模块文档](README.EN.md) |
|||
@ -0,0 +1,70 @@ |
|||
# LINGYUN.Abp.WeChat.Work.HttpApi |
|||
|
|||
WeChat Work HTTP API module, providing HTTP API interface implementation for WeChat Work application development. |
|||
|
|||
## Features |
|||
|
|||
* Contact management API |
|||
* Application management API |
|||
* Message pushing API |
|||
* Customer contact API |
|||
* Authentication API |
|||
* Enterprise payment API |
|||
* Electronic invoice API |
|||
* WeChat Work callback interface |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkHttpApiModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## API Interfaces |
|||
|
|||
### Contact Management |
|||
|
|||
* POST /api/wechat/work/contact/department/create |
|||
* POST /api/wechat/work/contact/department/update |
|||
* DELETE /api/wechat/work/contact/department/{id} |
|||
* POST /api/wechat/work/contact/user/create |
|||
* POST /api/wechat/work/contact/user/update |
|||
* DELETE /api/wechat/work/contact/user/{id} |
|||
|
|||
### Application Management |
|||
|
|||
* GET /api/wechat/work/agent/{agentId} |
|||
* POST /api/wechat/work/agent/set |
|||
* GET /api/wechat/work/agent/list |
|||
* POST /api/wechat/work/agent/workbench/template |
|||
|
|||
### Message Pushing |
|||
|
|||
* POST /api/wechat/work/message/text |
|||
* POST /api/wechat/work/message/image |
|||
* POST /api/wechat/work/message/voice |
|||
* POST /api/wechat/work/message/video |
|||
* POST /api/wechat/work/message/file |
|||
* POST /api/wechat/work/message/textcard |
|||
* POST /api/wechat/work/message/news |
|||
* POST /api/wechat/work/message/templatecard |
|||
|
|||
### Callback Interface |
|||
|
|||
* POST /api/wechat/work/callback/{corpId} |
|||
|
|||
## Permissions |
|||
|
|||
* `WeChatWork.Contact`: Contact management |
|||
* `WeChatWork.Agent`: Application management |
|||
* `WeChatWork.Message`: Message management |
|||
* `WeChatWork.Customer`: Customer management |
|||
* `WeChatWork.Payment`: Enterprise payment |
|||
* `WeChatWork.Invoice`: Electronic invoice |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,70 @@ |
|||
# LINGYUN.Abp.WeChat.Work.HttpApi |
|||
|
|||
企业微信HTTP API模块,提供企业微信应用开发的HTTP API接口实现。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 通讯录管理API |
|||
* 应用管理API |
|||
* 消息推送API |
|||
* 客户联系API |
|||
* 身份验证API |
|||
* 企业支付API |
|||
* 电子发票API |
|||
* 企业微信回调接口 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkHttpApiModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## API接口 |
|||
|
|||
### 通讯录管理 |
|||
|
|||
* POST /api/wechat/work/contact/department/create |
|||
* POST /api/wechat/work/contact/department/update |
|||
* DELETE /api/wechat/work/contact/department/{id} |
|||
* POST /api/wechat/work/contact/user/create |
|||
* POST /api/wechat/work/contact/user/update |
|||
* DELETE /api/wechat/work/contact/user/{id} |
|||
|
|||
### 应用管理 |
|||
|
|||
* GET /api/wechat/work/agent/{agentId} |
|||
* POST /api/wechat/work/agent/set |
|||
* GET /api/wechat/work/agent/list |
|||
* POST /api/wechat/work/agent/workbench/template |
|||
|
|||
### 消息推送 |
|||
|
|||
* POST /api/wechat/work/message/text |
|||
* POST /api/wechat/work/message/image |
|||
* POST /api/wechat/work/message/voice |
|||
* POST /api/wechat/work/message/video |
|||
* POST /api/wechat/work/message/file |
|||
* POST /api/wechat/work/message/textcard |
|||
* POST /api/wechat/work/message/news |
|||
* POST /api/wechat/work/message/templatecard |
|||
|
|||
### 回调接口 |
|||
|
|||
* POST /api/wechat/work/callback/{corpId} |
|||
|
|||
## 权限 |
|||
|
|||
* `WeChatWork.Contact`: 通讯录管理 |
|||
* `WeChatWork.Agent`: 应用管理 |
|||
* `WeChatWork.Message`: 消息管理 |
|||
* `WeChatWork.Customer`: 客户管理 |
|||
* `WeChatWork.Payment`: 企业支付 |
|||
* `WeChatWork.Invoice`: 电子发票 |
|||
|
|||
## 更多文档 |
|||
|
|||
* [企业微信HTTP API模块文档](README.EN.md) |
|||
@ -0,0 +1,55 @@ |
|||
# LINGYUN.Abp.WeChat.Work |
|||
|
|||
WeChat Work (Enterprise WeChat) integration module, providing necessary functionality support for WeChat Work application development. |
|||
|
|||
## Features |
|||
|
|||
* WeChat Work authentication |
|||
* Contact management |
|||
* Message pushing |
|||
* Media management |
|||
* Customer contact |
|||
* Application management |
|||
* Authentication |
|||
* Enterprise payment |
|||
* Electronic invoice |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatWorkModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"Work": { |
|||
"CorpId": "", // Enterprise ID |
|||
"AgentId": 0, // Application ID |
|||
"Secret": "", // Application secret |
|||
"Token": "", // Message Token |
|||
"EncodingAESKey": "", // Message encryption key |
|||
"ApiUrl": "https://qyapi.weixin.qq.com" // API URL |
|||
} |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## Settings Configuration |
|||
|
|||
* `WeChat.Work.CorpId`: Enterprise ID |
|||
* `WeChat.Work.AgentId`: Application ID |
|||
* `WeChat.Work.Secret`: Application secret |
|||
* `WeChat.Work.Token`: Message Token |
|||
* `WeChat.Work.EncodingAESKey`: Message encryption key |
|||
* `WeChat.Work.ApiUrl`: API URL |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,44 @@ |
|||
# LINGYUN.Abp.WeChat |
|||
|
|||
WeChat base module, providing fundamental functionality and configuration for WeChat application development. |
|||
|
|||
## Features |
|||
|
|||
* WeChat basic configuration management |
|||
* Unified WeChat API calling interface |
|||
* WeChat AccessToken management |
|||
* Unified error handling mechanism |
|||
|
|||
## Module Reference |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## Configuration |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"BaseUrl": "https://api.weixin.qq.com", // WeChat API base URL |
|||
"DefaultTimeout": 30000, // Default timeout in milliseconds |
|||
"RetryCount": 3, // Number of retry attempts |
|||
"RetryMilliseconds": 1000 // Retry interval in milliseconds |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## Settings Configuration |
|||
|
|||
* `WeChat.BaseUrl` : WeChat API base URL |
|||
* `WeChat.DefaultTimeout` : Default timeout |
|||
* `WeChat.RetryCount` : Number of retry attempts |
|||
* `WeChat.RetryMilliseconds` : Retry interval |
|||
|
|||
## More Documentation |
|||
|
|||
* [Chinese Documentation](README.md) |
|||
@ -0,0 +1,44 @@ |
|||
# LINGYUN.Abp.WeChat |
|||
|
|||
微信基础模块,提供微信应用开发的基础功能和配置。 |
|||
|
|||
## 功能特性 |
|||
|
|||
* 微信基础配置管理 |
|||
* 统一的微信API调用接口 |
|||
* 微信AccessToken管理 |
|||
* 统一的错误处理机制 |
|||
|
|||
## 模块引用 |
|||
|
|||
```csharp |
|||
[DependsOn(typeof(AbpWeChatModule))] |
|||
public class YouProjectModule : AbpModule |
|||
{ |
|||
// other |
|||
} |
|||
``` |
|||
|
|||
## 配置项 |
|||
|
|||
```json |
|||
{ |
|||
"WeChat": { |
|||
"BaseUrl": "https://api.weixin.qq.com", // 微信API基础地址 |
|||
"DefaultTimeout": 30000, // 默认超时时间(毫秒) |
|||
"RetryCount": 3, // 重试次数 |
|||
"RetryMilliseconds": 1000 // 重试间隔(毫秒) |
|||
} |
|||
} |
|||
``` |
|||
|
|||
## Settings配置 |
|||
|
|||
* `WeChat.BaseUrl` : 微信API基础地址 |
|||
* `WeChat.DefaultTimeout` : 默认超时时间 |
|||
* `WeChat.RetryCount` : 重试次数 |
|||
* `WeChat.RetryMilliseconds` : 重试间隔 |
|||
|
|||
## 更多文档 |
|||
|
|||
* [微信基础模块文档](README.EN.md) |
|||
Loading…
Reference in new issue