PairOnce

io.github.paironce由 GitHub 账号 paironce 发布v0.11.2更新于 Nov 6, 2026

Send files and text between an AI agent and your own paired devices, end-to-end encrypted.

发布方自己的服务:ONCE

概览

AI 生成的概览

PairOnce 把 AI 代理与你自己的手机或电脑配对,使其能发送文件和文本、请求照片、扫描件或文件,并查看摄像头或屏幕的静态画面。

可以做什么
  • 配对与设备管理:用六位码和安全码核对把手机或电脑配对,并列出已配对设备
  • 发送文件与消息:把本机文件或文本、链接端到端加密地发送到已配对设备
  • 接收文件:等待用户从已配对设备发来文件,并保存到本地文件夹
  • 请求内容:说明理由后请用户拍摄照片、扫描纸质页面生成 PDF,或选择某个文件
  • 观看摄像头或屏幕:请求获取用户所见画面的静态图片,并可随时停止共享
适用场景
适合代理在电脑上工作时需要用户手机或其他设备上的东西:标签或报错画面的照片、纸质页面的扫描件、只存在于那台设备上的文件,或查看用户屏幕以便一步步指导。也适合把构建日志、链接或文档推送到手机。
运行要求
通过 npx 以 stdio 在本地运行,需要 Node.js 22 或更高版本(Windows、macOS 或 Linux)。另一台设备只需用浏览器打开 PairOnce 网站,无需账号。需要能访问 paironce.com;直连受阻时经 443 端口的加密中继或隧道,在限制域名的沙箱中需放行该域名。可选环境变量 PAIRONCE_NAME 和 PAIRONCE_HOME。
安装前请注意
代理可以请求观看用户的摄像头或屏幕并收到静态图片;每次请求都会显示理由,用户可拒绝,任一方都能停止共享。文件和消息会从本机发送到用户设备,接收的文件写入服务器工作目录(默认 inbox)。发送时会排除 .env、.ssh 等隐藏文件和文件夹,但其他敏感文件不受限制。设备密钥和已配对设备列表保存在仅本人可读的本地目录中。

安装

在 SourceWeft 中

  1. 打开 控制台中的 PairOnce,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

paironce

Send files and text from a terminal to your own phone or computer with PairOnce. Pair once with a six-digit code; after that, npx paironce send report.pdf puts the file on your phone. End-to-end encrypted, direct between the devices whenever the network allows, and through an encrypted relay when it does not. No account.

sh
npx paironce pair                 # shows a code: type it at paironce.com on your phonenpx paironce send build.zip       # sends to the paired devicenpx paironce text "https://example.com/some/long/link"npx paironce receive --to ./inbox # receives files sent from the phone

The other device is any browser with https://paironce.com open: iPhone, Android, Windows, Mac or Linux. Nothing to install there.

Commands

CommandWhat it does
paironce pairShows a six-digit code. On the other device, open paironce.com, choose Enter a code and type it. Both screens show the same safety code; approve the device in the terminal.
paironce pair 123456Joins with the code the other device shows, for a person at this terminal.
paironce send <file>...Sends files to the paired device. With several paired devices, add --to "<name>". The other device accepts each file before it arrives.
paironce text "<message>"Sends a message or a link.
paironce receiveReceives files into the current folder (--to <folder>). Asks before each file; --yes accepts every file during this run. Large files are written straight to disk, so they can be as large as the sender may send, and one cut off continues when it is sent again.
paironce devicesLists paired devices.
paironce forget <name>Forgets a paired device.
paironce mcpRuns as an MCP server for AI agents.

--name "<name>" (or the PAIRONCE_NAME variable) sets what the other device shows for this one, for example --name "Build server". The key stays the same, so paired devices still know it. --agent marks this device as an AI agent on the other device (the MCP server always does). The MCP server stays connected for 30 minutes after its last tool call, so the next task needs no tap on your device; you see it as connected and can end it there. The MCP tools save inside the folder the server runs in (inbox by default). --ephemeral uses a throwaway identity in a temporary folder, which the other device forgets after a day without a connection: right for a sandbox that is thrown away.

When a paired device is not connected, the command asks it to connect: PairOnce on that device shows "Windows · Terminal wants to reconnect" with a Connect button.

Use it from an AI agent (MCP)

paironce mcp gives an agent ten tools:

ToolWhat it does
pair_devicePairs one of your devices. The agent gives you a six-digit code; you open paironce.com on that device, choose Enter a code and type it. The agent then tells you a safety code, and goes on only after you say your device shows the same. Once per device.
send_file, send_textSends to a paired device; you accept every file there.
receive_filesWaits while you send files from your device (a photo of a whiteboard, a scan, a document) and saves them into ./inbox.
request_photo, request_scan, request_fileAsks for something specific, with the reason. Your device shows the request; you take the photo, scan the pages or choose the file there, or decline. Saved into ./inbox.
watch_frames, watch_stopAsks to see your camera or screen, with the reason. You share it on your device, or decline; the agent then gets a still picture each time it asks (at most two a second) and can guide you step by step. Your device shows the share and a stop button; it ends when either side stops it.
list_devicesLists the paired devices.

The agent reaches only devices you paired and approved, and nothing arrives anywhere unasked. Your device marks it Agent when it asks to be approved and in your saved devices. Design and plans: Agent as a Device.

send_file does not send hidden files and folders (such as .env or .ssh), Windows's AppData, a Mac's Library or this device's own PairOnce files; you can still send those yourself with paironce send. A file that arrives after receive_files or a request stopped waiting is saved in the folder it was accepted for, and the next receive_files reports it. Changes in each version are in the releases.

Claude Code:

sh
claude mcp add paironce -e PAIRONCE_NAME="Claude Code · Agent" -- npx -y paironce mcp# in a throwaway sandbox: ... -- npx -y paironce mcp --ephemeral# on Windows, through cmd: claude mcp add paironce -- cmd /c npx -y paironce mcp

Other clients (Cursor, Claude Desktop and others), in their MCP configuration:

json
{ "mcpServers": { "paironce": { "command": "npx", "args": ["-y", "paironce", "mcp"], "env": { "PAIRONCE_NAME": "Cursor · Agent" } } } }

Then ask: "pair with my phone", "send the build log to my phone", or let the agent ask you: "I need a photo of the label on the back of the router".

How it works

The CLI runs the same connection code as paironce.com: the PairOnce protocol and @paironce/core for pairing and encryption, with WebRTC from node-datachannel for direct connections and @roamhq/wrtc (libwebrtc) for the relay. Files and messages are encrypted on this computer and decrypted on the other device; the PairOnce service only introduces the two devices and, when needed, relays encrypted bytes it cannot read.

This computer's device key and the list of paired devices are kept in ~/.paironce (or $PAIRONCE_HOME), readable only by you. The private key never leaves this computer.

It connects directly whenever the networks allow it, otherwise through the encrypted relay over UDP, TCP or TLS on port 443, and where even that is blocked, through the PairOnce tunnel: the same encrypted data over a secure WebSocket to paironce.com. So it works on servers, in containers that block UDP, and behind a web proxy (HTTPS_PROXY is used automatically). In a cloud sandbox with an allow-list, such as Claude Code on the web, add paironce.com to the allowed domains. PAIRONCE_DEBUG=1 shows each step of connecting.

Requires Node.js 22 or later on Windows, macOS (x64 and arm64) or Linux (x64 and arm64).

License

Apache-2.0. PairOnce is a trademark of its owner; see https://paironce.com.

来源:README.md,提交 3fc987e

工具

10

pair_device

Pair one of the user's devices (phone or computer) with this agent through PairOnce; needed once per device. Three calls. First call: returns a six-digit code; tell the user to open https://paironce.com on that device, choose "Enter a code" and type it. Second call: waits until they did and returns a safety code; ask the user whether their device shows the same one. Third call: confirm true if they said yes, false if not. Never confirm without asking the user.

输入参数confirmwait_seconds

list_devices

List the devices this agent is paired with through PairOnce.

无需输入参数。

send_file

Send files from this computer to one of the user's paired devices through PairOnce, end-to-end encrypted. The user accepts each file on that device, and PairOnce must be open there. Hidden files and folders (such as .env or .ssh) are not sent.

输入参数paths必填device

send_text

Send a message or a link to one of the user's paired devices through PairOnce, end-to-end encrypted. PairOnce must be open there.

输入参数text必填device

receive_files

Wait for the user to send files (photos, scans, documents) from one of their paired devices, and save them into a folder here. Tell the user to open https://paironce.com on that device, tap Connect, then choose the files. Returns the saved paths and any messages the user sent.

输入参数devicefolderwait_seconds

request_photo

Ask the user for a photo from one of their paired devices (usually their phone), for example of a label, a screen, an error message or a document. Their device shows your request with your reason; they take the photo there and it is saved here (default ./inbox). They may decline.

输入参数devicefolderpurpose必填wait_seconds

request_scan

Ask the user to scan paper pages with one of their paired devices (usually their phone): it makes a PDF there with straightened pages, which is saved here (default ./inbox). Their device shows your request with your reason. They may decline.

输入参数devicefolderpurpose必填wait_seconds

request_file

Ask the user for a file from one of their paired devices: their device shows your request with your reason, they choose the file there, and it is saved here (default ./inbox). They may decline.

输入参数devicefolderpurpose必填wait_seconds

watch_frames

See what the user sees: ask to watch their camera or screen on one of their paired devices, then get still pictures of it, returned as images you can look at (and saved, default ./inbox/watch). The first call asks; their device shows your reason and they share the camera or the screen there, or decline. Later calls return new stills from the same share, so you can guide them step by step ("now turn the switch on the left"). It ends when they stop, when you call watch_stop, or after 5 minutes without a call; their device ends it after 15 minutes.

输入参数countdevicefolderpurposewait_secondsinterval_seconds

watch_stop

Stop watching the user's camera or screen (see watch_frames). Their device stops sharing.

无需输入参数。

版本历史

4
  1. v0.11.2最新Nov 6, 2026
  2. v0.11.1Nov 5, 2026
  3. v0.11.0Nov 5, 2026
  4. v0.10.0Nov 5, 2026

评分

已满足适用检查项的 90%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分
  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具必需15 分
  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分

其他 Once 集成