简介
通过 CLI 读写 Things 3 数据,支持任务增删改查与项目/标签管理,需 macOS 本地数据库访问权限。
原始描述
Manage Things 3 via the `things` CLI on macOS (add/update projects+todos via URL scheme; read/search/list from the local Things database). Use when a user as...
通过你的 Agent 添加
点「快速安装」复制一段指令,粘给你正在用的 Agent(Claude Code、Codex、OpenClaw 等),它会自己完成安装。
或者手动安装
包里是 SKILL.md 加作者附带的文件,解压后目录名就是技能名。
技能申请的权限由作者决定,装之前请确认它能读什么、能执行什么。
中文使用说明 来自收录源
核心功能
Things 3 CLI (things) 是一款面向 macOS 的命令行工具,提供对 Cultured Code Things 3 的双向操作能力:
读取操作(本地数据库)
- 直接查询 SQLite 数据库:
inbox、today、upcoming列表 - 全文搜索:
things search "query" - 元数据枚举:
projects、areas、tags
写入操作(URL Scheme)
- 添加任务:
things add "标题" --notes --when --deadline - 更新任务:
things update --id <UUID> --title/--notes/--tags/--completed - 支持子任务(checklist)、项目分区(heading)、标签批量操作
高级特性
--dry-run安全预览 URL,不实际触发- STDIN 管道输入实现多行内容批量导入
THINGS_AUTH_TOKEN环境变量避免重复传参
显著优点
- 原生集成:直接读写 Things 3 本地数据库,非第三方 API 封装
- 脚本友好:返回结构化数据(JSON/表格),适合自动化工作流
- 灵活输入:支持管道、多行 heredoc、交互式补全场景
- 权限粒度清晰:读操作仅需磁盘访问,写操作需用户授权 Token
局限性与风险
| 维度 | 说明 |
|---|---|
| 平台锁定 | 仅限 macOS,无 Windows/iOS 支持 |
| 删除限制 | 无法硬删除任务(仅能 completed/canceled) |
| 权限要求 | 需为调用进程(Terminal/OpenClaw.app)开启「完全磁盘访问」 |
| 单用户 | 依赖本地 SQLite,不支持 Things Cloud 多设备同步冲突处理 |
| Schema 依赖 | Things 应用更新可能破坏数据库读取兼容性 |
适合人群
- 效率自动化用户:配合 Alfred/Raycast/Shortcuts 快速捕获任务
- 开发者/技术写作者:将任务管理集成到 Git hooks、CI 脚本
- Things 3 重度用户:需要批量导入、程序化整理历史任务
安全建议
- 生产环境建议
--dry-run验证后再执行批量更新 THINGS_AUTH_TOKEN避免写入 shell history,可用export或钥匙串管理- 定期检查 Things 应用更新后的数据库 Schema 变更日志
技能正文
name: things-mac
description: Manage Things 3 via the things CLI on macOS (add/update projects+todos via URL scheme; read/search/list from the local Things database). Use when a user asks OpenClaw to add a task to Things, list inbox/today/upcoming, search tasks, or inspect projects/areas/tags.
homepage: https://github.com/ossianhempel/things3-cli
metadata:
{
"openclaw":
{
"emoji": "✅",
"os": ["darwin"],
"requires": { "bins": ["things"] },
"install":
[
{
"id": "go",
"kind": "go",
"module": "github.com/ossianhempel/things3-cli/cmd/things@latest",
"bins": ["things"],
"label": "Install things3-cli (go)",
},
],
},
}
Things 3 CLI
Use things to read your local Things database (inbox/today/search/projects/areas/tags) and to add/update todos via the Things URL scheme.
Setup
- Install (recommended, Apple Silicon):
GOBIN=/opt/homebrew/bin go install github.com/ossianhempel/things3-cli/cmd/things@latest - If DB reads fail: grant Full Disk Access to the calling app (Terminal for manual runs;
OpenClaw.appfor gateway runs). - Optional: set
THINGSDB(or pass--db) to point at yourThingsData-*folder. - Optional: set
THINGS_AUTH_TOKENto avoid passing--auth-tokenfor update ops.
Read-only (DB)
things inbox --limit 50things todaythings upcomingthings search "query"things projects/things areas/things tags
Write (URL scheme)
- Prefer safe preview:
things --dry-run add "Title" - Add:
things add "Title" --notes "..." --when today --deadline 2026-01-02 - Bring Things to front:
things --foreground add "Title"
Examples: add a todo
- Basic:
things add "Buy milk" - With notes:
things add "Buy milk" --notes "2% + bananas" - Into a project/area:
things add "Book flights" --list "Travel" - Into a project heading:
things add "Pack charger" --list "Travel" --heading "Before" - With tags:
things add "Call dentist" --tags "health,phone" - Checklist:
things add "Trip prep" --checklist-item "Passport" --checklist-item "Tickets" - From STDIN (multi-line => title + notes):
cat <<'EOF' | things add -Title lineNotes line 1Notes line 2EOF
Examples: modify a todo (needs auth token)
- First: get the ID (UUID column):
things search "milk" --limit 5 - Auth: set
THINGS_AUTH_TOKENor pass--auth-token <TOKEN> - Title:
things update --id <UUID> --auth-token <TOKEN> "New title" - Notes replace:
things update --id <UUID> --auth-token <TOKEN> --notes "New notes" - Notes append/prepend:
things update --id <UUID> --auth-token <TOKEN> --append-notes "..."/--prepend-notes "..." - Move lists:
things update --id <UUID> --auth-token <TOKEN> --list "Travel" --heading "Before" - Tags replace/add:
things update --id <UUID> --auth-token <TOKEN> --tags "a,b"/things update --id <UUID> --auth-token <TOKEN> --add-tags "a,b" - Complete/cancel (soft-delete-ish):
things update --id <UUID> --auth-token <TOKEN> --completed/--canceled - Safe preview:
things --dry-run update --id <UUID> --auth-token <TOKEN> --completed
Delete a todo?
- Not supported by
things3-cliright now (no “delete/move-to-trash” write command;things trashis read-only listing). - Options: use Things UI to delete/trash, or mark as
--completed/--canceledviathings update.
Notes
- macOS-only.
--dry-runprints the URL and does not open Things.
正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。