mirror of
https://gitee.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat.git
synced 2026-03-10 00:13:36 +08:00
style: format
This commit is contained in:
@@ -1,3 +1,3 @@
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
[assembly: InternalsVisibleTo("SKIT.FlurlHttpClient.Wechat.Ads.UnitTests")]
|
||||
[assembly: InternalsVisibleTo("SKIT.FlurlHttpClient.Wechat.Ads.UnitTests")]
|
||||
|
||||
@@ -22,4 +22,4 @@
|
||||
|
||||
### 【更新日志】
|
||||
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
|
||||
@@ -8,17 +8,17 @@ namespace SKIT.FlurlHttpClient.Wechat.Ads
|
||||
public abstract class WechatAdsResponse : ICommonResponse
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
int ICommonResponse.RawStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
IDictionary<string, string> ICommonResponse.RawHeaders { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
byte[] ICommonResponse.RawBytes { get; set; } = default!;
|
||||
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /cgi-bin/express/delivery/open_msg/open_openmsg 接口的请求。</para>
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /cgi-bin/express/delivery/open_msg/open_query_plugin 接口的请求。</para>
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
[System.Obsolete]
|
||||
public class Article : CgibinMaterialGetMaterialAsNewsResponse.Types.Article
|
||||
{
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
[System.Obsolete]
|
||||
public class Article : CgibinMaterialAddNewsRequest.Types.Article
|
||||
{
|
||||
}
|
||||
|
||||
@@ -74,4 +74,4 @@ namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("env_version")]
|
||||
public string? EnvironmentVersion { get; set; }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /wxa/business/checkencryptedmsg 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class WxaBusinessCheckEncryptedMessageResponse : WechatApiResponse
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置是否是合法的数据。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("vaild")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("vaild")]
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /wxa/business/checkencryptedmsg 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class WxaBusinessCheckEncryptedMessageResponse : WechatApiResponse
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置是否是合法的数据。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("vaild")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("vaild")]
|
||||
public bool IsValid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置加密数据生成的时间戳。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("create_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("create_time")]
|
||||
/// <summary>
|
||||
/// 获取或设置加密数据生成的时间戳。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("create_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("create_time")]
|
||||
public long CreateTimestamp { get; set; }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,4 +22,4 @@
|
||||
|
||||
### 【更新日志】
|
||||
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
|
||||
@@ -8,17 +8,17 @@ namespace SKIT.FlurlHttpClient.Wechat.Api
|
||||
public abstract class WechatApiResponse : ICommonResponse
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
int ICommonResponse.RawStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
IDictionary<string, string> ICommonResponse.RawHeaders { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
byte[] ICommonResponse.RawBytes { get; set; } = default!;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.OpenAI
|
||||
{
|
||||
@@ -35,10 +35,10 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI
|
||||
|
||||
try
|
||||
{
|
||||
if (!Utilities.WxBizMsgCryptor.TryParseXml(callbackXml, out string? encryptedXml))
|
||||
if (!Utilities.WechatEventDataCryptor.TryParseXml(callbackXml, out string? encryptedXml))
|
||||
throw new Exceptions.WechatOpenAIEventSerializationException("Encrypt event failed, because of empty encrypted data.");
|
||||
|
||||
callbackXml = Utilities.WxBizMsgCryptor.AESDecrypt(cipherText: encryptedXml!, encodingAESKey: client.Credentials.EncodingAESKey!, out _);
|
||||
callbackXml = Utilities.WechatEventDataCryptor.AESDecrypt(cipherText: encryptedXml!, encodingAESKey: client.Credentials.EncodingAESKey!, out _);
|
||||
return Utilities.XmlUtility.Deserialize<TEvent>(callbackXml);
|
||||
}
|
||||
catch (WechatOpenAIException)
|
||||
@@ -104,13 +104,13 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI
|
||||
|
||||
try
|
||||
{
|
||||
string cipher = Utilities.WxBizMsgCryptor.AESEncrypt(
|
||||
string cipher = Utilities.WechatEventDataCryptor.AESEncrypt(
|
||||
plainText: xml,
|
||||
encodingAESKey: client.Credentials.EncodingAESKey!,
|
||||
appId: client.Credentials.AppId!
|
||||
);
|
||||
|
||||
xml = Utilities.WxBizMsgCryptor.WrapXml(sToken: client.Credentials.Token!, sMsgEncrypt: cipher);
|
||||
xml = Utilities.WechatEventDataCryptor.WrapXml(sToken: client.Credentials.Token!, sMsgEncrypt: cipher);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using System.Net.Http;
|
||||
using System.Net.Http.Headers;
|
||||
using System.Text;
|
||||
@@ -112,7 +112,7 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI
|
||||
|
||||
using var fileContent = new ByteArrayContent(request.FileBytes ?? Array.Empty<byte>());
|
||||
using var paramContent = new StringContent(
|
||||
Utilities.WxBizMsgCryptor.AESEncrypt(
|
||||
Utilities.WechatEventDataCryptor.AESEncrypt(
|
||||
plainText: Utilities.XmlUtility.Serialize(request),
|
||||
encodingAESKey: client.Credentials.EncodingAESKey!,
|
||||
appId: client.Credentials.AppId!
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
[assembly: InternalsVisibleTo("SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests")]
|
||||
[assembly: InternalsVisibleTo("SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests")]
|
||||
|
||||
@@ -24,4 +24,4 @@
|
||||
|
||||
### 【更新日志】
|
||||
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="JWT" Version="8.9.0" />
|
||||
<PackageReference Include="JWT" Version="9.0.0" />
|
||||
<PackageReference Include="SKIT.FlurlHttpClient.Common" Version="2.5.0" />
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using JWT;
|
||||
using JWT.Algorithms;
|
||||
using JWT.Serializers;
|
||||
@@ -10,7 +10,9 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI.Utilities
|
||||
{
|
||||
private static readonly Lazy<IJwtEncoder> _encoder = new Lazy<IJwtEncoder>(() =>
|
||||
{
|
||||
#pragma warning disable CS0618
|
||||
IJwtAlgorithm algorithm = new HMACSHA256Algorithm();
|
||||
#pragma warning restore CS0618
|
||||
IJsonSerializer serializer = new JsonNetSerializer(new JsonSerializer() { NullValueHandling = NullValueHandling.Ignore });
|
||||
IBase64UrlEncoder urlEncoder = new JwtBase64UrlEncoder();
|
||||
IJwtEncoder encoder = new JwtEncoder(algorithm, serializer, urlEncoder);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using JWT;
|
||||
using JWT.Algorithms;
|
||||
using JWT.Serializers;
|
||||
@@ -10,7 +10,9 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI.Utilities
|
||||
{
|
||||
private static readonly Lazy<IJwtEncoder> _encoder = new Lazy<IJwtEncoder>(() =>
|
||||
{
|
||||
#pragma warning disable CS0618
|
||||
IJwtAlgorithm algorithm = new HMACSHA256Algorithm();
|
||||
#pragma warning restore CS0618
|
||||
IJsonSerializer serializer = new JsonNetSerializer(new JsonSerializer() { NullValueHandling = NullValueHandling.Ignore });
|
||||
IBase64UrlEncoder urlEncoder = new JwtBase64UrlEncoder();
|
||||
IJwtEncoder encoder = new JwtEncoder(algorithm, serializer, urlEncoder);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
@@ -10,7 +10,7 @@ using System.Xml;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.OpenAI.Utilities
|
||||
{
|
||||
public static class WxBizMsgCryptor
|
||||
internal static class WechatEventDataCryptor
|
||||
{
|
||||
private const int AES_KEY_SIZE = 256;
|
||||
private const int AES_BLOCK_SIZE = 128;
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using System.Net.Http;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
@@ -103,7 +103,7 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI
|
||||
if (data is WechatOpenAIPlatformRequest.Serialization.IEncryptedXmlable)
|
||||
{
|
||||
string plainXml = Utilities.XmlUtility.Serialize(data);
|
||||
string encryptedXml = Utilities.WxBizMsgCryptor.AESEncrypt(plainText: plainXml, encodingAESKey: Credentials.EncodingAESKey!, appId: Credentials.AppId!);
|
||||
string encryptedXml = Utilities.WechatEventDataCryptor.AESEncrypt(plainText: plainXml, encodingAESKey: Credentials.EncodingAESKey!, appId: Credentials.AppId!);
|
||||
data = new { encrypt = encryptedXml };
|
||||
}
|
||||
|
||||
|
||||
@@ -8,17 +8,17 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI
|
||||
public abstract class WechatOpenAIPlatformResponse : ICommonResponse
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
int ICommonResponse.RawStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
IDictionary<string, string> ICommonResponse.RawHeaders { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
byte[] ICommonResponse.RawBytes { get; set; } = default!;
|
||||
|
||||
|
||||
@@ -8,17 +8,17 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI
|
||||
public abstract class WechatOpenAIThirdPartyResponse : ICommonResponse
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
int ICommonResponse.RawStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
IDictionary<string, string> ICommonResponse.RawHeaders { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
byte[] ICommonResponse.RawBytes { get; set; } = default!;
|
||||
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
using System.Net.Http;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using Flurl;
|
||||
using Flurl.Http;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
[assembly: InternalsVisibleTo("SKIT.FlurlHttpClient.Wechat.TenpayV2.UnitTests")]
|
||||
[assembly: InternalsVisibleTo("SKIT.FlurlHttpClient.Wechat.TenpayV2.UnitTests")]
|
||||
|
||||
@@ -26,4 +26,4 @@
|
||||
|
||||
### 【更新日志】
|
||||
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
|
||||
@@ -44,4 +44,4 @@
|
||||
<PackageReference Include="SKIT.FlurlHttpClient.Common" Version="2.5.0" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
</Project>
|
||||
|
||||
@@ -8,17 +8,17 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2
|
||||
public abstract class WechatTenpayResponse : ICommonResponse
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
int ICommonResponse.RawStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
IDictionary<string, string> ICommonResponse.RawHeaders { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
byte[] ICommonResponse.RawBytes { get; set; } = default!;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using System.Net.Http;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
@@ -37,7 +37,7 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "marketing", "bank", "packages", request.PackageId, "tasks");
|
||||
|
||||
using var httpContent = Utilities.FileHttpContentBuilder.Build(fileName: request.FileName, fileBytes: request.FileBytes, fileContentType: request.FileContentType, fileMetaJson: client.JsonSerializer.Serialize(request));
|
||||
using var httpContent = Utilities.FileHttpContentBuilder.Build(fileName: request.FileName, fileBytes: request.FileBytes!, fileContentType: request.FileContentType, fileMetaJson: client.JsonSerializer.Serialize(request));
|
||||
return await client.SendRequestAsync<Models.UploadMarketingBankPackagesTasksResponse>(flurlReq, httpContent: httpContent, cancellationToken: cancellationToken);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
[assembly: InternalsVisibleTo("SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests")]
|
||||
[assembly: InternalsVisibleTo("SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests")]
|
||||
|
||||
@@ -24,4 +24,4 @@
|
||||
|
||||
### 【更新日志】
|
||||
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
|
||||
@@ -45,4 +45,4 @@
|
||||
<PackageReference Include="SKIT.FlurlHttpClient.Common" Version="2.5.0" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
</Project>
|
||||
|
||||
@@ -98,7 +98,7 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.Utilities
|
||||
{
|
||||
InnerReplacePropertyStringValue(ref element, replacement);
|
||||
//if (!array.IsReadOnly)
|
||||
//{
|
||||
//{
|
||||
// array.SetValue(element, i);
|
||||
//}
|
||||
}
|
||||
|
||||
@@ -9,17 +9,17 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3
|
||||
public abstract class WechatTenpayResponse : ICommonResponse
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
int ICommonResponse.RawStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
IDictionary<string, string> ICommonResponse.RawHeaders { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
byte[] ICommonResponse.RawBytes { get; set; } = default!;
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailGroupCreateResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/exmail/group/update 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95510 </para>
|
||||
@@ -49,7 +49,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailGroupUpdateResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/exmail/group/delete 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95510 </para>
|
||||
@@ -69,7 +69,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailGroupDeleteResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [GET] /cgi-bin/exmail/group/search 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95510 </para>
|
||||
@@ -93,7 +93,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailGroupSearchResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [GET] /cgi-bin/exmail/group/get 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95510 </para>
|
||||
@@ -136,7 +136,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailPublicMailCreateResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/exmail/publicmail/update 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95511 </para>
|
||||
@@ -156,7 +156,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailPublicMailUpdateResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/exmail/publicmail/delete 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95511 </para>
|
||||
@@ -176,7 +176,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailPublicMailDeleteResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [GET] /cgi-bin/exmail/publicmail/search 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95510 </para>
|
||||
@@ -200,7 +200,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailPublicMailSearchResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/exmail/publicmail/get 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95510 </para>
|
||||
@@ -221,7 +221,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailPublicMailGetResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
#region Account
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/exmail/account/act_email 接口。</para>
|
||||
@@ -243,7 +243,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailAccountActiveEmailResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
#region UserOption
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/exmail/useroption/get 接口。</para>
|
||||
@@ -264,7 +264,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinExmailUserOptionGetResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/exmail/useroption/update 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95513 </para>
|
||||
|
||||
@@ -374,7 +374,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinKfSyncMessageResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [GET] /cgi-bin/kf/get_corp_qualification 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95153 </para>
|
||||
@@ -394,7 +394,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinKfGetCorpQualificationResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/kf/get_corp_statistic 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95489 </para>
|
||||
@@ -414,7 +414,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinKfGetCorpStatisticResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/kf/get_servicer_statistic 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95490 </para>
|
||||
|
||||
@@ -436,7 +436,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinReportResidentGetOrderInfoResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
#region SiteCode
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/report/sitecode/list 接口。</para>
|
||||
@@ -457,7 +457,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinReportSiteCodeListResponse>(flurlReq, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/report/sitecode/get_site_report_info 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95461 </para>
|
||||
@@ -477,7 +477,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.CgibinReportSiteCodeGetSiteReportInfoResponse>(flurlReq, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /cgi-bin/report/sitecode/get_report_answer 接口。</para>
|
||||
/// <para>REF: https://developer.work.weixin.qq.com/document/path/95464 </para>
|
||||
|
||||
@@ -73,7 +73,7 @@
|
||||
public Types.DepartmentIdList? AllowDepartmentIdList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置业务邮箱列表。
|
||||
/// </summary>
|
||||
|
||||
@@ -43,7 +43,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[Newtonsoft.Json.JsonProperty("userid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("userid")]
|
||||
public string? UserId { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置功能设置列表。
|
||||
/// </summary>
|
||||
|
||||
@@ -40,4 +40,4 @@
|
||||
[System.Text.Json.Serialization.JsonPropertyName("rule_list")]
|
||||
public Types.Rule[] RuleList { get; set; } = default!;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -76,4 +76,4 @@
|
||||
[System.Text.Json.Serialization.JsonPropertyName("rule")]
|
||||
public Types.Rule Rule { get; set; } = default!;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -93,4 +93,4 @@
|
||||
[System.Text.Json.Serialization.JsonPropertyName("product_list")]
|
||||
public Types.Product[] ProductList { get; set; } = default!;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,4 +25,4 @@
|
||||
[System.Text.Json.Serialization.JsonPropertyName("product")]
|
||||
public Types.Product Product { get; set; } = default!;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -259,7 +259,7 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("s_timestamp")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("s_timestamp")]
|
||||
[System.Text.Json.Serialization.JsonConverter(typeof(System.Text.Json.Converters.TextualNullableLongConverter))]
|
||||
[System.Text.Json.Serialization.JsonConverter(typeof(System.Text.Json.Converters.TextualNullableLongConverter))]
|
||||
public long? Timestamp { get; set; }
|
||||
}
|
||||
|
||||
|
||||
@@ -361,4 +361,4 @@
|
||||
[System.Text.Json.Serialization.JsonPropertyName("external_profile")]
|
||||
public Types.ExternalProfile? ExternalProfile { get; set; }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,4 +23,4 @@
|
||||
|
||||
### 【更新日志】
|
||||
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
[点此查看](https://github.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat/blob/main/CHANGELOG.md)。
|
||||
|
||||
@@ -43,4 +43,4 @@
|
||||
<PackageReference Include="SKIT.FlurlHttpClient.Common" Version="2.5.0" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
</Project>
|
||||
|
||||
@@ -8,17 +8,17 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
public abstract class WechatWorkResponse : ICommonResponse
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
int ICommonResponse.RawStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
IDictionary<string, string> ICommonResponse.RawHeaders { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
///
|
||||
/// </summary>
|
||||
byte[] ICommonResponse.RawBytes { get; set; } = default!;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user