Skip to content

Commit

Permalink
Merge pull request #34 from AIO-GAME/1.x
Browse files Browse the repository at this point in the history
1.x
  • Loading branch information
xinansky authored Nov 14, 2023
2 parents 745f15a + 8145c01 commit cd2e42f
Show file tree
Hide file tree
Showing 34 changed files with 2,068 additions and 552 deletions.
85 changes: 85 additions & 0 deletions Documentation~/Usage/Process/PrDingding.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
#### SendData
~~~ C#
const string remote = "https://oapi.dingtalk.com/robot/send?access_token=xxxxx";
const string secret = "xxxx";
var data = PrDingding.CreateData();
// ToLink
data.ToLink("title", "content", "messageUrl","picUrl");
PrDingding.SendData(data, remote, secret).Sync();

// ToText
data.ToText("content");
PrDingding.SendData(data, remote, secret).Sync();

// ToMarkdown
data.ToMarkdown("title", "content");
PrDingding.SendData(data, remote, secret).Sync();

// ToActionCard
data.ToActionCard("title", "时代的火车向前开1", new Dictionary<string, string>(){
{"阅读全文1", "https://www.dingtalk.com/"},
{"阅读全文2", "https://www.dingtalk.com/"}
}, {0 or 1});
PrDingding.SendData(data, remote, secret).Sync();

// ToActionCard
data.ToActionCard("title", "时代的火车向前开1", "阅读全部", "https://www.dingtalk.com/");
PrDingding.SendData(data, remote, secret).Sync();

// ToFeedCard
data.ToFeedCard(new Tuple<string, string, string>[]
{
new Tuple<string, string, string>(
"时代的火车向前开1",
"https://www.dingtalk.com/",
"https://img.alicdn.com/tfs/TB1NwmBEL9TBuNjy1zbXXXpepXa-2400-1218.png"
)
});

// ToMarkdown
data.ToMarkdown("title", "content");
PrDingding.SendData(data, remote, secret).Sync();

~~~
#### Send Markdown
~~~ C#
const string remote = "https://oapi.dingtalk.com/robot/send?access_token=xxxxx";
const string secret = "xxxx";
PrDingding.SendMarkdown("title", "content", remote, secret).Sync();
~~~
#### Send Text
~~~ C#
const string remote = "https://oapi.dingtalk.com/robot/send?access_token=xxxxx";
const string secret = "xxxx";
PrDingding.SendText("content", remote, secret).Sync();
~~~
#### Send Link
~~~ C#
const string remote = "https://oapi.dingtalk.com/robot/send?access_token=xxxxx";
const string secret = "xxxx";
PrDingding.SendLink("title", "content", "messageUrl","picUrl", remote, secret).Sync();
~~~
#### Send ActionCard
~~~ C#
const string remote = "https://oapi.dingtalk.com/robot/send?access_token=xxxxx";
const string secret = "xxxx";
PrDingding.SendActionCard("title", "时代的火车向前开1", new Dictionary<string, string>(){
{"阅读全文1", "https://www.dingtalk.com/"},
{"阅读全文2", "https://www.dingtalk.com/"}
}, {0 or 1}, remote, secret).Sync();
// or
PrDingding.SendActionCard("title", "content", "singleTitle", "singleURL", remote, secret).Sync();
~~~
#### Send FeedCard
~~~ C#
const string remote = "https://oapi.dingtalk.com/robot/send?access_token=xxxxx";
const string secret = "xxxx";
PrDingding.SendFeedCard(new Tuple<string, string, string>[]
{
new Tuple<string, string, string>(
"时代的火车向前开1",
"https://www.dingtalk.com/",
"https://img.alicdn.com/tfs/TB1NwmBEL9TBuNjy1zbXXXpepXa-2400-1218.png"
)
}, remote, secret).Sync();
~~~
Binary file modified Plugins/AIO.Common.dll
Binary file not shown.
171 changes: 125 additions & 46 deletions Plugins/AIO.Common.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13059,6 +13059,11 @@
Cookie
</summary>
</member>
<member name="P:AHandle.HTTP.ContentType">
<summary>
内容类型
</summary>
</member>
<member name="P:AHandle.HTTP.Encoding">
<summary>
编码
Expand Down Expand Up @@ -13522,6 +13527,29 @@
Utils 工具库
</summary>
</member>
<member name="T:AHelper.Encrypt">
<summary>
Encrypt 加密
</summary>
</member>
<member name="M:AHelper.Encrypt.HmacSHA256ToBase64(System.String,System.String,System.Text.Encoding)">
<summary>
HmacSHA256 单向散列函数
</summary>
<param name="secret">签名</param>
<param name="signKey">签名字符串</param>
<param name="encoding">编码</param>
<returns>签名</returns>
</member>
<member name="M:AHelper.Encrypt.HmacSHA256(System.String,System.String,System.Text.Encoding)">
<summary>
HmacSHA256 单向散列函数
</summary>
<param name="secret">签名</param>
<param name="signKey">签名字符串</param>
<param name="encoding">编码</param>
<returns>签名</returns>
</member>
<member name="T:AHelper.FileID">
<summary>
Unity File ID MD4 算法
Expand Down Expand Up @@ -13925,6 +13953,45 @@
<param name="bufferSize">容量</param>
<exception cref="T:System.Exception">异常</exception>
</member>
<member name="T:AHelper.Net.HTTP.Option">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
</member>
<member name="F:AHelper.Net.HTTP.Option.Timeout">
<summary>
超时时间
</summary>
</member>
<member name="F:AHelper.Net.HTTP.Option.Cookie">
<summary>
cookie
</summary>
</member>
<member name="F:AHelper.Net.HTTP.Option.Encoding">
<summary>
编码:默认UTF-8
</summary>
</member>
<member name="F:AHelper.Net.HTTP.Option.ContentType">
<summary>
默认:application/x-www-form-urlencoded
</summary>
</member>
<member name="M:AHelper.Net.HTTP.Option.#ctor">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
</member>
<member name="M:AHelper.Net.HTTP.Option.#ctor(System.UInt16,System.String,System.Text.Encoding,System.String)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="encoding">编码:默认UTF-8</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="contentType"></param>
</member>
<member name="M:AHelper.Net.HTTP.Get(System.String,System.Text.Encoding,System.UInt16,System.String)">
<summary>
请求获取特定的内容
Expand Down Expand Up @@ -14115,118 +14182,98 @@
<exception cref="T:AIO.NetGetResponseStream">异常</exception>
<returns>内容</returns>
</member>
<member name="M:AHelper.Net.HTTP.Post(System.String,System.String,System.Text.Encoding,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.Post(System.String,System.String,AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="data">上传数据</param>
<param name="encoding">编码:默认UTF-8</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.Post(System.String,System.Text.Encoding,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.Post(System.String,AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="encoding">编码:默认UTF-8</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.Post(System.String,System.Byte[],System.Text.Encoding,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.Post(System.String,System.Byte[],AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="data">上传数据</param>
<param name="encoding">编码:默认UTF-8</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.PostStream(System.String,System.String,System.Text.Encoding,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.PostStream(System.String,System.String,AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="data">上传数据</param>
<param name="timeout">超时时间</param>
<param name="encoding">编码:默认UTF-8</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.PostStream(System.String,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.PostStream(System.String,AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.PostStream(System.String,System.Byte[],System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.PostStream(System.String,System.Byte[],AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="data">上传数据</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.PostAsync(System.String,System.String,System.Text.Encoding,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.PostAsync(System.String,System.String,AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="data">上传数据</param>
<param name="encoding">编码:默认UTF-8</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.PostAsync(System.String,System.Text.Encoding,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.PostAsync(System.String,AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="encoding">编码:默认UTF-8</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.PostAsync(System.String,System.Byte[],System.Text.Encoding,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.PostAsync(System.String,System.Byte[],AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="data">上传数据</param>
<param name="encoding">编码:默认UTF-8</param>
<param name="options">选项参数</param>
<returns>返回内容</returns>
</member>
<member name="M:AHelper.Net.HTTP.PostStreamAsync(System.String,System.String,System.Text.Encoding,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.PostStreamAsync(System.String,System.String,AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="data">上传数据</param>
<param name="timeout">超时时间</param>
<param name="encoding">编码:默认UTF-8</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.PostStreamAsync(System.String,System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.PostStreamAsync(System.String,AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="options">选项参数</param>
</member>
<member name="M:AHelper.Net.HTTP.PostStreamAsync(System.String,System.Byte[],System.UInt16,System.String)">
<member name="M:AHelper.Net.HTTP.PostStreamAsync(System.String,System.Byte[],AHelper.Net.HTTP.Option)">
<summary>
请求服务器接受所指定的文档作为对所标识的URI的新的从属实体
</summary>
<param name="remoteUrl">远端路径</param>
<param name="timeout">超时时间</param>
<param name="cookie">cookie</param>
<param name="data">上传数据</param>
<param name="options">选项参数</param>
<returns>返回内容</returns>
</member>
<member name="M:AHelper.Net.HTTP.Put(System.String,System.Byte[],System.Text.Encoding,System.UInt16,System.String)">
Expand Down Expand Up @@ -14406,17 +14453,49 @@
<typeparam name="T">泛型</typeparam>
<returns>属性列表</returns>
</member>
<member name="T:AHelper.TimeStamp">
<summary>
TimeStamp 时间戳
</summary>
</member>
<member name="P:AHelper.TimeStamp.NowMillisecond">
<summary>
Get current timestamp / 当前时间戳,单位是毫秒
</summary>
</member>
<member name="P:AHelper.TimeStamp.NowSecond">
<summary>
Get current timestamp / 当前时间戳,单位是秒
</summary>
</member>
<member name="M:AHelper.TimeStamp.MillisecondToDateTime(System.Int64)">
<summary>
毫秒级时间戳转为时间
</summary>
<param name="timestamp">毫秒级时间磋</param>
</member>
<member name="M:AHelper.TimeStamp.SecondToDateTime(System.Int64)">
<summary>
秒级时间戳转为时间
</summary>
<param name="timestamp">秒级时间磋</param>
</member>
<member name="M:AHelper.TimeStamp.ConvertDateTime(System.DateTime)">
<summary>
DateTime时间格式转换为Unix时间戳格式
</summary>
</member>
<member name="T:AHelper.Base64">
<summary>
Base64 文件 解析
</summary>
</member>
<member name="M:AHelper.Base64.Serialize``1(``0)">
<member name="M:AHelper.Base64.SerializeData``1(``0)">
<summary>
序列化 未加密
</summary>
</member>
<member name="M:AHelper.Base64.Serialize``1(``0@)">
<member name="M:AHelper.Base64.SerializeData``1(``0@)">
<summary>
序列化 未加密
</summary>
Expand Down
Binary file modified Plugins/Editor/AIO.PrCourse.dll
Binary file not shown.
Loading

0 comments on commit cd2e42f

Please sign in to comment.