mirror of
https://gitee.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat.git
synced 2026-03-10 00:13:36 +08:00
feat(work): 新增营销获客相关接口
This commit is contained in:
@@ -801,6 +801,29 @@ namespace SKIT.FlurlHttpClient.Wechat.Work
|
||||
|
||||
return await client.SendFlurlRequestAsJsonAsync<Models.CgibinExternalContactCustomerAcquisitionGetChatInfoResponse>(flurlReq, data: request, cancellationToken: cancellationToken).ConfigureAwait(false);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [GET] /cgi-bin/externalcontact/customer_acquisition_app/get_permit 接口。</para>
|
||||
/// <para>
|
||||
/// REF: <br/>
|
||||
/// <![CDATA[ https://developer.work.weixin.qq.com/document/path/101146 ]]>
|
||||
/// </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.CgibinExternalContactCustomerAcquisitionAppGetPermitResponse> ExecuteCgibinExternalContactCustomerAcquisitionAppGetPermitAsync(this WechatWorkClient client, Models.CgibinExternalContactCustomerAcquisitionAppGetPermitRequest 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
|
||||
.CreateFlurlRequest(request, HttpMethod.Get, "cgi-bin", "externalcontact", "customer_acquisition_app", "get_permit")
|
||||
.SetQueryParam("access_token", request.AccessToken);
|
||||
|
||||
return await client.SendFlurlRequestAsJsonAsync<Models.CgibinExternalContactCustomerAcquisitionAppGetPermitResponse>(flurlReq, data: request, cancellationToken: cancellationToken).ConfigureAwait(false);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region CustomerStrategy
|
||||
|
||||
@@ -217,6 +217,13 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("is_exclusive")]
|
||||
public bool? IsExclusive { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否标记客户添加来源为该应用创建的。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mark_source")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mark_source")]
|
||||
public bool? IsMarkSource { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置结束语信息。
|
||||
/// </summary>
|
||||
|
||||
@@ -233,6 +233,13 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("is_exclusive")]
|
||||
public bool? IsExclusive { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否标记客户添加来源为该应用创建的。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mark_source")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mark_source")]
|
||||
public bool? IsMarkSource { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置结束语信息。
|
||||
/// </summary>
|
||||
|
||||
@@ -98,6 +98,13 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("is_exclusive")]
|
||||
public bool? IsExclusive { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否标记客户添加来源为该应用创建的。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mark_source")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mark_source")]
|
||||
public bool? IsMarkSource { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置结束语信息。
|
||||
/// </summary>
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [GET] /cgi-bin/externalcontact/customer_acquisition_app/get_permit 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class CgibinExternalContactCustomerAcquisitionAppGetPermitRequest : WechatWorkRequest
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [GET] /cgi-bin/externalcontact/customer_acquisition_app/get_permit 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class CgibinExternalContactCustomerAcquisitionAppGetPermitResponse : WechatWorkResponse
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置成员账号列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("user_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("user_list")]
|
||||
public string[]? UserIdList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置部门 ID 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("department_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("department_list")]
|
||||
public long[]? DepartmentIdList { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置标签 ID 列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("tag_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("tag_list")]
|
||||
public long[]? TagIdList { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -25,6 +25,23 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("department_list")]
|
||||
public IList<long>? DepartmentId { get; set; }
|
||||
}
|
||||
|
||||
public class PriorityOption
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置优先分配类型。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("priority_type")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("priority_type")]
|
||||
public int PriorityType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置成员账号列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("priority_userid_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("priority_userid_list")]
|
||||
public IList<string>? PriorityUserIdList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -41,11 +58,25 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("range")]
|
||||
public Types.Range? Range { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优先分配配置信息。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("priority_option")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("priority_option")]
|
||||
public Types.PriorityOption? PriorityOption { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否无需验证。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("skip_verify")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("skip_verify")]
|
||||
public bool? IsSkipVerify { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否标记客户添加来源为该应用创建的。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mark_source")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mark_source")]
|
||||
public bool? IsMarkSource { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -30,6 +30,20 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("url")]
|
||||
public string Url { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否无需验证。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("skip_verify")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("skip_verify")]
|
||||
public bool IsSkipVerify { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否标记客户添加来源为该应用创建的。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mark_source")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mark_source")]
|
||||
public bool IsMarkSource { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置创建时间戳。
|
||||
/// </summary>
|
||||
@@ -54,6 +68,23 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("department_list")]
|
||||
public long[]? DepartmentId { get; set; }
|
||||
}
|
||||
|
||||
public class PriorityOption
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置优先分配类型。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("priority_type")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("priority_type")]
|
||||
public int PriorityType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置成员账号列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("priority_userid_list")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("priority_userid_list")]
|
||||
public string[]? PriorityUserIdList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -68,13 +99,13 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("range")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("range")]
|
||||
public Types.Range Range { get; set; } = default!;
|
||||
public Types.Range? Range { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否无需验证。
|
||||
/// 获取或设置优先分配配置信息。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("skip_verify")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("skip_verify")]
|
||||
public bool IsSkipVerify { get; set; }
|
||||
[Newtonsoft.Json.JsonProperty("priority_option")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("priority_option")]
|
||||
public Types.PriorityOption? PriorityOption { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,6 +12,10 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
public class Range : CgibinExternalContactCustomerAcquisitionCreateLinkRequest.Types.Range
|
||||
{
|
||||
}
|
||||
|
||||
public class PriorityOption : CgibinExternalContactCustomerAcquisitionCreateLinkRequest.Types.PriorityOption
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -35,11 +39,25 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("range")]
|
||||
public Types.Range? Range { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优先分配配置信息。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("priority_option")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("priority_option")]
|
||||
public Types.PriorityOption? PriorityOption { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否无需验证。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("skip_verify")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("skip_verify")]
|
||||
public bool? IsSkipVerify { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否标记客户添加来源为该应用创建的。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mark_source")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mark_source")]
|
||||
public bool? IsMarkSource { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
{
|
||||
@@ -55,5 +55,12 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[Newtonsoft.Json.JsonProperty("state")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("state")]
|
||||
public string? State { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否标记客户添加来源为该应用创建的。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mark_source")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mark_source")]
|
||||
public bool? IsMarkSource { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /cgi-bin/externalcontact/groupchat/get_join_way 接口的响应。</para>
|
||||
@@ -71,6 +71,13 @@
|
||||
[Newtonsoft.Json.JsonProperty("state")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("state")]
|
||||
public string? State { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否标记客户添加来源为该应用创建的。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mark_source")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mark_source")]
|
||||
public bool? IsMarkSource { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
{
|
||||
@@ -62,5 +62,12 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.Models
|
||||
[Newtonsoft.Json.JsonProperty("state")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("state")]
|
||||
public string? State { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置是否标记客户添加来源为该应用创建的。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mark_source")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mark_source")]
|
||||
public bool? IsMarkSource { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user