Let's Chat?

Setting up Multiple Groups

All Cobrowse settings are specific to the group in which the session runs, including:

  • Masked elements
  • Trusted domains for cross domain Cobrowse
  • Trusted domains for invoking Cobrowse from a “chat” window

Cobrowse allows running multiple sessions in different groups based on varied call center models on the same website. Agents can be granted permission to join sessions only in specific groups.

Specify the Groups in the Script Tag

A customer can specify additional Group IDs in the script tag, for example:


It is possible for you to tag different pages with different sets of group ids. A primary Group ID (data-groupid) must still be specified to be used as a default and for non-Cobrowse features such as Presence.

Start a Session in a Particular Group

API call GLANCE.Cobrowse.Visitor.startSession() accepts an additional “groupid” parameter to indicate in which group a session should start. If the Group ID is not specified, the session defaults to the main group.

For example:

GLANCE.Cobrowse.Visitor.startSession({ groupid : 72 })

starts a session in group 72.

See the API section for more information.

A Group ID can also be specified by the agent side when starting a session via the Presence API.

Currently there is no way to specify an alternate Group ID when starting a session via:

  • A link with a data-glancebutton attribute
  • Key combinations specified in data-inputevents in the script tag.


Once a session is started with a particular Group ID, any agent with a Cobrowse subscription within that group can view the session. Therefore it is important to ensure that sessions can only run in groups that are explicitly allowed by the website authors.

Any time a session is started or continued (via the API, a window message, Presence, continued after navigating, after crossing a domain boundary, or when a page gets focus) there is a check to ensure that the Group ID either matches data-groupid or is in the data-additionalgroupid list.

See the Security section for more information.

Button Customization

Each group has its own button customization. If using the default UI, the Cobrowse scripts will load custom button styles according to which group the session is running in. In order to use the button style of a different group, call GLANCE.Cobrowse.VisitorUI.setStyle(). Additional information is available here.

Presence with Multiple Groups

Presence always uses the group specified in data-groupid. So an agent wanting to join a session via Presence needs to be a member of both the first group in the list and the group in which the session is started.

Custom UI with Multiple Groups

If using a custom UI (data-ui="custom") in the script tag, then the customer supplied user interface script can conditionally modify the user interface according to which group a session is running in. The custom user interface script can use new api GLANCE.Cobrowse.Visitor.sessionGroupId(), which returns the groupid for the currently running session, if any.

NOTE: It is not possible to use a custom UI for one group and the default UI for other groups.

By continuing to use the site, you agree to the use of cookies. Learn More