@miradorlabs/web-sdk.
Server-side? Use the standard OpenTelemetry SDK for your language — Python, Go, Java, .NET, Rust, Ruby, PHP, and more all export to Mirador over OTLP with no Mirador package. The Node.js SDK is deprecated.
Install
Initialize the client
mir_web_*) in the browser. Web keys are validated against the key’s allowed origins, so they are safe to ship in client bundles. Server keys (mir_srv_*) must never appear in browser code.
Configuration
Custom gateway URL
If you’re using a self-hosted gateway or a different environment:Custom keep-alive interval
Debug mode and plugins
Module formats
ESM import
CDN / browser global
Load the SDK directly from a CDN — no bundler required:MiradorWeb global:
Browser requirements
The SDK requires modern browser features:- ES2020+ - Modern JavaScript syntax
- Fetch API - For network requests
- Promises - For async operations
Supported browsers
Polyfills
For older browsers, you may need to include polyfills:Verifying installation
Next steps
Web SDK overview
Features, when to use it, and how it relates to OpenTelemetry
Core concepts
Traces, spans, events, and attributes