1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2025-11-29 22:27:42 +02:00
Files
OpenIntegrations/docs/en/examples/Bitrix24/SendMessage.txt
Vitaly the Alpaca (bot) 8ed6ee71a3 Main build (Jenkins)
2025-09-04 15:33:26 +03:00

22 lines
852 B
Plaintext
Vendored

URL = "https://b24-ar17wx.bitrix24.by/rest/1/h0m...";
ChatID = "2948";
OPI_TypeConversion.GetLine(ChatID);
ChatString = "chat" + ChatID;
Text = "Message text";
Image = "https://raw.githubusercontent.com/Bayselonarrend/OpenIntegrations/main/service/test_data/picture.jpg";
File = "https://github.com/Bayselonarrend/OpenIntegrations/raw/main/service/test_data/document.docx";
Attachments = New Array;
Attachments.Add(OPI_Bitrix24.GetPictureBlock("Image1" , Image));
Attachments.Add(OPI_Bitrix24.GetFileBlock("File1.docx" , File));
Result = OPI_Bitrix24.SendMessage(URL, ChatString, Text, Attachments);
URL = "b24-ar17wx.bitrix24.by";
Token = "4f8db968006e9f06006b12e400000001000...";
UserID = 10;
Result = OPI_Bitrix24.SendMessage(URL, UserID, Text, , Token);