用于 Planning Center Services API 的命令行工具。用于 Shadow 的教会工作(FBC Gulfport)。
https://github.com/rubysworld/pco-cli
/Users/ruby/Projects/pco-cli/pco.ts
tsx /Users/ruby/Projects/pco-cli/pco.ts <命令>
或创建别名:
alias pco="tsx /Users/ruby/Projects/pco-cli/pco.ts"
凭据存储在 ~/.config/pco-cli/config.json
# 检查认证状态
pco auth status
# 设置(交互式)
pco auth setup
# 登出
pco auth logout
所有列表命令均支持:
- --json - 以 JSON 格式输出(默认)
- --table - 以表格形式输出
- --quiet - 仅输出 ID
- --limit <n> - 限制结果数量(默认:25)
- --offset <n> - 结果偏移量
- --all - 获取所有分页
pco org get # 获取组织信息
pco service-types list # 列出所有服务类型
pco st list # 别名
pco service-types get <id> # 获取特定服务类型
# 列出计划(必须指定服务类型)
pco plans list --service-type <id>
pco plans list --service-type <id> --filter future
pco plans list --service-type <id> --filter past
# 获取特定计划
pco plans get <planId> --service-type <id>
pco plans get <planId> --service-type <id> --include items,team_members
过滤器:future, past, after, before, no_dates
pco items list --service-type <id> --plan <planId>
pco items get <itemId> --service-type <id> --plan <planId>
pco scheduled list --service-type <id> --plan <planId>
pco people list
pco people list --search "John Doe"
pco people get <id>
pco teams list --service-type <id>
pco teams get <teamId> --service-type <id>
pco songs list
pco songs list --search "Amazing Grace"
pco songs get <id>
pco songs arrangements <songId>
pco media list
pco media get <id>
pco folders list
pco folders get <id>
pco series list
pco series get <id>
pco tag-groups list
pco tag-groups tags <groupId>
pco email-templates list
pco attachment-types list
pco report-templates list
# 直接访问 API
pco api GET /service_types
pco api POST /endpoint --data '{"key": "value"}'
pco api PATCH /endpoint --file data.json
pco api DELETE /endpoint
# 1. 查找服务类型 ID
pco st list --table
# 2. 获取未来计划
pco plans list --service-type <id> --filter future --limit 1
# 3. 获取包含详细信息的计划
pco plans get <planId> --service-type <id> --include items,team_members
pco scheduled list --service-type <id> --plan <planId> --table
pco songs list --search "Great Are You Lord"
最后更新:2026-01-08