This reference documents the Web SDK. The same classes exist in
@miradorlabs/nodejs-sdk, which is deprecated — new backend services
should use OpenTelemetry.Overview
The SDK exports all TypeScript types for full type safety in your application.Import
Web SDK:ClientOptions
Configuration options for the client. Web SDK:Usage
TraceOptions
Configuration options for individual traces. Web SDK:Usage
Web SDK:TraceCallbacks
Lifecycle callbacks for observing trace events programmatically. See the Lifecycle Callbacks guide for detailed usage patterns.Usage
Logger
Interface for custom logging implementations. See the Custom Logging guide for integration examples.Usage
Severity
Event severity levels used by convenience methods.Usage
MiradorPlugin
Interface for creating plugins that extend trace functionality.TraceContext
Read/write access to the trace, passed to pluginsetup().
PluginSetupResult
Object returned by a plugin’ssetup() method.
FlushBuilder
Interface for contributing data to a flush payload from a plugin’sonFlush hook.
Web3Methods
Methods available ontrace.web3 when using the Web3Plugin.
EvmMethods
EVM transaction methods available ontrace.web3.evm.
SafeNamespaceMethods
Safe multisig methods available ontrace.web3.safe.
NoopTrace
A trace implementation that silently discards all operations. Returned when a trace is not sampled.Usage
HintType
Discriminator for the type of transaction hint.ChainName
Supported blockchain networks for transaction hints.Usage
TraceEvent
Structure of events added to traces.Usage
TxHashHint
Structure of blockchain transaction hints.Usage
SafeMsgHintData
Structure of Safe multisig message hints.Usage
SafeTxHintData
Structure of Safe multisig transaction hints.Usage
AddEventOptions
Options for theaddEvent() method.
Usage
SpanStatus
Terminal status for a span, mirroring the OTLP span status.Usage
SpanOptions
Options for opening a span viatrace.startSpan() or span.startSpan().
Usage
SpanEndOptions
Options for ending a span viaspan.end().
Usage
StackFrame
Represents a single frame in a stack trace.StackTrace
Captured stack trace information.Usage
ClientMetadata (Web SDK Only)
Browser environment metadata collected automatically.Usage
EIP1193Provider
Standard EIP-1193 provider interface. Compatible with MetaMask, WalletConnect, and any EIP-1193 compliant wallet.Usage
TxHintOptions
Structured options forweb3.evm.addTxHint(), extending the simple string details.
When
input is provided, it is emitted as a "Tx input data" event via web3.evm.addTxInputData(). Only details is stored in the hint itself.Usage
TransactionLike
A transaction-like object that matches common library shapes (ethers v5/v6, viem, raw RPC).Usage
TransactionRequest
Transaction parameters forweb3.evm.sendTransaction(), matching the EIP-1193 eth_sendTransaction format.
Usage
MiradorProviderOptions
Configuration for theMiradorProvider wrapper.
Usage
Utility Functions
Both SDKs export utility functions for stack traces and chain ID mapping. The Web SDK additionally exports browser metadata utilities. Both SDKs:Next Steps
Client
Client class reference
Trace
Trace builder reference