The Chatbox is really just the right half of the Inbox. It takes up less space and it's designed to be embedded in your app near an order, a booking, or a user profile.

Note that users can't switch between conversations in a Chatbox. Therefore, you may want to use both the Chatbox and the Inbox: the Chatbox right by its context, and the Inbox on its own page so that users can get back to old conversations.

The code for the Chatbox is almost identical to the code for the Inbox. Find the lines that contain createInbox and change them into the following:

const chatbox = session.createChatbox(conversation);
var chatbox = window.talkSession.createChatbox(conversation);

That's it! See the Chatbox JavaScript API reference for additional events and features.

Next step is to tune the placement of your Chatbox.