in src/JetBrains.Space.Samples.App/WebHooks/CateringWebHookHandler.cs [55:83]
private async Task StartNewSession(string userId)
{
var cateringSession = new CateringSession();
Sessions[userId] = cateringSession;
await SendOrEditMessageAsync(
channelIdentifier: null,
recipient: MessageRecipient.Member(ProfileIdentifier.Id(userId)),
content: ChatMessage.Block(
outline: new MessageOutline("Anything to eat or drink while we are on our way to Space?"),
messageData: "Anything to eat or drink while we are on our way to Space?",
sections: new()
{
MessageSectionElement.MessageSection(
elements: new()
{
MessageBlockElement.MessageText("JetBrains Space - Catering", size: MessageTextSize.SMALL),
MessageBlockElement.MessageText("Anything to eat or drink while we are on our way to Space?"),
MessageBlockElement.MessageControlGroup(new List<MessageControlElement>
{
MessageControlElement.MessageButton("Yes, please", MessageButtonStyle.PRIMARY,
MessageAction.Post("catering-start", ""))
})
})
},
style: MessageStyle.PRIMARY),
cateringSession: cateringSession);
}