← 返回
开发者工具

roku

Control Roku devices via CLI. Discovery, remote control, app launching, search, and HTTP bridge mode for real-time control.
通过 CLI 控制 Roku 设备,包括设备发现、遥控、应用启动、搜索以及 HTTP 桥接模式实现实时控制。
gumadeiras
开发者工具 clawhub v2.0.1 2 版本 99621.9 Key: 无需
★ 0
Stars
📥 2,635
下载
💾 1
安装
2
版本
#latest

概述

Roku CLI

Fast TypeScript CLI for controlling Roku devices via the ECP API.

Installation

npm install -g @gumadeiras/roku@latest

Quick Start

# Discover devices and save an alias
roku discover --save livingroom --index 1

# Use the alias
roku --host livingroom device-info
roku --host livingroom apps

Commands

CommandDescription
----------------------
roku discoverFind Roku devices on network
roku --host device-infoGet device info
roku --host appsList installed apps
roku --host command Send remote key
roku --host literal Type text
roku --host search --title Search content
roku --host launch Launch app
roku --host interactiveInteractive remote mode

Interactive Mode

roku livingroom                    # interactive control
roku --host livingroom interactive # same thing

Use arrow keys, enter, escape for remote-like control.

Bridge Service

Run a persistent HTTP bridge as a native OS service:

# Install and start the service
roku bridge install-service --port 19839 --token secret --host livingroom --user
roku bridge start --user

# Service management
roku bridge status --user
roku bridge stop --user
roku bridge uninstall --user

Send commands via HTTP:

# Send key
curl -X POST http://127.0.0.1:19839/key \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer secret" \
  -d '{"key":"home"}'

# Type text
curl -X POST http://127.0.0.1:19839/text \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer secret" \
  -d '{"text":"hello"}'

# Launch app
curl -X POST http://127.0.0.1:19839/launch \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer secret" \
  -d '{"app":"plex"}'

# Health check
curl http://127.0.0.1:19839/health -H "Authorization: Bearer secret"

Bridge Endpoints

EndpointBody
----------------
POST /key{"key": "home"}
POST /text{"text": "hello"}
POST /search{"title": "Stargate"}
POST /launch{"app": "plex"}
GET /health
GET /health?deep=1Deep health check (probes Roku)

Aliases

# Save device alias
roku discover --save livingroom --index 1
roku alias set office 192.168.1.20

# Save app alias  
roku alias set plex 13535

# List aliases
roku alias list

# Use aliases
roku --host livingroom launch plex

Remote Keys

home, back, select, up, down, left, right, play, pause, rev, fwd, replay, info, power, volume_up, volume_down, mute

Notes

  • Roku must be on the same network as the CLI
  • Bridge service runs as a native launchd (macOS) or systemd (Linux) service
  • Use --user flag for user-space service (no sudo required)
  • Use --token for authentication in bridge mode

Source

https://github.com/gumadeiras/roku-cli

版本历史

共 2 个版本

  • v2.0.1 当前
    2026-05-21 12:08 安全 安全
  • v2.0.0
    2026-03-28 13:51 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

productivity

jq

gumadeiras
{"answer":"命令行JSON处理器,提取、过滤、转换JSON。"}
★ 4 📥 4,588
developer-tools

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 668 📥 323,869
developer-tools

Gog

steipete
Google Workspace 命令行工具,支持 Gmail、日历、云端硬盘、通讯录、表格和文档。
★ 921 📥 185,748