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

@vamlabs/vam-chatbot

v0.1.77

Published

VAM Chatbot Web Component

Downloads

847

Readme

Steps to use the VAM Chatbot

  1. Import the Package:

    • To import the VAM chatbot package, add the following <script> tag to the <head> section of your root HTML file. This will load the package from our CDN:
      <script src="https://cdn.jsdelivr.net/npm/@vamlabs/vam-chatbot/dist/web-component.min.js"></script>
  2. Place the Floating Chatbot Component:

    • Insert the chatbot component into your HTML. By default, it appears as a minimized launcher at the bottom right of the screen. Replace the client-id with your specific client ID:
      <vam-chatbot client-id="<your-client-id>"></vam-chatbot>
  3. Place the Inline Chatbot Component:

    • For an in-page chatbot that sits wherever you place it in the page layout, use layout="inline":
      <vam-chatbot
        layout="inline"
        client-id="<your-client-id>"
        class="my-inline-chatbot"
      ></vam-chatbot>
    • Inline layout reserves its page space immediately at 100% width with a default height of 640px, then keeps that footprint while loading, ready, or temporarily unavailable. Use CSS variables and exposed shadow parts for customization. Scope inline-only overrides with [layout="inline"]:
      vam-chatbot[layout="inline"].my-inline-chatbot {
        --chatbot-inline-height: 720px;
      }
      
      vam-chatbot[layout="inline"].my-inline-chatbot::part(panel) {
        border-radius: 0;
        box-shadow: none;
      }
      
      vam-chatbot[layout="inline"].my-inline-chatbot::part(header) {
        background: #0500ff;
      }
  4. Provide an Auth Token (Optional):

    • For protected deployments (for example, your portal domain), pass a bearer token for POST /chat/session.
    • For public embeds where your backend allows unauthenticated session minting, this can be omitted.
    • Static token via attribute:
      <vam-chatbot client-id="<your-client-id>" auth-token="<id-token>"></vam-chatbot>
    • Recommended (fresh token per request) via JS property:
      <script>
        const bot = document.querySelector("vam-chatbot");
        bot.authTokenProvider = async () => {
          return window.getCognitoIdToken();
        };
      </script>

These steps will help you integrate the VAM chatbot into your webpage seamlessly. Ensure you replace the client-id with the one provided to you for proper configuration.

Notes

  • The widget uses a 2-step chat flow (POST /chat/session then streamed POST /chat/stream) and requires your site origin to be allowlisted for your tenant.
  • If configured, authTokenProvider is called before each message stream starts so expiring tokens can be refreshed on-demand.
  • Missing or invalid layout values default to the existing floating layout.
  • Exposed ::part(...) hooks include root, panel, header, header-title, header-actions, reset-button, close-button, body, inline-state, loading-state, error-state, conversation, prompts, prompt-button, message, bot-message, user-message, error-message, message-avatar, message-bubble, carousel, sources, source-link, source-toggle, promoted-topics, support-actions, feedback-form, footer, footer-branding, prompt-drawer-button, input, submit-button, launcher, launcher-popup, and launcher-button.