pp-customer-io
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseCustomer.io — Printing Press CLI
Customer.io — Printing Press CLI
Prerequisites: Install the CLI
前提条件:安装CLI
This skill drives the binary. You must verify the CLI is installed before invoking any command from this skill. If it is missing, install it first:
customer-io-pp-cli- Install via the Printing Press installer:
bash
npx -y @mvanhorn/printing-press install customer-io --cli-only - Verify:
customer-io-pp-cli --version - Ensure (or
$GOPATH/bin) is on$HOME/go/bin.$PATH
If the install fails (no Node, offline, etc.), fall back to a direct Go install (requires Go 1.23+):
npxbash
go install github.com/mvanhorn/printing-press-library/library/other/customer-io/cmd/customer-io-pp-cli@latestIf reports "command not found" after install, the install step did not put the binary on . Do not proceed with skill commands until verification succeeds.
--version$PATHThe official customerio/cli exposes the API as raw passthrough. This CLI gives you typed commands for every meaningful workflow, plus eight commands no other tool has — journey funnels cross-cut by segment, multi-segment overlap, customer 360 timelines, broadcast pre-flight, suppression audit trails, Reverse-ETL health, bulk suppress with provenance, and incident-ready delivery triage bundles. It is also the only Customer.io tool that ships an MCP server.
本技能基于二进制文件运行。在调用本技能的任何命令前,必须确认CLI已安装。如果未安装,请先执行以下步骤:
customer-io-pp-cli- 通过Printing Press安装程序安装:
bash
npx -y @mvanhorn/printing-press install customer-io --cli-only - 验证安装:
customer-io-pp-cli --version - 确保(或
$GOPATH/bin)已添加到$HOME/go/bin环境变量中。$PATH
如果npx安装失败(无Node环境、离线等),可以回退到直接通过Go安装(需要Go 1.23及以上版本):
bash
go install github.com/mvanhorn/printing-press-library/library/other/customer-io/cmd/customer-io-pp-cli@latest如果安装后执行提示“command not found”,说明安装程序未将二进制文件添加到中。请在验证成功前不要执行技能命令。
--version$PATH官方的customerio/cli仅将API作为原始透传接口。本CLI为所有有意义的工作流提供了类型化命令,另外还具备八项其他工具没有的功能——按细分维度交叉分析旅程漏斗、多细分受众重叠分析、客户360度时间线、广播预检查、屏蔽审计追踪、Reverse-ETL健康检查、带溯源的批量屏蔽,以及可直接用于事件响应的交付分类包。它也是唯一内置MCP服务器的Customer.io工具。
When to Use This CLI
何时使用本CLI
Reach for this CLI when you need to do anything in Customer.io that's tedious in the web UI: bulk suppressions with an audit trail, journey funnels cross-cut by segment, customer-360 timelines for incident triage, broadcast pre-flight before a high-stakes send, or Reverse-ETL health checks. It is also the right tool when an agent needs to drive Customer.io — the bundled MCP server exposes the same verbs over stdio and HTTP transports. For raw event ingestion (the Track API) or per-source CDP write keys, prefer one of the official server-side SDKs.
当你需要在Customer.io上执行Web UI中繁琐的操作时,可使用本CLI:带审计追踪的批量屏蔽、按细分维度交叉分析旅程漏斗、用于事件排查的客户360度时间线、高风险发送前的广播预检查,或Reverse-ETL健康检查。当需要通过Agent驱动Customer.io时,它也是合适的工具——内置的MCP服务器通过标准输入输出和HTTP传输暴露相同的动词接口。对于原始事件 ingestion(Track API)或按数据源划分的CDP写入密钥,建议使用官方的服务端SDK。
Unique Capabilities
独特功能
These capabilities aren't available in any other tool for this API.
这些功能是其他同类型API工具所不具备的。
Local state that compounds
可累积的本地状态
-
— Render a step-by-step journey funnel (sent → delivered → opened → clicked → converted) for one campaign, optionally cross-cut by segment.
campaigns funnelReach for this when an agent is asked 'what fraction of segment X completed journey Y' — the answer is one query against synced data, not two exports and a spreadsheet.bashcustomer-io campaigns funnel cmp_482 --segment seg_19 --since 30d --json -
— Compute pairwise and multi-way Venn diagrams of segment memberships from the local store.
segments overlapUse when validating audience design — 'are my churned-risk and high-value segments overlapping?' — without exporting twice.bashcustomer-io segments overlap seg_19 seg_42 seg_88 --json -
— Chronological per-customer event stream merging identifies, deliveries, suppressions, and segment-membership events from the local store.
customers timelineReach for this on incident triage or 'did the welcome SMS go out to this user?' — one command instead of a UI scroll-fest.bashcustomer-io customers timeline alice@example.com --since 30d --json
-
— 渲染单个营销活动的分步旅程漏斗(已发送 → 已交付 → 已打开 → 已点击 → 已转化),可选择按细分维度交叉分析。
campaigns funnel当Agent被问到“细分受众X中有多少比例完成了旅程Y”时,使用该命令——只需针对同步数据执行一次查询,无需两次导出再用电子表格计算。bashcustomer-io campaigns funnel cmp_482 --segment seg_19 --since 30d --json -
— 从本地存储计算细分受众成员的两两及多向维恩图重叠情况。
segments overlap用于验证受众设计——比如“我的高流失风险和高价值受众是否重叠?”——无需两次导出数据。bashcustomer-io segments overlap seg_19 seg_42 seg_88 --json -
— 按时间顺序合并单个客户的身份识别、消息交付、用户屏蔽和细分受众成员资格事件,数据来自本地存储。
customers timeline用于事件排查或“欢迎短信是否发送给了该用户?”这类问题——只需一条命令,无需在UI中反复滚动查找。bashcustomer-io customers timeline alice@example.com --since 30d --json
Send-time safety
发送时安全性
-
— Before triggering a broadcast, check target segment size, suppression overlap, and last-sent recency from the local deliveries cache; emit a green/yellow/red verdict with structured reasons.
broadcasts preflightUse before any broadcast to avoid double-sending, accidental over-mailing, or 429 storms.bashcustomer-io broadcasts preflight 123457 bcr_77 --segment seg_19 --json -
— Attribute every suppression in a window to the triggering bounce or complaint delivery (or 'manual' if no preceding event).
suppressions auditUse when an ops engineer needs to explain why a customer is suppressed, or when auditing complaint-driven churn.bashcustomer-io suppressions audit --since 30d --reason bounce --json -
— Named verb over Reverse-ETL run history with status, row counts, error reasons, and an optional --watch poll mode.
cdp-reverse-etl healthUse as the daily standup question 'are warehouse syncs healthy?' — replaces three separate api calls + jq filters.bashcustomer-io cdp-reverse-etl health --since 24h --watch
-
— 在触发广播前,检查目标细分受众规模、屏蔽重叠情况以及本地交付缓存中的最近发送记录;输出带有结构化原因的绿/黄/红判定结果。
broadcasts preflight在任何广播前使用,避免重复发送、意外过度发送或429限流风暴。bashcustomer-io broadcasts preflight 123457 bcr_77 --segment seg_19 --json -
— 将指定时间段内的每一项屏蔽操作归因于触发它的退信或投诉交付事件(如果没有前置事件则标记为“手动”)。
suppressions audit当运维工程师需要解释客户被屏蔽的原因,或审计由投诉导致的客户流失时使用。bashcustomer-io suppressions audit --since 30d --reason bounce --json -
— 通过命名动词查看Reverse-ETL运行历史,包含状态、行数、错误原因,可选
cdp-reverse-etl health轮询模式。--watch用于日常站会中“仓库同步是否正常?”这类问题——替代三次独立API调用+jq过滤。bashcustomer-io cdp-reverse-etl health --since 24h --watch
Audit and provenance
审计与溯源
-
— Read a CSV or JSONL of email/customer-id, fan out real suppress calls with adaptive throttle, append every call to a local JSONL audit log keyed by date.
suppressions bulk addUse for compliance-driven bulk actions where you need to defend later 'who got suppressed when, by whom, with what status code'.bashcustomer-io suppressions bulk add --from-csv complaints.csv --reason complaint --dry-run -
— Filter live + local deliveries by template + status + window, write a self-contained bundle (summary.md with SQL group-by error reasons, deliveries.jsonl, recipients.txt) ready to paste into an incident doc.
deliveries triagePipe the bundle into Claude or a Notion doc for one-shot incident handoff; replaces 30+ minutes of UI scrolling.bashcustomer-io deliveries triage --template tx_91 --status bounced --since 1h --bundle ./incident-2026-05-07
-
— 读取CSV或JSONL格式的邮箱/客户ID列表,通过自适应限流批量执行屏蔽调用,并将每一次调用追加到按日期分类的本地JSONL审计日志中。
suppressions bulk add用于合规驱动的批量操作,后续可追溯“谁在何时被屏蔽,执行方是谁,状态码是什么”。bashcustomer-io suppressions bulk add --from-csv complaints.csv --reason complaint --dry-run -
— 按模板、状态和时间段过滤实时+本地交付数据,生成一个独立的打包文件(包含按错误原因分组的SQL汇总文件summary.md、deliveries.jsonl、recipients.txt),可直接粘贴到事件文档中。
deliveries triage将打包文件导入Claude或Notion文档,即可一键完成事件交接;替代30分钟以上的UI滚动操作。bashcustomer-io deliveries triage --template tx_91 --status bounced --since 1h --bundle ./incident-2026-05-07
Command Reference
命令参考
broadcasts — List, inspect, and trigger one-off broadcasts (1 req / 10 s rate-limited)
- — Get one broadcast
customer-io-pp-cli broadcasts get - — List broadcasts in an environment
customer-io-pp-cli broadcasts list - — Read metrics for one broadcast
customer-io-pp-cli broadcasts metrics - — Trigger a broadcast (rate-limited to 1 req / 10 s)
customer-io-pp-cli broadcasts trigger
campaigns — List campaigns and read campaign + journey metrics
- — Get one campaign
customer-io-pp-cli campaigns get - — Read step-by-step journey funnel metrics
customer-io-pp-cli campaigns journey_metrics - — List campaigns in an environment
customer-io-pp-cli campaigns list - — Read aggregate metrics for a campaign
customer-io-pp-cli campaigns metrics
cdp_destinations — List CDP destinations (Premium feature)
- — List CDP destinations
customer-io-pp-cli cdp_destinations
cdp_reverse_etl — List Reverse-ETL syncs (Premium feature)
- — List Reverse-ETL syncs
customer-io-pp-cli cdp_reverse_etl
cdp_sources — List CDP data sources (Premium feature)
- — List CDP sources
customer-io-pp-cli cdp_sources
customers — Manage Customer.io customer profiles within an environment (workspace)
- — Get a customer's attributes
customer-io-pp-cli customers get - — List activity events for a customer
customer-io-pp-cli customers list_activities - — List messages sent to a customer
customer-io-pp-cli customers list_messages - — List the segments a customer belongs to
customer-io-pp-cli customers list_segments
deliveries — Inspect delivery events (sends, opens, clicks, bounces, complaints)
- — Get one delivery
customer-io-pp-cli deliveries get - — List recent deliveries
customer-io-pp-cli deliveries list
exports — Start, monitor, and download data exports (segment members, deliveries, customers, etc.)
- — Get the signed download URL for a finished export
customer-io-pp-cli exports download - — Get the status of an export
customer-io-pp-cli exports get - — List recent exports
customer-io-pp-cli exports list
segments — List segments and inspect segment membership
- — Get the customer count for a segment
customer-io-pp-cli segments customer_count - — Get one segment
customer-io-pp-cli segments get - — List segments in an environment
customer-io-pp-cli segments list - — List customer IDs in a segment
customer-io-pp-cli segments members
suppressions — Suppress and unsuppress customers; the official audit surface for compliance actions
- — Suppress a customer
customer-io-pp-cli suppressions add - — Get the count of suppressed customers in an environment (Customer.io has no list endpoint; use 'exports...
customer-io-pp-cli suppressions count - — Remove a suppression
customer-io-pp-cli suppressions remove
transactional — Inspect transactional templates and metrics
- — Get one transactional template
customer-io-pp-cli transactional get_template - — List transactional templates
customer-io-pp-cli transactional list_templates - — Read metrics for one transactional template
customer-io-pp-cli transactional template_metrics
webhooks — Manage Reporting Webhooks for delivery + engagement events
- — Get one Reporting Webhook
customer-io-pp-cli webhooks get - — List Reporting Webhooks
customer-io-pp-cli webhooks list
workspaces — List the environments (workspaces) visible to the Service Account
- — Get the current account details
customer-io-pp-cli workspaces account - — Read the current account, including environment_ids visible to the SA token
customer-io-pp-cli workspaces list
broadcasts — 列出、查看和触发一次性广播(速率限制:1请求/10秒)
- — 获取单个广播信息
customer-io-pp-cli broadcasts get - — 列出环境中的所有广播
customer-io-pp-cli broadcasts list - — 读取单个广播的指标
customer-io-pp-cli broadcasts metrics - — 触发广播(速率限制:1请求/10秒)
customer-io-pp-cli broadcasts trigger
campaigns — 列出营销活动并读取营销活动+旅程指标
- — 获取单个营销活动信息
customer-io-pp-cli campaigns get - — 读取分步旅程漏斗指标
customer-io-pp-cli campaigns journey_metrics - — 列出环境中的所有营销活动
customer-io-pp-cli campaigns list - — 读取营销活动的汇总指标
customer-io-pp-cli campaigns metrics
cdp_destinations — 列出CDP目标(高级功能)
- — 列出CDP目标
customer-io-pp-cli cdp_destinations
cdp_reverse_etl — 列出Reverse-ETL同步任务(高级功能)
- — 列出Reverse-ETL同步任务
customer-io-pp-cli cdp_reverse_etl
cdp_sources — 列出CDP数据源(高级功能)
- — 列出CDP数据源
customer-io-pp-cli cdp_sources
customers — 在环境(工作区)内管理Customer.io客户档案
- — 获取客户的属性信息
customer-io-pp-cli customers get - — 列出客户的活动事件
customer-io-pp-cli customers list_activities - — 列出发送给客户的消息
customer-io-pp-cli customers list_messages - — 列出客户所属的细分受众
customer-io-pp-cli customers list_segments
deliveries — 查看交付事件(发送、打开、点击、退信、投诉)
- — 获取单个交付事件信息
customer-io-pp-cli deliveries get - — 列出最近的交付事件
customer-io-pp-cli deliveries list
exports — 启动、监控和下载数据导出(细分受众成员、交付记录、客户数据等)
- — 获取已完成导出的签名下载链接
customer-io-pp-cli exports download - — 获取导出任务的状态
customer-io-pp-cli exports get - — 列出最近的导出任务
customer-io-pp-cli exports list
segments — 列出细分受众并查看细分受众成员
- — 获取细分受众的客户数量
customer-io-pp-cli segments customer_count - — 获取单个细分受众信息
customer-io-pp-cli segments get - — 列出环境中的所有细分受众
customer-io-pp-cli segments list - — 列出细分受众中的客户ID
customer-io-pp-cli segments members
suppressions — 屏蔽和取消屏蔽客户;合规操作的官方审计接口
- — 屏蔽客户
customer-io-pp-cli suppressions add - — 获取环境中被屏蔽客户的数量(Customer.io无列表端点;使用'exports...
customer-io-pp-cli suppressions count - — 取消客户屏蔽
customer-io-pp-cli suppressions remove
transactional — 查看事务性模板和指标
- — 获取单个事务性模板
customer-io-pp-cli transactional get_template - — 列出事务性模板
customer-io-pp-cli transactional list_templates - — 读取单个事务性模板的指标
customer-io-pp-cli transactional template_metrics
webhooks — 管理交付+互动事件的报告Webhook
- — 获取单个报告Webhook
customer-io-pp-cli webhooks get - — 列出报告Webhook
customer-io-pp-cli webhooks list
workspaces — 列出服务账号可见的环境(工作区)
- — 获取当前账号详情
customer-io-pp-cli workspaces account - — 读取当前账号信息,包括服务账号令牌可见的环境ID
customer-io-pp-cli workspaces list
Finding the right command
查找合适的命令
When you know what you want to do but not which command does it, ask the CLI directly:
bash
customer-io-pp-cli which "<capability in your own words>"which02--help当你知道要执行的操作但不知道对应的命令时,可直接询问CLI:
bash
customer-io-pp-cli which "<用自己的话描述功能>"which02--helpRecipes
使用示例
Find which high-value customers haven't engaged with the welcome journey
查找哪些高价值客户未参与欢迎旅程
bash
customer-io campaigns funnel cmp_welcome --segment seg_high_value --since 90d --agent --select steps.delivered.count,steps.opened.count,steps.clicked.count,non_engaged.recipientsThe funnel command joins synced deliveries with segment members; --agent + --select narrows the deeply-nested funnel response to just the counts and the non-engaged recipient list, keeping the agent's context lean.
bash
customer-io campaigns funnel cmp_welcome --segment seg_high_value --since 90d --agent --select steps.delivered.count,steps.opened.count,steps.clicked.count,non_engaged.recipients漏斗命令将同步的交付数据与细分受众成员关联;+将深度嵌套的漏斗响应缩小为仅包含计数和未参与受众列表,保持Agent的上下文简洁。
--agent--selectDraft an incident bundle for a transactional bounce spike
为事务性退信峰值生成事件打包文件
bash
customer-io deliveries triage --template tx_password_reset --status bounced --since 2h --bundle ./incident-bounce-2026-05-07Writes summary.md with grouped error reasons, deliveries.jsonl with full delivery objects, and recipients.txt — paste-ready for a Notion incident doc or a Claude summarize prompt.
bash
customer-io deliveries triage --template tx_password_reset --status bounced --since 2h --bundle ./incident-bounce-2026-05-07生成包含分组错误原因的summary.md、完整交付对象的deliveries.jsonl和recipients.txt——可直接粘贴到Notion事件文档或Claude汇总提示中。
Prove that a broadcast is safe to trigger
验证广播是否可安全触发
bash
customer-io broadcasts preflight bcr_summer_promo --segment seg_active_30d --jsonReturns a green/yellow/red verdict with structured reasons (segment size, suppression overlap, last-sent recency from synced deliveries). Run before every broadcast at non-trivial scale.
bash
customer-io broadcasts preflight bcr_summer_promo --segment seg_active_30d --json返回带有结构化原因(细分受众规模、屏蔽重叠情况、同步交付数据中的最近发送记录)的绿/黄/红判定结果。在任何非小规模广播前执行此命令。
Bulk-suppress a complaint list with provenance
带溯源的批量屏蔽投诉列表
bash
customer-io suppressions bulk add --from-csv complaints-2026-05.csv --reason complaint --dry-runDrop --dry-run to commit. Every call lands in with timestamp, recipient, status, and HTTP code — defensible later.
~/.customer-io/audit/suppressions-2026-05-07.jsonlbash
customer-io suppressions bulk add --from-csv complaints-2026-05.csv --reason complaint --dry-run移除参数即可执行实际操作。每一次调用都会记录到中,包含时间戳、收件人、状态和HTTP状态码——后续可追溯。
--dry-run~/.customer-io/audit/suppressions-2026-05-07.jsonlWatch Reverse-ETL syncs in real time
实时监控Reverse-ETL同步任务
bash
customer-io cdp-reverse-etl health --watch --since 24hPolls every 60 s and prints a status row per sync; pipe to to keep a log.
teebash
customer-io cdp-reverse-etl health --watch --since 24h每60秒轮询一次,并打印每个同步任务的状态行;可通过管道输出到命令保存日志。
teeAuth Setup
认证设置
Customer.io uses Service Account tokens ( prefix). The CLI exchanges the token for a short-lived JWT via the OAuth client-credentials endpoint at (or for EU workspaces) and uses the JWT as the Bearer for both the Journeys UI API () and the CDP control plane (). Run once; the cached JWT auto-refreshes. The Track API (separate Site ID + API Key auth) is intentionally out of scope for v1 — the SA token is the unified credential.
sa_live_*https://us.fly.customer.io/v1/service_accounts/oauth/tokeneu.fly.customer.io/v1/.../cdp/api/...customer-io auth login --sa-token $CIO_TOKEN --region usRun to verify setup.
customer-io-pp-cli doctorCustomer.io使用服务账号令牌(前缀为)。CLI会通过OAuth客户端凭证端点(欧盟工作区使用)将令牌交换为短期JWT,并使用该JWT作为Journeys UI API()和CDP控制平面()的Bearer凭证。只需执行一次;缓存的JWT会自动刷新。Track API(单独的站点ID+API密钥认证)在v1版本中未纳入范围——服务账号令牌是统一凭证。
sa_live_*https://us.fly.customer.io/v1/service_accounts/oauth/tokeneu.fly.customer.io/v1/.../cdp/api/...customer-io auth login --sa-token $CIO_TOKEN --region us执行验证设置是否正确。
customer-io-pp-cli doctorAgent Mode
Agent模式
Add to any command. Expands to: .
--agent--json --compact --no-input --no-color --yes-
Pipeable — JSON on stdout, errors on stderr
-
Filterable —keeps a subset of fields. Dotted paths descend into nested structures; arrays traverse element-wise. Critical for keeping context small on verbose APIs:
--selectbashcustomer-io-pp-cli broadcasts list mock-value --agent --select id,name,status -
Previewable —shows the request without sending
--dry-run -
Offline-friendly — sync/search commands can use the local SQLite store when available
-
Non-interactive — never prompts, every input is a flag
-
Explicit retries — useonly when an already-existing create should count as success
--idempotent
在任何命令后添加参数。等效于:。
--agent--json --compact --no-input --no-color --yes-
可管道化 — 标准输出为JSON,错误信息输出到标准错误
-
可过滤 —参数保留字段子集。点路径可深入嵌套结构;数组可遍历元素。对于冗长的API,这对于保持上下文简洁至关重要:
--selectbashcustomer-io-pp-cli broadcasts list mock-value --agent --select id,name,status -
可预览 —参数显示请求内容但不发送
--dry-run -
离线友好 — 同步/搜索命令在可用时可使用本地SQLite存储
-
非交互式 — 从不提示,所有输入均通过参数传递
-
显式重试 — 仅当已存在的创建操作应被视为成功时,使用参数
--idempotent
Response envelope
响应信封
Commands that read from the local store or the API wrap output in a provenance envelope:
json
{
"meta": {"source": "live" | "local", "synced_at": "...", "reason": "..."},
"results": <data>
}Parse for data and to know whether it's live or local. A human-readable summary is printed to stderr only when stdout is a terminal — piped/agent consumers get pure JSON on stdout.
.results.meta.sourceN results (live)从本地存储或API读取数据的命令会将输出封装在溯源信封中:
json
{
"meta": {"source": "live" | "local", "synced_at": "...", "reason": "..."},
"results": <data>
}解析获取数据,表示数据来自实时API还是本地存储。仅当标准输出为终端时,才会在标准错误输出中打印人类可读的摘要——管道/Agent消费者仅会在标准输出中获取纯JSON。
.results.meta.sourceN results (live)Agent Feedback
Agent反馈
When you (or the agent) notice something off about this CLI, record it:
customer-io-pp-cli feedback "the --since flag is inclusive but docs say exclusive"
customer-io-pp-cli feedback --stdin < notes.txt
customer-io-pp-cli feedback list --json --limit 10Entries are stored locally at . They are never POSTed unless is set AND either is passed or . Default behavior is local-only.
~/.customer-io-pp-cli/feedback.jsonlCUSTOMER_IO_FEEDBACK_ENDPOINT--sendCUSTOMER_IO_FEEDBACK_AUTO_SEND=trueWrite what surprised you, not a bug report. Short, specific, one line: that is the part that compounds.
当你(或Agent)发现本CLI存在问题时,可记录反馈:
customer-io-pp-cli feedback "the --since flag is inclusive but docs say exclusive"
customer-io-pp-cli feedback --stdin < notes.txt
customer-io-pp-cli feedback list --json --limit 10反馈条目存储在本地中。仅当设置了且传递了参数或时,才会将反馈POST到指定端点。默认行为仅存储在本地。
~/.customer-io-pp-cli/feedback.jsonlCUSTOMER_IO_FEEDBACK_ENDPOINT--sendCUSTOMER_IO_FEEDBACK_AUTO_SEND=true写下让你感到意外的内容,而非正式的bug报告。简短、具体、单行描述:这类反馈的价值会不断累积。
Output Delivery
输出交付
Every command accepts . The output goes to the named sink in addition to (or instead of) stdout, so agents can route command results without hand-piping. Three sinks are supported:
--deliver <sink>| Sink | Effect |
|---|---|
| Default; write to stdout only |
| Atomically write output to |
| POST the output body to the URL ( |
Unknown schemes are refused with a structured error naming the supported set. Webhook failures return non-zero and log the URL + HTTP status on stderr.
所有命令都支持参数。输出会发送到指定的sink,同时(或替代)输出到标准输出,因此Agent无需手动管道即可路由命令结果。支持三种sink:
--deliver <sink>| Sink | 效果 |
|---|---|
| 默认值;仅输出到标准输出 |
| 原子性地将输出写入 |
| 将输出体POST到指定URL( |
不支持的scheme会返回结构化错误,并列出支持的类型。Webhook调用失败会返回非零退出码,并在标准错误输出中记录URL和HTTP状态。
Named Profiles
命名配置文件
A profile is a saved set of flag values, reused across invocations. Use it when a scheduled agent calls the same command every run with the same configuration - HeyGen's "Beacon" pattern.
customer-io-pp-cli profile save briefing --json
customer-io-pp-cli --profile briefing broadcasts list mock-value
customer-io-pp-cli profile list --json
customer-io-pp-cli profile show briefing
customer-io-pp-cli profile delete briefing --yesExplicit flags always win over profile values; profile values win over defaults. lists all available profiles under so introspecting agents discover them at runtime.
agent-contextavailable_profiles配置文件是一组保存的参数值,可在多次调用中复用。当定时Agent每次运行都使用相同配置执行同一命令时,可使用此功能——即HeyGen的“Beacon”模式。
customer-io-pp-cli profile save briefing --json
customer-io-pp-cli --profile briefing broadcasts list mock-value
customer-io-pp-cli profile list --json
customer-io-pp-cli profile show briefing
customer-io-pp-cli profile delete briefing --yes显式参数始终优先于配置文件值;配置文件值优先于默认值。会在下列出所有可用配置文件,因此自省Agent可在运行时发现这些配置文件。
agent-contextavailable_profilesExit Codes
退出码
| Code | Meaning |
|---|---|
| 0 | Success |
| 2 | Usage error (wrong arguments) |
| 3 | Resource not found |
| 4 | Authentication required |
| 5 | API error (upstream issue) |
| 7 | Rate limited (wait and retry) |
| 10 | Config error |
| 代码 | 含义 |
|---|---|
| 0 | 成功 |
| 2 | 使用错误(参数错误) |
| 3 | 资源未找到 |
| 4 | 需要认证 |
| 5 | API错误(上游问题) |
| 7 | 速率限制(等待后重试) |
| 10 | 配置错误 |
Argument Parsing
参数解析
Parse :
$ARGUMENTS- Empty, , or
help→ show--helpoutputcustomer-io-pp-cli --help - Starts with → ends with
install→ MCP installation; otherwise → see Prerequisites abovemcp - Anything else → Direct Use (execute as CLI command with )
--agent
解析的逻辑:
$ARGUMENTS- 为空、或
help→ 显示--help输出customer-io-pp-cli --help - 以开头 → 若结尾为
install→ 安装MCP;否则 → 参考上方前提条件中的安装步骤mcp - 其他情况 → 直接使用(添加参数执行CLI命令)
--agent
MCP Server Installation
MCP服务器安装
- Install the MCP server:
bash
go install github.com/mvanhorn/printing-press-library/library/other/customer-io/cmd/customer-io-pp-mcp@latest - Register with Claude Code:
bash
claude mcp add customer-io-pp-mcp -- customer-io-pp-mcp - Verify:
claude mcp list
- 安装MCP服务器:
bash
go install github.com/mvanhorn/printing-press-library/library/other/customer-io/cmd/customer-io-pp-mcp@latest - 在Claude Code中注册:
bash
claude mcp add customer-io-pp-mcp -- customer-io-pp-mcp - 验证:
claude mcp list
Direct Use
直接使用
- Check if installed: If not found, offer to install (see Prerequisites at the top of this skill).
which customer-io-pp-cli - Match the user query to the best command from the Unique Capabilities and Command Reference above.
- Execute with the flag:
--agentbashcustomer-io-pp-cli <command> [subcommand] [args] --agent - If ambiguous, drill into subcommand help: .
customer-io-pp-cli <command> --help
- 检查是否安装:若未找到,提供安装选项(参考顶部前提条件中的步骤)。
which customer-io-pp-cli - 将用户查询与上方独特功能和命令参考中最匹配的命令对应。
- 添加参数执行:
--agentbashcustomer-io-pp-cli <command> [subcommand] [args] --agent - 若存在歧义,查看子命令帮助:。
customer-io-pp-cli <command> --help