zinkee 0.1.23 → 0.1.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/settings.local.json +5 -1
- package/AGENTS.md +1 -0
- package/README.md +82 -4
- package/dist/index.js +1238 -404
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/api/automations.ts +1 -1
- package/src/api/displays.ts +48 -0
- package/src/api/document-templates.ts +110 -0
- package/src/api/navigation.ts +0 -1
- package/src/command-registry.ts +91 -0
- package/src/commands/automations.test.ts +32 -0
- package/src/commands/automations.ts +9 -3
- package/src/commands/displays.test.ts +74 -0
- package/src/commands/displays.ts +143 -1
- package/src/commands/document-templates.test.ts +569 -0
- package/src/commands/document-templates.ts +563 -0
- package/src/commands/navigation.test.ts +2 -5
- package/src/commands/navigation.ts +11 -11
- package/src/commands/teamspace.ts +19 -13
- package/src/program.ts +2 -0
- package/src/utils/examples.test.ts +13 -4
- package/src/utils/examples.ts +280 -50
|
@@ -43,7 +43,11 @@
|
|
|
43
43
|
"Bash(git -C /home/guillermo/dev/cli branch --show-current)",
|
|
44
44
|
"Bash(git -C /home/guillermo/dev/cli diff --stat)",
|
|
45
45
|
"Bash(git fetch *)",
|
|
46
|
-
"Bash(pnpm exec *)"
|
|
46
|
+
"Bash(pnpm exec *)",
|
|
47
|
+
"Bash(echo \"=== exit $? \\(grep\\) ===\")",
|
|
48
|
+
"Bash(grep -rn \"resourceType\" src/)",
|
|
49
|
+
"Bash(grep -rn \"automation-folders/\\\\${\\\\|/automations:move\\\\|{folderId}/automations\" src/)",
|
|
50
|
+
"Bash(grep -rn \"navigation resources move.*--type\\\\|resourceType\" docs/ README.md)"
|
|
47
51
|
]
|
|
48
52
|
}
|
|
49
53
|
}
|
package/AGENTS.md
CHANGED
package/README.md
CHANGED
|
@@ -17,6 +17,7 @@ Implemented command groups:
|
|
|
17
17
|
- `teamspace`
|
|
18
18
|
- `displays`
|
|
19
19
|
- `automations`
|
|
20
|
+
- `document-templates`
|
|
20
21
|
|
|
21
22
|
## Requirements
|
|
22
23
|
|
|
@@ -337,7 +338,7 @@ zinkee --json logs list <schema-slug> <record-uuid>
|
|
|
337
338
|
|
|
338
339
|
## Navigation
|
|
339
340
|
|
|
340
|
-
Organize schemas into database folders.
|
|
341
|
+
Organize schemas into database folders. The navigation menu holds databases, so only schemas can be moved here.
|
|
341
342
|
|
|
342
343
|
```bash
|
|
343
344
|
# List folders with contents
|
|
@@ -347,13 +348,16 @@ zinkee --json navigation folders list
|
|
|
347
348
|
zinkee navigation folders create --name "CRM" --order 1
|
|
348
349
|
|
|
349
350
|
# Move a schema into a folder
|
|
350
|
-
zinkee navigation resources move <schema-uuid> --
|
|
351
|
+
zinkee navigation resources move <schema-uuid> --to "CRM"
|
|
351
352
|
|
|
352
|
-
#
|
|
353
|
+
# Move a schema back to the workspace root
|
|
354
|
+
zinkee navigation resources move <schema-uuid> --to 00000000-0000-0000-0000-000000000000
|
|
355
|
+
|
|
356
|
+
# Delete folder (schemas move back to root silently)
|
|
353
357
|
zinkee navigation folders delete "CRM"
|
|
354
358
|
```
|
|
355
359
|
|
|
356
|
-
Root folder cannot be deleted
|
|
360
|
+
Only schemas can be moved (schedules and sub-schemas follow their parent schema). Root folder cannot be deleted; its UUID is always `00000000-0000-0000-0000-000000000000`.
|
|
357
361
|
|
|
358
362
|
---
|
|
359
363
|
|
|
@@ -387,6 +391,27 @@ zinkee teamspace resources publish projects --to "Other Folder"
|
|
|
387
391
|
|
|
388
392
|
Displays are dashboards composed of widgets that visualize data from schemas.
|
|
389
393
|
|
|
394
|
+
### Display folders
|
|
395
|
+
|
|
396
|
+
Organize displays into folders in the displays menu. Folders are flat (name only) and only displays can be moved into them.
|
|
397
|
+
|
|
398
|
+
```bash
|
|
399
|
+
# List display folders (non-root folders plus the root bucket)
|
|
400
|
+
zinkee --json displays folders list
|
|
401
|
+
|
|
402
|
+
# Create a folder
|
|
403
|
+
zinkee displays folders create --name "Executive Dashboards"
|
|
404
|
+
|
|
405
|
+
# Rename a folder
|
|
406
|
+
zinkee displays folders update "Executive Dashboards" --name "Executive Dashboards (2026)"
|
|
407
|
+
|
|
408
|
+
# Move a display into a folder
|
|
409
|
+
zinkee displays folders move <display-uuid> --to "Executive Dashboards"
|
|
410
|
+
|
|
411
|
+
# Delete a folder (its displays move back to the root folder)
|
|
412
|
+
zinkee displays folders delete "Executive Dashboards"
|
|
413
|
+
```
|
|
414
|
+
|
|
390
415
|
### Creation flow
|
|
391
416
|
|
|
392
417
|
1. Create the display
|
|
@@ -656,6 +681,58 @@ zinkee --json automations connections list
|
|
|
656
681
|
|
|
657
682
|
---
|
|
658
683
|
|
|
684
|
+
## Document templates
|
|
685
|
+
|
|
686
|
+
Document templates group reusable files (e.g. Word/Excel masters) that automations can render against a record via the `generate_document` action. Names must be unique within the workspace; the `<template>` argument accepts a UUID or an exact name. The `<asset>` argument requires a UUID.
|
|
687
|
+
|
|
688
|
+
### Typical lifecycle
|
|
689
|
+
|
|
690
|
+
1. Create an empty template
|
|
691
|
+
|
|
692
|
+
```bash
|
|
693
|
+
zinkee --json document-templates create --name "Quarterly report"
|
|
694
|
+
```
|
|
695
|
+
|
|
696
|
+
2. Upload one or more asset files
|
|
697
|
+
|
|
698
|
+
```bash
|
|
699
|
+
zinkee --json document-templates assets add "Quarterly report" ./requirements.docx
|
|
700
|
+
zinkee --json document-templates assets add "Quarterly report" ./contract.docx --name "Customer Contract"
|
|
701
|
+
```
|
|
702
|
+
|
|
703
|
+
3. List and inspect
|
|
704
|
+
|
|
705
|
+
```bash
|
|
706
|
+
zinkee --json document-templates list
|
|
707
|
+
zinkee --json document-templates get "Quarterly report"
|
|
708
|
+
```
|
|
709
|
+
|
|
710
|
+
4. Rename / replace assets / remove
|
|
711
|
+
|
|
712
|
+
```bash
|
|
713
|
+
zinkee --json document-templates update "Quarterly report" --name "Annual report"
|
|
714
|
+
zinkee --json document-templates assets delete <template-uuid> <asset-uuid>
|
|
715
|
+
zinkee --json document-templates delete <template-uuid>
|
|
716
|
+
```
|
|
717
|
+
|
|
718
|
+
### Download asset bytes
|
|
719
|
+
|
|
720
|
+
`download` streams raw bytes — use `--output` to write to disk (required when combined with `--json`):
|
|
721
|
+
|
|
722
|
+
```bash
|
|
723
|
+
zinkee --json document-templates assets download <template-uuid> <asset-uuid> --output ./contract.docx
|
|
724
|
+
zinkee document-templates assets download <template-uuid> <asset-uuid> > contract.docx
|
|
725
|
+
```
|
|
726
|
+
|
|
727
|
+
### Notes
|
|
728
|
+
|
|
729
|
+
- `get` is a client-side helper: the backend has no get-one endpoint, so the CLI filters the list response. Use `list` if you want everything in one call.
|
|
730
|
+
- The `assets` returned by list/get include a relative `link` ready to call directly (it already includes both the templateId and assetId path segments).
|
|
731
|
+
- Deleting a template removes its asset files from storage; record fields that referenced previously generated documents are not modified.
|
|
732
|
+
- Use `--json --example document-templates <subcommand>` for canonical examples.
|
|
733
|
+
|
|
734
|
+
---
|
|
735
|
+
|
|
659
736
|
## Discovery
|
|
660
737
|
|
|
661
738
|
```bash
|
|
@@ -665,5 +742,6 @@ zinkee --json displays list
|
|
|
665
742
|
zinkee --json automations list
|
|
666
743
|
zinkee --json automations plugins list
|
|
667
744
|
zinkee --json automations connections list
|
|
745
|
+
zinkee --json document-templates list
|
|
668
746
|
zinkee --example <command path>
|
|
669
747
|
```
|