{"_id":"@abimaelmartell/pco-cli","_rev":"5-12497f5a1fa0aaf7ef95548d38e14aef","name":"@abimaelmartell/pco-cli","dist-tags":{"latest":"0.1.4"},"versions":{"0.1.0":{"name":"@abimaelmartell/pco-cli","version":"0.1.0","keywords":["planning-center","planning-center-online","pco","cli","api","agents"],"author":"","license":"MIT","_id":"@abimaelmartell/pco-cli@0.1.0","maintainers":[{"name":"abimaelmartell","email":"abimex@gmail.com"}],"homepage":"https://github.com/abimaelmartell/pco-cli#readme","bugs":{"url":"https://github.com/abimaelmartell/pco-cli/issues"},"bin":{"pco":"dist/cli.js","pco-cli":"dist/cli.js"},"dist":{"shasum":"88eb4faa1d34a43966fb3d8fe4b9ca0a25234a64","tarball":"https://registry.npmjs.org/@abimaelmartell/pco-cli/-/pco-cli-0.1.0.tgz","fileCount":35,"integrity":"sha512-nTNtmeHdtj5NLcKFwnZOo3XMG4d4bWarwwtOE4yU9s4MaT1aNe52r0l/qtvkFkYKANratl4VgbuLu8WEZTR1HQ==","signatures":[{"sig":"MEUCIQDo1CLUUALGpWmpNHoo9SuCLZtrTWTWrBWjqDO+j0GWzgIgMl8lL8AA6B2s+iz6xBm8zIQI2LMXxr9S1npEH7xsVM0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":150615},"type":"module","engines":{"node":">=20.11"},"gitHead":"7f8d9a3f1c130c07054eeb25e637502d867638a3","scripts":{"dev":"tsx src/cli.ts","lint":"eslint .","test":"vitest run","build":"tsc -p tsconfig.build.json","check":"tsc -p tsconfig.json --noEmit","prepack":"npm run build"},"_npmUser":{"name":"abimaelmartell","email":"abimex@gmail.com"},"repository":{"url":"git+https://github.com/abimaelmartell/pco-cli.git","type":"git"},"_npmVersion":"11.6.2","description":"Agent-friendly TypeScript CLI for the Planning Center API.","directories":{},"_nodeVersion":"24.13.0","dependencies":{"zod":"^3.24.2","dotenv":"^16.4.7","undici":"^6.22.0","commander":"^12.1.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.2","eslint":"^9.18.0","vitest":"^2.1.8","@eslint/js":"^9.18.0","typescript":"^5.7.3","@types/node":"^22.10.7","typescript-eslint":"^8.20.0"},"_npmOperationalInternal":{"tmp":"tmp/pco-cli_0.1.0_1787773739922_0.16782428119485937","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"name":"@abimaelmartell/pco-cli","version":"0.1.1","keywords":["planning-center","planning-center-online","pco","cli","api","agents"],"author":"","license":"MIT","_id":"@abimaelmartell/pco-cli@0.1.1","maintainers":[{"name":"abimaelmartell","email":"abimex@gmail.com"}],"homepage":"https://github.com/abimaelmartell/pco-cli#readme","bugs":{"url":"https://github.com/abimaelmartell/pco-cli/issues"},"bin":{"pco":"dist/cli.js","pco-cli":"dist/cli.js"},"dist":{"shasum":"058ca638b4b8497807fc720bdc196c2131fcbc15","tarball":"https://registry.npmjs.org/@abimaelmartell/pco-cli/-/pco-cli-0.1.1.tgz","fileCount":23,"integrity":"sha512-sugdDjWqbbwX8Vw1v7HCYHh22e3pQyo0icnHO/zf+OGxUNZOKLgCdJPOsz+i6K2uWFL1clU0yPuwrapS1y7JPQ==","signatures":[{"sig":"MEQCIHXwfnc4m/w39te9ouME9ajB7gYra7jkxxnCBBjGjhhuAiB5SzVKPQQxTRt5aK93VDcDOmvfbJqwyYG6oDMMEcj/BQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@abimaelmartell%2fpco-cli@0.1.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":103847},"type":"module","engines":{"node":">=20.11"},"gitHead":"d6aaecdbf51c67f14ebe69c9c83c8a274d688a46","scripts":{"dev":"tsx src/cli.ts","lint":"eslint .","test":"vitest run","build":"tsc -p tsconfig.build.json","check":"tsc -p tsconfig.json --noEmit","prepack":"npm run build"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:75d27c94-8c4c-46c6-b16e-8d2659605cd1"}},"repository":{"url":"git+https://github.com/abimaelmartell/pco-cli.git","type":"git"},"_npmVersion":"12.0.2","description":"Agent-friendly TypeScript CLI for the Planning Center API.","directories":{},"_nodeVersion":"24.19.0","dependencies":{"zod":"^3.24.2","dotenv":"^16.4.7","undici":"^6.22.0","commander":"^12.1.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.2","eslint":"^9.18.0","vitest":"^2.1.8","@eslint/js":"^9.18.0","typescript":"^5.7.3","@types/node":"^22.10.7","typescript-eslint":"^8.20.0"},"_npmOperationalInternal":{"tmp":"tmp/pco-cli_0.1.1_1787785924681_0.5560810013721569","host":"s3://npm-registry-packages-npm-production"}},"0.1.2":{"name":"@abimaelmartell/pco-cli","version":"0.1.2","keywords":["planning-center","planning-center-online","pco","cli","api","agents"],"author":"","license":"MIT","_id":"@abimaelmartell/pco-cli@0.1.2","maintainers":[{"name":"abimaelmartell","email":"abimex@gmail.com"}],"homepage":"https://github.com/abimaelmartell/pco-cli#readme","bugs":{"url":"https://github.com/abimaelmartell/pco-cli/issues"},"bin":{"pco":"dist/cli.js","pco-cli":"dist/cli.js"},"dist":{"shasum":"46941270ad1fced44bed704d1fd3237d8bd1f523","tarball":"https://registry.npmjs.org/@abimaelmartell/pco-cli/-/pco-cli-0.1.2.tgz","fileCount":23,"integrity":"sha512-1ZvqhwUnU2XtIWs+a9mx5wFfCV28yX8SYM+pmlrLMs2xjsAZ+IPo9QXH6IbyshqpPBq4igccB73iWsqQsv4ZHA==","signatures":[{"sig":"MEUCIQDWyoLGY57lmOz8SMDRoCVJF99t4++fsa3VIvoPSLoJFwIgGMBf0WrY1ekjngiG7FSq7J65uNTPhDYh2wcpfll4WfA=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@abimaelmartell%2fpco-cli@0.1.2","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":156072},"type":"module","engines":{"node":">=20.11"},"gitHead":"190c8782a6cefd83f357b93594e62d5605bf05e5","scripts":{"dev":"tsx src/cli.ts","lint":"eslint .","test":"vitest run","build":"tsc -p tsconfig.build.json","check":"tsc -p tsconfig.json --noEmit","prepack":"npm run build"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:75d27c94-8c4c-46c6-b16e-8d2659605cd1"}},"repository":{"url":"git+https://github.com/abimaelmartell/pco-cli.git","type":"git"},"_npmVersion":"12.0.2","description":"Agent-friendly TypeScript CLI for the Planning Center API.","directories":{},"_nodeVersion":"24.19.0","dependencies":{"zod":"^3.24.2","dotenv":"^16.4.7","undici":"^6.22.0","commander":"^12.1.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.2","eslint":"^9.18.0","vitest":"^2.1.8","@eslint/js":"^9.18.0","typescript":"^5.7.3","@types/node":"^22.10.7","typescript-eslint":"^8.20.0"},"_npmOperationalInternal":{"tmp":"tmp/pco-cli_0.1.2_1787789182707_0.5043214882309779","host":"s3://npm-registry-packages-npm-production"}},"0.1.3":{"name":"@abimaelmartell/pco-cli","version":"0.1.3","keywords":["planning-center","planning-center-online","pco","cli","api","agents"],"author":"","license":"MIT","_id":"@abimaelmartell/pco-cli@0.1.3","maintainers":[{"name":"abimaelmartell","email":"abimex@gmail.com"}],"homepage":"https://github.com/abimaelmartell/pco-cli#readme","bugs":{"url":"https://github.com/abimaelmartell/pco-cli/issues"},"bin":{"pco":"dist/cli.js","pco-cli":"dist/cli.js"},"dist":{"shasum":"d73ab3e7914ad6323c5cfaa042815c2aea5931c0","tarball":"https://registry.npmjs.org/@abimaelmartell/pco-cli/-/pco-cli-0.1.3.tgz","fileCount":27,"integrity":"sha512-x+01TiMhdTAGYZ0hIhkKS7z/Yls7afFsCqXSvQB0My1yEiOEteiMr+14wShKWTecLUs656NiHk1YPj2ZX3lshw==","signatures":[{"sig":"MEUCIQDQJxT1DBN3Wgx4MRGZk15QSz/JobOJrYVmeZIy/UM48QIgCfTSCcYfvKyMb5P7RYjn98jnv7G3AIaijdbXr/4Rj4o=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@abimaelmartell%2fpco-cli@0.1.3","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":161080},"type":"module","engines":{"node":">=20.11"},"gitHead":"d6324ddde02f14d49d914cfb2b049de86a5c3673","scripts":{"dev":"tsx src/cli.ts","lint":"eslint .","test":"vitest run","build":"tsc -p tsconfig.build.json","check":"tsc -p tsconfig.json --noEmit","prepack":"npm run build","release":"semantic-release"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:75d27c94-8c4c-46c6-b16e-8d2659605cd1"}},"repository":{"url":"git+https://github.com/abimaelmartell/pco-cli.git","type":"git"},"_npmVersion":"11.19.1","description":"Agent-friendly TypeScript CLI for the Planning Center API.","directories":{},"_nodeVersion":"24.19.0","dependencies":{"zod":"^3.24.2","dotenv":"^16.4.7","undici":"^6.22.0","commander":"^12.1.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsx":"^4.19.2","eslint":"^9.18.0","vitest":"^2.1.8","@eslint/js":"^9.18.0","typescript":"^5.7.3","@types/node":"^22.10.7","semantic-release":"^25.0.9","typescript-eslint":"^8.20.0"},"_npmOperationalInternal":{"tmp":"tmp/pco-cli_0.1.3_1787790644906_0.13761420680981362","host":"s3://npm-registry-packages-npm-production"}},"0.1.4":{"name":"@abimaelmartell/pco-cli","version":"0.1.4","description":"Agent-friendly TypeScript CLI for the Planning Center API.","type":"module","bin":{"pco":"dist/cli.js","pco-cli":"dist/cli.js"},"scripts":{"build":"tsc -p tsconfig.build.json","check":"tsc -p tsconfig.json --noEmit","dev":"tsx src/cli.ts","lint":"eslint .","test":"vitest run","prepack":"npm run build","release":"semantic-release"},"keywords":["planning-center","planning-center-online","pco","cli","api","agents"],"author":"","license":"MIT","repository":{"type":"git","url":"git+https://github.com/abimaelmartell/pco-cli.git"},"homepage":"https://github.com/abimaelmartell/pco-cli#readme","bugs":{"url":"https://github.com/abimaelmartell/pco-cli/issues"},"publishConfig":{"access":"public"},"engines":{"node":">=20.11"},"dependencies":{"commander":"^12.1.0","dotenv":"^16.4.7","undici":"^6.22.0","zod":"^3.24.2"},"devDependencies":{"@eslint/js":"^9.18.0","@semantic-release/git":"^10.0.1","@types/node":"^22.10.7","eslint":"^9.18.0","semantic-release":"^25.0.9","tsx":"^4.19.2","typescript":"^5.7.3","typescript-eslint":"^8.20.0","vitest":"^2.1.8"},"gitHead":"8c783fdfffbefd1346a8d734a03750a8757d3a33","_id":"@abimaelmartell/pco-cli@0.1.4","_nodeVersion":"24.19.0","_npmVersion":"11.19.1","dist":{"integrity":"sha512-t3hDFkUGdFZ3+t0LjaAYnDDM5yW5TcZwWOkJ84n4Bh01n+ZATY6g0ocVi4cahu+bEuMktXC5iW+k5Ge8ZBo6HQ==","shasum":"0cad76d0a4d08ffcad30ac21462fef0c8041a5b9","tarball":"https://registry.npmjs.org/@abimaelmartell/pco-cli/-/pco-cli-0.1.4.tgz","fileCount":31,"unpackedSize":162251,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@abimaelmartell%2fpco-cli@0.1.4","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIFfvG3o+OqPxSe9YKbPpogML9mJlUd3DmiE39Y8ah3B4AiEA7iEYM270G+8w3wEKS7rMIATZndsDwkHYCMwysuCWJzQ="}]},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:75d27c94-8c4c-46c6-b16e-8d2659605cd1"}},"directories":{},"maintainers":[{"name":"abimaelmartell","email":"abimex@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/pco-cli_0.1.4_1787791045180_0.240151674645114"},"_hasShrinkwrap":false}},"time":{"created":"2026-08-26T19:48:59.706Z","modified":"2026-08-27T00:37:25.666Z","0.1.0":"2026-08-26T19:49:00.093Z","0.1.1":"2026-08-26T23:12:04.831Z","0.1.2":"2026-08-27T00:06:22.857Z","0.1.3":"2026-08-27T00:30:45.085Z","0.1.4":"2026-08-27T00:37:25.338Z"},"bugs":{"url":"https://github.com/abimaelmartell/pco-cli/issues"},"license":"MIT","homepage":"https://github.com/abimaelmartell/pco-cli#readme","keywords":["planning-center","planning-center-online","pco","cli","api","agents"],"repository":{"type":"git","url":"git+https://github.com/abimaelmartell/pco-cli.git"},"description":"Agent-friendly TypeScript CLI for the Planning Center API.","maintainers":[{"name":"abimaelmartell","email":"abimex@gmail.com"}],"readme":"# pco-cli\n\nAgent-friendly TypeScript CLI for the Planning Center API, intended for npm publishing.\n\nPlanning Center exposes APIs for products including Calendar, Check-Ins, Giving, Groups, People, and Services. This CLI focuses on the **Services** product for worship planning workflows.\n\n## Install\n\nFrom npm (after the package is published):\n\n```bash\nnpm install -g @abimaelmartell/pco-cli\npco health\n```\n\nThe registry package is scoped because npm rejects unscoped `pco-cli` as too similar to existing [`cp-cli`](https://www.npmjs.com/package/cp-cli). The installed binaries are still `pco` and `pco-cli`.\n\nFrom this repository:\n\n```bash\nnpm install\nnpm run build\nnpm link\npco health\n```\n\n`npm install` and `npm run build` alone do not put `pco` on `PATH`. Use `npm link` for a local checkout, or run `npm run dev -- health`.\n\n## Configuration\n\nCopy `.env.example` to `.env` and set credentials:\n\n```bash\ncp .env.example .env\n```\n\nTo store credentials once for every working directory, copy the same file to `~/.config/pco/env` (or `$XDG_CONFIG_HOME/pco/env`). Override the path with `PCO_CONFIG_PATH` if needed.\n\nSupported authentication inputs:\n\n- `PCO_ACCESS_TOKEN` for bearer token flows.\n- `PCO_CLIENT_ID` and `PCO_SECRET` for basic auth. Planning Center personal access tokens are labeled Client ID + Secret.\n- `PCO_APP_ID` is a compatible alias of `PCO_CLIENT_ID`. If both are set to different values, the CLI exits with an error.\n\nYou can also pass credentials via CLI flags: `--access-token`, `--client-id` (alias `--app-id`), and `--secret`. Flags override environment values. Environment values override a project `.env`, which overrides the global config file. You do not need to pass flags on every command when credentials are in the environment or a config file.\n\nBearer `PCO_ACCESS_TOKEN` / `--access-token` wins over basic auth when both are present.\n\n## Agent skill\n\nA portable [Agent Skill](https://agentskills.io) lives at `.agents/skills/pco-cli/SKILL.md`. Cursor, Claude Code, Codex, and other compatible agents load it from that path automatically in this repo. The skill is the source of truth for calling the CLI, including the **songs + keys + musicians** playbook (`plan-items add-song` with `--arrangement-id` and `--key-id`; do not use `create-worship-plan` when keys matter).\n\nTo use the CLI from another project or globally:\n\n```bash\nmkdir -p ~/.agents/skills/pco-cli\ncurl -fsSL https://raw.githubusercontent.com/abimaelmartell/pco-cli/main/.agents/skills/pco-cli/SKILL.md \\\n  -o ~/.agents/skills/pco-cli/SKILL.md\n```\n\nProject copy (Cursor also reads `.cursor/skills/`):\n\n```bash\nmkdir -p .agents/skills/pco-cli\ncurl -fsSL https://raw.githubusercontent.com/abimaelmartell/pco-cli/main/.agents/skills/pco-cli/SKILL.md \\\n  -o .agents/skills/pco-cli/SKILL.md\n```\n\n## Usage\n\nThe CLI prints JSON so automation agents can parse output reliably.\n\n### Health check\n\n```bash\npco health\n```\n\nJSON includes `ok`, `version` (from `package.json`), `baseUrl`, `auth` (`basic`, `bearer`, or `none`), and `clientReady`.\n\n### Service Types\n\nList available service types:\n\n```bash\npco service-types list\npco service-types list --per-page 10 --offset 0\n```\n\n### Songs\n\nSearch for songs by title:\n\n```bash\npco songs search \"Amazing Grace\"\npco songs search \"How Great\" --per-page 5\n```\n\nCreate or update library songs (Planning Center assignable fields: title, admin, author, copyright, ccli_number, hidden, themes):\n\n```bash\npco songs get <song-id>\npco songs create --title \"Holy Forever\" --author \"Chris Tomlin\" --ccli-number 7200535\npco songs update <song-id> --hidden true --themes \"Praise\"\n```\n\nTags replace the full set. Look up IDs first:\n\n```bash\npco tag-groups list --tags-for song --include tags\npco tag-groups tags <tag-group-id>\npco songs tags <song-id>\npco songs assign-tags <song-id> --tag-ids 5,9\n```\n\n### Arrangements and keys\n\nKeys belong to an arrangement, not directly to a song. Creating a song usually adds a default arrangement; list it before adding keys.\n\n```bash\npco arrangements list <song-id> --include keys\npco arrangements create <song-id> --name \"Default\" --meter 4/4 --bpm 72\npco arrangements update <song-id> <arrangement-id> --chord-chart \"[G]Holy forever\"\npco arrangements assign-tags <song-id> <arrangement-id> --tag-ids 12\n\npco keys list <song-id> <arrangement-id>\npco keys create <song-id> <arrangement-id> --starting-key G --ending-key G\npco keys update <song-id> <arrangement-id> <key-id> --starting-key A --name \"Acoustic\"\n```\n\n`--starting-key` / `--ending-key` use Planning Center values (`C`, `Cm`, `F#`, …). `--alternate-keys` is a JSON array of `{\"name\":\"Capo 3\",\"key\":\"A\"}`.\n\nKeys do not have their own tags in the Services API. Tag songs and arrangements instead.\n\n### People\n\nSearch for people by name:\n\n```bash\npco people search \"John Smith\"\npco people search \"Sarah\" --per-page 10\n```\n\n### Teams\n\nList teams for a service type, and positions for a team:\n\n```bash\npco teams list <service-type-id>\npco teams positions <team-id>\n```\n\n### Plans\n\nCreate and manage service plans:\n\n```bash\n# List plans\npco plans list <service-type-id>\npco plans list <service-type-id> --filter future --order sort_date\n\n# Get a specific plan (includes planning_center_url for the Services web UI)\npco plans get <service-type-id> <plan-id>\n\n# Create a plan with optional service time (returns plan_time id for reminders)\npco plans create <service-type-id> \\\n  --title \"Sunday Worship\" \\\n  --series-title \"Summer Series\" \\\n  --public \\\n  --starts-at \"2026-08-30T10:00:00Z\" \\\n  --ends-at \"2026-08-30T11:30:00Z\"\n\n`--starts-at` and `--ends-at` must be ISO 8601 datetimes with a timezone. `--ends-at` requires `--starts-at` and must be later than the start time.\n\n# List times on a plan\npco plan-times list <service-type-id> <plan-id>\n```\n\n### Plan Items (Songs)\n\nAdd songs to a plan:\n\n```bash\n# List items in a plan\npco plan-items list <service-type-id> <plan-id>\n\n# Add a song by ID\npco plan-items add-song <service-type-id> <plan-id> --song-id <song-id>\n\n# Add a song by title (must match exactly one song across every search page)\npco plan-items add-song <service-type-id> <plan-id> --title \"Amazing Grace\"\n\n# Add with arrangement and key\npco plan-items add-song <service-type-id> <plan-id> \\\n  --song-id <song-id> \\\n  --arrangement-id <arrangement-id> \\\n  --key-id <key-id>\n```\n\nSong items always send `title` from the song resource (same as the Planning Center UI) plus `song_id`. Without `title`, Services shows \"New Item\".\n\n### Team Member Assignments\n\nAssign people to plans:\n\n```bash\n# List team members on a plan\npco plan-team-members list <service-type-id> <plan-id>\n\n# See who still needs the first Accept/Decline scheduling email (all assigned members)\npco plan-team-members notify-status <service-type-id> <plan-id>\n\n# Assign a person to a plan\npco plan-team-members assign <service-type-id> <plan-id> <person-id> <team-id> \\\n  --position \"Worship Leader\" \\\n  --prepare-notification\n```\n\n### Team Reminders\n\nSet automated reminder emails for teams:\n\n```bash\n# Set team reminders (days before service)\npco plan-reminders set <service-type-id> <plan-time-id> \\\n  --team-reminders '{\"<team-id>\": 7, \"<team-id-2>\": 3}'\n```\n\nThe `team_reminders` object maps team IDs to the number of days (0-7) before the service time to send automated reminder emails.\n\n### Complete Worship Planning Workflow\n\nCreate a full worship plan in one command:\n\n```bash\npco create-worship-plan <service-type-id> \\\n  --title \"Sunday Morning Service\" \\\n  --starts-at \"2026-08-30T10:00:00Z\" \\\n  --ends-at \"2026-08-30T11:30:00Z\" \\\n  --series-title \"Summer Worship\" \\\n  --public \\\n  --songs \"Amazing Grace\" \"How Great Thou Art\" \"Oceans\" \\\n  --assignments '[{\"person_id\":\"123\",\"team_id\":\"10\",\"position\":\"Worship Leader\"}]' \\\n  --team-reminders '{\"10\": 7, \"11\": 3}'\n```\n\nThis command:\n1. Validates assignment JSON and reminder offsets, then looks up each song title in the church library (fails before creating anything if a title is missing or not unique)\n2. Creates a plan with the specified title and series\n3. Adds a service time, including `team_reminders` when provided\n4. Adds the matched songs in order (`song_id` and `title` — Planning Center default arrangement/key)\n5. Assigns team members with their positions\n6. Returns `planning_center_url` from the plan resource (the Services web UI URL, not the API `links.self`)\n\nWhen the setlist includes specific keys, do not use `create-worship-plan`. Follow the **Worship plan with keys and musicians** playbook in `.agents/skills/pco-cli/SKILL.md` (`keys create` if needed, then `plan-items add-song` with `--arrangement-id` and `--key-id`).\n\n## Important API Limitations\n\n### Scheduling Email (\"Accept/Decline\") Not Supported\n\nPlanning Center's \"Send scheduling email\" button (the one that sends Accept/Decline links to team members) is **NOT available via the API**. This was confirmed by Planning Center in [planningcenter/developers#1475](https://github.com/planningcenter/developers/issues/1475).\n\n**Workarounds:**\n\n1. **Automated Reminders:** Use `team_reminders` when creating or updating plan times. This sends automated reminder emails to teams at a specified number of days before the service.\n\n2. **Manual Sending:** After creating a plan via the CLI, use the returned `planning_center_url` to open the plan in the Planning Center web UI and manually send scheduling emails.\n\n3. **Check Notification Status:** Use `plan-team-members notify-status` (or `list`) to see `notification_sent_at`, `prepare_notification`, and `notification_prepared_at` and who still needs the first scheduling email.\n\n## Project layout\n\n- `src/cli.ts` wires the command-line interface.\n- `src/client.ts` contains the reusable Planning Center API client.\n- `src/helpers.ts` maps CLI arguments and JSON:API resources.\n- `src/config.ts` loads and validates environment configuration.\n- `src/index.ts` exports library primitives for programmatic use.\n\n## Publishing\n\nReleases are automated with [semantic-release](https://semantic-release.gitbook.io/) and [Conventional Commits](https://www.conventionalcommits.org/). On every push to `main`, `.github/workflows/publish.yml` runs tests and then publishes only when the commits since the last release include a `feat` or `fix` (semver). npm authenticates with [trusted publishing](https://docs.npmjs.com/trusted-publishers/) (GitHub OIDC). There is no `NPM_TOKEN` secret.\n\nUse a Conventional Commit **PR title** and squash-merge. CI rejects titles that do not match. Do not bump `version` in `package.json` or push `v*` tags by hand — semantic-release publishes to npm, tags `vX.Y.Z`, and commits the new version back to `package.json` / `package-lock.json`.\n\n| PR title | Semver bump | Example |\n| --- | --- | --- |\n| `feat: add song tags` | minor (`0.1.2` → `0.2.0`) | new command or capability |\n| `fix: handle empty search` | patch (`0.1.2` → `0.1.3`) | bug fix |\n| `feat!: drop Node 18` or a `BREAKING CHANGE:` footer | major (`0.1.2` → `1.0.0`) | breaking change |\n| `docs:`, `chore:`, `ci:`, `test:`, `refactor:` | no publish | docs and tooling |\n\n`perf:` also publishes a patch. A GitHub Release and git tag (`vX.Y.Z`) are created with the npm publish. The release commit is `chore(release): X.Y.Z [skip ci]` so it does not start another publish.\n\nThe workflow filename must stay `publish.yml` so it matches the trusted publisher on npmjs.com. Do not set `NODE_AUTH_TOKEN` or `NPM_TOKEN` on that job, and do not pass `registry-url` to `actions/setup-node` — both make npm skip OIDC trusted publishing.\n\n### One-time setup on npmjs.com\n\n1. Sign in as the npm user `abimaelmartell` (the scope must match your npm username).\n2. On [npmjs.com](https://www.npmjs.com/) open **@abimaelmartell/pco-cli → Settings → Trusted Publisher**.\n3. Choose **GitHub Actions** and set:\n   - Organization or user: `abimaelmartell`\n   - Repository: `pco-cli`\n   - Workflow filename: `publish.yml` (filename only, including `.yml`)\n   - Environment name: leave blank\n   - Allowed actions: `npm publish`\n4. After a successful OIDC publish, optionally set **Publishing access** to require 2FA and disallow tokens.\n\nYou can do the same attach step from a local npm 11.5.1+ CLI:\n\n```bash\nnpm trust github @abimaelmartell/pco-cli --repo abimaelmartell/pco-cli --file publish.yml --allow-publish\n```\n\nLocal dry run (does not publish):\n\n```bash\nnpm run check\nnpm run build\nnpm pack --dry-run\nnpx semantic-release --dry-run\n```\n","readmeFilename":"README.md"}