1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2025-11-29 22:27:42 +02:00
Files
OpenIntegrations/docs/en/examples/Telegram/SendDocument.txt
2025-07-06 01:01:25 +03:00

19 lines
717 B
Plaintext
Vendored

Token = "6129457865:AAFyzNYOAFbu...";
ChatID = "461699897";
ChannelID = "@testsichee";
Text = "Строковое значение";
Document = "https://hut.openintegrations.dev/test_data/document.docx";
DocumentPath = GetTempFileName("docx");
CopyFile(Document, DocumentPath);
DocumentDD = New BinaryData(DocumentPath);
Result = OPI_Telegram.SendDocument(Token, ChatID, Text, Document);
Result = OPI_Telegram.SendDocument(Token, ChatID, Text, Document, , , "customname.docx");
Result = OPI_Telegram.SendDocument(Token, ChannelID, Text, DocumentPath);
Result = OPI_Telegram.SendDocument(Token, ChannelID, Text, DocumentDD, , , "customname.docx");