diff --git a/aspnet-core/framework/cloud-aliyun/LINGYUN.Abp.Aliyun/README.EN.md b/aspnet-core/framework/cloud-aliyun/LINGYUN.Abp.Aliyun/README.EN.md index bf93c149d..a9f0ceeb3 100644 --- a/aspnet-core/framework/cloud-aliyun/LINGYUN.Abp.Aliyun/README.EN.md +++ b/aspnet-core/framework/cloud-aliyun/LINGYUN.Abp.Aliyun/README.EN.md @@ -72,6 +72,57 @@ public class YouProjectModule : AbpModule * Type: Optional * Format: JSON string +### SMS Service Configuration + +```json +{ + "Settings": { + "Abp.Aliyun.Sms": { + "Domain": "dysmsapi.aliyuncs.com", // API endpoint, default is dysmsapi.aliyuncs.com + "Version": "2017-05-25", // API version, default is 2017-05-25 + "ActionName": "SendSms", // API method name, default is SendSms + "DefaultSignName": "", // Default SMS signature + "DefaultTemplateCode": "", // Default SMS template code + "DefaultPhoneNumber": "", // Default phone number for receiving SMS + "VisableErrorToClient": "false" // Whether to show error messages to client + } + } +} +``` + +## Available Regions + +The module supports the following Alibaba Cloud regions: + +* China Regions + * North China 1 (Qingdao) - cn-qingdao + * North China 2 (Beijing) - cn-beijing + * North China 3 (Zhangjiakou) - cn-zhangjiakou + * North China 5 (Hohhot) - cn-huhehaote + * East China 1 (Hangzhou) - cn-hangzhou + * East China 2 (Shanghai) - cn-shanghai + * South China 1 (Shenzhen) - cn-shenzhen + * South China 2 (Heyuan) - cn-heyuan + * South China 3 (Guangzhou) - cn-guangzhou + * Southwest 1 (Chengdu) - cn-chengdu + +* Hong Kong and International Regions + * Hong Kong - cn-hongkong + * US (Silicon Valley) - us-west-1 + * US (Virginia) - us-east-1 + * Japan (Tokyo) - ap-northeast-1 + * South Korea (Seoul) - ap-northeast-2 + * Singapore - ap-southeast-1 + * Australia (Sydney) - ap-southeast-2 + * Malaysia (Kuala Lumpur) - ap-southeast-3 + * Indonesia (Jakarta) - ap-southeast-5 + * Philippines (Manila) - ap-southeast-6 + * Thailand (Bangkok) - ap-southeast-7 + * India (Mumbai) - ap-south-1 + * Germany (Frankfurt) - eu-central-1 + * UK (London) - eu-west-1 + * UAE (Dubai) - me-east-1 + ## Performance Optimization * In high concurrency scenarios, it is recommended to enable distributed caching to improve performance diff --git a/aspnet-core/framework/cloud-aliyun/LINGYUN.Abp.Aliyun/README.md b/aspnet-core/framework/cloud-aliyun/LINGYUN.Abp.Aliyun/README.md index 4edc9f411..23e590bad 100644 --- a/aspnet-core/framework/cloud-aliyun/LINGYUN.Abp.Aliyun/README.md +++ b/aspnet-core/framework/cloud-aliyun/LINGYUN.Abp.Aliyun/README.md @@ -72,6 +72,57 @@ public class YouProjectModule : AbpModule * 类型:可选 * 格式:JSON字符串 +### 短信服务配置 + +```json +{ + "Settings": { + "Abp.Aliyun.Sms": { + "Domain": "dysmsapi.aliyuncs.com", // API域名,默认为 dysmsapi.aliyuncs.com + "Version": "2017-05-25", // API版本,默认为 2017-05-25 + "ActionName": "SendSms", // API方法名,默认为 SendSms + "DefaultSignName": "", // 默认短信签名 + "DefaultTemplateCode": "", // 默认短信模板代码 + "DefaultPhoneNumber": "", // 默认接收短信的手机号码 + "VisableErrorToClient": "false" // 是否向客户端显示错误信息 + } + } +} +``` + +## 可用区域 + +本模块支持以下阿里云区域: + +* 中国区域 + * 华北1(青岛)- cn-qingdao + * 华北2(北京)- cn-beijing + * 华北3(张家口)- cn-zhangjiakou + * 华北5(呼和浩特)- cn-huhehaote + * 华东1(杭州)- cn-hangzhou + * 华东2(上海)- cn-shanghai + * 华南1(深圳)- cn-shenzhen + * 华南2(河源)- cn-heyuan + * 华南3(广州)- cn-guangzhou + * 西南1(成都)- cn-chengdu + +* 香港及海外区域 + * 香港 - cn-hongkong + * 美国(硅谷)- us-west-1 + * 美国(弗吉尼亚)- us-east-1 + * 日本(东京)- ap-northeast-1 + * 韩国(首尔)- ap-northeast-2 + * 新加坡 - ap-southeast-1 + * 澳大利亚(悉尼)- ap-southeast-2 + * 马来西亚(吉隆坡)- ap-southeast-3 + * 印度尼西亚(雅加达)- ap-southeast-5 + * 菲律宾(马尼拉)- ap-southeast-6 + * 泰国(曼谷)- ap-southeast-7 + * 印度(孟买)- ap-south-1 + * 德国(法兰克福)- eu-central-1 + * 英国(伦敦)- eu-west-1 + * 阿联酋(迪拜)- me-east-1 + ## 性能优化 * 在高并发场景下,建议开启分布式缓存以提高性能 diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.BlobStoring.Tencent/README.EN.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.BlobStoring.Tencent/README.EN.md new file mode 100644 index 000000000..1d465743a --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.BlobStoring.Tencent/README.EN.md @@ -0,0 +1,137 @@ +# LINGYUN.Abp.BlobStoring.Tencent + +Tencent Cloud Object Storage (COS) Module, integrating Tencent Cloud Object Storage service into ABP BlobStoring system. + +## Features + +* Support for Tencent Cloud Object Storage service +* Multi-tenant configuration support +* Automatic bucket creation support +* Bucket referer configuration support +* Multi-region configuration support +* File size limit support +* Tenant-isolated storage support + +## Configuration Items + +### Basic Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "Your Tencent Cloud SecretId", // Get from Tencent Cloud Console + "SecretKey": "Your Tencent Cloud SecretKey", // Get from Tencent Cloud Console + "DurationSecond": "600" // Session duration in seconds + } + } +} +``` + +### Object Storage Configuration + +```json +{ + "Tencent": { + "OSS": { + "AppId": "", // Tencent Cloud AppId + "Region": "", // Bucket region + "BucketName": "", // Bucket name + "CreateBucketIfNotExists": false, // Create bucket if not exists + "CreateBucketReferer": [] // Referer settings when creating bucket + } + } +} +``` + +### Bucket Naming Rules + +* Only lowercase letters and numbers are supported, i.e., [a-z, 0-9], hyphen "-" and their combinations +* Cannot start or end with a hyphen (-) +* The maximum allowed characters for bucket names are affected by the region abbreviation and APPID, with a total limit of 60 characters for the complete request domain +* For more rules, refer to [Tencent Cloud Bucket Naming Rules](https://cloud.tencent.com/document/product/436/13312) + +### Object Naming Rules + +* Cannot start with forward slash / or backslash \\ +* ASCII control characters are not supported in object keys: up arrow (↑), down arrow (↓), right arrow (→), left arrow (←) +* For more rules, refer to [Tencent Cloud Object Naming Rules](https://cloud.tencent.com/document/product/436/13324) + +## Basic Usage + +1. Add module dependency +```csharp +[DependsOn(typeof(AbpBlobStoringTencentCloudModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. Configure Tencent Cloud Object Storage +```csharp +Configure(options => +{ + options.Containers.Configure(container => + { + container.UseTencentCloud(tencent => + { + tencent.AppId = "Your Tencent Cloud AppId"; + tencent.Region = "ap-guangzhou"; + tencent.BucketName = "your-bucket-name"; + tencent.CreateBucketIfNotExists = true; + tencent.CreateBucketReferer = new List + { + "*.example.com", + "example.com" + }; + }); + }); +}); +``` + +3. Use BLOB storage +```csharp +public class YourService +{ + private readonly IBlobContainer _blobContainer; + + public YourService(IBlobContainer blobContainer) + { + _blobContainer = blobContainer; + } + + public async Task SaveBlobAsync(string name, Stream stream) + { + await _blobContainer.SaveAsync(name, stream); + } + + public async Task GetBlobAsync(string name) + { + return await _blobContainer.GetAsync(name); + } +} +``` + +## Advanced Features + +### Multi-tenant Support + +The module supports tenant-isolated storage with the following path format: +* Host: `host/{blobName}` +* Tenant: `tenants/{tenantId}/{blobName}` + +### Feature Management + +The module provides the following feature switches: + +* TencentBlobStoring - Controls enabling/disabling of Tencent Cloud Object Storage service +* TencentBlobStoringMaximumStreamSize - Controls the maximum file size limit (MB) for uploads + +## More Documentation + +* [Tencent Cloud Object Storage](https://cloud.tencent.com/document/product/436) +* [Tencent Cloud COS Console](https://console.cloud.tencent.com/cos) +* [ABP BlobStoring System](https://docs.abp.io/en/abp/latest/Blob-Storing) + +[简体中文](./README.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.BlobStoring.Tencent/README.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.BlobStoring.Tencent/README.md new file mode 100644 index 000000000..e4b304105 --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.BlobStoring.Tencent/README.md @@ -0,0 +1,137 @@ +# LINGYUN.Abp.BlobStoring.Tencent + +腾讯云对象存储(COS)模块,集成腾讯云对象存储服务到ABP BlobStoring系统。 + +## 功能特性 + +* 支持腾讯云对象存储服务 +* 支持多租户配置 +* 支持自动创建存储桶(Bucket) +* 支持存储桶防盗链配置 +* 支持多区域配置 +* 支持文件大小限制 +* 支持按租户隔离存储 + +## 配置项说明 + +### 基础配置 + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "您的腾讯云SecretId", // 从腾讯云控制台获取 + "SecretKey": "您的腾讯云SecretKey", // 从腾讯云控制台获取 + "DurationSecond": "600" // 会话持续时长,单位秒 + } + } +} +``` + +### 对象存储配置 + +```json +{ + "Tencent": { + "OSS": { + "AppId": "", // 腾讯云AppId + "Region": "", // 存储桶所在地域 + "BucketName": "", // 存储桶名称 + "CreateBucketIfNotExists": false, // 存储桶不存在时是否创建 + "CreateBucketReferer": [] // 创建存储桶时的防盗链设置 + } + } +} +``` + +### 存储桶命名规范 + +* 仅支持小写英文字母和数字,即[a-z,0-9]、中划线"-"及其组合 +* 不能以短划线(-)开头或结尾 +* 存储桶名称的最大允许字符受到地域简称和APPID的字符数影响,组成的完整请求域名字符数总计最多60个字符 +* 更多规范请参考[腾讯云存储桶命名规范](https://cloud.tencent.com/document/product/436/13312) + +### 对象命名规范 + +* 不允许以正斜线/或者反斜线\\开头 +* 对象键中不支持ASCII控制字符中的字符上(↑),字符下(↓),字符右(→),字符左(←) +* 更多规范请参考[腾讯云对象命名规范](https://cloud.tencent.com/document/product/436/13324) + +## 基本用法 + +1. 添加模块依赖 +```csharp +[DependsOn(typeof(AbpBlobStoringTencentCloudModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. 配置腾讯云对象存储 +```csharp +Configure(options => +{ + options.Containers.Configure(container => + { + container.UseTencentCloud(tencent => + { + tencent.AppId = "您的腾讯云AppId"; + tencent.Region = "ap-guangzhou"; + tencent.BucketName = "your-bucket-name"; + tencent.CreateBucketIfNotExists = true; + tencent.CreateBucketReferer = new List + { + "*.example.com", + "example.com" + }; + }); + }); +}); +``` + +3. 使用BLOB存储 +```csharp +public class YourService +{ + private readonly IBlobContainer _blobContainer; + + public YourService(IBlobContainer blobContainer) + { + _blobContainer = blobContainer; + } + + public async Task SaveBlobAsync(string name, Stream stream) + { + await _blobContainer.SaveAsync(name, stream); + } + + public async Task GetBlobAsync(string name) + { + return await _blobContainer.GetAsync(name); + } +} +``` + +## 高级特性 + +### 多租户支持 + +模块支持按租户隔离存储,存储路径格式如下: +* 宿主:`host/{blobName}` +* 租户:`tenants/{tenantId}/{blobName}` + +### 特性管理 + +模块提供以下特性开关: + +* TencentBlobStoring - 控制腾讯云对象存储服务的启用/禁用 +* TencentBlobStoringMaximumStreamSize - 控制上传文件的最大大小限制(MB) + +## 更多文档 + +* [腾讯云对象存储](https://cloud.tencent.com/document/product/436) +* [腾讯云COS控制台](https://console.cloud.tencent.com/cos) +* [ABP BlobStoring系统](https://docs.abp.io/en/abp/latest/Blob-Storing) + +[English](./README.EN.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Sms.Tencent/README.EN.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Sms.Tencent/README.EN.md new file mode 100644 index 000000000..5364e881f --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Sms.Tencent/README.EN.md @@ -0,0 +1,128 @@ +# LINGYUN.Abp.Sms.Tencent + +Tencent Cloud SMS Service Module, integrating Tencent Cloud SMS service into ABP applications. + +## Features + +* Support for Tencent Cloud SMS sending functionality +* Multi-tenant configuration support +* Default signature and template configuration support +* Support for batch sending to multiple phone numbers +* SMS template parameter support +* Built-in error handling and logging + +## Configuration Items + +### Basic Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "Your Tencent Cloud SecretId", // Get from Tencent Cloud Console + "SecretKey": "Your Tencent Cloud SecretKey", // Get from Tencent Cloud Console + "DurationSecond": "600" // Session duration in seconds + } + } +} +``` + +### SMS Service Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud.Sms": { + "AppId": "", // SMS application ID, generated after adding application in SMS console + "DefaultSignName": "", // Default SMS signature + "DefaultTemplateId": "" // Default SMS template ID + } + } +} +``` + +## Basic Usage + +1. Add module dependency +```csharp +[DependsOn(typeof(AbpSmsTencentModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. Configure Tencent Cloud SMS service +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "Your Tencent Cloud SecretId", + "SecretKey": "Your Tencent Cloud SecretKey", + "DurationSecond": "600" + }, + "Abp.TencentCloud.Sms": { + "AppId": "Your SMS Application ID", + "DefaultSignName": "Your SMS Signature", + "DefaultTemplateId": "Your Default Template ID" + } + } +} +``` + +3. SMS sending examples +```csharp +public class YourService +{ + private readonly ISmsSender _smsSender; + + public YourService(ISmsSender smsSender) + { + _smsSender = smsSender; + } + + // Send using default signature and template + public async Task SendSmsAsync(string phoneNumber, Dictionary templateParams) + { + await _smsSender.SendAsync( + phoneNumber, + nameof(TencentCloudSmsSender), + templateParams); + } + + // Send using specified signature and template + public async Task SendSmsAsync( + string signName, + string templateCode, + string phoneNumber, + Dictionary templateParams) + { + await _smsSender.SendAsync( + signName, + templateCode, + phoneNumber, + templateParams); + } +} +``` + +## Advanced Features + +### Feature Switches + +The module provides the following feature switches: + +* TencentSms - Controls enabling/disabling of Tencent Cloud SMS service + +### Error Handling + +* Throws exception when all SMS sending fails +* Logs warning when partial SMS sending fails +* Supports viewing detailed failure information, including serial number, phone number, error code, and error message + +## More Documentation + +* [Tencent Cloud SMS Service](https://cloud.tencent.com/document/product/382) +* [SMS Console](https://console.cloud.tencent.com/smsv2) + +[简体中文](./README.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Sms.Tencent/README.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Sms.Tencent/README.md new file mode 100644 index 000000000..80dfa5eb4 --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Sms.Tencent/README.md @@ -0,0 +1,127 @@ +# LINGYUN.Abp.Sms.Tencent + +腾讯云短信服务模块,集成腾讯云短信服务到ABP应用程序。 + +## 功能特性 + +* 支持腾讯云短信服务的发送功能 +* 支持多租户配置 +* 支持默认签名和模板配置 +* 支持多手机号批量发送 +* 支持短信模板参数传递 +* 内置错误处理和日志记录 + +## 配置项说明 + +### 基础配置 + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "您的腾讯云SecretId", // 从腾讯云控制台获取 + "SecretKey": "您的腾讯云SecretKey", // 从腾讯云控制台获取 + "DurationSecond": "600" // 会话持续时长,单位秒 + } + } +} +``` + +### 短信服务配置 + +```json +{ + "Settings": { + "Abp.TencentCloud.Sms": { + "AppId": "", // 短信应用ID,在短信控制台添加应用后生成 + "DefaultSignName": "", // 默认短信签名 + "DefaultTemplateId": "" // 默认短信模板ID + } + } +} +``` + +## 基本用法 + +1. 添加模块依赖 +```csharp +[DependsOn(typeof(AbpSmsTencentModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. 配置腾讯云短信服务 +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "您的腾讯云SecretId", + "SecretKey": "您的腾讯云SecretKey" + }, + "Abp.TencentCloud.Sms": { + "AppId": "您的短信应用ID", + "DefaultSignName": "您的短信签名", + "DefaultTemplateId": "您的默认模板ID" + } + } +} +``` + +3. 发送短信示例 +```csharp +public class YourService +{ + private readonly ISmsSender _smsSender; + + public YourService(ISmsSender smsSender) + { + _smsSender = smsSender; + } + + // 使用默认签名和模板发送 + public async Task SendSmsAsync(string phoneNumber, Dictionary templateParams) + { + await _smsSender.SendAsync( + phoneNumber, + nameof(TencentCloudSmsSender), + templateParams); + } + + // 使用指定签名和模板发送 + public async Task SendSmsAsync( + string signName, + string templateCode, + string phoneNumber, + Dictionary templateParams) + { + await _smsSender.SendAsync( + signName, + templateCode, + phoneNumber, + templateParams); + } +} +``` + +## 高级特性 + +### 特性开关 + +模块提供以下特性开关: + +* TencentSms - 控制腾讯云短信服务的启用/禁用 + +### 错误处理 + +* 当所有短信发送失败时,会抛出异常 +* 当部分短信发送失败时,会记录警告日志 +* 支持查看发送失败的详细信息,包括流水号、手机号、错误代码和错误信息 + +## 更多文档 + +* [腾讯云短信服务](https://cloud.tencent.com/document/product/382) +* [短信控制台](https://console.cloud.tencent.com/smsv2) + +[English](./README.EN.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.QQ/README.EN.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.QQ/README.EN.md new file mode 100644 index 000000000..cbbec1529 --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.QQ/README.EN.md @@ -0,0 +1,81 @@ +# LINGYUN.Abp.Tencent.QQ + +Tencent QQ Connect module, integrating QQ Connect service into ABP applications. + +## Features + +* Support for QQ Connect quick login +* Multi-tenant configuration support +* Provides QQ Connect client factory for dynamic client creation + +## Configuration Items + +### Basic Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "Your Tencent Cloud SecretId", // Get from Tencent Cloud Console + "SecretKey": "Your Tencent Cloud SecretKey", // Get from Tencent Cloud Console + "DurationSecond": "600" // Session duration in seconds + } + } +} +``` + +### QQ Connect Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud.QQConnect": { + "AppId": "", // QQ Connect AppId, get from QQ Connect Management Center + "AppKey": "", // QQ Connect AppKey, get from QQ Connect Management Center + "IsMobile": "false" // Whether to use mobile style, default is PC style + } + } +} +``` + +## Basic Usage + +1. Add module dependency +```csharp +[DependsOn(typeof(AbpTencentQQModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. Configure QQ Connect service + +Refer to the configuration items description above for the corresponding configuration. + +3. QQ Connect service usage example +```csharp +public class YourService +{ + private readonly TencentQQClientFactory _qqClientFactory; + + public YourService(TencentQQClientFactory qqClientFactory) + { + _qqClientFactory = qqClientFactory; + } + + public async Task QQConnectAsync() + { + var qqClient = await _qqClientFactory.CreateAsync(); + // Use qqClient to call QQ Connect service APIs + // For detailed API usage, please refer to QQ Connect development documentation + } +} +``` + +## More Documentation + +* [QQ Connect Open Platform](https://connect.qq.com/) +* [QQ Connect Development Documentation](https://wiki.connect.qq.com/) + +[简体中文](./README.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.QQ/README.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.QQ/README.md new file mode 100644 index 000000000..ecbea9a6e --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.QQ/README.md @@ -0,0 +1,81 @@ +# LINGYUN.Abp.Tencent.QQ + +腾讯QQ互联模块,集成腾讯QQ互联服务到ABP应用程序。 + +## 功能特性 + +* 支持QQ互联快速登录 +* 支持多租户配置 +* 提供QQ互联客户端工厂,支持动态创建客户端 + +## 配置项说明 + +### 基础配置 + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "您的腾讯云SecretId", // 从腾讯云控制台获取 + "SecretKey": "您的腾讯云SecretKey", // 从腾讯云控制台获取 + "DurationSecond": "600" // 会话持续时间(秒) + } + } +} +``` + +### QQ互联配置 + +```json +{ + "Settings": { + "Abp.TencentCloud.QQConnect": { + "AppId": "", // QQ互联应用ID,从QQ互联管理中心获取 + "AppKey": "", // QQ互联应用密钥,从QQ互联管理中心获取 + "IsMobile": "false" // 是否使用移动端样式,默认为PC端样式 + } + } +} +``` + +## 基本用法 + +1. 添加模块依赖 +```csharp +[DependsOn(typeof(AbpTencentQQModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. 配置QQ互联服务 + +参考上述配置项说明进行相应配置。 + +3. QQ互联服务使用示例 +```csharp +public class YourService +{ + private readonly TencentQQClientFactory _qqClientFactory; + + public YourService(TencentQQClientFactory qqClientFactory) + { + _qqClientFactory = qqClientFactory; + } + + public async Task QQConnectAsync() + { + var qqClient = await _qqClientFactory.CreateAsync(); + // 使用qqClient调用QQ互联服务API + // 详细API使用方法请参考QQ互联开发文档 + } +} +``` + +## 更多文档 + +* [QQ互联开放平台](https://connect.qq.com/) +* [QQ互联开发文档](https://wiki.connect.qq.com/) + +[English](./README.EN.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.SettingManagement/README.EN.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.SettingManagement/README.EN.md new file mode 100644 index 000000000..d5e8be196 --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.SettingManagement/README.EN.md @@ -0,0 +1,156 @@ +# LINGYUN.Abp.Tencent.SettingManagement + +Tencent Cloud Service Setting Management Module, providing configuration management interface and API for Tencent Cloud services. + +## Features + +* Provides configuration management interface for Tencent Cloud services +* Supports global and tenant-level configuration management +* Supports configuration for the following Tencent Cloud services: + * Basic configuration (keys, regions, etc.) + * Connection configuration (HTTP method, timeout, proxy, etc.) + * SMS service configuration (application ID, default signature, default template, etc.) + * QQ Connect configuration (application ID, application key, etc.) +* Built-in permission management +* Multi-language localization support +* Support for all Tencent Cloud available regions + +## Permissions + +* `TencentCloud` - Tencent Cloud service permission group + * `TencentCloud.Settings` - Configure Tencent Cloud service permission + +## API Endpoints + +### Get Global Configuration + +```http +GET /api/setting-management/tencent/by-global +``` + +### Get Current Tenant Configuration + +```http +GET /api/setting-management/tencent/by-current-tenant +``` + +## Basic Usage + +1. Add module dependency +```csharp +[DependsOn(typeof(AbpTencentCloudSettingManagementModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. Configure authorization +```csharp +public override void ConfigureServices(ServiceConfigurationContext context) +{ + Configure(options => + { + options.GrantByDefault(TencentCloudSettingPermissionNames.Settings); + }); +} +``` + +## Configuration Items + +### Basic Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "EndPoint": "ap-guangzhou", // Resource region, default is Guangzhou + "SecretId": "Your Tencent Cloud SecretId", // Get from Tencent Cloud Console + "SecretKey": "Your Tencent Cloud SecretKey", // Get from Tencent Cloud Console + "DurationSecond": "600" // Session duration in seconds + } + } +} +``` + +### Connection Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud.Connection": { + "HttpMethod": "POST", // Request method, default is POST + "Timeout": "60", // Connection timeout in seconds + "WebProxy": "", // Proxy server address, optional + "EndPoint": "" // Specific service domain, required for financial zone services + } + } +} +``` + +### SMS Service Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud.Sms": { + "AppId": "", // SMS application ID, generated after adding application in SMS console + "DefaultSignName": "", // Default SMS signature + "DefaultTemplateId": "" // Default SMS template ID + } + } +} +``` + +### QQ Connect Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud.QQConnect": { + "AppId": "", // QQ Connect application ID, get from QQ Connect Management Center + "AppKey": "", // QQ Connect application key, get from QQ Connect Management Center + "IsMobile": "false" // Whether to use mobile style, default is PC style + } + } +} +``` + +## Available Regions + +The module supports the following Tencent Cloud regions: + +* China Regions + * North China (Beijing) - ap-beijing + * Southwest China (Chengdu) - ap-chengdu + * Southwest China (Chongqing) - ap-chongqing + * South China (Guangzhou) - ap-guangzhou + * Hong Kong/Macao/Taiwan (Hong Kong, China) - ap-hongkong + * East China (Nanjing) - ap-nanjing + * East China (Shanghai) - ap-shanghai + * East China (Shanghai Financial) - ap-shanghai-fsi + * South China (Shenzhen Financial) - ap-shenzhen-fsi + +* Asia Pacific + * Bangkok - ap-bangkok + * Jakarta - ap-jakarta + * Mumbai - ap-mumbai + * Seoul - ap-seoul + * Singapore - ap-singapore + * Tokyo - ap-tokyo + +* Europe + * Frankfurt - eu-frankfurt + * Moscow - eu-moscow + +* North America + * Virginia - na-ashburn + * Silicon Valley - na-siliconvalley + * Toronto - na-toronto + +## More Documentation + +* [Tencent Cloud API Key Management](https://console.cloud.tencent.com/cam/capi) +* [Tencent Cloud Regions and Availability Zones](https://cloud.tencent.com/document/product/213/6091) + +[简体中文](./README.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.SettingManagement/README.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.SettingManagement/README.md new file mode 100644 index 000000000..c5a7997dc --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.SettingManagement/README.md @@ -0,0 +1,156 @@ +# LINGYUN.Abp.Tencent.SettingManagement + +腾讯云服务设置管理模块,提供腾讯云服务的配置管理界面和API。 + +## 功能特性 + +* 提供腾讯云服务的配置管理界面 +* 支持全局和租户级别的配置管理 +* 支持以下腾讯云服务的配置: + * 基础配置(密钥、地域等) + * 连接配置(HTTP方法、超时时间、代理等) + * 短信服务配置(应用ID、默认签名、默认模板等) + * QQ互联配置(应用ID、应用密钥等) +* 内置权限管理 +* 支持多语言本地化 +* 支持所有腾讯云可用区域的配置 + +## 权限 + +* `TencentCloud` - 腾讯云服务权限组 + * `TencentCloud.Settings` - 配置腾讯云服务权限 + +## API接口 + +### 获取全局配置 + +```http +GET /api/setting-management/tencent/by-global +``` + +### 获取当前租户配置 + +```http +GET /api/setting-management/tencent/by-current-tenant +``` + +## 基本用法 + +1. 添加模块依赖 +```csharp +[DependsOn(typeof(AbpTencentCloudSettingManagementModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. 授权配置 +```csharp +public override void ConfigureServices(ServiceConfigurationContext context) +{ + Configure(options => + { + options.GrantByDefault(TencentCloudSettingPermissionNames.Settings); + }); +} +``` + +## 配置项说明 + +### 基础配置 + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "EndPoint": "ap-guangzhou", // 资源所在地域,默认为广州 + "SecretId": "您的腾讯云SecretId", // 从腾讯云控制台获取 + "SecretKey": "您的腾讯云SecretKey", // 从腾讯云控制台获取 + "DurationSecond": "600" // 会话持续时长,单位秒 + } + } +} +``` + +### 连接配置 + +```json +{ + "Settings": { + "Abp.TencentCloud.Connection": { + "HttpMethod": "POST", // 请求方法,默认POST + "Timeout": "60", // 连接超时时间,单位秒 + "WebProxy": "", // 代理服务器地址,可选 + "EndPoint": "" // 特定服务的域名,如金融区服务需要指定 + } + } +} +``` + +### 短信服务配置 + +```json +{ + "Settings": { + "Abp.TencentCloud.Sms": { + "AppId": "", // 短信应用ID,在短信控制台添加应用后生成 + "DefaultSignName": "", // 默认短信签名 + "DefaultTemplateId": "" // 默认短信模板ID + } + } +} +``` + +### QQ互联配置 + +```json +{ + "Settings": { + "Abp.TencentCloud.QQConnect": { + "AppId": "", // QQ互联应用ID,从QQ互联管理中心获取 + "AppKey": "", // QQ互联应用密钥,从QQ互联管理中心获取 + "IsMobile": "false" // 是否使用移动端样式,默认为PC端样式 + } + } +} +``` + +## 可用区域 + +模块支持以下腾讯云区域: + +* 中国区域 + * 华北地区(北京)- ap-beijing + * 西南地区(成都)- ap-chengdu + * 西南地区(重庆)- ap-chongqing + * 华南地区(广州)- ap-guangzhou + * 港澳台地区(中国香港)- ap-hongkong + * 华东地区(南京)- ap-nanjing + * 华东地区(上海)- ap-shanghai + * 华东地区(上海金融)- ap-shanghai-fsi + * 华南地区(深圳金融)- ap-shenzhen-fsi + +* 亚太地区 + * 曼谷 - ap-bangkok + * 雅加达 - ap-jakarta + * 孟买 - ap-mumbai + * 首尔 - ap-seoul + * 新加坡 - ap-singapore + * 东京 - ap-tokyo + +* 欧洲地区 + * 法兰克福 - eu-frankfurt + * 莫斯科 - eu-moscow + +* 北美地区 + * 弗吉尼亚 - na-ashburn + * 硅谷 - na-siliconvalley + * 多伦多 - na-toronto + +## 更多文档 + +* [腾讯云API密钥管理](https://console.cloud.tencent.com/cam/capi) +* [腾讯云地域和可用区](https://cloud.tencent.com/document/product/213/6091) + +[English](./README.EN.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.TTS/README.EN.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.TTS/README.EN.md new file mode 100644 index 000000000..91833c60d --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.TTS/README.EN.md @@ -0,0 +1,93 @@ +# LINGYUN.Abp.Tencent.TTS + +Tencent Cloud Text-to-Speech (TTS) Service Module, integrating Tencent Cloud TTS service into ABP applications. + +## Features + +* Support for Tencent Cloud Text-to-Speech (TTS) service +* Multi-tenant configuration support +* Based on Tencent Cloud TTS SDK V20190823 +* Provides TTS client factory for dynamic TTS client creation + +## Basic Usage + +1. Add module dependency +```csharp +[DependsOn(typeof(AbpTencentTTSModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. Configure Tencent Cloud service +```json +{ + "Settings": { + "LINGYUN.Abp.Tencent": { + "SecretId": "Your Tencent Cloud SecretId", + "SecretKey": "Your Tencent Cloud SecretKey" + } + } +} +``` + +3. TTS service usage example +```csharp +public class YourService +{ + private readonly TencentCloudTTSClientFactory _ttsClientFactory; + + public YourService(TencentCloudTTSClientFactory ttsClientFactory) + { + _ttsClientFactory = ttsClientFactory; + } + + public async Task TextToSpeechAsync(string text) + { + var ttsClient = await _ttsClientFactory.CreateAsync(); + // Use ttsClient to call Tencent Cloud TTS service APIs + // For detailed API usage, please refer to Tencent Cloud TTS SDK documentation + } +} +``` + +## Configuration Items + +### Basic Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "Your Tencent Cloud SecretId", // Get from Tencent Cloud Console + "SecretKey": "Your Tencent Cloud SecretKey", // Get from Tencent Cloud Console + "DurationSecond": "600" // Session duration in seconds + } + } +} +``` + +### TTS Service Configuration + +```json +{ + "Settings": { + "Abp.TencentCloud.TTS": { + "AppId": "", // TTS application ID + "VoiceType": "", // Voice type, default is "0" + "Language": "1", // Language, 1-Chinese, 2-English + "Speed": "0", // Speech speed, range: -2~2 + "Volume": "0", // Volume, range: 0~10 + "ProjectId": "0" // Project ID + } + } +} +``` + +## More Documentation + +* [Tencent Cloud TTS Service](https://cloud.tencent.com/document/product/1073) +* [Tencent Cloud TTS SDK Documentation](https://cloud.tencent.com/document/product/1073/37927) + +[简体中文](./README.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.TTS/README.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.TTS/README.md new file mode 100644 index 000000000..d3e13d3d6 --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent.TTS/README.md @@ -0,0 +1,93 @@ +# LINGYUN.Abp.Tencent.TTS + +腾讯云语音合成服务模块,集成腾讯云语音合成服务到ABP应用程序。 + +## 功能特性 + +* 支持腾讯云语音合成服务(TTS) +* 支持多租户配置 +* 基于腾讯云TTS SDK V20190823 +* 提供TTS客户端工厂,支持动态创建TTS客户端 + +## 基本用法 + +1. 添加模块依赖 +```csharp +[DependsOn(typeof(AbpTencentTTSModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. 配置腾讯云服务 +```json +{ + "Settings": { + "LINGYUN.Abp.Tencent": { + "SecretId": "您的腾讯云SecretId", + "SecretKey": "您的腾讯云SecretKey" + } + } +} +``` + +3. 使用TTS服务示例 +```csharp +public class YourService +{ + private readonly TencentCloudTTSClientFactory _ttsClientFactory; + + public YourService(TencentCloudTTSClientFactory ttsClientFactory) + { + _ttsClientFactory = ttsClientFactory; + } + + public async Task TextToSpeechAsync(string text) + { + var ttsClient = await _ttsClientFactory.CreateAsync(); + // 使用ttsClient调用腾讯云TTS服务API + // 详细API使用方法请参考腾讯云TTS SDK文档 + } +} +``` + +## 配置项说明 + +### 基础配置 + +```json +{ + "Settings": { + "Abp.TencentCloud": { + "SecretId": "您的腾讯云SecretId", // 从腾讯云控制台获取 + "SecretKey": "您的腾讯云SecretKey", // 从腾讯云控制台获取 + "DurationSecond": "600" // 会话持续时间(秒) + } + } +} +``` + +### TTS服务配置 + +```json +{ + "Settings": { + "Abp.TencentCloud.TTS": { + "AppId": "", // TTS应用ID + "VoiceType": "", // 音色,默认为"0" + "Language": "1", // 语言,1-中文,2-英文 + "Speed": "0", // 语速,范围:-2~2 + "Volume": "0", // 音量,范围:0~10 + "ProjectId": "0" // 项目ID + } + } +} +``` + +## 更多文档 + +* [腾讯云语音合成服务](https://cloud.tencent.com/document/product/1073) +* [腾讯云TTS SDK文档](https://cloud.tencent.com/document/product/1073/37927) + +[English](./README.EN.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent/README.EN.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent/README.EN.md new file mode 100644 index 000000000..e042c59a2 --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent/README.EN.md @@ -0,0 +1,87 @@ +# LINGYUN.Abp.Tencent + +Tencent Cloud Service Base Module, providing infrastructure support for other Tencent Cloud service modules. + +## Features + +* Provides Tencent Cloud SDK client factory, supporting dynamic creation of clients for various Tencent Cloud services +* Multi-tenant configuration support +* Built-in localization support (Chinese and English) +* Unified Tencent Cloud service configuration management +* Feature management support, enabling/disabling functionalities as needed +* Region localization display support + +## Configuration + +### Basic Settings + +```json +{ + "Settings": { + "LINGYUN.Abp.Tencent": { + "EndPoint": "ap-guangzhou", // Resource region, default is Guangzhou + "SecretId": "Your Tencent Cloud SecretId", // Get from Tencent Cloud Console + "SecretKey": "Your Tencent Cloud SecretKey", // Get from Tencent Cloud Console + "DurationSecond": "600" // Session duration in seconds + } + } +} +``` + +### Connection Settings + +```json +{ + "Settings": { + "LINGYUN.Abp.Tencent.Connection": { + "HttpMethod": "POST", // Request method, default is POST + "Timeout": "60", // Connection timeout in seconds + "WebProxy": "" // Proxy server address, optional + } + } +} +``` + +## Basic Usage + +1. Add module dependency +```csharp +[DependsOn(typeof(AbpTencentCloudModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. Configure Tencent Cloud service +```json +{ + "Settings": { + "LINGYUN.Abp.Tencent": { + "SecretId": "Your Tencent Cloud SecretId", + "SecretKey": "Your Tencent Cloud SecretKey" + } + } +} +``` + +## Advanced Features + +### Feature Management + +The module provides the following feature switches: + +* TencentSms - Tencent Cloud SMS service +* TencentBlobStoring - Tencent Cloud Object Storage service + * MaximumStreamSize - Maximum file stream size limit for single upload (MB) + +### Multi-tenant Support + +All configurations support multi-tenant settings, allowing different Tencent Cloud service parameters for different tenants. + +## More Documentation + +* [Tencent Cloud API Key Management](https://console.cloud.tencent.com/cam/capi) +* [Tencent Cloud Regions and Availability Zones](https://cloud.tencent.com/document/product/213/6091) + +[简体中文](./README.md) diff --git a/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent/README.md b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent/README.md new file mode 100644 index 000000000..4e6af7322 --- /dev/null +++ b/aspnet-core/framework/cloud-tencent/LINGYUN.Abp.Tencent/README.md @@ -0,0 +1,87 @@ +# LINGYUN.Abp.Tencent + +腾讯云服务基础模块,为其他腾讯云服务模块提供基础设施支持。 + +## 功能特性 + +* 提供腾讯云SDK客户端工厂,支持动态创建腾讯云各项服务的客户端 +* 支持多租户配置 +* 内置多语言本地化支持(中文和英文) +* 提供统一的腾讯云服务配置管理 +* 支持特性(Feature)管理,可按需启用/禁用功能 +* 支持区域(Region)本地化显示 + +## 配置项 + +### 基础配置 + +```json +{ + "Settings": { + "LINGYUN.Abp.Tencent": { + "EndPoint": "ap-guangzhou", // 资源所在地域,默认为广州 + "SecretId": "您的腾讯云SecretId", // 从腾讯云控制台获取 + "SecretKey": "您的腾讯云SecretKey", // 从腾讯云控制台获取 + "DurationSecond": "600" // 会话持续时长,单位秒 + } + } +} +``` + +### 连接配置 + +```json +{ + "Settings": { + "LINGYUN.Abp.Tencent.Connection": { + "HttpMethod": "POST", // 请求方法,默认POST + "Timeout": "60", // 连接超时时间,单位秒 + "WebProxy": "" // 代理服务器地址,可选 + } + } +} +``` + +## 基本用法 + +1. 添加模块依赖 +```csharp +[DependsOn(typeof(AbpTencentCloudModule))] +public class YourModule : AbpModule +{ + // ... +} +``` + +2. 配置腾讯云服务 +```json +{ + "Settings": { + "LINGYUN.Abp.Tencent": { + "SecretId": "您的腾讯云SecretId", + "SecretKey": "您的腾讯云SecretKey" + } + } +} +``` + +## 高级特性 + +### 特性管理 + +模块提供以下特性开关: + +* TencentSms - 腾讯云短信服务 +* TencentBlobStoring - 腾讯云对象存储服务 + * MaximumStreamSize - 单次上传文件流大小限制(MB) + +### 多租户支持 + +所有配置均支持多租户配置,可以为不同租户配置不同的腾讯云服务参数。 + +## 更多文档 + +* [腾讯云API密钥管理](https://console.cloud.tencent.com/cam/capi) +* [腾讯云地域和可用区](https://cloud.tencent.com/document/product/213/6091) + +[English](./README.EN.md)