feat(wxapi): 新增微信长辈就医相关接口

This commit is contained in:
Fu Diwei
2024-06-17 16:27:08 +08:00
parent 39e372fc29
commit 0827d9f8c1
11 changed files with 195 additions and 1 deletions

View File

@@ -0,0 +1,29 @@
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
{
/// <summary>
/// <para>表示 [POST] /cityservice/getmedrealname 接口的请求。</para>
/// </summary>
public class CityServiceGetMedicalRealNameRequest : WechatApiRequest, IInferable<CityServiceGetMedicalRealNameRequest, CityServiceGetMedicalRealNameResponse>
{
/// <summary>
/// 获取或设置业务方 AppId。如果不指定将使用构造 <see cref="WechatApiClient"/> 时的 <see cref="WechatApiClientOptions.AppId"/> 参数。
/// </summary>
[Newtonsoft.Json.JsonProperty("app_id")]
[System.Text.Json.Serialization.JsonPropertyName("app_id")]
public string? AppId { get; set; }
/// <summary>
/// 获取或设置用户唯一标识。
/// </summary>
[Newtonsoft.Json.JsonProperty("open_id")]
[System.Text.Json.Serialization.JsonPropertyName("open_id")]
public string OpenId { get; set; } = string.Empty;
/// <summary>
/// 获取或设置实名信息 Code。
/// </summary>
[Newtonsoft.Json.JsonProperty("wxmed_authcode")]
[System.Text.Json.Serialization.JsonPropertyName("wxmed_authcode")]
public string AuthCode { get; set; } = string.Empty;
}
}

View File

@@ -0,0 +1,43 @@
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
{
/// <summary>
/// <para>表示 [POST] /cityservice/getmedrealname 接口的响应。</para>
/// </summary>
public class CityServiceGetMedicalRealNameResponse : WechatApiResponse
{
/// <summary>
/// 获取或设置业务方 AppId。
/// </summary>
[Newtonsoft.Json.JsonProperty("app_id")]
[System.Text.Json.Serialization.JsonPropertyName("app_id")]
public string AppId { get; set; } = default!;
/// <summary>
/// 获取或设置用户唯一标识。
/// </summary>
[Newtonsoft.Json.JsonProperty("open_id")]
[System.Text.Json.Serialization.JsonPropertyName("open_id")]
public string OpenId { get; set; } = default!;
/// <summary>
/// 获取或设置实名信息加密密钥版本号。
/// </summary>
[Newtonsoft.Json.JsonProperty("key_version")]
[System.Text.Json.Serialization.JsonPropertyName("key_version")]
public int KeyVersion { get; set; }
/// <summary>
/// 获取或设置加密后的实名信息。
/// </summary>
[Newtonsoft.Json.JsonProperty("cipher_real_name")]
[System.Text.Json.Serialization.JsonPropertyName("cipher_real_name")]
public string CipherRealName { get; set; } = default!;
/// <summary>
/// 获取或设置加密算法。
/// </summary>
[Newtonsoft.Json.JsonProperty("cipher_algorithm")]
[System.Text.Json.Serialization.JsonPropertyName("cipher_algorithm")]
public string CipherAlgorithm { get; set; } = default!;
}
}

View File

@@ -0,0 +1,22 @@
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
{
/// <summary>
/// <para>表示 [POST] /cityservice/getmsgrelation 接口的请求。</para>
/// </summary>
public class CityServiceGetMessageRelationRequest : WechatApiRequest, IInferable<CityServiceGetMessageRelationRequest, CityServiceGetMessageRelationResponse>
{
/// <summary>
/// 获取或设置业务 ID。
/// </summary>
[Newtonsoft.Json.JsonProperty("business_id")]
[System.Text.Json.Serialization.JsonPropertyName("business_id")]
public int BusinessId { get; set; }
/// <summary>
/// 获取或设置用户唯一标识。
/// </summary>
[Newtonsoft.Json.JsonProperty("open_id")]
[System.Text.Json.Serialization.JsonPropertyName("open_id")]
public string OpenId { get; set; } = string.Empty;
}
}

View File

@@ -0,0 +1,17 @@
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
{
/// <summary>
/// <para>表示 [POST] /cityservice/getmsgrelation 接口的响应。</para>
/// </summary>
public class CityServiceGetMessageRelationResponse : WechatApiResponse
{
/// <summary>
/// 获取或设置是否已订阅。
/// </summary>
[Newtonsoft.Json.JsonProperty("is_subscribed")]
[Newtonsoft.Json.JsonConverter(typeof(Newtonsoft.Json.Converters.Common.NumericalBooleanReadOnlyConverter))]
[System.Text.Json.Serialization.JsonPropertyName("is_subscribed")]
[System.Text.Json.Serialization.JsonConverter(typeof(System.Text.Json.Serialization.Common.NumericalBooleanReadOnlyConverter))]
public bool IsSubscribed { get; set; }
}
}

View File

@@ -651,6 +651,15 @@ namespace SKIT.FlurlHttpClient.Wechat.Api.Models
[System.Text.Json.Serialization.JsonPropertyName("business_id")]
public int BusinessId { get; set; }
/// <summary>
/// 获取或设置是否是测试版本。
/// </summary>
[Newtonsoft.Json.JsonProperty("testonly_is_trial")]
[Newtonsoft.Json.JsonConverter(typeof(Newtonsoft.Json.Converters.Common.NumericalBooleanConverter))]
[System.Text.Json.Serialization.JsonPropertyName("testonly_is_trial")]
[System.Text.Json.Serialization.JsonConverter(typeof(System.Text.Json.Serialization.Common.NumericalBooleanConverter))]
public bool? IsTrial { get; set; }
/// <summary>
/// 获取或设置业务字段。
/// </summary>