I find it surprising that this is the recommended way to embed a chat bot in a Pega manager / user portal. Creating a non-auto-generated section goes against the Pega guardrail warnings.
I found an OOTB section called pxEmbedChat, but there's very little documentation about it. The only example that I can find that uses it is the App Factory which also has a non-auto-generated section to place the chat button on the screen to pop up the chat window.
I've tried using the mashup code as well as the pxEmbedChat section in overlays and modal dialogs, and both have (different) issues with scroll bars.
It would be nice if Pega made it easier to embed a chat bot in Pega portals without having to write custom HTML, CSS and JS.
I copied the HTML from the non-auto-generated section, AppFactoryChatBot, and used it to create a new section in my application. It includes another section called EmbeddedAFChatbot, which I copied to create a new section for my app. You have to update the value of the botid parameter passed to the pxEmbedChat section to the botid for your web chat bot.
It takes a little work but it looks nice and doesn't have any issues with scrollbars or getting an empty screen when you close and then reopen the chatbot.