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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@hzkj/voicenine

v1.2.10

Published

js sdk of cloud platform base on janus gateway.

Readme

HANZI VOICENINE

VERSION 1.2.10

引入

import { VoiceNine } from '@hzkj/voicenine'
const voice9 = new VoiceNine()

方法

//身份初始化方法
voice9.init(login接口返回的对象)

//主动触发登出
voice9.logout()

//设置登录状态为”忙碌“
voice9.setBusy()

//设置登录状态为”空闲“
voice9.setReady()

//自定义忙碌(参数自定义)
voice9.setWorkNotReady('1234')

//拨打电话
voice9.call(telNum)

//接通电话
voice9.answer()

//挂断电话
voice9.hangup()

//发送按键
voice9.sendDtmf('1234')

//转接(转技能组: groupId:1, 转坐席: 1001@test, 转ivr: ivrId:100, 转外呼: 13311112222)
voice9.transfer(telNum)

//咨询(咨询ivr流程: ivrId:123,  咨询坐席:1001@test,  咨询分机:950002)
voice9.consult(telNum)

//取消咨询
voice9.consultCancel(telNum)

//咨询转接
voice9.consultTransfer(telNum)

//转多方
voice9.consultParty()

//通话静音
voice9.mute()

//通话取消静音
voice9.cancelMute()

//通话保持
voice9.hold()

//通话取消保持
voice9.cancelHold()

//班长监听:班长可以听到别人的声音,别人听不到班长的声音。
voice9.monitor('1003@test', callId)

//强拆:原本与客户通话的坐席会被挂断,发起强拆的坐席代替原坐席继续与客户通话。(必须处于监听中的电话)
voice9.intercept()

//强插:通话将由原来的双方通话变成三人会议
voice9.barge('1003@test', callId)

//辅导:辅导过程中被辅导坐席可以听到辅导者的声音,客户无法听到辅导者的声音。
voice9.coach('1003@test', callId)

事件

// 监听全量消息
voice9.on('message', (data) => {})

// 监听退出
voice9.on('logout', (data) => {})

// 监听可用行为列表
voice9.on('btnstate', (btns) => {})

// 监听状态变化
voice9.on('agentstate', (state) => {})

// 监听具体状态
voice9.on(voice9.enum.state.LOGIN, (data) => {})

// 触发事件
voice.emit(event, data)