ODIN Communicator
ODIN Communicator is a sleek, embeddable voice chat widget for websites. It lets users join a room with a nickname and talk in real-time - without building a custom UI.
Pro tip: Send this URL to your friends and you can directly start a voice chat with them! https://docs.4players.io/voice/web/widgets/odin-communicator/
What it’s good for
- “Try ODIN Voice” demo on your product/landing page
- Community voice hubs (per game / per page / per event)
- Lightweight party voice on a website
Features
- Real-time voice chat (ODIN-powered)
- Room-based (join by
roomId) - Modern UI (React + TailwindCSS)
- Talking indicators / visualizers
- Simple embed (a single
mountOdinCommunicator(...)call) - Optional theming (brand colors)
Quickstart (Embed)
1. Create a container element:
2. Import and mount the widget:
Please note: The widget is built as a UMD (CJS) module and should therefore work in any environment. Make sure
that you place the script tag before the end of the body tag.
We also offer a ES Module version of the widget. It has the same API, but is built with ES Modules. You can import it directly import it like so:
The mountOdinCommunicator(...) function takes three arguments:
- The container element ID
- The ODIN Communicator configuration object
- The optional theme object
The container element must be present on the page before calling mountOdinCommunicator(...).
The ODIN Communicator configuration object contains the following properties:
apiKey(required): Your Rooms API key (see below on how to get one)roomId(required): The name of the room to join (all users in the same room will talk together)title(optional): The widget titledescription(optional): A description shown below the titleconnectBtnText(optional): The text on the connect buttonheight(optional): The height of the widget (defaults to400px)`
The theme object contains the following properties:
colors.primary(optional): The primary color of the widgetcolors.secondary(optional): The secondary color of the widgetcolors.background(optional): The background color of the widget (defaults totransparent)colors.panel(optional): The background color of the panel (defaults todark gray)
3. Getting an API key (via Rooms)
For easier setup, we leverage the Rooms backend service to manage access of your ODIN Communicator instance.
The easiest path is to create a Rooms instance (includes a free option):
Create a Rooms instanceOnce your Rooms instance is ready, navigate to our dashboard to retrive your API-Key for your Rooms-Instance. Just use this link to directly navigate to the dashboard:
Get Rooms API-KeyYou can also use your own backend to manage access tokens. In this case, you'll need to implement the authentication
flow yourself. The source code is open source and available on GitHub: https://github.com/4players/odin-communicator.
Clone it, and adjust the OdinTokenService.js script to get tokens based on your backend logic. See
Understanding Access Keys for more information.
Follow ODIN Web SDK guidance
ODIN Communicator is built on top of the ODIN Web SDK. Review the Web SDK docs and follow the recommended authentication patterns for your environment.
ODIN Web SDK docs: https://docs.4players.io/voice/web/