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

@wandox/sdk

v0.1.65

Published

Wandox embeddable AI assistant and playbook execution SDK.

Readme

@wandox/sdk

Wandox 可嵌入式 AI 工作台 SDK。完整工作台通过 mountAssistant 挂载,当前最新版本为 V2;抽屉、剧本执行面板和业务组件 API 保持独立调用方式。

安装

npm install @wandox/sdk

使用

import wandox from '@wandox/sdk'
import '@wandox/sdk/style.css'

const sdk = wandox.init({
  token: 'YOUR_SSO_TOKEN',
  domain: 'maiduo',
  username: 'YOUR_USERNAME',
  userId: 'YOUR_USER_ID',
})

sdk.mountAssistant('#app')

mountAssistant 页面版本

version 用于选择完整工作台协议,缺省使用当前最新版本 2。现有调用无需增加参数即可进入 V2 工作台;需要使用 V1 Assistant 体验时显式传入 version: 1

// 当前最新工作台,等同于 version: 2
sdk.mountAssistant('#app')

// 显式使用 V1 Assistant 工作台
sdk.mountAssistant('#app', {
  version: 1,
})

version 只影响 mountAssistant 的完整页面。openDraweropenDrawerOnly、剧本执行面板、业务组件和其他 SDK 方法保持原有调用方式;智能体、剧本及参数仍使用 agentId / agent_idplaybookId / playbook_idplaybookParams / playbook_params

Web 应用对应的版本入口是 /agent-workbench/v1/agent-workbench/v2/assistant/console 已从 Web 应用路由移除。SDK 直接把工作台挂载到传入容器,不依赖 Web 路由;容器需要提供明确的宽度和高度,V2 初始化加载状态只覆盖该容器。

客服抽屉模式

通过 openDrawerOnly 打开业务抽屉,并设置 enable_customer_service: true。抽屉头部会显示“人工客服”按钮,用户点击后在新窗口打开客服系统;客服地址和 SSO token 跳转由 SDK 统一处理。

const sdk = wandox.init({
  token: 'YOUR_SSO_TOKEN',
  domain: 'maiduo',
  companyCode: 'YOUR_COMPANY',
})

sdk.openDrawerOnly({
  agent_id: 'maiduo_global',
  enable_customer_service: true,
})

打开抽屉时可以同时发送消息:

sdk.openDrawerOnly({
  agent_id: 'maiduo_global',
  message: '帮我分析一下当前店铺表现',
  enable_customer_service: true,
})

camelCase 参数同样受支持:agentIdenableCustomerService。客服入口按单次抽屉调用控制,完整页面和独立执行面板保持原有行为。

应用卸载时清理 SDK:

sdk.destroy()

命名导入及类型导入:

import { wandox, type WandoxConfig } from '@wandox/sdk'