This repository has a generated CLI surface and a hand-written agent skill. Several files must be updated together to avoid drift.
These layers describe the same command surface and must stay aligned:
scripts/generate.tssrc/codegen/normalize.tssrc/generated/manifest.gen.tssrc/generated/sdk.gen.tsand the rest ofsrc/generated/src/cli.tsREADME.mdskills/clattio/SKILL.mdskills/clattio/references/api-surface.md
If the Attio OpenAPI spec changes, or if you change normalization logic in
src/codegen/normalize.ts, then you must:
- run
bun run generate - run
bun run build - run
bun run test - inspect
node dist/attio.js --help - update the skill docs if command groups, command names, body shapes, or recommended workflows changed
These two files are intentionally split into:
- a concise operational playbook in
SKILL.md - a detailed command reference in
references/api-surface.md
Keep them synchronized:
- Resource vocabulary must match: object, attribute, record, list, entry, note, comment, thread, task, meeting, call recording, transcript, file, webhook, workspace member.
- If a command group is added, renamed, or removed, update both files.
- If command-selection guidance changes in
SKILL.md, make sure the detailed reference still supports it. - If
api-surface.mdgains or loses top-level sections, update its table of contents. SKILL.mdshould keep explicit links toreferences/api-surface.mdwherever deeper lookup is expected.
src/manifest-types.ts, src/codegen/normalize.ts, src/io.ts, and
src/cli.ts are tightly coupled.
Examples:
- If you add a new parameter type in
manifest-types.ts, update parsing and option wiring insrc/cli.tsand any input-building logic insrc/io.ts. - If you change how multipart or JSON bodies are represented in the manifest, update both the normalizer and the CLI execution path.
- If command naming logic changes in
normalize.ts, review the skill docs and README examples because user-facing command names may change.
The version in package.json and the VERSION constant in src/cli.ts must
match before release.
If you change authentication behavior in src/auth.ts, also review:
README.mdskills/clattio/SKILL.md- any tests covering auth behavior
The token setup flow, OAuth setup flow, and user-facing command examples must stay consistent.
When changing anything that affects commands or flags:
- Edit source files.
- Regenerate if needed:
bun run generate - Build:
bun run build - Test:
bun run test - Spot-check help output:
node dist/attio.js --help - Update README and skill docs in the same change.
If the CLI does not change and you are only improving the skill:
- update
skills/clattio/SKILL.md - update
skills/clattio/references/api-surface.mdif the main skill now points to sections that need more detail - keep examples and terminology consistent with the real CLI help output