Introduction
Monterosa JavaScript SDK documentation
The Monterosa JavaScript SDK connects your website to the Monterosa platform. Use it to embed interactive Experiences (live polls, quizzes, leaderboards, predictions) into your pages, or to build your own Experiences from scratch. The SDK handles real-time communication, user identity, and storage so you can focus on the product.
Use cases
Embed an Experience quickly, without a build step
Drop a <monterosa-experience> element into your HTML. Your page acts as the parent and controls identity and storage. No bundler needed.
Embed an Experience with full programmatic control Load and manage the Experience from JavaScript. Gives you control over when and where the Experience appears, with access to lifecycle events.
Build an embeddable Experience Create your own Experience on the Monterosa platform. You write the UI; the SDK provides real-time data, voting, identity, and storage.
Build a standalone Experience Run an Experience directly in the browser without a parent page. The Experience handles everything itself: authentication, storage, and the interactive UI. For campaign microsites, standalone quizzes, PWAs, or direct-link URLs.
SDK distribution
The SDK is available in two formats:
CDN modules. Loaded directly from CDN via a
<script>tag. No build step required.npm modules. Installed into your project via
npm install. Requires a bundler (Webpack, Vite, etc.).
Both formats provide the same functionality. Choose the one that fits your project setup. For a detailed comparison, see SDK Overview.
Reference
These pages explain the concepts behind the SDK. Refer to them as you go:
SDK Overview: Packages, lifecycle, versioning
Core Concepts: Projects, Events, Elements, and how they relate
Experience Embedding: What embedding is and what the SDK handles
Bridge: How parent pages and Experiences communicate
Connection: Real-time connection and reconnection
Identity: How user identity flows between your application and Experiences
Real-time Data Delivery: Content and configuration delivered in real time
Data and Privacy: What the SDK sends, stores, and does not collect
Last updated
