Reference

NameTypeDefaultDescription
publicKeystring

The public key of your workspace. You need to go to your workspace settings to get this key.

pullIntervalnumber | undefined60000

The time, in milliseconds, for the Messenger to wait before pulling the latest changes from the server. This acts as a fallback in case the component's websocket doesn't work.

authOptions

AuthOptions | undefined

You can pass your user's information here or leave it blank for usage in guest mode. More information.

viewOptions

ViewOptions | undefined

Options for customizing the Messenger's appearance and content. More information.

AuthOptions

NameTypeDefaultDescription
user

User | undefined

Your signed in User's information. Use your auth provider to get this information.

anonymousSignedInDurationnumber | undefined7

The time, in days, for how long a guest's information is kept in their local storage.

User

NameTypeDefaultDescription
idstring

The unique identifier of the user. Use the one from your auth provider as it will used for future updates to their personal information. Internally, this id is indexed with the workspace ID, so there is no danger of conflicts in case this same user is used in multiple workspaces in Makkuro.

namestring

Your user's full name.

emailstring

Your user's email address. It's ok if it changes, we always use the ID to identify the user.

photoUrlstring | undefined

Your user's avatar. If not provided, we'll just render a generic anonymous figure.

ViewOptions

NameTypeDefaultDescription
brandColorstring | undefined#000000

This will update the background color of the header and the color of the send button. Other types, such as rgba and hsl, are also supported.

header

HeaderViewOptions | React.JSX.Element | null | undefined

Customization options for the header. Passing a React JSX Element will render your component instead and using null will hide the header completely. If nothing is provided (undefined), the default header will be shown.

panels

( PanelConversations | PanelLinks | PanelCard )[]
| undefined

Panels are the white boxes that contain content in the Messenger and you can completely customize them. If nothing is provided (undefined), just the panel with the conversations list will be shown. More information

HeaderViewOptions

NameTypeDefaultDescription
titlestring

The title that shows at the top of the Messenger. Usually contains a greeting.

descriptionstring

The short text under this title where you can provide more information about your reply times, or time of operation. There is no limit to the length of this text.

avatars

AgentAvatar[] | undefined

Avatars that are shown on the right side of the header. These are usually the agents that are currently online and you would currently need to provide them statically.

AgentAvatar

NameTypeDefaultDescription
photoUrlstring

The URL of the agent's avatar.

namestring

The name of the agent, used only for the alt text of the image.

PanelConversations

NameTypeDefaultDescription
typeconversations

You only need to provide this static property to render the conversations panel.

PanelLinks

NameTypeDefaultDescription
typelinks

This static property will help Makkuro understand that a panel with links needs to be rendered.

contentLinkPanelContent

The content of the links panel.

LinkPanelContent

NameTypeDefaultDescription
titlestring | undefined

An optional title for the links panel.

linksLinkProps

The content of the links panel.

LinkProps
NameTypeDefaultDescription
hrefstring

The URL of the link.

labelstring

The text that will be shown as the link.

targetstring | undefined

The target attribute of the link.

iconReact.JSX.Element | undefined

An optional icon that will be shown before the label.

PanelCard

NameTypeDefaultDescription
typecard

This static property will help Makkuro understand that a panel with a card needs to be rendered.

contentCardPanelContent

The content of the card panel.

CardPanelContent

NameTypeDefaultDescription
image

Image | undefined

The image that will be shown on the top of the card.

titlestring

The title of the card.

descriptionstring

The description of the card.

readMoreLinkProps (without the icon) | undefined

An optional link that will be shown at the bottom of the card.

Image
NameTypeDefaultDescription
srcstring

The URL of the image.

altstring

The alt text of the image.

NotificationOptions

NameTypeDefaultDescription
notificationSoundstring | null | undefined[path_to_chime_sound.mp3]

This will update the notification sound. If a null value is provided, no sound will be played at all.

pageTitle

string | null | undefined

[You have a new message]

This will update the page title of the Messenger's window tab. If a null value is provided, the page title will not change.

How can we help?

Send us a message and we'll get back to you as soon as possible.