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

iclick-auto

v1.0.5

Published

iClick Automation Tool Without Jailbreak NodeJS Package.

Readme

iclick-auto

npm version npm license

English | 中文

用于iOS免越狱自动化的 Node.js SDK。除了 API 调用功能外,实现了断线重连和事件监听机制以及二进制meta数据包解析。

官方网站: https://iosclick.com/

安装

npm install iclick-auto

快速开始

const iclick = require('iclick-auto')

// 创建客户端实例
const client = new iclick()

// 监听设备事件
client.on('device:online', (_data) => {
    console.log('设备上线:', _data)
})

client.on('device:offline', (_data) => {
    console.log('设备下线:', _data)
})

// 连接服务器
await client.connect()

// 调用 API
const result = await client.invoke('getDevices', { deviceId: 'P60904DC8D3F' })

console.log('结果:', result)

API 文档

new iclick(options)

创建客户端实例。

参数:

| 参数 | 类型 | 可选 | 说明 | 默认值 | |------|------|------|------|--------| | options.host | string | 是 | WebSocket 服务器地址 | 127.0.0.1 | | options.port | number | 是 | WebSocket 服务器端口 | 23188 | | options.autoReconnect | boolean | 是 | 是否启用自动重连 | true | | options.reconnectDelay | number | 是 | 重连延迟(秒) | 3 |

client.connect()

连接到 WebSocket 服务器。

返回: Promise<void>

示例:

try {
    await client.connect()
    console.log('连接成功')
} catch (error) {
    console.error('连接失败:', error)
}

client.invoke(type, params, timeout)

调用 API 方法。

参数:

  • type (string): API 类型
  • params (object, 可选): 请求参数,默认 {}
  • timeout (number, 可选): 超时时间(秒),默认 18

返回: Promise<any>

示例:

// 发送按键
const result = await client.invoke('sendKey', {
    deviceId: 'P60904DC8D3F',
    key: 'h',
    fnkey: 'COMMAND'
})

// 自定义超时时间
const result = await client.invoke('someType', { param: 'value' }, 30)

client.on(eventName, callback)

注册事件监听器。

参数:

  • eventName (string): 事件名称
  • callback (function): 回调函数,接收事件数据作为参数

示例:

client.on('device:online', (_data) => {
    console.log('设备上线:', _data)
})

client.on('device:offline', (_data) => {
    console.log('设备下线:', _data)
})

client.off(eventName, callback)

移除事件监听器。

参数:

  • eventName (string): 事件名称
  • callback (function, 可选): 要移除的回调函数。如果不提供,将移除该事件的所有监听器

示例:

const handler = (_data) => {
    console.log('收到事件:', _data)
}

// 注册监听器
client.on('someEvent', handler)

// 移除特定监听器
client.off('someEvent', handler)

// 移除事件的所有监听器
client.off('someEvent')

client.destroy()

销毁客户端,断开连接并清理所有资源。

示例:

client.destroy()
console.log('客户端已销毁')

License

ISC

相关链接

  • API参考: https://iosclick.com/zh/api/index.html
  • 事件通知: https://iosclick.com/zh/api/notify.html

问题反馈

如有问题,请在 Issues 中反馈。