1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2026-05-22 10:05:29 +02:00

Пересборка доков EN

This commit is contained in:
Anton Titovets
2024-08-13 16:37:03 +03:00
parent 01dda94800
commit 4be60436d7
227 changed files with 817 additions and 1129 deletions
@@ -27,8 +27,8 @@ Method at API documentation: [GET /chats/members/delete](https://teams.vk.com/bo
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
ChatID = FunctionParameters["VkTeams_ChatID2"];
Token = "001.3501506236.091...";
ChatID = "689203963@chat.agent";
User = 1011987091;
Result = OPI_VKTeams.RemoveChatMembers(Token, ChatID, User);
@@ -25,7 +25,7 @@ Method at API documentation: [GET /self/get](https://teams.vk.com/botapi/#/self/
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
Token = "001.3501506236.091...";
Result = OPI_VKTeams.CheckToken(Token);
```
@@ -27,15 +27,13 @@ Method at API documentation: [GET /events/get](https://teams.vk.com/botapi/#/eve
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
Token = "001.3501506236.091...";
LastID = 0;
For N = 1 To 5 Do // In real work - endless loop
Result = OPI_VKTeams.GetEvents(Token, LastID, 3);
OPI_TestDataRetrieval.WriteLog(Result, "GetEvents", "VkTeams");
Events = Result["events"];
// Event handling...
@@ -26,8 +26,8 @@ Method at API documentation: [GET /files/getInfo](https://teams.vk.com/botapi/#/
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
FileID = FunctionParameters["VkTeams_FileID"];
Token = "001.3501506236.091...";
FileID = "sXhpbA5K2ZCOdG5ROIfRan66ba356d1bd";
Result = OPI_VKTeams.GetFileInformation(Token, FileID);
```
@@ -27,9 +27,9 @@ Method at API documentation: [GET /messages/deleteMessages](https://teams.vk.com
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
ChatID = FunctionParameters["VkTeams_ChatID2"];
MessageID = FunctionParameters["VkTeams_MessageID"];
Token = "001.3501506236.091...";
ChatID = "689203963@chat.agent";
MessageID = "7402287649739767956";
Result = OPI_VKTeams.DeleteMessage(Token, ChatID, MessageID);
```
@@ -31,15 +31,13 @@ You can mention a user by appending their userId to the text in the following fo
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
ChatID = FunctionParameters["VkTeams_ChatID2"];
MessageID = FunctionParameters["VkTeams_MessageID"];
Token = "001.3501506236.091...";
ChatID = "689203963@chat.agent";
MessageID = "7402287649739767956";
Text = "New message text";
Result = OPI_VKTeams.EditMessageText(Token, ChatID, MessageID, Text);
OPI_TestDataRetrieval.WriteLog(Result, "EditMessageText (simple)", "VkTeams");
Text = "<b>New bold message text</b>";
Markup = "HTML";
@@ -31,15 +31,13 @@ Only the chatId from events can be passed to the FromChatID (the code from the c
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
ChatID = FunctionParameters["VkTeams_ChatID"];
FromChatID = FunctionParameters["VkTeams_ChatID2"];
MessageID = FunctionParameters["VkTeams_MessageID"];
Token = "001.3501506236.091...";
ChatID = "AoLI0egLWBSLR1Ngn2w";
FromChatID = "689203963@chat.agent";
MessageID = "7402287649739767956";
Result = OPI_VKTeams.ForwardMessage(Token, MessageID, FromChatID, ChatID);
OPI_TestDataRetrieval.WriteLog(Result, "ForwardMessage (simple)", "VkTeams");
Text = "Additional text";
Result = OPI_VKTeams.ForwardMessage(Token, MessageID, FromChatID, ChatID, Text);
@@ -30,9 +30,9 @@ Method at API documentation: [GET /messages/sendFile](https://teams.vk.com/botap
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
ChatID = FunctionParameters["VkTeams_ChatID"];
FileID = FunctionParameters["VkTeams_FileID"];
Token = "001.3501506236.091...";
ChatID = "AoLI0egLWBSLR1Ngn2w";
FileID = "sXhpbA5K2ZCOdG5ROIfRan66ba356d1bd";
Text = "File caption";
Result = OPI_VKTeams.ResendFile(Token, ChatID, FileID, Text, "SameDoc.docx");
@@ -27,9 +27,9 @@ Method at API documentation: [GET /messages/sendVoice](https://teams.vk.com/bota
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
ChatID = FunctionParameters["VkTeams_ChatID"];
FileID = FunctionParameters["VkTeams_VoiceID"];
Token = "001.3501506236.091...";
ChatID = "AoLI0egLWBSLR1Ngn2w";
FileID = "I000bPVBYaNQkn9Fg3oY0066ba35811bd";
Result = OPI_VKTeams.ResendVoice(Token, ChatID, FileID);
```
@@ -30,11 +30,11 @@ Method at API documentation: [POST /messages/sendFile](https://teams.vk.com/bota
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
ChatID = FunctionParameters["VkTeams_ChatID"];
Token = "001.3501506236.091...";
ChatID = "AoLI0egLWBSLR1Ngn2w";
Text = "File caption";
File = FunctionParameters["Document"]; // URL
File = "https://openintegrations.dev/test_data/document.docx"; // URL
FilePath = GetTempFileName("docx"); // Path
CopyFile(File, FilePath);
@@ -43,12 +43,8 @@ Method at API documentation: [POST /messages/sendFile](https://teams.vk.com/bota
Result = OPI_VKTeams.SendFile(Token, ChatID, File);
OPI_TestDataRetrieval.WriteLog(Result, "SendFile (URL)", "VkTeams");
Result = OPI_VKTeams.SendFile(Token, ChatID, FilePath, Text);
OPI_TestDataRetrieval.WriteLog(Result, "SendFile (Path)", "VkTeams");
Result = OPI_VKTeams.SendFile(Token, ChatID, File, Text, "ImportantDocument.docx");
```
@@ -32,16 +32,14 @@ You can mention a user by appending their userId to the text in the following fo
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
ChatID = FunctionParameters["VkTeams_ChatID"];
Token = "001.3501506236.091...";
ChatID = "AoLI0egLWBSLR1Ngn2w";
Text = "Message text";
Result = OPI_VKTeams.SendTextMessage(Token, ChatID, Text);
OPI_TestDataRetrieval.WriteLog(Result, "SendTextMessage)", "VkTeams");
ChatID = FunctionParameters["VkTeams_ChatID2"];
ReplyID = FunctionParameters["VkTeams_MessageID"];
ChatID = "689203963@chat.agent";
ReplyID = "7402287649739767956";
Text = "<b>Bold text</b>";
Markup = "HTML";
@@ -32,12 +32,12 @@ If you want the client to display this file as a playable voice message, it must
```bsl title="Code example"
Token = FunctionParameters["VkTeams_Token"];
ChatID = FunctionParameters["VkTeams_ChatID2"];
ReplyID = FunctionParameters["VkTeams_MessageID"];
Token = "001.3501506236.091...";
ChatID = "689203963@chat.agent";
ReplyID = "7402287649739767956";
Text = "File caption";
File = FunctionParameters["Audio2"] ; // URL
File = "https://openintegrations.dev/test_data/song.m4a" ; // URL
FilePath = GetTempFileName("m4a"); // Path
CopyFile(File, FilePath);
@@ -46,12 +46,8 @@ If you want the client to display this file as a playable voice message, it must
Result = OPI_VKTeams.SendVoice(Token, ChatID, File);
OPI_TestDataRetrieval.WriteLog(Result, "SendVoice (URL)", "VkTeams");
Result = OPI_VKTeams.SendVoice(Token, ChatID, FilePath, ,ReplyID);
OPI_TestDataRetrieval.WriteLog(Result, "SendVoice (Path)", "VkTeams");
Result = OPI_VKTeams.SendVoice(Token, ChatID, File);
```