mirror of
https://github.com/Bayselonarrend/OpenIntegrations.git
synced 2024-12-02 09:21:37 +02:00
17 lines
584 B
Plaintext
17 lines
584 B
Plaintext
Token = "001.3501506236.091...";
|
|
ChatID = "AoLI0egLWBSLR1Ngn2w";
|
|
Text = "File caption";
|
|
|
|
File = "https://github.com/Bayselonarrend/OpenIntegrations/raw/main/service/test_data/document.docx"; // URL
|
|
FilePath = GetTempFileName("docx"); // Path
|
|
|
|
CopyFile(File, FilePath);
|
|
|
|
FileBD = New BinaryData(FilePath); // Binary
|
|
|
|
Result = OPI_VKTeams.SendFile(Token, ChatID, File);
|
|
|
|
Result = OPI_VKTeams.SendFile(Token, ChatID, FilePath, Text);
|
|
|
|
Result = OPI_VKTeams.SendFile(Token, ChatID, FileBD, Text, "ImportantDocument.docx");
|