JavaScript SDK - Methods
Methods
Section titled Methods ConstructorLearn all about the initialization options for the tracker. → event()Send custom events to be recorded as part of your replays with this method. → getSessionToken()Get the currently active session's token. → getSessionID()Get the currently active session's ID. → getSessionURL()Get the url to replay the current session. → handleError()Capture custom error information and save it as part of your recording. → isActive()Get the current state of the active session. → issue()Capture custom technical events and save them as part of the replay. → setUserID()Identify your users with this method. → setMetadata()Set a metadata field and save it as part of the recording. → resanitize()Re-apply sanitization rules to already-recorded DOM nodes mid-session. → start()Start recording a session. → stop()Stop the recording of a session with this method. → coldStart()Starts buffering messages (refreshing buffer) with the possibility to call start() to enable session recording and send the buffer content. → startOfflineRecording()Starts offline session recording which can be sent with uploadOfflineRecording. → uploadOfflineRecording()Uploads the stored session buffer to the backend. → forceFlushBatch()Force sends the current batch of messages without waiting for its completion. → trackWs()Create a hook to capture WebSocket messages. → incident()Mark significant events or incidents during a user's session. →