Hi,
I have begun playing with the web service integration capabilities within a process to send a message to a Teams channel. Obviously many use cases exist for having a message sent to a Team channel.
I have been able to successfully send a message to a channel, however I am having issues in managing the formatting of the message, so a clear title, and message body structure can be provided. Has anyone got any integration working with Teams that would be prepared to share how the web service, variables etc. are configured to allow formatted messages to be sent?
Thanks in advance.
Like
Mark Roberts,
Could you please share how the implementation is done currently?
Also, have you tried about the content using <HTML>
BR,
Bhoobalan Palanivelu
Bhoobalan Palanivelu writes:
Mark Roberts,
Could you please share how the implementation is done currently?
Also, have you tried about the content using <HTML>BR,
Bhoobalan Palanivelu
hi Mark Roberts,
Using the Content type as HTML depicted below.
GraphServiceClient graphClient = new GraphServiceClient( authProvider ); var chatMessage = new ChatMessage { Body = new ItemBody { ContentType = BodyType.Html, Content = "{\r\n \"title\": \"This is an example of posting a card\",\r\n \"subtitle\": \"<h3>This is the subtitle</h3>\",\r\n \"text\": \"Here is some body text. <br>\\r\\nAnd a <a href=\\\"http://microsoft.com/\\\">hyperlink</a>. <br>\\r\\nAnd below that is some buttons:\",\r\n \"buttons\": [\r\n {\r\n \"type\": \"messageBack\",\r\n \"title\": \"Login to FakeBot\",\r\n \"text\": \"login\",\r\n \"displayText\": \"login\",\r\n \"value\": \"login\"\r\n }\r\n ]\r\n}", } }; await graphClient.Teams["{team-id}"].Channels["{channel-id}"].Messages .Request() .AddAsync(chatMessage);
BR,
Bhoobalan Palanivelu.
Bhoobalan Palanivelu,
Hi
Thanks for your reply. This is what I have done so far:
1. Created a new Web Service entry
2. Configured a single Method and populated top fields. I know this is correct as I can successful send a test request with just a single parameter line and it was received and displayed in my Teams channel
3. The issue I have is with the configuration of the Parameters, for which all but contentType I assume are Body parameters. The following screenshot is me playing with various structures and content entries, but I cannot get anything working :/
I am trying to send a message in a form similar to the following:
https://adaptivecards.io/samples/ActivityUpdate.html
I feel I am missing something straightforward in how this should be built within the Creatio Web Service definition, but the docs are not helping find it.
thanks
Mark
keith schmitt,
No, I have been distracted with other things, so not got back to this. This would be a great blog for someone to write up and share!