mirror of
https://gitee.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat.git
synced 2026-02-17 21:56:26 +08:00
feat(wxapi): 新增自定义交易组件分享员相关接口
This commit is contained in:
@@ -1047,5 +1047,147 @@ namespace SKIT.FlurlHttpClient.Wechat.Api
|
||||
return await client.SendRequestWithJsonAsync<Models.ShopPromoterListResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Sharer
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /shop/sharer/bind 接口。</para>
|
||||
/// <para>REF: https://developers.weixin.qq.com/miniprogram/dev/platform-capabilities/business-capabilities/ministore/minishopopencomponent2/API/sharer/bind_sharer.html </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.ShopSharerBindResponse> ExecuteShopSharerBindAsync(this WechatApiClient client, Models.ShopSharerBindRequest request, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (client is null) throw new ArgumentNullException(nameof(client));
|
||||
if (request is null) throw new ArgumentNullException(nameof(request));
|
||||
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "shop", "sharer", "bind")
|
||||
.SetQueryParam("access_token", request.AccessToken);
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.ShopSharerBindResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /shop/sharer/get_sharer_data_summary 接口。</para>
|
||||
/// <para>REF: https://developers.weixin.qq.com/miniprogram/dev/platform-capabilities/business-capabilities/ministore/minishopopencomponent2/API/sharer/get_sharer_data_summary.html </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.ShopSharerGetSharerDataSummaryResponse> ExecuteShopSharerGetSharerDataSummaryAsync(this WechatApiClient client, Models.ShopSharerGetSharerDataSummaryRequest request, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (client is null) throw new ArgumentNullException(nameof(client));
|
||||
if (request is null) throw new ArgumentNullException(nameof(request));
|
||||
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "shop", "sharer", "get_sharer_data_summary")
|
||||
.SetQueryParam("access_token", request.AccessToken);
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.ShopSharerGetSharerDataSummaryResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /shop/sharer/get_sharer_list 接口。</para>
|
||||
/// <para>REF: https://developers.weixin.qq.com/miniprogram/dev/platform-capabilities/business-capabilities/ministore/minishopopencomponent2/API/sharer/get_sharer_list.html </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.ShopSharerGetSharerListResponse> ExecuteShopSharerGetSharerListAsync(this WechatApiClient client, Models.ShopSharerGetSharerListRequest request, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (client is null) throw new ArgumentNullException(nameof(client));
|
||||
if (request is null) throw new ArgumentNullException(nameof(request));
|
||||
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "shop", "sharer", "get_sharer_list")
|
||||
.SetQueryParam("access_token", request.AccessToken);
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.ShopSharerGetSharerListResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /shop/sharer/get_sharer_live_order_list 接口。</para>
|
||||
/// <para>REF: https://developers.weixin.qq.com/miniprogram/dev/platform-capabilities/business-capabilities/ministore/minishopopencomponent2/API/sharer/get_sharer_live_order_list.html </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.ShopSharerGetSharerLiveOrderListResponse> ExecuteShopSharerGetSharerLiveOrderListAsync(this WechatApiClient client, Models.ShopSharerGetSharerLiveOrderListRequest request, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (client is null) throw new ArgumentNullException(nameof(client));
|
||||
if (request is null) throw new ArgumentNullException(nameof(request));
|
||||
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "shop", "sharer", "get_sharer_live_order_list")
|
||||
.SetQueryParam("access_token", request.AccessToken);
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.ShopSharerGetSharerLiveOrderListResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /shop/sharer/get_sharer_live_summary_list 接口。</para>
|
||||
/// <para>REF: https://developers.weixin.qq.com/miniprogram/dev/platform-capabilities/business-capabilities/ministore/minishopopencomponent2/API/sharer/get_sharer_live_summary_list.html </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.ShopSharerGetSharerLiveSummaryListResponse> ExecuteShopSharerGetSharerLiveSummaryListAsync(this WechatApiClient client, Models.ShopSharerGetSharerLiveSummaryListRequest request, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (client is null) throw new ArgumentNullException(nameof(client));
|
||||
if (request is null) throw new ArgumentNullException(nameof(request));
|
||||
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "shop", "sharer", "get_sharer_live_summary_list")
|
||||
.SetQueryParam("access_token", request.AccessToken);
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.ShopSharerGetSharerLiveSummaryListResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /shop/sharer/search_sharer 接口。</para>
|
||||
/// <para>REF: https://developers.weixin.qq.com/miniprogram/dev/platform-capabilities/business-capabilities/ministore/minishopopencomponent2/API/sharer/search_sharer.html </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.ShopSharerSearchSharerResponse> ExecuteShopSharerSearchSharerAsync(this WechatApiClient client, Models.ShopSharerSearchSharerRequest request, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (client is null) throw new ArgumentNullException(nameof(client));
|
||||
if (request is null) throw new ArgumentNullException(nameof(request));
|
||||
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "shop", "sharer", "search_sharer")
|
||||
.SetQueryParam("access_token", request.AccessToken);
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.ShopSharerSearchSharerResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /shop/sharer/unbind 接口。</para>
|
||||
/// <para>REF: https://developers.weixin.qq.com/miniprogram/dev/platform-capabilities/business-capabilities/ministore/minishopopencomponent2/API/sharer/unbind_sharer.html </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.ShopSharerUnbindResponse> ExecuteShopSharerUnbindAsync(this WechatApiClient client, Models.ShopSharerUnbindRequest request, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (client is null) throw new ArgumentNullException(nameof(client));
|
||||
if (request is null) throw new ArgumentNullException(nameof(request));
|
||||
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "shop", "sharer", "unbind")
|
||||
.SetQueryParam("access_token", request.AccessToken);
|
||||
|
||||
return await client.SendRequestWithJsonAsync<Models.ShopSharerUnbindResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -239,6 +239,13 @@ namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promoter_openid")]
|
||||
public string? PromoterOpenId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置推广员用户名。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("finder_username")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("finder_username")]
|
||||
public string? FinderUsername { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置推广员昵称。
|
||||
/// </summary>
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/bind 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerBindRequest : WechatApiRequest, IInferable<ShopSharerBindRequest, ShopSharerBindResponse>
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员 OpenId 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("openids")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("openids")]
|
||||
public IList<string> OpenIdList { get; set; } = new List<string>();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,63 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/bind 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerBindResponse : WechatApiResponse
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class Result
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员 OpenId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("openid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("openid")]
|
||||
public string OpenId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置邀请结果代码。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("result_code")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("result_code")]
|
||||
public int ResultCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置邀请错误原因代码。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("reason_code")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("reason_code")]
|
||||
public int ReasonCode { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置绑定成功的分享员 OpenId 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("success_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("success_list")]
|
||||
public string[] SuccessOpenIdList { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置绑定失败的分享员 OpenId 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("fail_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("fail_list")]
|
||||
public string[] FailOpenIdList { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置绑定拒绝的分享员 OpenId 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refuse_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refuse_list")]
|
||||
public string[] RefuseOpenIdList { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置绑定结果列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("result_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("result_list")]
|
||||
public Types.Result[] ResultList { get; set; } = default!;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/get_sharer_data_summary 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerGetSharerDataSummaryRequest : WechatApiRequest, IInferable<ShopSharerGetSharerDataSummaryRequest, ShopSharerGetSharerDataSummaryResponse>
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员 OpenId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("openid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("openid")]
|
||||
public string OpenId { get; set; } = string.Empty;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/get_sharer_data_summary 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerGetSharerDataSummaryResponse : WechatApiResponse
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员有效带货额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("gmv")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("gmv")]
|
||||
public int GMV { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置订单数。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("order_cnt")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("order_cnt")]
|
||||
public int OrderCount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置下单用户数。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("user_cnt")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("user_cnt")]
|
||||
public int UserCount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/get_sharer_list 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerGetSharerListRequest : WechatApiRequest, IInferable<ShopSharerGetSharerListRequest, ShopSharerGetSharerListResponse>
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分页页数(从 1 开始)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("page")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("page")]
|
||||
public int Page { get; set; } = 1;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置分页每页数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("page_size")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("page_size")]
|
||||
public int Limit { get; set; } = 10;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,56 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/get_sharer_list 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerGetSharerListResponse : WechatApiResponse
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class Sharer
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员 OpenId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("openid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("openid")]
|
||||
public string OpenId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置分享员昵称。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("nickname")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("nickname")]
|
||||
public string Nickname { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置邀请时间戳。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("invited_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("invited_time")]
|
||||
public long InviteTimestamp { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置绑定时间戳。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("bind_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("bind_time")]
|
||||
public long BindTimestamp { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置分享员列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("sharers")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("sharers")]
|
||||
public Types.Sharer[] SharerList { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置总数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_num")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_num")]
|
||||
public int TotalCount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/get_sharer_live_order_list 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerGetSharerLiveOrderListRequest : WechatApiRequest, IInferable<ShopSharerGetSharerLiveOrderListRequest, ShopSharerGetSharerLiveOrderListResponse>
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员 OpenId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("openid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("openid")]
|
||||
public string OpenId { get; set; } = string.Empty;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置直播间 ExportId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("live_export_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("live_export_id")]
|
||||
public string LiveExportId { get; set; } = string.Empty;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置分页页数(从 1 开始)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("page")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("page")]
|
||||
public int Page { get; set; } = 1;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置分页每页数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("page_size")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("page_size")]
|
||||
public int Limit { get; set; } = 10;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/get_sharer_live_order_list 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerGetSharerLiveOrderListResponse : WechatApiResponse
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class Order : ShopOrderGetListResponse.Types.Order
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置订单列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("orders")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("orders")]
|
||||
public Types.Order[] OrderList { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置总数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_num")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_num")]
|
||||
public int TotalCount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/get_sharer_live_summary_list 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerGetSharerLiveSummaryListRequest : WechatApiRequest, IInferable<ShopSharerGetSharerLiveSummaryListRequest, ShopSharerGetSharerLiveOrderListResponse>
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员 OpenId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("openid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("openid")]
|
||||
public string OpenId { get; set; } = string.Empty;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置分页页数(从 1 开始)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("page")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("page")]
|
||||
public int Page { get; set; } = 1;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置分页每页数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("page_size")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("page_size")]
|
||||
public int Limit { get; set; } = 10;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,84 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/get_sharer_live_summary_list 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerGetSharerLiveSummaryListResponse : WechatApiResponse
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class Live
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置直播间 ExportId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("live_export_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("live_export_id")]
|
||||
public string LiveExportId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置直播间昵称。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("live_nickname")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("live_nickname")]
|
||||
public string LiveNickname { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置直播开始时间戳。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("live_start_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("live_start_time")]
|
||||
public long LiveStartTimestamp { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置直播结束时间戳。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("live_end_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("live_end_time")]
|
||||
public long LiveEndTimestamp { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置直播状态。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("live_status")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("live_status")]
|
||||
public int LiveStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置分享员有效带货额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("gmv")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("gmv")]
|
||||
public int GMV { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置订单数。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("order_cnt")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("order_cnt")]
|
||||
public int OrderCount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置下单用户数。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("user_cnt")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("user_cnt")]
|
||||
public int UserCount { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置直播列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("lives")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("lives")]
|
||||
public Types.Live[] LiveList { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置总数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_num")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_num")]
|
||||
public int TotalCount { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/search_sharer 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerSearchSharerRequest : WechatApiRequest, IInferable<ShopSharerSearchSharerRequest, ShopSharerSearchSharerResponse>
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员 OpenId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("openid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("openid")]
|
||||
public string OpenId { get; set; } = string.Empty;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/search_sharer 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerSearchSharerResponse : WechatApiResponse
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员昵称。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("nickname")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("nickname")]
|
||||
public string Nickname { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置邀请时间戳。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("invited_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("invited_time")]
|
||||
public long InviteTimestamp { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置绑定状态。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("bind_status")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("bind_status")]
|
||||
public int BindStatus { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置绑定时间戳。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("bind_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("bind_time")]
|
||||
public long? BindTimestamp { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/unbind 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerUnbindRequest : WechatApiRequest, IInferable<ShopSharerUnbindRequest, ShopSharerUnbindResponse>
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置分享员 OpenId 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("openids")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("openids")]
|
||||
public IList<string> OpenIdList { get; set; } = new List<string>();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Api.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /shop/sharer/unbind 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class ShopSharerUnbindResponse : WechatApiResponse
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置解绑成功的分享员 OpenId 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("success_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("success_list")]
|
||||
public string[] SuccessOpenIdList { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置解绑失败的分享员 OpenId 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("fail_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("fail_list")]
|
||||
public string[] FailOpenIdList { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置解绑拒绝的分享员 OpenId 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refuse_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refuse_list")]
|
||||
public string[] RefuseOpenIdList { get; set; } = default!;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user