npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@sessioniq/widget-sdk

v0.4.2

Published

SessionIQ Widget SDK

Readme

SessionIQ Widget SDK (@sessioniq/widget-sdk)

npm version

Overview

Effortlessly integrate SessionIQ's recording capabilities and agent interaction widget into any web application with just a few lines of code.

This package acts as a simple wrapper around the core @sessioniq/client-sdk and the @sessioniq/widget-vue component. It handles:

  • Initializing the SessionIQ client SDK.
  • Dynamically loading Vue 3 onto the page if it's not already present.
  • Mounting the SessionIQ agent widget UI component.
  • Providing simple controls to interact with the widget (show/hide).

Use this package if you want the quickest way to add the SessionIQ widget to a website, regardless of the framework it uses.

Installation

# Using npm
npm install @sessioniq/widget-sdk

# Using yarn
yarn add @sessioniq/widget-sdk

# Using pnpm
pnpm add @sessioniq/widget-sdk

Basic Usage

Simply import the SDK and call the setup function with your clientId.

<!DOCTYPE html>
<html>
  <head>
    <title>SessionIQ Widget Example</title>
  </head>
  <body>
    <h1>My Application</h1>
    <p>The SessionIQ widget will be loaded here.</p>

    <!-- Your application content -->

    <script type="module">
      import { SessionIQWidgetSdk } from "@sessioniq/widget-sdk";

      (async () => {
        try {
          // Initialize the SDK and widget
          const widgetControls = await SessionIQWidgetSdk.setup({
            clientId: "YOUR_CLIENT_ID", // Replace with your actual Client ID
            // Optional: Specify baseUrl if self-hosting
            // baseUrl: 'https://your-sessioniq-api.com',
            // Optional: Set log level ('debug', 'info', 'warn', 'error', 'silent')
            // logLevel: 'info',
          });

          console.log("SessionIQ Widget SDK Initialized!");

          // You can now use the controls if needed:
          // widgetControls?.openWidget();
          // widgetControls?.closeWidget();
          // widgetControls?.toggleWidget();
        } catch (error) {
          console.error("Failed to initialize SessionIQ Widget SDK:", error);
        }
      })();
    </script>
  </body>
</html>

That's it! The widget will be added to the page (initially hidden) and recording will be managed automatically based on your SessionIQ project settings.

API

SessionIQWidgetSdk.setup(options: SdkInitOptions): Promise<WidgetControls | undefined>

  • Initializes the core SDK, loads necessary dependencies (like Vue), mounts the widget, and returns controls for interacting with the widget UI.
  • options: An object conforming to the SdkInitOptions from @sessioniq/client-sdk. clientId is required. Other options like baseUrl and logLevel are optional.
  • Returns: A promise that resolves with the widget controls (an object with methods like openWidget, closeWidget, toggleWidget, and the reactive isWidgetOpen ref) or undefined if initialization fails.

Under the Hood / Alternatives

This package simplifies the integration by combining two core SessionIQ libraries:

  1. @sessioniq/client-sdk: The main library for session recording, event tracking, interacting with the SessionIQ backend API, and handling real-time updates.

    • View on npm
    • Use this directly if you need fine-grained control over the recording lifecycle or want to integrate deeply within a specific framework without the UI widget.
  2. @sessioniq/widget-vue: A Vue 3 component that provides the user interface for interacting with SessionIQ agents (chat, analysis triggers).

    • View on npm
    • Use this directly if your application is already built with Vue 3 and you want to embed the widget manually within your component structure, potentially alongside the @sessioniq/client-sdk.

This @sessioniq/widget-sdk package orchestrates both, making the setup process trivial for projects that just need the complete widget functionality added quickly.