zinkee 0.1.44 → 0.1.46

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.
Files changed (94) hide show
  1. package/README.md +4 -0
  2. package/dist/chunk-MHEVRMDX.js +1230 -0
  3. package/dist/chunk-MHEVRMDX.js.map +1 -0
  4. package/{src/utils/examples.ts → dist/examples-67U5IRBS.js} +866 -1141
  5. package/dist/examples-67U5IRBS.js.map +1 -0
  6. package/dist/index.js +1145 -8456
  7. package/dist/index.js.map +1 -1
  8. package/package.json +6 -3
  9. package/.github/workflows/npm-publish.yml +0 -77
  10. package/.github/workflows/pr-checks.yml +0 -36
  11. package/AGENTS.md +0 -110
  12. package/docs/cli-contract.md +0 -41
  13. package/docs/npm-release.md +0 -64
  14. package/docs/superpowers/plans/2026-03-24-zinkee-cli-implementation.md +0 -837
  15. package/docs/superpowers/plans/2026-03-25-cli-backend-error-contract.md +0 -503
  16. package/docs/superpowers/plans/2026-03-26-display-freeform-create.md +0 -389
  17. package/docs/superpowers/specs/2026-03-24-zinkee-cli-backend-blockers.md +0 -172
  18. package/docs/superpowers/specs/2026-03-24-zinkee-cli-design.md +0 -1576
  19. package/docs/superpowers/specs/2026-03-24-zinkee-cli-e2e-checklist.md +0 -215
  20. package/docs/superpowers/specs/2026-03-24-zinkee-cli-e2e-design.md +0 -492
  21. package/docs/superpowers/specs/2026-03-24-zinkee-cli-e2e-status.md +0 -307
  22. package/docs/superpowers/specs/2026-07-30-cli-pr-checks-design.md +0 -37
  23. package/src/api/automations.ts +0 -404
  24. package/src/api/comments.ts +0 -51
  25. package/src/api/displays.ts +0 -337
  26. package/src/api/document-templates.ts +0 -110
  27. package/src/api/files.ts +0 -50
  28. package/src/api/formulas.test.ts +0 -65
  29. package/src/api/formulas.ts +0 -67
  30. package/src/api/logs.ts +0 -34
  31. package/src/api/navigation.ts +0 -70
  32. package/src/api/records.ts +0 -184
  33. package/src/api/schemas.ts +0 -148
  34. package/src/api/teamspace.ts +0 -110
  35. package/src/cli-examples.ts +0 -130
  36. package/src/cli-runner.ts +0 -95
  37. package/src/client.test.ts +0 -189
  38. package/src/client.ts +0 -269
  39. package/src/command-registry.ts +0 -882
  40. package/src/commands/automations.test.ts +0 -1030
  41. package/src/commands/automations.ts +0 -2102
  42. package/src/commands/comments.test.ts +0 -214
  43. package/src/commands/comments.ts +0 -303
  44. package/src/commands/config.test.ts +0 -81
  45. package/src/commands/config.ts +0 -150
  46. package/src/commands/displays.test.ts +0 -1105
  47. package/src/commands/displays.ts +0 -1442
  48. package/src/commands/document-templates.test.ts +0 -569
  49. package/src/commands/document-templates.ts +0 -563
  50. package/src/commands/files.test.ts +0 -284
  51. package/src/commands/files.ts +0 -280
  52. package/src/commands/formulas.test.ts +0 -194
  53. package/src/commands/formulas.ts +0 -243
  54. package/src/commands/logs.test.ts +0 -123
  55. package/src/commands/logs.ts +0 -159
  56. package/src/commands/navigation.test.ts +0 -211
  57. package/src/commands/navigation.ts +0 -348
  58. package/src/commands/profiles.test.ts +0 -191
  59. package/src/commands/profiles.ts +0 -303
  60. package/src/commands/records.test.ts +0 -860
  61. package/src/commands/records.ts +0 -883
  62. package/src/commands/schemas.test.ts +0 -1252
  63. package/src/commands/schemas.ts +0 -890
  64. package/src/commands/teamspace.test.ts +0 -229
  65. package/src/commands/teamspace.ts +0 -546
  66. package/src/completion/engine.test.ts +0 -138
  67. package/src/completion/engine.ts +0 -168
  68. package/src/completion/install.test.ts +0 -179
  69. package/src/completion/install.ts +0 -260
  70. package/src/completion/runtime.ts +0 -150
  71. package/src/completion/scripts.ts +0 -91
  72. package/src/config.test.ts +0 -362
  73. package/src/config.ts +0 -294
  74. package/src/index.test.ts +0 -217
  75. package/src/index.ts +0 -8
  76. package/src/parsers/expressions.test.ts +0 -95
  77. package/src/parsers/expressions.ts +0 -128
  78. package/src/parsers/kv.test.ts +0 -35
  79. package/src/parsers/kv.ts +0 -49
  80. package/src/parsers/selectors.test.ts +0 -23
  81. package/src/parsers/selectors.ts +0 -29
  82. package/src/program.ts +0 -64
  83. package/src/runtime-context.ts +0 -103
  84. package/src/types.ts +0 -76
  85. package/src/utils/argv-rewrite.test.ts +0 -149
  86. package/src/utils/argv-rewrite.ts +0 -269
  87. package/src/utils/errors.test.ts +0 -85
  88. package/src/utils/errors.ts +0 -191
  89. package/src/utils/examples.test.ts +0 -374
  90. package/src/utils/output.test.ts +0 -65
  91. package/src/utils/output.ts +0 -154
  92. package/src/utils/schema-fields.ts +0 -1016
  93. package/tsconfig.json +0 -20
  94. package/tsup.config.ts +0 -13
@@ -1,33 +1,13 @@
1
1
  import {
2
+ buildJsonSuccess,
2
3
  getSchemaFieldTypeDefinitions,
3
- resolveSchemaFieldType,
4
- } from "./schema-fields.js";
5
- import { buildJsonSuccess } from "./output.js";
4
+ resolveSchemaFieldType
5
+ } from "./chunk-MHEVRMDX.js";
6
6
 
7
- export interface CommandExample {
8
- command: string;
9
- description: string;
10
- raw?: string;
11
- response?: string;
12
- }
13
-
14
- export function buildCommandExample(example: CommandExample): CommandExample {
15
- return {
16
- command: example.command,
17
- description: example.description,
18
- raw: example.raw,
19
- response: example.response,
20
- };
21
- }
22
-
23
- export function buildCommandExamples(examples: readonly CommandExample[]): readonly CommandExample[] {
24
- return examples.map((example) => buildCommandExample(example));
25
- }
26
-
27
- const SAMPLE_UUID = "550e8400-e29b-41d4-a716-446655440001";
28
-
29
- const specificExamples: Record<string, readonly CommandExample[]> = {
30
- "formulas recompute field": buildCommandExamples([
7
+ // src/utils/examples.ts
8
+ var SAMPLE_UUID = "550e8400-e29b-41d4-a716-446655440001";
9
+ var specificExamples = {
10
+ "formulas recompute field": [
31
11
  {
32
12
  description: "Queue a full recalculation of one formula column.",
33
13
  command: "zinkee --json formulas recompute field invoices total",
@@ -43,10 +23,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
43
23
  "skippedFormulaCount": 0,
44
24
  "eventsQueued": 1,
45
25
  "status": "QUEUED"
46
- }`,
47
- },
48
- ]),
49
- "formulas recompute schema": buildCommandExamples([
26
+ }`
27
+ }
28
+ ],
29
+ "formulas recompute schema": [
50
30
  {
51
31
  description: "Queue recalculation of every active formula in one schema.",
52
32
  command: "zinkee --json formulas recompute schema invoices --yes",
@@ -61,10 +41,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
61
41
  "skippedFormulaCount": 1,
62
42
  "eventsQueued": 8,
63
43
  "status": "QUEUED"
64
- }`,
65
- },
66
- ]),
67
- "formulas recompute workspace": buildCommandExamples([
44
+ }`
45
+ }
46
+ ],
47
+ "formulas recompute workspace": [
68
48
  {
69
49
  description: "Queue recalculation of every active formula in the workspace.",
70
50
  command: "zinkee --json formulas recompute workspace --yes",
@@ -78,13 +58,12 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
78
58
  "skippedFormulaCount": 2,
79
59
  "eventsQueued": 24,
80
60
  "status": "QUEUED"
81
- }`,
82
- },
83
- ]),
84
- "profiles list": buildCommandExamples([
61
+ }`
62
+ }
63
+ ],
64
+ "profiles list": [
85
65
  {
86
- description:
87
- "List all local profiles. The CLI always redacts the apiKey to ******** plus the last 4 chars.",
66
+ description: "List all local profiles. The CLI always redacts the apiKey to ******** plus the last 4 chars.",
88
67
  command: "zinkee --json profiles list",
89
68
  response: `[
90
69
  {
@@ -99,10 +78,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
99
78
  "apiKey": "********4321",
100
79
  "baseUrl": "http://localhost:8088"
101
80
  }
102
- ]`,
103
- },
104
- ]),
105
- "profiles get": buildCommandExamples([
81
+ ]`
82
+ }
83
+ ],
84
+ "profiles get": [
106
85
  {
107
86
  description: "Show one profile by name.",
108
87
  command: "zinkee --json profiles get prod",
@@ -111,54 +90,50 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
111
90
  "isDefault": true,
112
91
  "apiKey": "********cdef",
113
92
  "baseUrl": "https://api.zinkee.com"
114
- }`,
115
- },
116
- ]),
117
- "profiles use": buildCommandExamples([
93
+ }`
94
+ }
95
+ ],
96
+ "profiles use": [
118
97
  {
119
98
  description: "Set a profile as the default one used when --profile is not passed.",
120
99
  command: "zinkee --json profiles use local",
121
100
  response: `{
122
101
  "profile": "local",
123
102
  "defaultProfile": "local"
124
- }`,
125
- },
126
- ]),
127
- "profiles add": buildCommandExamples([
103
+ }`
104
+ }
105
+ ],
106
+ "profiles add": [
128
107
  {
129
- description:
130
- "Add a new profile with an explicit base URL. Becomes the default if no other profile existed.",
131
- command:
132
- "zinkee --json profiles add prod --api-key sk-prod-9f3a2c1b-1234567890abcdef --base-url https://api.zinkee.com",
108
+ description: "Add a new profile with an explicit base URL. Becomes the default if no other profile existed.",
109
+ command: "zinkee --json profiles add prod --api-key sk-prod-9f3a2c1b-1234567890abcdef --base-url https://api.zinkee.com",
133
110
  response: `{
134
111
  "name": "prod",
135
112
  "isDefault": true,
136
113
  "apiKey": "********cdef",
137
114
  "baseUrl": "https://api.zinkee.com"
138
- }`,
115
+ }`
139
116
  },
140
117
  {
141
- description:
142
- "Add a profile without --base-url (the runtime falls back to the production URL at call time).",
143
- command: "zinkee --json profiles add staging --api-key sk-staging-7777aaaa-bbbbccccddddeeee",
118
+ description: "Add a profile without --base-url (the runtime falls back to the production URL at call time).",
119
+ command: "zinkee --json profiles add staging --api-key sk-REPLACE_WITH_YOUR_API_KEY",
144
120
  response: `{
145
121
  "name": "staging",
146
122
  "isDefault": false,
147
123
  "apiKey": "********eeee"
148
- }`,
149
- },
150
- ]),
151
- "profiles update": buildCommandExamples([
124
+ }`
125
+ }
126
+ ],
127
+ "profiles update": [
152
128
  {
153
129
  description: "Rotate just the API key of an existing profile.",
154
- command:
155
- "zinkee --json profiles update prod --api-key sk-prod-0000new0-fedcba0987654321",
130
+ command: "zinkee --json profiles update prod --api-key sk-prod-0000new0-fedcba0987654321",
156
131
  response: `{
157
132
  "name": "prod",
158
133
  "isDefault": true,
159
134
  "apiKey": "********4321",
160
135
  "baseUrl": "https://api.zinkee.com"
161
- }`,
136
+ }`
162
137
  },
163
138
  {
164
139
  description: "Point an existing profile at a different base URL (useful when moving envs).",
@@ -168,33 +143,31 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
168
143
  "isDefault": false,
169
144
  "apiKey": "********4321",
170
145
  "baseUrl": "http://localhost:9090"
171
- }`,
172
- },
173
- ]),
174
- "profiles remove": buildCommandExamples([
146
+ }`
147
+ }
148
+ ],
149
+ "profiles remove": [
175
150
  {
176
- description:
177
- "Remove a profile. If it was the default, defaultProfile becomes null and you should set a new one with profiles use.",
151
+ description: "Remove a profile. If it was the default, defaultProfile becomes null and you should set a new one with profiles use.",
178
152
  command: "zinkee --json profiles remove staging",
179
153
  response: `{
180
154
  "profile": "staging",
181
155
  "defaultProfile": "prod"
182
- }`,
183
- },
184
- ]),
185
- "config path": buildCommandExamples([
156
+ }`
157
+ }
158
+ ],
159
+ "config path": [
186
160
  {
187
161
  description: "Print the path of the config file the CLI is reading right now.",
188
162
  command: "zinkee --json config path",
189
163
  response: `{
190
164
  "path": "/home/guillermo/.config/zinkee/config.json"
191
- }`,
192
- },
193
- ]),
194
- "config show": buildCommandExamples([
165
+ }`
166
+ }
167
+ ],
168
+ "config show": [
195
169
  {
196
- description:
197
- "Dump the whole config with secrets redacted. Same ******** + last 4 chars mask that profiles list uses.",
170
+ description: "Dump the whole config with secrets redacted. Same ******** + last 4 chars mask that profiles list uses.",
198
171
  command: "zinkee --json config show",
199
172
  response: `{
200
173
  "defaultProfile": "prod",
@@ -208,25 +181,23 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
208
181
  "baseUrl": "http://localhost:8088"
209
182
  }
210
183
  }
211
- }`,
212
- },
213
- ]),
214
- "config validate": buildCommandExamples([
184
+ }`
185
+ }
186
+ ],
187
+ "config validate": [
215
188
  {
216
- description:
217
- "Validate that the local config resolves a profile. Useful as a CI gate before running other commands.",
189
+ description: "Validate that the local config resolves a profile. Useful as a CI gate before running other commands.",
218
190
  command: "zinkee --json config validate",
219
191
  response: `{
220
192
  "valid": true,
221
193
  "profile": "prod"
222
- }`,
223
- },
224
- ]),
225
- "schemas create": buildCommandExamples([
194
+ }`
195
+ }
196
+ ],
197
+ "schemas create": [
226
198
  {
227
199
  description: "Create an auditable and commentable schema from flags.",
228
- command:
229
- 'zinkee --json schemas create --name "Codex Demo" --slug codex-demo --auditable --commentable',
200
+ command: 'zinkee --json schemas create --name "Codex Demo" --slug codex-demo --auditable --commentable',
230
201
  raw: `{
231
202
  "name": "Codex Demo",
232
203
  "slug": "codex-demo",
@@ -241,34 +212,32 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
241
212
  "name": "root",
242
213
  "isRoot": true
243
214
  }
244
- }`,
215
+ }`
245
216
  },
246
217
  {
247
218
  description: "Minimal create with just name and slug.",
248
- command: 'zinkee --json schemas create --name Leads --slug leads',
219
+ command: "zinkee --json schemas create --name Leads --slug leads",
249
220
  raw: `{
250
221
  "name": "Leads",
251
222
  "slug": "leads"
252
- }`,
223
+ }`
253
224
  },
254
225
  {
255
- description:
256
- "Create an auditable schema inside an existing navigation folder (folder id can be a UUID or the exact folder name).",
257
- command:
258
- 'zinkee --json schemas create --name Tasks --slug tasks --auditable --folder 7f4e7c25-d8b2-4c1a-9f3e-6a7b5c8d9e1f',
226
+ description: "Create an auditable schema inside an existing navigation folder (folder id can be a UUID or the exact folder name).",
227
+ command: "zinkee --json schemas create --name Tasks --slug tasks --auditable --folder 7f4e7c25-d8b2-4c1a-9f3e-6a7b5c8d9e1f",
259
228
  raw: `{
260
229
  "name": "Tasks",
261
230
  "slug": "tasks",
262
231
  "auditable": true,
263
232
  "commentable": false,
264
233
  "folderId": "7f4e7c25-d8b2-4c1a-9f3e-6a7b5c8d9e1f"
265
- }`,
266
- },
267
- ]),
268
- "schemas update": buildCommandExamples([
234
+ }`
235
+ }
236
+ ],
237
+ "schemas update": [
269
238
  {
270
239
  description: "Toggle the commentable flag on a schema.",
271
- command: 'zinkee --json schemas update contacts --commentable true',
240
+ command: "zinkee --json schemas update contacts --commentable true",
272
241
  raw: `{
273
242
  "commentable": true
274
243
  }`,
@@ -300,40 +269,35 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
300
269
  }
301
270
  ],
302
271
  "uniqueFields": []
303
- }`,
272
+ }`
304
273
  },
305
274
  {
306
275
  description: "Rename a schema and change its slug.",
307
- command:
308
- 'zinkee --json schemas update contacts --name "Customer Contacts" --slug customer-contacts',
276
+ command: 'zinkee --json schemas update contacts --name "Customer Contacts" --slug customer-contacts',
309
277
  raw: `{
310
278
  "name": "Customer Contacts",
311
279
  "slug": "customer-contacts"
312
- }`,
280
+ }`
313
281
  },
314
282
  {
315
283
  description: "Enable the audit log on a schema.",
316
- command: 'zinkee --json schemas update contacts --auditable true',
284
+ command: "zinkee --json schemas update contacts --auditable true",
317
285
  raw: `{
318
286
  "auditable": true
319
- }`,
287
+ }`
320
288
  },
321
289
  {
322
- description:
323
- "Set the schema's highlighted (main) field — the field whose value names each record in the UI (activity-panel title and detail-view record list).",
324
- command:
325
- 'zinkee --json schemas update contacts --highlighted-field contact-name',
290
+ description: "Set the schema's highlighted (main) field \u2014 the field whose value names each record in the UI (activity-panel title and detail-view record list).",
291
+ command: "zinkee --json schemas update contacts --highlighted-field contact-name",
326
292
  raw: `{
327
293
  "highlightedField": "c60b8526-5835-4c9f-aecd-9a16c7704a34"
328
- }`,
329
- },
330
- ]),
331
- "schemas set-unique-fields": buildCommandExamples([
294
+ }`
295
+ }
296
+ ],
297
+ "schemas set-unique-fields": [
332
298
  {
333
- description:
334
- "Set a composite unique constraint: the listed fields must be unique together across records.",
335
- command:
336
- "zinkee --json schemas set-unique-fields contacts --field contact-name --field notes",
299
+ description: "Set a composite unique constraint: the listed fields must be unique together across records.",
300
+ command: "zinkee --json schemas set-unique-fields contacts --field contact-name --field notes",
337
301
  raw: `{
338
302
  "fieldIds": [
339
303
  "c60b8526-5835-4c9f-aecd-9a16c7704a34",
@@ -384,7 +348,7 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
384
348
  "c60b8526-5835-4c9f-aecd-9a16c7704a34",
385
349
  "1d2e3f4a-5b6c-7d8e-9f01-23456789abcd"
386
350
  ]
387
- }`,
351
+ }`
388
352
  },
389
353
  {
390
354
  description: "Set a single-field unique constraint.",
@@ -393,37 +357,34 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
393
357
  "fieldIds": [
394
358
  "c60b8526-5835-4c9f-aecd-9a16c7704a34"
395
359
  ]
396
- }`,
360
+ }`
397
361
  },
398
362
  {
399
363
  description: "Clear the unique constraint (no field must be unique anymore).",
400
364
  command: "zinkee --json schemas set-unique-fields contacts --clear",
401
365
  raw: `{
402
366
  "fieldIds": []
403
- }`,
404
- },
405
- ]),
406
- "schemas fields update": buildCommandExamples([
367
+ }`
368
+ }
369
+ ],
370
+ "schemas fields update": [
407
371
  {
408
372
  description: "Set the field description without changing its label or configuration.",
409
- command:
410
- 'zinkee --json schemas fields update contacts contact-name --description "Primary name shown for the customer"',
373
+ command: 'zinkee --json schemas fields update contacts contact-name --description "Primary name shown for the customer"',
411
374
  raw: `{
412
375
  "description": "Primary name shown for the customer"
413
- }`,
376
+ }`
414
377
  },
415
378
  {
416
379
  description: "Clear the field description.",
417
- command:
418
- 'zinkee --json schemas fields update contacts contact-name --description ""',
380
+ command: 'zinkee --json schemas fields update contacts contact-name --description ""',
419
381
  raw: `{
420
382
  "description": ""
421
- }`,
383
+ }`
422
384
  },
423
385
  {
424
386
  description: "Rename slug and label.",
425
- command:
426
- `zinkee --json schemas fields update contacts contact-name --label "Customer Full Name" --raw '{"slug":"customer-full-name"}'`,
387
+ command: `zinkee --json schemas fields update contacts contact-name --label "Customer Full Name" --raw '{"slug":"customer-full-name"}'`,
427
388
  raw: `{
428
389
  "slug": "customer-full-name",
429
390
  "label": "Customer Full Name"
@@ -432,19 +393,18 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
432
393
  "schemaId": "2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e",
433
394
  "fieldId": "c60b8526-5835-4c9f-aecd-9a16c7704a34",
434
395
  "slug": "customer-full-name"
435
- }`,
396
+ }`
436
397
  },
437
398
  {
438
399
  description: "Toggle required.",
439
400
  command: "zinkee --json schemas fields update contacts status --required true",
440
401
  raw: `{
441
402
  "required": true
442
- }`,
403
+ }`
443
404
  },
444
405
  {
445
406
  description: "Patch text field (long with default).",
446
- command:
447
- `zinkee --json schemas fields update contacts contact-name --raw '{"type":"TextField","label":"Customer Full Name","required":false,"config":{"textType":"LONG","defaultValue":"Unknown","conditionalFormatting":[]}}'`,
407
+ command: `zinkee --json schemas fields update contacts contact-name --raw '{"type":"TextField","label":"Customer Full Name","required":false,"config":{"textType":"LONG","defaultValue":"Unknown","conditionalFormatting":[]}}'`,
448
408
  raw: `{
449
409
  "type": "TextField",
450
410
  "label": "Customer Full Name",
@@ -454,12 +414,21 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
454
414
  "defaultValue": "Unknown",
455
415
  "conditionalFormatting": []
456
416
  }
457
- }`,
417
+ }`
418
+ },
419
+ {
420
+ description: "Declare an expected DNI/NIE format (warnings never block record saves). Omit expectedFormat to keep it; use kind none to disable it.",
421
+ command: `zinkee --json schemas fields update contacts tax-id --raw '{"type":"TextField","config":{"expectedFormat":{"kind":"dniNie"}}}'`,
422
+ raw: `{
423
+ "type": "TextField",
424
+ "config": {
425
+ "expectedFormat": { "kind": "dniNie" }
426
+ }
427
+ }`
458
428
  },
459
429
  {
460
430
  description: "Patch number field (to currency).",
461
- command:
462
- `zinkee --json schemas fields update contacts amount --raw '{"type":"NumberField","config":{"defaultValue":"0","formatOptions":{"format":"currency","decimals":2,"thousandsSeparator":true,"symbolEnabled":true,"symbolPosition":"before","symbolValue":"€"},"conditionalFormatting":[]}}'`,
431
+ command: `zinkee --json schemas fields update contacts amount --raw '{"type":"NumberField","config":{"defaultValue":"0","formatOptions":{"format":"currency","decimals":2,"thousandsSeparator":true,"symbolEnabled":true,"symbolPosition":"before","symbolValue":"\u20AC"},"conditionalFormatting":[]}}'`,
463
432
  raw: `{
464
433
  "type": "NumberField",
465
434
  "config": {
@@ -470,16 +439,15 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
470
439
  "thousandsSeparator": true,
471
440
  "symbolEnabled": true,
472
441
  "symbolPosition": "before",
473
- "symbolValue": "€"
442
+ "symbolValue": "\u20AC"
474
443
  },
475
444
  "conditionalFormatting": []
476
445
  }
477
- }`,
446
+ }`
478
447
  },
479
448
  {
480
449
  description: "Patch number field (to percentage).",
481
- command:
482
- `zinkee --json schemas fields update contacts discount-rate --raw '{"type":"NumberField","config":{"defaultValue":"0","formatOptions":{"format":"percentage","decimals":1},"conditionalFormatting":[]}}'`,
450
+ command: `zinkee --json schemas fields update contacts discount-rate --raw '{"type":"NumberField","config":{"defaultValue":"0","formatOptions":{"format":"percentage","decimals":1},"conditionalFormatting":[]}}'`,
483
451
  raw: `{
484
452
  "type": "NumberField",
485
453
  "config": {
@@ -490,12 +458,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
490
458
  },
491
459
  "conditionalFormatting": []
492
460
  }
493
- }`,
461
+ }`
494
462
  },
495
463
  {
496
464
  description: "Patch date field (to date only).",
497
- command:
498
- `zinkee --json schemas fields update contacts due-date --raw '{"type":"DateField","config":{"defaultValue":null,"formatOptions":{"format":"date","dateFormat":"YYYY-MM-DD","showTime":false},"conditionalFormatting":[]}}'`,
465
+ command: `zinkee --json schemas fields update contacts due-date --raw '{"type":"DateField","config":{"defaultValue":null,"formatOptions":{"format":"date","dateFormat":"YYYY-MM-DD","showTime":false},"conditionalFormatting":[]}}'`,
499
466
  raw: `{
500
467
  "type": "DateField",
501
468
  "config": {
@@ -507,12 +474,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
507
474
  },
508
475
  "conditionalFormatting": []
509
476
  }
510
- }`,
477
+ }`
511
478
  },
512
479
  {
513
480
  description: "Patch option field (button cycle).",
514
- command:
515
- `zinkee --json schemas fields update contacts stage --raw '{"type":"OptionField","config":{"options":[{"id":1,"name":"To Do","color":"default"},{"id":2,"name":"Doing","color":"warning"},{"id":3,"name":"Done","color":"success"}],"defaultValue":1,"conditionalFormatting":[],"buttonConfig":{"displayMode":"button","buttonBehavior":{"mode":"cycle","cycleOrder":[1,2,3],"allowReselect":true}}}}'`,
481
+ command: `zinkee --json schemas fields update contacts stage --raw '{"type":"OptionField","config":{"options":[{"id":1,"name":"To Do","color":"default"},{"id":2,"name":"Doing","color":"warning"},{"id":3,"name":"Done","color":"success"}],"defaultValue":1,"conditionalFormatting":[],"buttonConfig":{"displayMode":"button","buttonBehavior":{"mode":"cycle","cycleOrder":[1,2,3],"allowReselect":true}}}}'`,
516
482
  raw: `{
517
483
  "type": "OptionField",
518
484
  "config": {
@@ -532,12 +498,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
532
498
  }
533
499
  }
534
500
  }
535
- }`,
501
+ }`
536
502
  },
537
503
  {
538
504
  description: "Patch option field (drop button mode).",
539
- command:
540
- `zinkee --json schemas fields update contacts status --raw '{"type":"OptionField","config":{"options":[{"id":1,"name":"Open","color":"default"},{"id":2,"name":"In Progress","color":"warning"},{"id":3,"name":"Done","color":"success"}],"defaultValue":1,"conditionalFormatting":[],"buttonConfig":null}}'`,
505
+ command: `zinkee --json schemas fields update contacts status --raw '{"type":"OptionField","config":{"options":[{"id":1,"name":"Open","color":"default"},{"id":2,"name":"In Progress","color":"warning"},{"id":3,"name":"Done","color":"success"}],"defaultValue":1,"conditionalFormatting":[],"buttonConfig":null}}'`,
541
506
  raw: `{
542
507
  "type": "OptionField",
543
508
  "config": {
@@ -550,12 +515,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
550
515
  "conditionalFormatting": [],
551
516
  "buttonConfig": null
552
517
  }
553
- }`,
518
+ }`
554
519
  },
555
520
  {
556
521
  description: "Patch formula field (formula text).",
557
- command:
558
- `zinkee --json schemas fields update contacts formula-total --raw '{"type":"FormulaField","config":{"formulaText":"c52efe3f-2825-4c60-a7e3-34dd4c1ce043 * 1.10","uiFormatKind":"number","status":"ACTIVE","numberFormatOptions":{"format":"number","decimals":2,"thousandsSeparator":true},"conditionalFormatting":[]}}'`,
522
+ command: `zinkee --json schemas fields update contacts formula-total --raw '{"type":"FormulaField","config":{"formulaText":"c52efe3f-2825-4c60-a7e3-34dd4c1ce043 * 1.10","uiFormatKind":"number","status":"ACTIVE","numberFormatOptions":{"format":"number","decimals":2,"thousandsSeparator":true},"conditionalFormatting":[]}}'`,
559
523
  raw: `{
560
524
  "type": "FormulaField",
561
525
  "config": {
@@ -569,12 +533,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
569
533
  },
570
534
  "conditionalFormatting": []
571
535
  }
572
- }`,
536
+ }`
573
537
  },
574
538
  {
575
539
  description: "Patch reference field (delete behavior).",
576
- command:
577
- `zinkee --json schemas fields update contacts customer-ref --raw '{"type":"ReferenceField","config":{"targetSchema":"5223cbc8-8c6c-4694-93bc-dd176364df9b","targetDisplayField":"c60b8526-5835-4c9f-aecd-9a16c7704a34","deleteBehavior":"RESTRICT","defaultValue":null,"filterFields":[],"descriptionFields":[],"conditionalFormatting":[]}}'`,
540
+ command: `zinkee --json schemas fields update contacts customer-ref --raw '{"type":"ReferenceField","config":{"targetSchema":"5223cbc8-8c6c-4694-93bc-dd176364df9b","targetDisplayField":"c60b8526-5835-4c9f-aecd-9a16c7704a34","deleteBehavior":"RESTRICT","defaultValue":null,"filterFields":[],"descriptionFields":[],"conditionalFormatting":[]}}'`,
578
541
  raw: `{
579
542
  "type": "ReferenceField",
580
543
  "config": {
@@ -586,12 +549,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
586
549
  "descriptionFields": [],
587
550
  "conditionalFormatting": []
588
551
  }
589
- }`,
552
+ }`
590
553
  },
591
554
  {
592
555
  description: "Patch schedule field (to daily).",
593
- command:
594
- `zinkee --json schemas fields update contacts recurrence --raw '{"type":"ScheduleField","config":{"referenceField":"c52efe3f-2825-4c60-a7e3-34dd4c1ce043","beginningPeriodField":"d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90","endingPeriodField":"d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90","frequency":"daily"}}'`,
556
+ command: `zinkee --json schemas fields update contacts recurrence --raw '{"type":"ScheduleField","config":{"referenceField":"c52efe3f-2825-4c60-a7e3-34dd4c1ce043","beginningPeriodField":"d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90","endingPeriodField":"d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90","frequency":"daily"}}'`,
595
557
  raw: `{
596
558
  "type": "ScheduleField",
597
559
  "config": {
@@ -600,14 +562,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
600
562
  "endingPeriodField": "d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90",
601
563
  "frequency": "daily"
602
564
  }
603
- }`,
604
- },
605
- ]),
606
- "records query": buildCommandExamples([
565
+ }`
566
+ }
567
+ ],
568
+ "records query": [
607
569
  {
608
570
  description: "Lookup a single record by id.",
609
- command:
610
- 'zinkee --json records query contacts --select id,contact-name --where "id eq 550e8400-e29b-41d4-a716-446655440000" --sort id:desc --limit 10',
571
+ command: 'zinkee --json records query contacts --select id,contact-name --where "id eq 550e8400-e29b-41d4-a716-446655440000" --sort id:desc --limit 10',
611
572
  raw: `{
612
573
  "select": ["id", "contact-name"],
613
574
  "where": [
@@ -636,13 +597,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
636
597
  "count": 1,
637
598
  "hasMore": false
638
599
  }
639
- }`,
600
+ }`
640
601
  },
641
602
  {
642
- description:
643
- "Filter by multiple conditions and sort by amount then name.",
644
- command:
645
- `zinkee --json records query contacts --select id,contact-name,status,amount --where "status in 1,2" --where "amount gte 500" --sort amount:desc --sort contact-name:asc --limit 25`,
603
+ description: "Filter by multiple conditions and sort by amount then name.",
604
+ command: `zinkee --json records query contacts --select id,contact-name,status,amount --where "status in 1,2" --where "amount gte 500" --sort amount:desc --sort contact-name:asc --limit 25`,
646
605
  raw: `{
647
606
  "select": ["id", "contact-name", "status", "amount"],
648
607
  "where": [
@@ -654,12 +613,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
654
613
  { "field": "contact-name", "direction": "ASC" }
655
614
  ],
656
615
  "page": { "offset": 0, "limit": 25 }
657
- }`,
616
+ }`
658
617
  },
659
618
  {
660
619
  description: "Filter by status with a free-text search term.",
661
- command:
662
- `zinkee --json records query contacts --select id,contact-name,status --where "status in OPEN" --search garcia --limit 25`,
620
+ command: `zinkee --json records query contacts --select id,contact-name,status --where "status in OPEN" --search garcia --limit 25`,
663
621
  raw: `{
664
622
  "select": ["id", "contact-name", "status"],
665
623
  "where": [
@@ -667,24 +625,22 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
667
625
  ],
668
626
  "search": { "term": "garcia" },
669
627
  "page": { "offset": 0, "limit": 25 }
670
- }`,
628
+ }`
671
629
  },
672
630
  {
673
631
  description: "Text contains search.",
674
- command:
675
- 'zinkee --json records query contacts --select id,contact-name,contact-email --where "contact-name contains Lovelace" --limit 50',
632
+ command: 'zinkee --json records query contacts --select id,contact-name,contact-email --where "contact-name contains Lovelace" --limit 50',
676
633
  raw: `{
677
634
  "select": ["id", "contact-name", "contact-email"],
678
635
  "where": [
679
636
  { "field": "contact-name", "op": "contains", "value": "Lovelace" }
680
637
  ],
681
638
  "page": { "offset": 0, "limit": 50 }
682
- }`,
639
+ }`
683
640
  },
684
641
  {
685
642
  description: "Records with a non-empty due-date inside a date range.",
686
- command:
687
- 'zinkee --json records query contacts --where "due-date is_not_empty" --where "due-date lte 2026-12-31T23:59:59Z" --sort due-date:asc',
643
+ command: 'zinkee --json records query contacts --where "due-date is_not_empty" --where "due-date lte 2026-12-31T23:59:59Z" --sort due-date:asc',
688
644
  raw: `{
689
645
  "where": [
690
646
  { "field": "due-date", "op": "is_not_empty" },
@@ -693,65 +649,58 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
693
649
  "sort": [
694
650
  { "field": "due-date", "direction": "ASC" }
695
651
  ]
696
- }`,
652
+ }`
697
653
  },
698
654
  {
699
655
  description: "Records whose status is not equal to a value.",
700
- command:
701
- 'zinkee --json records query contacts --where "status neq 0"',
656
+ command: 'zinkee --json records query contacts --where "status neq 0"',
702
657
  raw: `{
703
658
  "where": [
704
659
  { "field": "status", "op": "neq", "value": 0 }
705
660
  ]
706
- }`,
661
+ }`
707
662
  },
708
663
  {
709
664
  description: "Records with an amount greater than a threshold.",
710
- command:
711
- 'zinkee --json records query contacts --where "amount gt 1000"',
665
+ command: 'zinkee --json records query contacts --where "amount gt 1000"',
712
666
  raw: `{
713
667
  "where": [
714
668
  { "field": "amount", "op": "gt", "value": 1000 }
715
669
  ]
716
- }`,
670
+ }`
717
671
  },
718
672
  {
719
673
  description: "Records with an amount less than a threshold.",
720
- command:
721
- 'zinkee --json records query contacts --where "amount lt 100"',
674
+ command: 'zinkee --json records query contacts --where "amount lt 100"',
722
675
  raw: `{
723
676
  "where": [
724
677
  { "field": "amount", "op": "lt", "value": 100 }
725
678
  ]
726
- }`,
679
+ }`
727
680
  },
728
681
  {
729
682
  description: "Records whose due-date is empty.",
730
- command:
731
- 'zinkee --json records query contacts --where "due-date is_empty"',
683
+ command: 'zinkee --json records query contacts --where "due-date is_empty"',
732
684
  raw: `{
733
685
  "where": [
734
686
  { "field": "due-date", "op": "is_empty" }
735
687
  ]
736
- }`,
688
+ }`
737
689
  },
738
690
  {
739
691
  description: "Records whose contact-email is not empty.",
740
- command:
741
- 'zinkee --json records query contacts --where "contact-email is_not_empty"',
692
+ command: 'zinkee --json records query contacts --where "contact-email is_not_empty"',
742
693
  raw: `{
743
694
  "where": [
744
695
  { "field": "contact-email", "op": "is_not_empty" }
745
696
  ]
746
- }`,
747
- },
748
- ]),
749
- "records create": buildCommandExamples([
697
+ }`
698
+ }
699
+ ],
700
+ "records create": [
750
701
  {
751
- description:
752
- "Create a single record with --set/--set-json (the single-record flags build one record, sent as a one-element 'records' array).",
753
- command:
754
- `zinkee --json records create contacts --set contact-name="Ada Lovelace" --set contact-email=ada@example.com`,
702
+ description: "Create a single record with --set/--set-json (the single-record flags build one record, sent as a one-element 'records' array).",
703
+ command: `zinkee --json records create contacts --set contact-name="Ada Lovelace" --set contact-email=ada@example.com`,
755
704
  raw: `{
756
705
  "records": [
757
706
  {
@@ -765,11 +714,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
765
714
  "550e8400-e29b-41d4-a716-446655440000"
766
715
  ],
767
716
  "errors": []
768
- }`,
717
+ }`
769
718
  },
770
719
  {
771
- description:
772
- "Create many records from a JSON array file (one object per record, slug -> value). Best-effort: valid records are created and invalid ones are reported per index in 'errors'. ReferenceField values accept the target record id (a bare UUID, or the compound 'recordId::anything' whose label is ignored) or an exact display value; the server stores the canonical 'recordId::displayValue'.",
720
+ description: "Create many records from a JSON array file (one object per record, slug -> value). Best-effort: valid records are created and invalid ones are reported per index in 'errors'. ReferenceField values accept the target record id (a bare UUID, or the compound 'recordId::anything' whose label is ignored) or an exact display value; the server stores the canonical 'recordId::displayValue'.",
773
721
  command: `zinkee --json records create contacts --records-file ./records.json`,
774
722
  raw: `{
775
723
  "records": [
@@ -800,13 +748,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
800
748
  "action": "Use a valid field slug from the schema and retry."
801
749
  }
802
750
  ]
803
- }`,
751
+ }`
804
752
  },
805
753
  {
806
- description:
807
- "Set a ReferenceField by the target record id (a bare UUID, or the compound 'recordId::anything' whose label is ignored) or by an exact display value. The server resolves and stores the canonical 'recordId::displayValue'. Unknown references are rejected per index with reason 'data_field_reference_not_found'.",
808
- command:
809
- `zinkee --json records create deals --set deal-name="Acme renewal" --set customer-ref=00000000-0000-0000-0000-000000000000`,
754
+ description: "Set a ReferenceField by the target record id (a bare UUID, or the compound 'recordId::anything' whose label is ignored) or by an exact display value. The server resolves and stores the canonical 'recordId::displayValue'. Unknown references are rejected per index with reason 'data_field_reference_not_found'.",
755
+ command: `zinkee --json records create deals --set deal-name="Acme renewal" --set customer-ref=00000000-0000-0000-0000-000000000000`,
810
756
  raw: `{
811
757
  "records": [
812
758
  {
@@ -825,14 +771,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
825
771
  "action": "Use an existing record id or an existing display value for this reference field."
826
772
  }
827
773
  ]
828
- }`,
829
- },
830
- ]),
831
- "records update": buildCommandExamples([
774
+ }`
775
+ }
776
+ ],
777
+ "records update": [
832
778
  {
833
779
  description: "Set one field and unset another.",
834
- command:
835
- 'zinkee --json records update contacts 550e8400-e29b-41d4-a716-446655440000 --set contact-name="Ada Lovelace Updated" --unset contact-email',
780
+ command: 'zinkee --json records update contacts 550e8400-e29b-41d4-a716-446655440000 --set contact-name="Ada Lovelace Updated" --unset contact-email',
836
781
  raw: `{
837
782
  "set": {
838
783
  "contact-name": "Ada Lovelace Updated"
@@ -848,12 +793,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
848
793
  "due-date": "2026-05-15T12:00:00Z",
849
794
  "owner": "6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d"
850
795
  }
851
- }`,
796
+ }`
852
797
  },
853
798
  {
854
799
  description: "Patch multiple typed values at once.",
855
- command:
856
- 'zinkee --json records update contacts 550e8400-e29b-41d4-a716-446655440000 --set status=3 --set amount=2500.00 --set due-date=2026-07-01T09:00:00Z --set owner=6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d',
800
+ command: "zinkee --json records update contacts 550e8400-e29b-41d4-a716-446655440000 --set status=3 --set amount=2500.00 --set due-date=2026-07-01T09:00:00Z --set owner=6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d",
857
801
  raw: `{
858
802
  "set": {
859
803
  "status": 3,
@@ -861,21 +805,18 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
861
805
  "due-date": "2026-07-01T09:00:00Z",
862
806
  "owner": "6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d"
863
807
  }
864
- }`,
808
+ }`
865
809
  },
866
810
  {
867
811
  description: "Unset only (clear fields).",
868
- command:
869
- 'zinkee --json records update contacts 550e8400-e29b-41d4-a716-446655440000 --unset contact-email --unset due-date',
812
+ command: "zinkee --json records update contacts 550e8400-e29b-41d4-a716-446655440000 --unset contact-email --unset due-date",
870
813
  raw: `{
871
814
  "unset": ["contact-email", "due-date"]
872
- }`,
815
+ }`
873
816
  },
874
817
  {
875
- description:
876
- "Set a ReferenceField on an existing record. Pass the target record id (a bare UUID, or the compound 'recordId::anything' whose label is ignored) or an exact display value; the response shows the canonical 'recordId::displayValue' the server stored. If the reference doesn't exist the whole update is rejected with reason 'data_field_reference_not_found'.",
877
- command:
878
- 'zinkee --json records update deals 550e8400-e29b-41d4-a716-446655440000 --set customer-ref=8ad602a1-f6e3-43f6-9ab2-f1c5afc99621',
818
+ description: "Set a ReferenceField on an existing record. Pass the target record id (a bare UUID, or the compound 'recordId::anything' whose label is ignored) or an exact display value; the response shows the canonical 'recordId::displayValue' the server stored. If the reference doesn't exist the whole update is rejected with reason 'data_field_reference_not_found'.",
819
+ command: "zinkee --json records update deals 550e8400-e29b-41d4-a716-446655440000 --set customer-ref=8ad602a1-f6e3-43f6-9ab2-f1c5afc99621",
879
820
  raw: `{
880
821
  "set": {
881
822
  "customer-ref": "8ad602a1-f6e3-43f6-9ab2-f1c5afc99621"
@@ -887,14 +828,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
887
828
  "deal-name": "Acme renewal",
888
829
  "customer-ref": "8ad602a1-f6e3-43f6-9ab2-f1c5afc99621::Acme Corp"
889
830
  }
890
- }`,
891
- },
892
- ]),
893
- "comments create": buildCommandExamples([
831
+ }`
832
+ }
833
+ ],
834
+ "comments create": [
894
835
  {
895
836
  description: "Plain text comment on a record (uses --text).",
896
- command:
897
- `zinkee --json comments create contacts 550e8400-e29b-41d4-a716-446655440000 --text "This record needs review."`,
837
+ command: `zinkee --json comments create contacts 550e8400-e29b-41d4-a716-446655440000 --text "This record needs review."`,
898
838
  raw: `{
899
839
  "content": [
900
840
  {
@@ -911,55 +851,49 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
911
851
  "content": [
912
852
  { "type": "TEXT", "value": "This record needs review." }
913
853
  ]
914
- }`,
854
+ }`
915
855
  },
916
856
  {
917
- description:
918
- "Comment with an inline member mention. Mentions only go through --raw today because --text is plain text.",
919
- command:
920
- `zinkee --json comments create contacts 550e8400-e29b-41d4-a716-446655440000 --raw '{"content":[{"type":"TEXT","value":"Assigning to "},{"type":"MENTION","value":"9f8e7d6c-5b4a-3c2d-1e0f-a1b2c3d4e5f6"},{"type":"TEXT","value":" for follow up."}]}'`,
857
+ description: "Comment with an inline member mention. Mentions only go through --raw today because --text is plain text.",
858
+ command: `zinkee --json comments create contacts 550e8400-e29b-41d4-a716-446655440000 --raw '{"content":[{"type":"TEXT","value":"Assigning to "},{"type":"MENTION","value":"9f8e7d6c-5b4a-3c2d-1e0f-a1b2c3d4e5f6"},{"type":"TEXT","value":" for follow up."}]}'`,
921
859
  raw: `{
922
860
  "content": [
923
861
  { "type": "TEXT", "value": "Assigning to " },
924
862
  { "type": "MENTION", "value": "9f8e7d6c-5b4a-3c2d-1e0f-a1b2c3d4e5f6" },
925
863
  { "type": "TEXT", "value": " for follow up." }
926
864
  ]
927
- }`,
928
- },
929
- ]),
930
- "files download": buildCommandExamples([
865
+ }`
866
+ }
867
+ ],
868
+ "files download": [
931
869
  {
932
- description:
933
- "Download a file to disk (the CLI writes the raw bytes to the --output path; the JSON mode only emits a success envelope).",
934
- command: `zinkee --json files download ${SAMPLE_UUID} --output ./download.bin`,
935
- },
936
- ]),
937
- "files upload": buildCommandExamples([
870
+ description: "Download a file to disk (the CLI writes the raw bytes to the --output path; the JSON mode only emits a success envelope).",
871
+ command: `zinkee --json files download ${SAMPLE_UUID} --output ./download.bin`
872
+ }
873
+ ],
874
+ "files upload": [
938
875
  {
939
- description:
940
- "Upload a local file. The CLI sends the multipart form and the backend returns the generated file id to reference from record FileField values.",
876
+ description: "Upload a local file. The CLI sends the multipart form and the backend returns the generated file id to reference from record FileField values.",
941
877
  command: "zinkee --json files upload ./report.pdf",
942
878
  response: `{
943
879
  "id": "d290f1ee-6c54-4b01-90e6-d701748f0851"
944
- }`,
945
- },
946
- ]),
947
- "files delete": buildCommandExamples([
880
+ }`
881
+ }
882
+ ],
883
+ "files delete": [
948
884
  {
949
- description:
950
- "Delete a file from workspace storage. Records that still reference the file id keep the stale pointer until updated separately.",
885
+ description: "Delete a file from workspace storage. Records that still reference the file id keep the stale pointer until updated separately.",
951
886
  command: `zinkee --json files delete ${SAMPLE_UUID}`,
952
887
  response: `{
953
888
  "id": "d290f1ee-6c54-4b01-90e6-d701748f0851",
954
889
  "deleted": true
955
- }`,
956
- },
957
- ]),
958
- "navigation folders create": buildCommandExamples([
890
+ }`
891
+ }
892
+ ],
893
+ "navigation folders create": [
959
894
  {
960
895
  description: "Create a folder with a display order and custom properties.",
961
- command:
962
- `zinkee --json navigation folders create --name Finance --order 20 --props '{"color":"green"}'`,
896
+ command: `zinkee --json navigation folders create --name Finance --order 20 --props '{"color":"green"}'`,
963
897
  raw: `{
964
898
  "name": "Finance",
965
899
  "order": 20,
@@ -970,19 +904,18 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
970
904
  response: `{
971
905
  "folderId": "c5d6e7f8-9012-3456-789a-bcdef0123456",
972
906
  "name": "Finance"
973
- }`,
907
+ }`
974
908
  },
975
909
  {
976
910
  description: "Minimal create with just a name.",
977
- command: 'zinkee --json navigation folders create --name Archive',
911
+ command: "zinkee --json navigation folders create --name Archive",
978
912
  raw: `{
979
913
  "name": "Archive"
980
- }`,
914
+ }`
981
915
  },
982
916
  {
983
917
  description: "Create a folder with color and icon metadata.",
984
- command:
985
- `zinkee --json navigation folders create --name Reports --order 5 --props '{"color":"teal","icon":"chart-line"}'`,
918
+ command: `zinkee --json navigation folders create --name Reports --order 5 --props '{"color":"teal","icon":"chart-line"}'`,
986
919
  raw: `{
987
920
  "name": "Reports",
988
921
  "order": 5,
@@ -990,14 +923,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
990
923
  "color": "teal",
991
924
  "icon": "chart-line"
992
925
  }
993
- }`,
994
- },
995
- ]),
996
- "navigation folders update": buildCommandExamples([
926
+ }`
927
+ }
928
+ ],
929
+ "navigation folders update": [
997
930
  {
998
931
  description: "Rename the folder, change its order, and rewrite its additionalProperties.",
999
- command:
1000
- `zinkee --json navigation folders update Finance --name "Finance Ops" --order 30 --props '{"color":"teal"}'`,
932
+ command: `zinkee --json navigation folders update Finance --name "Finance Ops" --order 30 --props '{"color":"teal"}'`,
1001
933
  raw: `{
1002
934
  "name": "Finance Ops",
1003
935
  "order": 30,
@@ -1008,40 +940,37 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1008
940
  response: `{
1009
941
  "folderId": "84a0fca4-37ef-4c83-a8ed-9ef67ad9324a",
1010
942
  "name": "Finance Ops"
1011
- }`,
943
+ }`
1012
944
  },
1013
945
  {
1014
946
  description: "Rename only.",
1015
947
  command: 'zinkee --json navigation folders update Finance --name "Finance (legacy)"',
1016
948
  raw: `{
1017
949
  "name": "Finance (legacy)"
1018
- }`,
950
+ }`
1019
951
  },
1020
952
  {
1021
953
  description: "Change only the display order.",
1022
- command: 'zinkee --json navigation folders update Finance --order 1',
954
+ command: "zinkee --json navigation folders update Finance --order 1",
1023
955
  raw: `{
1024
956
  "order": 1
1025
- }`,
957
+ }`
1026
958
  },
1027
959
  {
1028
960
  description: "Replace only additionalProperties.",
1029
- command:
1030
- `zinkee --json navigation folders update Finance --props '{"color":"red","icon":"archive"}'`,
961
+ command: `zinkee --json navigation folders update Finance --props '{"color":"red","icon":"archive"}'`,
1031
962
  raw: `{
1032
963
  "additionalProperties": {
1033
964
  "color": "red",
1034
965
  "icon": "archive"
1035
966
  }
1036
- }`,
1037
- },
1038
- ]),
1039
- "navigation resources move": buildCommandExamples([
967
+ }`
968
+ }
969
+ ],
970
+ "navigation resources move": [
1040
971
  {
1041
- description:
1042
- "Move a schema into a navigation folder. Only schemas can be moved; the navigation menu holds databases.",
1043
- command:
1044
- 'zinkee --json navigation resources move 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --to Sales',
972
+ description: "Move a schema into a navigation folder. Only schemas can be moved; the navigation menu holds databases.",
973
+ command: "zinkee --json navigation resources move 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --to Sales",
1045
974
  raw: `{
1046
975
  "resourceId": "2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e",
1047
976
  "targetFolderId": "84a0fca4-37ef-4c83-a8ed-9ef67ad9324a"
@@ -1049,23 +978,21 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1049
978
  response: `{
1050
979
  "resourceId": "2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e",
1051
980
  "targetFolderId": "84a0fca4-37ef-4c83-a8ed-9ef67ad9324a"
1052
- }`,
981
+ }`
1053
982
  },
1054
983
  {
1055
984
  description: "Move a schema back to the root folder (root is always UUID 00000000-0000-0000-0000-000000000000).",
1056
- command:
1057
- 'zinkee --json navigation resources move 5223cbc8-8c6c-4694-93bc-dd176364df9b --to 00000000-0000-0000-0000-000000000000',
985
+ command: "zinkee --json navigation resources move 5223cbc8-8c6c-4694-93bc-dd176364df9b --to 00000000-0000-0000-0000-000000000000",
1058
986
  raw: `{
1059
987
  "resourceId": "5223cbc8-8c6c-4694-93bc-dd176364df9b",
1060
988
  "targetFolderId": "00000000-0000-0000-0000-000000000000"
1061
- }`,
1062
- },
1063
- ]),
1064
- "teamspace folders create": buildCommandExamples([
989
+ }`
990
+ }
991
+ ],
992
+ "teamspace folders create": [
1065
993
  {
1066
994
  description: "Create a teamspace folder with order and icon metadata.",
1067
- command:
1068
- `zinkee --json teamspace folders create --name "Customer Success" --order 10 --props '{"icon":"folder-users"}'`,
995
+ command: `zinkee --json teamspace folders create --name "Customer Success" --order 10 --props '{"icon":"folder-users"}'`,
1069
996
  raw: `{
1070
997
  "name": "Customer Success",
1071
998
  "order": 10,
@@ -1083,19 +1010,18 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1083
1010
  "additionalProperties": {
1084
1011
  "icon": "folder-users"
1085
1012
  }
1086
- }`,
1013
+ }`
1087
1014
  },
1088
1015
  {
1089
1016
  description: "Minimal create.",
1090
- command: 'zinkee --json teamspace folders create --name Shared',
1017
+ command: "zinkee --json teamspace folders create --name Shared",
1091
1018
  raw: `{
1092
1019
  "name": "Shared"
1093
- }`,
1020
+ }`
1094
1021
  },
1095
1022
  {
1096
1023
  description: "Prominent folder with icon and color.",
1097
- command:
1098
- `zinkee --json teamspace folders create --name Executive --order 1 --props '{"icon":"crown","color":"gold"}'`,
1024
+ command: `zinkee --json teamspace folders create --name Executive --order 1 --props '{"icon":"crown","color":"gold"}'`,
1099
1025
  raw: `{
1100
1026
  "name": "Executive",
1101
1027
  "order": 1,
@@ -1103,14 +1029,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1103
1029
  "icon": "crown",
1104
1030
  "color": "gold"
1105
1031
  }
1106
- }`,
1107
- },
1108
- ]),
1109
- "teamspace folders update": buildCommandExamples([
1032
+ }`
1033
+ }
1034
+ ],
1035
+ "teamspace folders update": [
1110
1036
  {
1111
1037
  description: "Rename, reorder and update properties in one call.",
1112
- command:
1113
- `zinkee --json teamspace folders update "Customer Success" --name "Shared KPIs" --order 5 --props '{"icon":"chart-bar"}'`,
1038
+ command: `zinkee --json teamspace folders update "Customer Success" --name "Shared KPIs" --order 5 --props '{"icon":"chart-bar"}'`,
1114
1039
  raw: `{
1115
1040
  "name": "Shared KPIs",
1116
1041
  "order": 5,
@@ -1134,39 +1059,36 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1134
1059
  "additionalProperties": {
1135
1060
  "icon": "chart-bar"
1136
1061
  }
1137
- }`,
1062
+ }`
1138
1063
  },
1139
1064
  {
1140
1065
  description: "Rename only.",
1141
- command:
1142
- 'zinkee --json teamspace folders update "Customer Success" --name "Shared Analytics"',
1066
+ command: 'zinkee --json teamspace folders update "Customer Success" --name "Shared Analytics"',
1143
1067
  raw: `{
1144
1068
  "name": "Shared Analytics"
1145
- }`,
1069
+ }`
1146
1070
  },
1147
1071
  {
1148
1072
  description: "Reorder only.",
1149
1073
  command: 'zinkee --json teamspace folders update "Customer Success" --order 2',
1150
1074
  raw: `{
1151
1075
  "order": 2
1152
- }`,
1076
+ }`
1153
1077
  },
1154
1078
  {
1155
1079
  description: "Update only the icon metadata.",
1156
- command:
1157
- `zinkee --json teamspace folders update "Customer Success" --props '{"icon":"chart-line"}'`,
1080
+ command: `zinkee --json teamspace folders update "Customer Success" --props '{"icon":"chart-line"}'`,
1158
1081
  raw: `{
1159
1082
  "additionalProperties": {
1160
1083
  "icon": "chart-line"
1161
1084
  }
1162
- }`,
1163
- },
1164
- ]),
1165
- "teamspace resources publish": buildCommandExamples([
1085
+ }`
1086
+ }
1087
+ ],
1088
+ "teamspace resources publish": [
1166
1089
  {
1167
1090
  description: "Publish a schema by slug into a teamspace folder.",
1168
- command:
1169
- 'zinkee --json teamspace resources publish customer-records --to "Shared Dashboards"',
1091
+ command: 'zinkee --json teamspace resources publish customer-records --to "Shared Dashboards"',
1170
1092
  raw: `{
1171
1093
  "resourceId": "customer-records",
1172
1094
  "targetFolderId": "f45a251d-3ea0-4b41-bfe8-c0f44c8ad54a"
@@ -1179,40 +1101,37 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1179
1101
  "isRoot": false
1180
1102
  },
1181
1103
  "previousFolder": null
1182
- }`,
1104
+ }`
1183
1105
  },
1184
1106
  {
1185
1107
  description: "Publish a schema by UUID.",
1186
- command:
1187
- 'zinkee --json teamspace resources publish 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --to "Shared Dashboards"',
1108
+ command: 'zinkee --json teamspace resources publish 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --to "Shared Dashboards"',
1188
1109
  raw: `{
1189
1110
  "resourceId": "2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e",
1190
1111
  "targetFolderId": "f45a251d-3ea0-4b41-bfe8-c0f44c8ad54a"
1191
- }`,
1112
+ }`
1192
1113
  },
1193
1114
  {
1194
1115
  description: "Publish a display.",
1195
- command:
1196
- 'zinkee --json teamspace resources publish 0f6f062f-1478-4df2-96a1-c495d037d260 --to "Shared Dashboards"',
1116
+ command: 'zinkee --json teamspace resources publish 0f6f062f-1478-4df2-96a1-c495d037d260 --to "Shared Dashboards"',
1197
1117
  raw: `{
1198
1118
  "resourceId": "0f6f062f-1478-4df2-96a1-c495d037d260",
1199
1119
  "targetFolderId": "f45a251d-3ea0-4b41-bfe8-c0f44c8ad54a"
1200
- }`,
1120
+ }`
1201
1121
  },
1202
1122
  {
1203
1123
  description: "Publish directly at the teamspace root (root folder UUID is always 00000000-0000-0000-0000-000000000000).",
1204
- command:
1205
- 'zinkee --json teamspace resources publish customer-records --to 00000000-0000-0000-0000-000000000000',
1124
+ command: "zinkee --json teamspace resources publish customer-records --to 00000000-0000-0000-0000-000000000000",
1206
1125
  raw: `{
1207
1126
  "resourceId": "customer-records",
1208
1127
  "targetFolderId": "00000000-0000-0000-0000-000000000000"
1209
- }`,
1210
- },
1211
- ]),
1212
- "teamspace resources unpublish": buildCommandExamples([
1128
+ }`
1129
+ }
1130
+ ],
1131
+ "teamspace resources unpublish": [
1213
1132
  {
1214
1133
  description: "Unpublish a schema by slug.",
1215
- command: 'zinkee --json teamspace resources unpublish customer-records',
1134
+ command: "zinkee --json teamspace resources unpublish customer-records",
1216
1135
  raw: `{
1217
1136
  "resourceId": "customer-records"
1218
1137
  }`,
@@ -1223,31 +1142,27 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1223
1142
  "name": "Shared Dashboards",
1224
1143
  "isRoot": false
1225
1144
  }
1226
- }`,
1145
+ }`
1227
1146
  },
1228
1147
  {
1229
1148
  description: "Unpublish a schema by UUID.",
1230
- command:
1231
- 'zinkee --json teamspace resources unpublish 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e',
1149
+ command: "zinkee --json teamspace resources unpublish 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e",
1232
1150
  raw: `{
1233
1151
  "resourceId": "2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e"
1234
- }`,
1152
+ }`
1235
1153
  },
1236
1154
  {
1237
1155
  description: "Unpublish a display.",
1238
- command:
1239
- 'zinkee --json teamspace resources unpublish 0f6f062f-1478-4df2-96a1-c495d037d260',
1156
+ command: "zinkee --json teamspace resources unpublish 0f6f062f-1478-4df2-96a1-c495d037d260",
1240
1157
  raw: `{
1241
1158
  "resourceId": "0f6f062f-1478-4df2-96a1-c495d037d260"
1242
- }`,
1243
- },
1244
- ]),
1245
- "displays create": buildCommandExamples([
1159
+ }`
1160
+ }
1161
+ ],
1162
+ "displays create": [
1246
1163
  {
1247
- description:
1248
- "Create a described freeform display with an initial widget layout. Freeform layouts travel through --freeform-layouts.",
1249
- command:
1250
- `zinkee --json displays create --name "Control Proyecto Freeform" --description "Project delivery overview" --template freeform --freeform-layouts '{"lg":[{"i":"widget-1","x":0,"y":0,"w":6,"h":5}]}'`,
1164
+ description: "Create a described freeform display with an initial widget layout. Freeform layouts travel through --freeform-layouts.",
1165
+ command: `zinkee --json displays create --name "Control Proyecto Freeform" --description "Project delivery overview" --template freeform --freeform-layouts '{"lg":[{"i":"widget-1","x":0,"y":0,"w":6,"h":5}]}'`,
1251
1166
  raw: `{
1252
1167
  "name": "Control Proyecto Freeform",
1253
1168
  "description": "Project delivery overview",
@@ -1262,36 +1177,33 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1262
1177
  }`,
1263
1178
  response: `{
1264
1179
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260"
1265
- }`,
1180
+ }`
1266
1181
  },
1267
1182
  {
1268
1183
  description: "Create a tabbed display using the widget_row_tabs template.",
1269
- command:
1270
- 'zinkee --json displays create --name "Executive Revenue" --template widget_row_tabs',
1184
+ command: 'zinkee --json displays create --name "Executive Revenue" --template widget_row_tabs',
1271
1185
  raw: `{
1272
1186
  "name": "Executive Revenue",
1273
1187
  "layout": {
1274
1188
  "template": "widget_row_tabs"
1275
1189
  }
1276
- }`,
1190
+ }`
1277
1191
  },
1278
1192
  {
1279
1193
  description: "Create a grid display.",
1280
- command:
1281
- 'zinkee --json displays create --name "Customer Detail" --template grid',
1194
+ command: 'zinkee --json displays create --name "Customer Detail" --template grid',
1282
1195
  raw: `{
1283
1196
  "name": "Customer Detail",
1284
1197
  "layout": {
1285
1198
  "template": "grid"
1286
1199
  }
1287
- }`,
1288
- },
1289
- ]),
1290
- "displays tabs create": buildCommandExamples([
1200
+ }`
1201
+ }
1202
+ ],
1203
+ "displays tabs create": [
1291
1204
  {
1292
1205
  description: "Create a horizontal tab.",
1293
- command:
1294
- 'zinkee --json displays tabs create 0f6f062f-1478-4df2-96a1-c495d037d260 --name Overview --orientation horizontal',
1206
+ command: "zinkee --json displays tabs create 0f6f062f-1478-4df2-96a1-c495d037d260 --name Overview --orientation horizontal",
1295
1207
  raw: `{
1296
1208
  "name": "Overview",
1297
1209
  "orientation": "horizontal"
@@ -1299,55 +1211,49 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1299
1211
  response: `{
1300
1212
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
1301
1213
  "tabId": "tab-overview"
1302
- }`,
1214
+ }`
1303
1215
  },
1304
1216
  {
1305
1217
  description: "Create a vertical tab.",
1306
- command:
1307
- 'zinkee --json displays tabs create 0f6f062f-1478-4df2-96a1-c495d037d260 --name Details --orientation vertical',
1218
+ command: "zinkee --json displays tabs create 0f6f062f-1478-4df2-96a1-c495d037d260 --name Details --orientation vertical",
1308
1219
  raw: `{
1309
1220
  "name": "Details",
1310
1221
  "orientation": "vertical"
1311
- }`,
1312
- },
1313
- ]),
1314
- "displays tabs update": buildCommandExamples([
1222
+ }`
1223
+ }
1224
+ ],
1225
+ "displays tabs update": [
1315
1226
  {
1316
1227
  description: "Rename a tab.",
1317
- command:
1318
- 'zinkee --json displays tabs update 0f6f062f-1478-4df2-96a1-c495d037d260 tab-main --name "Overview (renamed)"',
1228
+ command: 'zinkee --json displays tabs update 0f6f062f-1478-4df2-96a1-c495d037d260 tab-main --name "Overview (renamed)"',
1319
1229
  raw: `{
1320
1230
  "name": "Overview (renamed)"
1321
1231
  }`,
1322
1232
  response: `{
1323
1233
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
1324
1234
  "tabId": "tab-main"
1325
- }`,
1235
+ }`
1326
1236
  },
1327
1237
  {
1328
1238
  description: "Change orientation only.",
1329
- command:
1330
- 'zinkee --json displays tabs update 0f6f062f-1478-4df2-96a1-c495d037d260 tab-main --orientation vertical',
1239
+ command: "zinkee --json displays tabs update 0f6f062f-1478-4df2-96a1-c495d037d260 tab-main --orientation vertical",
1331
1240
  raw: `{
1332
1241
  "orientation": "vertical"
1333
- }`,
1242
+ }`
1334
1243
  },
1335
1244
  {
1336
1245
  description: "Rename and reorient at once.",
1337
- command:
1338
- 'zinkee --json displays tabs update 0f6f062f-1478-4df2-96a1-c495d037d260 tab-main --name Details --orientation vertical',
1246
+ command: "zinkee --json displays tabs update 0f6f062f-1478-4df2-96a1-c495d037d260 tab-main --name Details --orientation vertical",
1339
1247
  raw: `{
1340
1248
  "name": "Details",
1341
1249
  "orientation": "vertical"
1342
- }`,
1343
- },
1344
- ]),
1345
- "displays variables create": buildCommandExamples([
1250
+ }`
1251
+ }
1252
+ ],
1253
+ "displays variables create": [
1346
1254
  {
1347
- description:
1348
- "Create a single-select REFERENCE variable bound to a (schema, field) pair. schemaId and fieldId accept slugs or UUIDs.",
1349
- command:
1350
- 'zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type REFERENCE --name Customer --source-schema contacts --source-field contact-name --default ""',
1255
+ description: "Create a single-select REFERENCE variable bound to a (schema, field) pair. schemaId and fieldId accept slugs or UUIDs.",
1256
+ command: 'zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type REFERENCE --name Customer --source-schema contacts --source-field contact-name --default ""',
1351
1257
  raw: `{
1352
1258
  "type": "REFERENCE",
1353
1259
  "name": "Customer",
@@ -1363,13 +1269,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1363
1269
  response: `{
1364
1270
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
1365
1271
  "variableId": "aaaaaaaa-1111-4111-a111-111111111111"
1366
- }`,
1272
+ }`
1367
1273
  },
1368
1274
  {
1369
- description:
1370
- "Create a multi-select REFERENCE variable with a filter. Complex filters go via --raw because --filter only accepts raw expressions.",
1371
- command:
1372
- `zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --raw '{"type":"REFERENCE","name":"Active customers","source":{"schemaId":"contacts","fieldId":"contact-name"},"defaultValues":[],"allowMultiple":true,"staticVariable":false,"filters":[{"origin":{"schemaId":"contacts","fieldId":"status"},"comparisonOperator":"ANY_OF","values":["1","2"]}]}'`,
1275
+ description: "Create a multi-select REFERENCE variable with a filter. Complex filters go via --raw because --filter only accepts raw expressions.",
1276
+ command: `zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --raw '{"type":"REFERENCE","name":"Active customers","source":{"schemaId":"contacts","fieldId":"contact-name"},"defaultValues":[],"allowMultiple":true,"staticVariable":false,"filters":[{"origin":{"schemaId":"contacts","fieldId":"status"},"comparisonOperator":"ANY_OF","values":["1","2"]}]}'`,
1373
1277
  raw: `{
1374
1278
  "type": "REFERENCE",
1375
1279
  "name": "Active customers",
@@ -1390,24 +1294,22 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1390
1294
  "values": ["1", "2"]
1391
1295
  }
1392
1296
  ]
1393
- }`,
1297
+ }`
1394
1298
  },
1395
1299
  {
1396
1300
  description: "Create a MEMBER variable with a default user id.",
1397
- command:
1398
- 'zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type MEMBER --name Owner --default 6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d',
1301
+ command: "zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type MEMBER --name Owner --default 6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d",
1399
1302
  raw: `{
1400
1303
  "type": "MEMBER",
1401
1304
  "name": "Owner",
1402
1305
  "defaultValue": "6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d",
1403
1306
  "allowMultiple": false,
1404
1307
  "staticVariable": false
1405
- }`,
1308
+ }`
1406
1309
  },
1407
1310
  {
1408
1311
  description: "Create a DATE variable using a dynamic period (thisMonth).",
1409
- command:
1410
- 'zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type DATE --name Period --date-mode dynamic --date-dynamic-option thisMonth',
1312
+ command: "zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type DATE --name Period --date-mode dynamic --date-dynamic-option thisMonth",
1411
1313
  raw: `{
1412
1314
  "type": "DATE",
1413
1315
  "name": "Period",
@@ -1415,12 +1317,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1415
1317
  "mode": "dynamic",
1416
1318
  "dynamicOption": "thisMonth"
1417
1319
  }
1418
- }`,
1320
+ }`
1419
1321
  },
1420
1322
  {
1421
1323
  description: "Create a DATE variable with a specific date.",
1422
- command:
1423
- 'zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type DATE --name Cutoff --date-mode specific --date-specific 2026-04-22',
1324
+ command: "zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type DATE --name Cutoff --date-mode specific --date-specific 2026-04-22",
1424
1325
  raw: `{
1425
1326
  "type": "DATE",
1426
1327
  "name": "Cutoff",
@@ -1428,12 +1329,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1428
1329
  "mode": "specific",
1429
1330
  "specificDate": "2026-04-22"
1430
1331
  }
1431
- }`,
1332
+ }`
1432
1333
  },
1433
1334
  {
1434
1335
  description: "Create a DATE variable with a custom range.",
1435
- command:
1436
- 'zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type DATE --name Quarter --date-mode range --date-range-start 2026-04-01 --date-range-end 2026-06-30',
1336
+ command: "zinkee --json displays variables create 0f6f062f-1478-4df2-96a1-c495d037d260 --type DATE --name Quarter --date-mode range --date-range-start 2026-04-01 --date-range-end 2026-06-30",
1437
1337
  raw: `{
1438
1338
  "type": "DATE",
1439
1339
  "name": "Quarter",
@@ -1442,15 +1342,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1442
1342
  "rangeStart": "2026-04-01",
1443
1343
  "rangeEnd": "2026-06-30"
1444
1344
  }
1445
- }`,
1446
- },
1447
- ]),
1448
- "displays variables update": buildCommandExamples([
1345
+ }`
1346
+ }
1347
+ ],
1348
+ "displays variables update": [
1449
1349
  {
1450
- description:
1451
- "Rename the variable and make it static (defaults must be cleared with a raw patch because the CLI has no --default-values [] shortcut).",
1452
- command:
1453
- `zinkee --json displays variables update 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111 --raw '{"name":"Proyecto principal","staticVariable":true,"defaultValues":[]}'`,
1350
+ description: "Rename the variable and make it static (defaults must be cleared with a raw patch because the CLI has no --default-values [] shortcut).",
1351
+ command: `zinkee --json displays variables update 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111 --raw '{"name":"Proyecto principal","staticVariable":true,"defaultValues":[]}'`,
1454
1352
  raw: `{
1455
1353
  "name": "Proyecto principal",
1456
1354
  "staticVariable": true,
@@ -1459,12 +1357,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1459
1357
  response: `{
1460
1358
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
1461
1359
  "variableId": "aaaaaaaa-1111-4111-a111-111111111111"
1462
- }`,
1360
+ }`
1463
1361
  },
1464
1362
  {
1465
1363
  description: "Replace the reference filters of the variable.",
1466
- command:
1467
- `zinkee --json displays variables update 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111 --raw '{"filters":[{"origin":{"schemaId":"contacts","fieldId":"status"},"comparisonOperator":"ANY_OF","values":["2","3"]}]}'`,
1364
+ command: `zinkee --json displays variables update 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111 --raw '{"filters":[{"origin":{"schemaId":"contacts","fieldId":"status"},"comparisonOperator":"ANY_OF","values":["2","3"]}]}'`,
1468
1365
  raw: `{
1469
1366
  "filters": [
1470
1367
  {
@@ -1476,35 +1373,31 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1476
1373
  "values": ["2", "3"]
1477
1374
  }
1478
1375
  ]
1479
- }`,
1376
+ }`
1480
1377
  },
1481
1378
  {
1482
1379
  description: "Switch a variable to multi-select.",
1483
- command:
1484
- `zinkee --json displays variables update 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111 --allow-multiple --raw '{"defaultValues":[]}'`,
1380
+ command: `zinkee --json displays variables update 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111 --allow-multiple --raw '{"defaultValues":[]}'`,
1485
1381
  raw: `{
1486
1382
  "allowMultiple": true,
1487
1383
  "defaultValues": []
1488
- }`,
1384
+ }`
1489
1385
  },
1490
1386
  {
1491
1387
  description: "Change a DATE variable to use last12Months.",
1492
- command:
1493
- 'zinkee --json displays variables update 0f6f062f-1478-4df2-96a1-c495d037d260 bbbbbbbb-2222-4222-a222-222222222222 --date-mode dynamic --date-dynamic-option last12Months',
1388
+ command: "zinkee --json displays variables update 0f6f062f-1478-4df2-96a1-c495d037d260 bbbbbbbb-2222-4222-a222-222222222222 --date-mode dynamic --date-dynamic-option last12Months",
1494
1389
  raw: `{
1495
1390
  "date": {
1496
1391
  "mode": "dynamic",
1497
1392
  "dynamicOption": "last12Months"
1498
1393
  }
1499
- }`,
1500
- },
1501
- ]),
1502
- "displays widgets create": buildCommandExamples([
1394
+ }`
1395
+ }
1396
+ ],
1397
+ "displays widgets create": [
1503
1398
  {
1504
- description:
1505
- "Create a TABLE widget (CLI normalises --type table to TABLE_OR_SUBTABLE).",
1506
- command:
1507
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type table --name Customers --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":8}' --field contact-name --field status --field amount --sort '{"fieldId":"contact-name","direction":"ASC"}'`,
1399
+ description: "Create a TABLE widget (CLI normalises --type table to TABLE_OR_SUBTABLE).",
1400
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type table --name Customers --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":8}' --field contact-name --field status --field amount --sort '{"fieldId":"contact-name","direction":"ASC"}'`,
1508
1401
  raw: `{
1509
1402
  "type": "TABLE_OR_SUBTABLE",
1510
1403
  "source": {
@@ -1529,13 +1422,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1529
1422
  response: `{
1530
1423
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
1531
1424
  "widgetId": "11111111-1111-4111-a111-111111111111"
1532
- }`,
1425
+ }`
1533
1426
  },
1534
1427
  {
1535
- description:
1536
- "Create a TABLE widget with locked fields: contact-name locked permanently (no conditions) and status locked while invoice-number is empty, with before/after lock messages.",
1537
- command:
1538
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type table --name Invoices --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":8}' --field contact-name --field invoice-number --field status --field amount --lock-field contact-name --lock-condition "status:invoice-number:is_empty" --lock-message-before "status:Status locks until the invoice number is set." --lock-message-after "status:Status is locked because the invoice number is missing."`,
1428
+ description: "Create a TABLE widget with locked fields: contact-name locked permanently (no conditions) and status locked while invoice-number is empty, with before/after lock messages.",
1429
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type table --name Invoices --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":8}' --field contact-name --field invoice-number --field status --field amount --lock-field contact-name --lock-condition "status:invoice-number:is_empty" --lock-message-before "status:Status locks until the invoice number is set." --lock-message-after "status:Status is locked because the invoice number is missing."`,
1539
1430
  raw: `{
1540
1431
  "type": "TABLE_OR_SUBTABLE",
1541
1432
  "source": {
@@ -1573,13 +1464,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1573
1464
  response: `{
1574
1465
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
1575
1466
  "widgetId": "11111111-1111-4111-a111-111111111111"
1576
- }`,
1467
+ }`
1577
1468
  },
1578
1469
  {
1579
- description:
1580
- "Create a DETAIL widget on a tab. The rich placement is easier via --raw.",
1581
- command:
1582
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --raw '{"type":"DETAIL","source":{"originResourceId":"2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e","isOriginSubSchema":false},"placement":{"tabId":"tab-detail","layout":{"x":0,"y":0,"w":6,"h":10}},"presentation":{"name":"Customer detail"},"behavior":{"readOnly":true},"view":{"fields":["contact-name","contact-email","status","amount"]}}'`,
1470
+ description: "Create a DETAIL widget on a tab. The rich placement is easier via --raw.",
1471
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --raw '{"type":"DETAIL","source":{"originResourceId":"2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e","isOriginSubSchema":false},"placement":{"tabId":"tab-detail","layout":{"x":0,"y":0,"w":6,"h":10}},"presentation":{"name":"Customer detail"},"behavior":{"readOnly":true},"view":{"fields":["contact-name","contact-email","status","amount"]}}'`,
1583
1472
  raw: `{
1584
1473
  "type": "DETAIL",
1585
1474
  "source": {
@@ -1595,12 +1484,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1595
1484
  "view": {
1596
1485
  "fields": ["contact-name", "contact-email", "status", "amount"]
1597
1486
  }
1598
- }`,
1487
+ }`
1599
1488
  },
1600
1489
  {
1601
1490
  description: "Create a KPI widget computing SUM(amount).",
1602
- command:
1603
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type KPI --name "Total revenue" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":3,"h":3}' --calc SUM --calc-field amount --kpi-config '{"format":"currency","decimals":2}'`,
1491
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type KPI --name "Total revenue" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":3,"h":3}' --calc SUM --calc-field amount --kpi-config '{"format":"currency","decimals":2}'`,
1604
1492
  raw: `{
1605
1493
  "type": "KPI",
1606
1494
  "source": {
@@ -1616,12 +1504,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1616
1504
  "fieldCalc": "amount",
1617
1505
  "config": { "format": "currency", "decimals": 2 }
1618
1506
  }
1619
- }`,
1507
+ }`
1620
1508
  },
1621
1509
  {
1622
1510
  description: "Create a CHART widget with a daily time-serie x-axis.",
1623
- command:
1624
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type CHART --name "Revenue by day" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":8,"h":6}' --chart-type lines --x-axis-field due-date --x-axis-date-format DATE --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#4B9CD3","axisType":"PRIMARY"}' --legend '{"position":"bottom"}'`,
1511
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type CHART --name "Revenue by day" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":8,"h":6}' --chart-type lines --x-axis-field due-date --x-axis-date-format DATE --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#4B9CD3","axisType":"PRIMARY"}' --legend '{"position":"bottom"}'`,
1625
1512
  raw: `{
1626
1513
  "type": "CHART",
1627
1514
  "source": {
@@ -1647,12 +1534,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1647
1534
  ],
1648
1535
  "legend": { "position": "bottom" }
1649
1536
  }
1650
- }`,
1537
+ }`
1651
1538
  },
1652
1539
  {
1653
1540
  description: "Create a bars CHART widget with a monthly time-serie x-axis and two y-axis series.",
1654
- command:
1655
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type CHART --name "Revenue by month" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":8,"h":6}' --chart-type bars --x-axis-field due-date --x-axis-date-format MONTH_YEAR --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#4B9CD3","axisType":"PRIMARY"}' --y-axis-serie '{"typeCalc":"COUNT","fieldCalc":"contact-name","color":"#E57373","axisType":"SECONDARY"}' --legend '{"position":"bottom"}'`,
1541
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type CHART --name "Revenue by month" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":8,"h":6}' --chart-type bars --x-axis-field due-date --x-axis-date-format MONTH_YEAR --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#4B9CD3","axisType":"PRIMARY"}' --y-axis-serie '{"typeCalc":"COUNT","fieldCalc":"contact-name","color":"#E57373","axisType":"SECONDARY"}' --legend '{"position":"bottom"}'`,
1656
1542
  raw: `{
1657
1543
  "type": "CHART",
1658
1544
  "source": {
@@ -1684,12 +1570,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1684
1570
  ],
1685
1571
  "legend": { "position": "bottom" }
1686
1572
  }
1687
- }`,
1573
+ }`
1688
1574
  },
1689
1575
  {
1690
1576
  description: "Create a bars CHART widget with a quarterly time-serie x-axis.",
1691
- command:
1692
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type CHART --name "Revenue by quarter" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":8,"h":6}' --chart-type bars --x-axis-field due-date --x-axis-date-format QUARTER_YEAR --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#4B9CD3","axisType":"PRIMARY"}' --legend '{"position":"bottom"}'`,
1577
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type CHART --name "Revenue by quarter" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":8,"h":6}' --chart-type bars --x-axis-field due-date --x-axis-date-format QUARTER_YEAR --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#4B9CD3","axisType":"PRIMARY"}' --legend '{"position":"bottom"}'`,
1693
1578
  raw: `{
1694
1579
  "type": "CHART",
1695
1580
  "source": {
@@ -1715,12 +1600,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1715
1600
  ],
1716
1601
  "legend": { "position": "bottom" }
1717
1602
  }
1718
- }`,
1603
+ }`
1719
1604
  },
1720
1605
  {
1721
1606
  description: "Create a CHART widget with a yearly time-serie x-axis.",
1722
- command:
1723
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type CHART --name "Revenue by year" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":8,"h":6}' --chart-type lines --x-axis-field due-date --x-axis-date-format YEAR --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#4B9CD3","axisType":"PRIMARY"}' --legend '{"position":"bottom"}'`,
1607
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type CHART --name "Revenue by year" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":8,"h":6}' --chart-type lines --x-axis-field due-date --x-axis-date-format YEAR --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#4B9CD3","axisType":"PRIMARY"}' --legend '{"position":"bottom"}'`,
1724
1608
  raw: `{
1725
1609
  "type": "CHART",
1726
1610
  "source": {
@@ -1746,13 +1630,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1746
1630
  ],
1747
1631
  "legend": { "position": "bottom" }
1748
1632
  }
1749
- }`,
1633
+ }`
1750
1634
  },
1751
1635
  {
1752
- description:
1753
- "Create a TIMELINE widget via flags. The typed view state lives in view.viewAdditionalProperties.viewState; field references there must be UUIDs (slugs are only resolved in --field). cardConfig uses category1/category2/category4 (no category3). Use --view-state for UI scalars (granularity, sidebarWidth, show* ...).",
1754
- command:
1755
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type TIMELINE --name "Customer schedule" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":6}' --field c60b8526-5835-4c9f-aecd-9a16c7704a34 --field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --start-date-field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --end-date-field e5f6a7b8-c9d0-1e2f-3a4b-5c6d7e8f9012 --label-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --group-field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --subgroup-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --progress-field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --card-title-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --card-category1-field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --card-category2-field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --card-category4-field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --card-description-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --view-state '{"granularity":"month","sidebarWidth":300,"showUngroupedEvents":true,"showUnsubgroupedEvents":true}'`,
1636
+ description: "Create a TIMELINE widget via flags. The typed view state lives in view.viewAdditionalProperties.viewState; field references there must be UUIDs (slugs are only resolved in --field). cardConfig uses category1/category2/category4 (no category3). Use --view-state for UI scalars (granularity, sidebarWidth, show* ...).",
1637
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type TIMELINE --name "Customer schedule" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":6}' --field c60b8526-5835-4c9f-aecd-9a16c7704a34 --field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --start-date-field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --end-date-field e5f6a7b8-c9d0-1e2f-3a4b-5c6d7e8f9012 --label-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --group-field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --subgroup-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --progress-field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --card-title-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --card-category1-field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --card-category2-field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --card-category4-field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --card-description-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --view-state '{"granularity":"month","sidebarWidth":300,"showUngroupedEvents":true,"showUnsubgroupedEvents":true}'`,
1756
1638
  raw: `{
1757
1639
  "type": "TIMELINE",
1758
1640
  "source": {
@@ -1794,13 +1676,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1794
1676
  }
1795
1677
  }
1796
1678
  }
1797
- }`,
1679
+ }`
1798
1680
  },
1799
1681
  {
1800
- description:
1801
- "Create a KANBAN widget via flags. The typed view state lives in view.viewAdditionalProperties.viewState; field references there must be UUIDs (slugs are only resolved in --field). cardConfig uses category1/category2/category3 (no category4). --aggregation-method/--aggregation-field set the card aggregation; use --view-state for UI scalars.",
1802
- command:
1803
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type KANBAN --name "Status board" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":8}' --field c60b8526-5835-4c9f-aecd-9a16c7704a34 --field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --column-field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --swimlane-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --card-title-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --card-category1-field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --card-category2-field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --card-category3-field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --card-description-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --aggregation-method sum --aggregation-field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --view-state '{"hideEmptyColumns":false,"showNoValueColumn":true,"showNoValueSwimlane":true}'`,
1682
+ description: "Create a KANBAN widget via flags. The typed view state lives in view.viewAdditionalProperties.viewState; field references there must be UUIDs (slugs are only resolved in --field). cardConfig uses category1/category2/category3 (no category4). --aggregation-method/--aggregation-field set the card aggregation; use --view-state for UI scalars.",
1683
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type KANBAN --name "Status board" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":8}' --field c60b8526-5835-4c9f-aecd-9a16c7704a34 --field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --column-field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --swimlane-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --card-title-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --card-category1-field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --card-category2-field d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90 --card-category3-field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --card-description-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --aggregation-method sum --aggregation-field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --view-state '{"hideEmptyColumns":false,"showNoValueColumn":true,"showNoValueSwimlane":true}'`,
1804
1684
  raw: `{
1805
1685
  "type": "KANBAN",
1806
1686
  "source": {
@@ -1841,13 +1721,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1841
1721
  }
1842
1722
  }
1843
1723
  }
1844
- }`,
1724
+ }`
1845
1725
  },
1846
1726
  {
1847
- description:
1848
- "Create a HIERARCHY widget via flags. Declare columns once (--hierarchy-label, repeatable --hierarchy-info <id:name>, --hierarchy-number <id:name:aggregation>), map the root level (the view's own table) with --hierarchy-root-* and add each child level as a JSON object with --hierarchy-child. label is required per level; info/number mappings are optional. Column ids (e.g. col_1779975207355_zfndknslw) are unique opaque identifiers you choose — not the column name — and are reused as columnId in every mapping. All field references must be UUIDs.",
1849
- command:
1850
- `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type HIERARCHY --name "Org tree" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":6}' --field c60b8526-5835-4c9f-aecd-9a16c7704a34 --field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --hierarchy-label "Name" --hierarchy-info "col_1779975207355_zfndknslw:Status" --hierarchy-info "col_1779975243018_qm4t7xb2pa:Description" --hierarchy-number "col_1779975261490_h8kd3nv9ws:Total amount:SUM" --hierarchy-root-name "Customers" --hierarchy-root-label-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --hierarchy-root-info "col_1779975207355_zfndknslw:a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890" --hierarchy-root-number "col_1779975261490_h8kd3nv9ws:c52efe3f-2825-4c60-a7e3-34dd4c1ce043" --hierarchy-child '{"name":"Projects","schemaId":"3ec9cdef-7e0a-4cdd-8019-8fb9281f5d6f","childFieldId":"80deefae-af3d-4000-b322-bfe1594f8073","labelFieldId":"50dbef0b-7e0a-4fdd-8019-8fb9281f5d70","infoMappings":[{"columnId":"col_1779975243018_qm4t7xb2pa","fieldId":"60dcef0c-8f1b-4eee-9120-9fc0392f6e71"}],"numberMappings":[{"columnId":"col_1779975261490_h8kd3nv9ws","fieldId":"70ddef0d-9f2c-4fff-a221-afd0493f7f72"}]}'`,
1727
+ description: "Create a HIERARCHY widget via flags. Declare columns once (--hierarchy-label, repeatable --hierarchy-info <id:name>, --hierarchy-number <id:name:aggregation>), map the root level (the view's own table) with --hierarchy-root-* and add each child level as a JSON object with --hierarchy-child. label is required per level; info/number mappings are optional. Column ids (e.g. col_1779975207355_zfndknslw) are unique opaque identifiers you choose \u2014 not the column name \u2014 and are reused as columnId in every mapping. All field references must be UUIDs.",
1728
+ command: `zinkee --json displays widgets create 0f6f062f-1478-4df2-96a1-c495d037d260 --type HIERARCHY --name "Org tree" --origin-resource 2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e --layout '{"x":0,"y":0,"w":12,"h":6}' --field c60b8526-5835-4c9f-aecd-9a16c7704a34 --field a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890 --field c52efe3f-2825-4c60-a7e3-34dd4c1ce043 --hierarchy-label "Name" --hierarchy-info "col_1779975207355_zfndknslw:Status" --hierarchy-info "col_1779975243018_qm4t7xb2pa:Description" --hierarchy-number "col_1779975261490_h8kd3nv9ws:Total amount:SUM" --hierarchy-root-name "Customers" --hierarchy-root-label-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --hierarchy-root-info "col_1779975207355_zfndknslw:a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890" --hierarchy-root-number "col_1779975261490_h8kd3nv9ws:c52efe3f-2825-4c60-a7e3-34dd4c1ce043" --hierarchy-child '{"name":"Projects","schemaId":"3ec9cdef-7e0a-4cdd-8019-8fb9281f5d6f","childFieldId":"80deefae-af3d-4000-b322-bfe1594f8073","labelFieldId":"50dbef0b-7e0a-4fdd-8019-8fb9281f5d70","infoMappings":[{"columnId":"col_1779975243018_qm4t7xb2pa","fieldId":"60dcef0c-8f1b-4eee-9120-9fc0392f6e71"}],"numberMappings":[{"columnId":"col_1779975261490_h8kd3nv9ws","fieldId":"70ddef0d-9f2c-4fff-a221-afd0493f7f72"}]}'`,
1851
1729
  raw: `{
1852
1730
  "type": "HIERARCHY",
1853
1731
  "source": {
@@ -1901,14 +1779,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1901
1779
  ]
1902
1780
  }
1903
1781
  }
1904
- }`,
1905
- },
1906
- ]),
1907
- "displays widgets update": buildCommandExamples([
1782
+ }`
1783
+ }
1784
+ ],
1785
+ "displays widgets update": [
1908
1786
  {
1909
1787
  description: "Move placement, update view columns, rename the widget and lock it.",
1910
- command:
1911
- `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --layout '{"x":1,"y":2,"w":8,"h":4}' --field contact-name --field status --field amount --name "Revenue Updated" --widget-read-only`,
1788
+ command: `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --layout '{"x":1,"y":2,"w":8,"h":4}' --field contact-name --field status --field amount --name "Revenue Updated" --widget-read-only`,
1912
1789
  raw: `{
1913
1790
  "placement": {
1914
1791
  "layout": { "x": 1, "y": 2, "w": 8, "h": 4 }
@@ -1922,13 +1799,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1922
1799
  response: `{
1923
1800
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
1924
1801
  "widgetId": "11111111-1111-4111-a111-111111111111"
1925
- }`,
1802
+ }`
1926
1803
  },
1927
1804
  {
1928
- description:
1929
- "Add query filters with --filter. The CLI parses the expression and emits the structured comparisonOperator payload the API expects.",
1930
- command:
1931
- `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --filter "status:eq:2" --filter "amount:gte:500"`,
1805
+ description: "Add query filters with --filter. The CLI parses the expression and emits the structured comparisonOperator payload the API expects.",
1806
+ command: `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --filter "status:eq:2" --filter "amount:gte:500"`,
1932
1807
  raw: `{
1933
1808
  "query": {
1934
1809
  "filters": [
@@ -1944,13 +1819,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1944
1819
  }
1945
1820
  ]
1946
1821
  }
1947
- }`,
1822
+ }`
1948
1823
  },
1949
1824
  {
1950
- description:
1951
- "Fall back to --raw for comparators the parser does not cover yet (e.g. NOT_CONTAINS, RANGE).",
1952
- command:
1953
- `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --raw '{"query":{"filters":[{"origin":{"fieldId":"due-date"},"comparisonOperator":"RANGE","values":["2025-01-01","2025-12-31"]}]}}'`,
1825
+ description: "Fall back to --raw for comparators the parser does not cover yet (e.g. NOT_CONTAINS, RANGE).",
1826
+ command: `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --raw '{"query":{"filters":[{"origin":{"fieldId":"due-date"},"comparisonOperator":"RANGE","values":["2025-01-01","2025-12-31"]}]}}'`,
1954
1827
  raw: `{
1955
1828
  "query": {
1956
1829
  "filters": [
@@ -1961,25 +1834,22 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
1961
1834
  }
1962
1835
  ]
1963
1836
  }
1964
- }`,
1837
+ }`
1965
1838
  },
1966
1839
  {
1967
1840
  description: "Hide the add, delete and filter buttons.",
1968
- command:
1969
- 'zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --hide-add-button --hide-delete-button --hide-filter-button',
1841
+ command: "zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --hide-add-button --hide-delete-button --hide-filter-button",
1970
1842
  raw: `{
1971
1843
  "behavior": {
1972
1844
  "hideAddButton": true,
1973
1845
  "hideDeleteButton": true,
1974
1846
  "hideFilterButton": true
1975
1847
  }
1976
- }`,
1848
+ }`
1977
1849
  },
1978
1850
  {
1979
- description:
1980
- "Configure locked fields (replaces the stored configuration): contact-name locked permanently, status locked while invoice-number is empty. Empty conditions = always locked; conditions combine with AND. Enforcement happens in display widgets only, never in the database view.",
1981
- command:
1982
- `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --lock-field contact-name --lock-condition "status:invoice-number:is_empty" --lock-message-before "status:Status locks until the invoice number is set." --lock-message-after "status:Status is locked because the invoice number is missing."`,
1851
+ description: "Configure locked fields (replaces the stored configuration): contact-name locked permanently, status locked while invoice-number is empty. Empty conditions = always locked; conditions combine with AND. Enforcement happens in display widgets only, never in the database view.",
1852
+ command: `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --lock-field contact-name --lock-condition "status:invoice-number:is_empty" --lock-message-before "status:Status locks until the invoice number is set." --lock-message-after "status:Status is locked because the invoice number is missing."`,
1983
1853
  raw: `{
1984
1854
  "behavior": {
1985
1855
  "lockedFields": [
@@ -2005,32 +1875,29 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2005
1875
  response: `{
2006
1876
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
2007
1877
  "widgetId": "11111111-1111-4111-a111-111111111111"
2008
- }`,
1878
+ }`
2009
1879
  },
2010
1880
  {
2011
1881
  description: "Clear the locked-fields configuration.",
2012
- command:
2013
- 'zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --clear-locked-fields',
1882
+ command: "zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --clear-locked-fields",
2014
1883
  raw: `{
2015
1884
  "behavior": { "lockedFields": [] }
2016
- }`,
1885
+ }`
2017
1886
  },
2018
1887
  {
2019
1888
  description: "Update the KPI aggregation to AVG with one-decimal format.",
2020
- command:
2021
- `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 33333333-3333-4333-a333-333333333333 --calc AVG --calc-field amount --kpi-config '{"format":"number","decimals":1}'`,
1889
+ command: `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 33333333-3333-4333-a333-333333333333 --calc AVG --calc-field amount --kpi-config '{"format":"number","decimals":1}'`,
2022
1890
  raw: `{
2023
1891
  "kpi": {
2024
1892
  "typeCalc": "AVG",
2025
1893
  "fieldCalc": "amount",
2026
1894
  "config": { "format": "number", "decimals": 1 }
2027
1895
  }
2028
- }`,
1896
+ }`
2029
1897
  },
2030
1898
  {
2031
1899
  description: "Replace the chart series with quarterly lines.",
2032
- command:
2033
- `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 22222222-2222-4222-a222-222222222222 --chart-type lines --x-axis-field due-date --x-axis-date-format QUARTER_YEAR --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#2E7D32","axisType":"PRIMARY"}'`,
1900
+ command: `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 22222222-2222-4222-a222-222222222222 --chart-type lines --x-axis-field due-date --x-axis-date-format QUARTER_YEAR --x-axis-time-series --y-axis-serie '{"typeCalc":"SUM","fieldCalc":"amount","color":"#2E7D32","axisType":"PRIMARY"}'`,
2034
1901
  raw: `{
2035
1902
  "chart": {
2036
1903
  "chartType": "lines",
@@ -2046,12 +1913,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2046
1913
  }
2047
1914
  ]
2048
1915
  }
2049
- }`,
1916
+ }`
2050
1917
  },
2051
1918
  {
2052
1919
  description: "Rewrite the widget bindings (requires --raw because the CLI has no --binding flag).",
2053
- command:
2054
- `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --raw '{"bindings":{"variableMap":{"aaaaaaaa-1111-4111-a111-111111111111":"contact-name","cccccccc-3333-4333-a333-333333333333":"owner"}}}'`,
1920
+ command: `zinkee --json displays widgets update 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111 --raw '{"bindings":{"variableMap":{"aaaaaaaa-1111-4111-a111-111111111111":"contact-name","cccccccc-3333-4333-a333-333333333333":"owner"}}}'`,
2055
1921
  raw: `{
2056
1922
  "bindings": {
2057
1923
  "variableMap": {
@@ -2059,14 +1925,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2059
1925
  "cccccccc-3333-4333-a333-333333333333": "owner"
2060
1926
  }
2061
1927
  }
2062
- }`,
2063
- },
2064
- ]),
2065
- "displays navigation-targets create": buildCommandExamples([
1928
+ }`
1929
+ }
1930
+ ],
1931
+ "displays navigation-targets create": [
2066
1932
  {
2067
1933
  description: "Create a navigation target with a visible label.",
2068
- command:
2069
- 'zinkee --json displays navigation-targets create 0f6f062f-1478-4df2-96a1-c495d037d260 --source-widget 11111111-1111-4111-a111-111111111111 --target-display ef012345-6789-4abc-8def-0123456789ab --target-variable aaaaaaaa-1111-4111-a111-111111111111 --label "Open customer"',
1934
+ command: 'zinkee --json displays navigation-targets create 0f6f062f-1478-4df2-96a1-c495d037d260 --source-widget 11111111-1111-4111-a111-111111111111 --target-display ef012345-6789-4abc-8def-0123456789ab --target-variable aaaaaaaa-1111-4111-a111-111111111111 --label "Open customer"',
2070
1935
  raw: `{
2071
1936
  "sourceWidgetId": "11111111-1111-4111-a111-111111111111",
2072
1937
  "targetDisplayId": "ef012345-6789-4abc-8def-0123456789ab",
@@ -2076,56 +1941,50 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2076
1941
  response: `{
2077
1942
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
2078
1943
  "navigationTargetId": "nav-target-customer"
2079
- }`,
1944
+ }`
2080
1945
  },
2081
1946
  {
2082
1947
  description: "Create a navigation target without a label (uses the target display name).",
2083
- command:
2084
- 'zinkee --json displays navigation-targets create 0f6f062f-1478-4df2-96a1-c495d037d260 --source-widget 22222222-2222-4222-a222-222222222222 --target-display ef012345-6789-4abc-8def-0123456789ab --target-variable aaaaaaaa-1111-4111-a111-111111111111',
1948
+ command: "zinkee --json displays navigation-targets create 0f6f062f-1478-4df2-96a1-c495d037d260 --source-widget 22222222-2222-4222-a222-222222222222 --target-display ef012345-6789-4abc-8def-0123456789ab --target-variable aaaaaaaa-1111-4111-a111-111111111111",
2085
1949
  raw: `{
2086
1950
  "sourceWidgetId": "22222222-2222-4222-a222-222222222222",
2087
1951
  "targetDisplayId": "ef012345-6789-4abc-8def-0123456789ab",
2088
1952
  "targetVariableId": "aaaaaaaa-1111-4111-a111-111111111111"
2089
- }`,
2090
- },
2091
- ]),
2092
- "displays navigation-targets update": buildCommandExamples([
1953
+ }`
1954
+ }
1955
+ ],
1956
+ "displays navigation-targets update": [
2093
1957
  {
2094
1958
  description: "Change just the label.",
2095
- command:
2096
- 'zinkee --json displays navigation-targets update 0f6f062f-1478-4df2-96a1-c495d037d260 nav-target-customer --label "Go to customer"',
1959
+ command: 'zinkee --json displays navigation-targets update 0f6f062f-1478-4df2-96a1-c495d037d260 nav-target-customer --label "Go to customer"',
2097
1960
  raw: `{
2098
1961
  "label": "Go to customer"
2099
1962
  }`,
2100
1963
  response: `{
2101
1964
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
2102
1965
  "navigationTargetId": "nav-target-customer"
2103
- }`,
1966
+ }`
2104
1967
  },
2105
1968
  {
2106
1969
  description: "Redirect the target to another display/variable pair.",
2107
- command:
2108
- 'zinkee --json displays navigation-targets update 0f6f062f-1478-4df2-96a1-c495d037d260 nav-target-customer --target-display 6b7c8d9e-0f12-3456-789a-bcdef0123456 --target-variable bbbbbbbb-2222-4222-a222-222222222222',
1970
+ command: "zinkee --json displays navigation-targets update 0f6f062f-1478-4df2-96a1-c495d037d260 nav-target-customer --target-display 6b7c8d9e-0f12-3456-789a-bcdef0123456 --target-variable bbbbbbbb-2222-4222-a222-222222222222",
2109
1971
  raw: `{
2110
1972
  "targetDisplayId": "6b7c8d9e-0f12-3456-789a-bcdef0123456",
2111
1973
  "targetVariableId": "bbbbbbbb-2222-4222-a222-222222222222"
2112
- }`,
1974
+ }`
2113
1975
  },
2114
1976
  {
2115
1977
  description: "Change the source widget.",
2116
- command:
2117
- 'zinkee --json displays navigation-targets update 0f6f062f-1478-4df2-96a1-c495d037d260 nav-target-customer --source-widget 44444444-4444-4444-a444-444444444444',
1978
+ command: "zinkee --json displays navigation-targets update 0f6f062f-1478-4df2-96a1-c495d037d260 nav-target-customer --source-widget 44444444-4444-4444-a444-444444444444",
2118
1979
  raw: `{
2119
1980
  "sourceWidgetId": "44444444-4444-4444-a444-444444444444"
2120
- }`,
2121
- },
2122
- ]),
2123
- "displays cross-widget-filter set": buildCommandExamples([
1981
+ }`
1982
+ }
1983
+ ],
1984
+ "displays cross-widget-filter set": [
2124
1985
  {
2125
- description:
2126
- "Single configuration with flags: link one source widget/field to several targets. The whole array is replaced.",
2127
- command:
2128
- 'zinkee --json displays cross-widget-filter set 0f6f062f-1478-4df2-96a1-c495d037d260 --source-widget 11111111-1111-4111-a111-111111111111 --source-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --target 22222222-2222-4222-a222-222222222222:c60b8526-5835-4c9f-aecd-9a16c7704a34 --target 33333333-3333-4333-a333-333333333333:c60b8526-5835-4c9f-aecd-9a16c7704a34',
1986
+ description: "Single configuration with flags: link one source widget/field to several targets. The whole array is replaced.",
1987
+ command: "zinkee --json displays cross-widget-filter set 0f6f062f-1478-4df2-96a1-c495d037d260 --source-widget 11111111-1111-4111-a111-111111111111 --source-field c60b8526-5835-4c9f-aecd-9a16c7704a34 --target 22222222-2222-4222-a222-222222222222:c60b8526-5835-4c9f-aecd-9a16c7704a34 --target 33333333-3333-4333-a333-333333333333:c60b8526-5835-4c9f-aecd-9a16c7704a34",
2129
1988
  raw: `[
2130
1989
  {
2131
1990
  "source": {
@@ -2143,13 +2002,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2143
2002
  }
2144
2003
  ]
2145
2004
  }
2146
- ]`,
2005
+ ]`
2147
2006
  },
2148
2007
  {
2149
- description:
2150
- "Several independent configurations with --raw (each source filters its own targets). A widget cannot be a target of two configurations.",
2151
- command:
2152
- "zinkee --json displays cross-widget-filter set 0f6f062f-1478-4df2-96a1-c495d037d260 --raw '[{\"source\":{\"widgetId\":\"11111111-1111-4111-a111-111111111111\",\"fieldId\":\"c60b8526-5835-4c9f-aecd-9a16c7704a34\"},\"targets\":[{\"widgetId\":\"22222222-2222-4222-a222-222222222222\",\"fieldId\":\"c60b8526-5835-4c9f-aecd-9a16c7704a34\"}]},{\"source\":{\"widgetId\":\"44444444-4444-4444-a444-444444444444\",\"fieldId\":\"a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890\"},\"targets\":[{\"widgetId\":\"55555555-5555-4555-a555-555555555555\",\"fieldId\":\"a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890\"}]}]'",
2008
+ description: "Several independent configurations with --raw (each source filters its own targets). A widget cannot be a target of two configurations.",
2009
+ command: `zinkee --json displays cross-widget-filter set 0f6f062f-1478-4df2-96a1-c495d037d260 --raw '[{"source":{"widgetId":"11111111-1111-4111-a111-111111111111","fieldId":"c60b8526-5835-4c9f-aecd-9a16c7704a34"},"targets":[{"widgetId":"22222222-2222-4222-a222-222222222222","fieldId":"c60b8526-5835-4c9f-aecd-9a16c7704a34"}]},{"source":{"widgetId":"44444444-4444-4444-a444-444444444444","fieldId":"a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890"},"targets":[{"widgetId":"55555555-5555-4555-a555-555555555555","fieldId":"a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890"}]}]'`,
2153
2010
  raw: `[
2154
2011
  {
2155
2012
  "source": {
@@ -2175,13 +2032,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2175
2032
  }
2176
2033
  ]
2177
2034
  }
2178
- ]`,
2035
+ ]`
2179
2036
  },
2180
2037
  {
2181
- description:
2182
- "Hierarchy chain with --raw-file: a target of one configuration is the source of the next (click Parent → filters Child, click Child → filters Grandchild).",
2183
- command:
2184
- "zinkee --json displays cross-widget-filter set 0f6f062f-1478-4df2-96a1-c495d037d260 --raw-file cross-widget-filter.json",
2038
+ description: "Hierarchy chain with --raw-file: a target of one configuration is the source of the next (click Parent \u2192 filters Child, click Child \u2192 filters Grandchild).",
2039
+ command: "zinkee --json displays cross-widget-filter set 0f6f062f-1478-4df2-96a1-c495d037d260 --raw-file cross-widget-filter.json",
2185
2040
  raw: `[
2186
2041
  {
2187
2042
  "source": {
@@ -2207,10 +2062,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2207
2062
  }
2208
2063
  ]
2209
2064
  }
2210
- ]`,
2211
- },
2212
- ]),
2213
- "schemas list": buildCommandExamples([
2065
+ ]`
2066
+ }
2067
+ ],
2068
+ "schemas list": [
2214
2069
  {
2215
2070
  description: "List schemas in the workspace with folder and field counts.",
2216
2071
  command: "zinkee --json schemas list",
@@ -2241,10 +2096,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2241
2096
  "commentable": true,
2242
2097
  "fieldCount": 7
2243
2098
  }
2244
- ]`,
2245
- },
2246
- ]),
2247
- "schemas get": buildCommandExamples([
2099
+ ]`
2100
+ }
2101
+ ],
2102
+ "schemas get": [
2248
2103
  {
2249
2104
  description: "Get a schema with all its fields.",
2250
2105
  command: "zinkee --json schemas get contacts",
@@ -2303,7 +2158,7 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2303
2158
  "thousandsSeparator": true,
2304
2159
  "symbolEnabled": true,
2305
2160
  "symbolPosition": "before",
2306
- "symbolValue": "€"
2161
+ "symbolValue": "\u20AC"
2307
2162
  },
2308
2163
  "conditionalFormatting": []
2309
2164
  }
@@ -2573,20 +2428,20 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2573
2428
  "c60b8526-5835-4c9f-aecd-9a16c7704a34",
2574
2429
  "1d2e3f4a-5b6c-7d8e-9f01-23456789abcd"
2575
2430
  ]
2576
- }`,
2577
- },
2578
- ]),
2579
- "schemas delete": buildCommandExamples([
2431
+ }`
2432
+ }
2433
+ ],
2434
+ "schemas delete": [
2580
2435
  {
2581
2436
  description: "Delete a schema (also removes it from navigation folders).",
2582
2437
  command: "zinkee --json schemas delete contacts",
2583
2438
  response: `{
2584
2439
  "schemaId": "2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e",
2585
2440
  "deleted": true
2586
- }`,
2587
- },
2588
- ]),
2589
- "schemas fields list": buildCommandExamples([
2441
+ }`
2442
+ }
2443
+ ],
2444
+ "schemas fields list": [
2590
2445
  {
2591
2446
  description: "List the fields of a schema (fields are inlined in the schema resource).",
2592
2447
  command: "zinkee --json schemas fields list contacts",
@@ -2622,10 +2477,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2622
2477
  "buttonConfig": null
2623
2478
  }
2624
2479
  }
2625
- ]`,
2626
- },
2627
- ]),
2628
- "schemas fields get": buildCommandExamples([
2480
+ ]`
2481
+ }
2482
+ ],
2483
+ "schemas fields get": [
2629
2484
  {
2630
2485
  description: "Get a schema field (returns the full typed field contract).",
2631
2486
  command: "zinkee --json schemas fields get contacts status",
@@ -2656,10 +2511,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2656
2511
  }
2657
2512
  }
2658
2513
  }
2659
- }`,
2660
- },
2661
- ]),
2662
- "schemas fields delete": buildCommandExamples([
2514
+ }`
2515
+ }
2516
+ ],
2517
+ "schemas fields delete": [
2663
2518
  {
2664
2519
  description: "Delete a schema field.",
2665
2520
  command: "zinkee --json schemas fields delete contacts status",
@@ -2667,10 +2522,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2667
2522
  "schemaId": "2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e",
2668
2523
  "fieldId": "a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890",
2669
2524
  "slug": "status"
2670
- }`,
2671
- },
2672
- ]),
2673
- "records list": buildCommandExamples([
2525
+ }`
2526
+ }
2527
+ ],
2528
+ "records list": [
2674
2529
  {
2675
2530
  description: "List records with default pagination.",
2676
2531
  command: "zinkee --json records list contacts",
@@ -2704,14 +2559,14 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2704
2559
  "count": 2,
2705
2560
  "hasMore": false
2706
2561
  }
2707
- }`,
2562
+ }`
2708
2563
  },
2709
2564
  {
2710
2565
  description: "Paginate further into the result set.",
2711
- command: "zinkee --json records list contacts --limit 50 --offset 100",
2712
- },
2713
- ]),
2714
- "records get": buildCommandExamples([
2566
+ command: "zinkee --json records list contacts --limit 50 --offset 100"
2567
+ }
2568
+ ],
2569
+ "records get": [
2715
2570
  {
2716
2571
  description: "Get one record by id (values are keyed by field slug).",
2717
2572
  command: `zinkee --json records get contacts ${SAMPLE_UUID}`,
@@ -2725,10 +2580,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2725
2580
  "due-date": "2026-05-15T12:00:00Z",
2726
2581
  "owner": "6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d"
2727
2582
  }
2728
- }`,
2729
- },
2730
- ]),
2731
- "records delete": buildCommandExamples([
2583
+ }`
2584
+ }
2585
+ ],
2586
+ "records delete": [
2732
2587
  {
2733
2588
  description: "Delete one or more records by id (--record is repeatable).",
2734
2589
  command: `zinkee --json records delete contacts --record 550e8400-e29b-41d4-a716-446655440000 --record 6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d`,
@@ -2738,11 +2593,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2738
2593
  "6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d"
2739
2594
  ],
2740
2595
  "deleted": true
2741
- }`,
2596
+ }`
2742
2597
  },
2743
2598
  {
2744
- description:
2745
- "Delete many records listing one uuid per line in a file (merged with any --record flags and de-duplicated).",
2599
+ description: "Delete many records listing one uuid per line in a file (merged with any --record flags and de-duplicated).",
2746
2600
  command: `zinkee --json records delete contacts --records-file ./record-ids.txt`,
2747
2601
  response: `{
2748
2602
  "recordIds": [
@@ -2750,21 +2604,20 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2750
2604
  "6c8a3e0d-4e5f-4a1b-9c2d-3e4f5a6b7c8d"
2751
2605
  ],
2752
2606
  "deleted": true
2753
- }`,
2754
- },
2755
- ]),
2756
- "records clear": buildCommandExamples([
2607
+ }`
2608
+ }
2609
+ ],
2610
+ "records clear": [
2757
2611
  {
2758
- description:
2759
- "Delete every record from a schema's table. Heritage rules (CASCADE / SET NULL) propagate to child schemas asynchronously via the CDC pipeline.",
2612
+ description: "Delete every record from a schema's table. Heritage rules (CASCADE / SET NULL) propagate to child schemas asynchronously via the CDC pipeline.",
2760
2613
  command: "zinkee --json records clear contacts",
2761
2614
  response: `{
2762
2615
  "schemaId": "2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e",
2763
2616
  "cleared": true
2764
- }`,
2765
- },
2766
- ]),
2767
- "comments list": buildCommandExamples([
2617
+ }`
2618
+ }
2619
+ ],
2620
+ "comments list": [
2768
2621
  {
2769
2622
  description: "List comments on a record (content is an array of TEXT/MENTION items).",
2770
2623
  command: `zinkee --json comments list contacts ${SAMPLE_UUID}`,
@@ -2789,13 +2642,12 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2789
2642
  { "type": "TEXT", "value": " for follow up." }
2790
2643
  ]
2791
2644
  }
2792
- ]`,
2793
- },
2794
- ]),
2795
- "logs list": buildCommandExamples([
2645
+ ]`
2646
+ }
2647
+ ],
2648
+ "logs list": [
2796
2649
  {
2797
- description:
2798
- "List the change history for a record (CREATE entry plus UPDATE entries with before/after values per field).",
2650
+ description: "List the change history for a record (CREATE entry plus UPDATE entries with before/after values per field).",
2799
2651
  command: `zinkee --json logs list contacts ${SAMPLE_UUID}`,
2800
2652
  response: `[
2801
2653
  {
@@ -2831,10 +2683,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2831
2683
  "operation": "UPDATE"
2832
2684
  }
2833
2685
  }
2834
- ]`,
2835
- },
2836
- ]),
2837
- "navigation folders list": buildCommandExamples([
2686
+ ]`
2687
+ }
2688
+ ],
2689
+ "navigation folders list": [
2838
2690
  {
2839
2691
  description: "List navigation folders with embedded resources, sorted by order.",
2840
2692
  command: "zinkee --json navigation folders list",
@@ -2887,29 +2739,29 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2887
2739
  "resources": [],
2888
2740
  "additionalProperties": {}
2889
2741
  }
2890
- ]`,
2891
- },
2892
- ]),
2893
- "navigation folders get": buildCommandExamples([
2742
+ ]`
2743
+ }
2744
+ ],
2745
+ "navigation folders get": [
2894
2746
  {
2895
2747
  description: "Get a navigation folder by exact name or UUID.",
2896
- command: 'zinkee --json navigation folders get Finance',
2897
- },
2898
- ]),
2899
- "navigation folders delete": buildCommandExamples([
2748
+ command: "zinkee --json navigation folders get Finance"
2749
+ }
2750
+ ],
2751
+ "navigation folders delete": [
2900
2752
  {
2901
2753
  description: "Delete a navigation folder by exact name or UUID.",
2902
- command: 'zinkee --json navigation folders delete Finance',
2754
+ command: "zinkee --json navigation folders delete Finance",
2903
2755
  response: `{
2904
2756
  "folderId": "84a0fca4-37ef-4c83-a8ed-9ef67ad9324a",
2905
2757
  "name": "Finance Ops"
2906
- }`,
2907
- },
2908
- ]),
2909
- "teamspace folders list": buildCommandExamples([
2758
+ }`
2759
+ }
2760
+ ],
2761
+ "teamspace folders list": [
2910
2762
  {
2911
2763
  description: "List teamspace folders.",
2912
- command: "zinkee --json teamspace folders list",
2764
+ command: "zinkee --json teamspace folders list"
2913
2765
  },
2914
2766
  {
2915
2767
  description: "List teamspace folders with their published resources.",
@@ -2935,19 +2787,18 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2935
2787
  ],
2936
2788
  "additionalProperties": {}
2937
2789
  }
2938
- ]`,
2939
- },
2940
- ]),
2941
- "teamspace folders get": buildCommandExamples([
2790
+ ]`
2791
+ }
2792
+ ],
2793
+ "teamspace folders get": [
2942
2794
  {
2943
2795
  description: "Get a teamspace folder by exact name or UUID.",
2944
- command: 'zinkee --json teamspace folders get "Shared Dashboards"',
2945
- },
2946
- ]),
2947
- "teamspace folders delete": buildCommandExamples([
2796
+ command: 'zinkee --json teamspace folders get "Shared Dashboards"'
2797
+ }
2798
+ ],
2799
+ "teamspace folders delete": [
2948
2800
  {
2949
- description:
2950
- "Delete a teamspace folder. Its resources are moved to the returned target folder (root by default).",
2801
+ description: "Delete a teamspace folder. Its resources are moved to the returned target folder (root by default).",
2951
2802
  command: 'zinkee --json teamspace folders delete "Customer Success"',
2952
2803
  response: `{
2953
2804
  "folderId": "f45a251d-3ea0-4b41-bfe8-c0f44c8ad54a",
@@ -2957,20 +2808,20 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2957
2808
  "name": "root",
2958
2809
  "isRoot": true
2959
2810
  }
2960
- }`,
2961
- },
2962
- ]),
2963
- "files storage": buildCommandExamples([
2811
+ }`
2812
+ }
2813
+ ],
2814
+ "files storage": [
2964
2815
  {
2965
2816
  description: "Get the storage quota and current usage (bytes).",
2966
2817
  command: "zinkee --json files storage",
2967
2818
  response: `{
2968
2819
  "maxSize": 10737418240,
2969
2820
  "usedSize": 2147483648
2970
- }`,
2971
- },
2972
- ]),
2973
- "displays list": buildCommandExamples([
2821
+ }`
2822
+ }
2823
+ ],
2824
+ "displays list": [
2974
2825
  {
2975
2826
  description: "List displays in the workspace with variable and widget counts.",
2976
2827
  command: "zinkee --json displays list",
@@ -2983,7 +2834,7 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
2983
2834
  "widgetCount": 6,
2984
2835
  "folder": {
2985
2836
  "id": "b1a2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d",
2986
- "name": "📊 Executive",
2837
+ "name": "\u{1F4CA} Executive",
2987
2838
  "isRoot": false
2988
2839
  }
2989
2840
  },
@@ -3007,17 +2858,16 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3007
2858
  "widgetCount": 2,
3008
2859
  "folder": {
3009
2860
  "id": "b1a2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d",
3010
- "name": "📊 Executive",
2861
+ "name": "\u{1F4CA} Executive",
3011
2862
  "isRoot": false
3012
2863
  }
3013
2864
  }
3014
- ]`,
3015
- },
3016
- ]),
3017
- "displays get": buildCommandExamples([
2865
+ ]`
2866
+ }
2867
+ ],
2868
+ "displays get": [
3018
2869
  {
3019
- description:
3020
- "Get a display with its layout (tabs/freeformLayouts/slots), variables, widgets, cross-widget filter and navigation targets.",
2870
+ description: "Get a display with its layout (tabs/freeformLayouts/slots), variables, widgets, cross-widget filter and navigation targets.",
3021
2871
  command: "zinkee --json displays get 0f6f062f-1478-4df2-96a1-c495d037d260",
3022
2872
  response: `{
3023
2873
  "id": "0f6f062f-1478-4df2-96a1-c495d037d260",
@@ -3145,48 +2995,45 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3145
2995
  ],
3146
2996
  "folder": {
3147
2997
  "id": "b1a2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d",
3148
- "name": "📊 Executive",
2998
+ "name": "\u{1F4CA} Executive",
3149
2999
  "isRoot": false
3150
3000
  }
3151
- }`,
3152
- },
3153
- ]),
3154
- "displays update": buildCommandExamples([
3001
+ }`
3002
+ }
3003
+ ],
3004
+ "displays update": [
3155
3005
  {
3156
3006
  description: "Update only the display description.",
3157
- command:
3158
- 'zinkee --json displays update 0f6f062f-1478-4df2-96a1-c495d037d260 --description "Sales pipeline overview"',
3007
+ command: 'zinkee --json displays update 0f6f062f-1478-4df2-96a1-c495d037d260 --description "Sales pipeline overview"',
3159
3008
  raw: `{
3160
3009
  "description": "Sales pipeline overview"
3161
- }`,
3010
+ }`
3162
3011
  },
3163
3012
  {
3164
3013
  description: "Clear the display description.",
3165
- command:
3166
- 'zinkee --json displays update 0f6f062f-1478-4df2-96a1-c495d037d260 --description ""',
3014
+ command: 'zinkee --json displays update 0f6f062f-1478-4df2-96a1-c495d037d260 --description ""',
3167
3015
  raw: `{
3168
3016
  "description": ""
3169
- }`,
3017
+ }`
3170
3018
  },
3171
3019
  {
3172
3020
  description: "Rename a display (patch of top-level metadata only).",
3173
- command:
3174
- 'zinkee --json displays update 0f6f062f-1478-4df2-96a1-c495d037d260 --name "Pipeline overview (renamed)"',
3021
+ command: 'zinkee --json displays update 0f6f062f-1478-4df2-96a1-c495d037d260 --name "Pipeline overview (renamed)"',
3175
3022
  raw: `{
3176
3023
  "name": "Pipeline overview (renamed)"
3177
3024
  }`,
3178
3025
  response: `{
3179
3026
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260"
3180
- }`,
3181
- },
3182
- ]),
3183
- "displays delete": buildCommandExamples([
3027
+ }`
3028
+ }
3029
+ ],
3030
+ "displays delete": [
3184
3031
  {
3185
3032
  description: "Delete a display.",
3186
- command: "zinkee --json displays delete 0f6f062f-1478-4df2-96a1-c495d037d260",
3187
- },
3188
- ]),
3189
- "displays folders list": buildCommandExamples([
3033
+ command: "zinkee --json displays delete 0f6f062f-1478-4df2-96a1-c495d037d260"
3034
+ }
3035
+ ],
3036
+ "displays folders list": [
3190
3037
  {
3191
3038
  description: "List flat display folders (non-root folders plus the root bucket).",
3192
3039
  command: "zinkee --json displays folders list",
@@ -3203,10 +3050,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3203
3050
  "isRoot": true,
3204
3051
  "displayCount": 4
3205
3052
  }
3206
- ]`,
3207
- },
3208
- ]),
3209
- "displays folders create": buildCommandExamples([
3053
+ ]`
3054
+ }
3055
+ ],
3056
+ "displays folders create": [
3210
3057
  {
3211
3058
  description: "Create one flat display folder.",
3212
3059
  command: 'zinkee --json displays folders create --name "Executive Dashboards"',
@@ -3218,14 +3065,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3218
3065
  "name": "Executive Dashboards",
3219
3066
  "isRoot": false,
3220
3067
  "displayCount": 0
3221
- }`,
3222
- },
3223
- ]),
3224
- "displays folders update": buildCommandExamples([
3068
+ }`
3069
+ }
3070
+ ],
3071
+ "displays folders update": [
3225
3072
  {
3226
3073
  description: "Rename a display folder. The folder argument accepts a UUID or an exact name.",
3227
- command:
3228
- 'zinkee --json displays folders update "Executive Dashboards" --name "Executive Dashboards (2026)"',
3074
+ command: 'zinkee --json displays folders update "Executive Dashboards" --name "Executive Dashboards (2026)"',
3229
3075
  raw: `{
3230
3076
  "name": "Executive Dashboards (2026)"
3231
3077
  }`,
@@ -3234,10 +3080,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3234
3080
  "name": "Executive Dashboards (2026)",
3235
3081
  "isRoot": false,
3236
3082
  "displayCount": 2
3237
- }`,
3238
- },
3239
- ]),
3240
- "displays folders delete": buildCommandExamples([
3083
+ }`
3084
+ }
3085
+ ],
3086
+ "displays folders delete": [
3241
3087
  {
3242
3088
  description: "Delete a non-root display folder. Its displays move back to the root folder.",
3243
3089
  command: 'zinkee --json displays folders delete "Executive Dashboards"',
@@ -3246,14 +3092,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3246
3092
  "name": "Executive Dashboards",
3247
3093
  "isRoot": false,
3248
3094
  "displayCount": 2
3249
- }`,
3250
- },
3251
- ]),
3252
- "displays folders move": buildCommandExamples([
3095
+ }`
3096
+ }
3097
+ ],
3098
+ "displays folders move": [
3253
3099
  {
3254
3100
  description: "Move one display into a target folder by exact folder name.",
3255
- command:
3256
- 'zinkee --json displays folders move 0f6f062f-1478-4df2-96a1-c495d037d260 --to "Executive Dashboards"',
3101
+ command: 'zinkee --json displays folders move 0f6f062f-1478-4df2-96a1-c495d037d260 --to "Executive Dashboards"',
3257
3102
  raw: `{
3258
3103
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
3259
3104
  "targetFolderId": "e7a1c3d2-5f4b-4a6c-9d8e-1f2a3b4c5d6e"
@@ -3262,73 +3107,69 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3262
3107
  "id": "e7a1c3d2-5f4b-4a6c-9d8e-1f2a3b4c5d6e",
3263
3108
  "name": "Executive Dashboards",
3264
3109
  "isRoot": false
3265
- }`,
3266
- },
3267
- ]),
3268
- "displays layout get": buildCommandExamples([
3110
+ }`
3111
+ }
3112
+ ],
3113
+ "displays layout get": [
3269
3114
  {
3270
3115
  description: "Get the layout block of a display (template + tabs/freeformLayouts/slots).",
3271
- command: "zinkee --json displays layout get 0f6f062f-1478-4df2-96a1-c495d037d260",
3272
- },
3273
- ]),
3274
- "displays layout update": buildCommandExamples([
3116
+ command: "zinkee --json displays layout get 0f6f062f-1478-4df2-96a1-c495d037d260"
3117
+ }
3118
+ ],
3119
+ "displays layout update": [
3275
3120
  {
3276
3121
  description: "Replace the freeform layout of a display.",
3277
- command:
3278
- `zinkee --json displays layout update 0f6f062f-1478-4df2-96a1-c495d037d260 --template freeform --freeform-layouts '{"lg":[{"i":"widget-1","x":0,"y":0,"w":6,"h":5}]}'`,
3279
- },
3280
- ]),
3281
- "displays tabs list": buildCommandExamples([
3122
+ command: `zinkee --json displays layout update 0f6f062f-1478-4df2-96a1-c495d037d260 --template freeform --freeform-layouts '{"lg":[{"i":"widget-1","x":0,"y":0,"w":6,"h":5}]}'`
3123
+ }
3124
+ ],
3125
+ "displays tabs list": [
3282
3126
  {
3283
3127
  description: "List the tabs of a display (only meaningful when the layout template uses tabs).",
3284
- command: "zinkee --json displays tabs list 0f6f062f-1478-4df2-96a1-c495d037d260",
3285
- },
3286
- ]),
3287
- "displays tabs delete": buildCommandExamples([
3128
+ command: "zinkee --json displays tabs list 0f6f062f-1478-4df2-96a1-c495d037d260"
3129
+ }
3130
+ ],
3131
+ "displays tabs delete": [
3288
3132
  {
3289
3133
  description: "Delete a tab by id.",
3290
3134
  command: "zinkee --json displays tabs delete 0f6f062f-1478-4df2-96a1-c495d037d260 tab-main",
3291
3135
  response: `{
3292
3136
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
3293
3137
  "tabId": "tab-main"
3294
- }`,
3295
- },
3296
- ]),
3297
- "displays variables list": buildCommandExamples([
3138
+ }`
3139
+ }
3140
+ ],
3141
+ "displays variables list": [
3298
3142
  {
3299
3143
  description: "List the variables of a display.",
3300
- command: "zinkee --json displays variables list 0f6f062f-1478-4df2-96a1-c495d037d260",
3301
- },
3302
- ]),
3303
- "displays variables get": buildCommandExamples([
3144
+ command: "zinkee --json displays variables list 0f6f062f-1478-4df2-96a1-c495d037d260"
3145
+ }
3146
+ ],
3147
+ "displays variables get": [
3304
3148
  {
3305
3149
  description: "Get one variable by id.",
3306
- command:
3307
- "zinkee --json displays variables get 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111",
3308
- },
3309
- ]),
3310
- "displays variables delete": buildCommandExamples([
3150
+ command: "zinkee --json displays variables get 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111"
3151
+ }
3152
+ ],
3153
+ "displays variables delete": [
3311
3154
  {
3312
3155
  description: "Delete a variable.",
3313
- command:
3314
- "zinkee --json displays variables delete 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111",
3156
+ command: "zinkee --json displays variables delete 0f6f062f-1478-4df2-96a1-c495d037d260 aaaaaaaa-1111-4111-a111-111111111111",
3315
3157
  response: `{
3316
3158
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
3317
3159
  "variableId": "aaaaaaaa-1111-4111-a111-111111111111"
3318
- }`,
3319
- },
3320
- ]),
3321
- "displays widgets list": buildCommandExamples([
3160
+ }`
3161
+ }
3162
+ ],
3163
+ "displays widgets list": [
3322
3164
  {
3323
3165
  description: "List the widgets of a display.",
3324
- command: "zinkee --json displays widgets list 0f6f062f-1478-4df2-96a1-c495d037d260",
3325
- },
3326
- ]),
3327
- "displays widgets get": buildCommandExamples([
3166
+ command: "zinkee --json displays widgets list 0f6f062f-1478-4df2-96a1-c495d037d260"
3167
+ }
3168
+ ],
3169
+ "displays widgets get": [
3328
3170
  {
3329
3171
  description: "Get one widget (returns the canonical typed widget contract).",
3330
- command:
3331
- "zinkee --json displays widgets get 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111",
3172
+ command: "zinkee --json displays widgets get 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111",
3332
3173
  response: `{
3333
3174
  "id": "11111111-1111-4111-a111-111111111111",
3334
3175
  "type": "TABLE_OR_SUBTABLE",
@@ -3365,51 +3206,48 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3365
3206
  "fields": ["contact-name", "status", "amount"],
3366
3207
  "columnSize": { "contact-name": 240 }
3367
3208
  }
3368
- }`,
3369
- },
3370
- ]),
3371
- "displays widgets delete": buildCommandExamples([
3209
+ }`
3210
+ }
3211
+ ],
3212
+ "displays widgets delete": [
3372
3213
  {
3373
3214
  description: "Delete a widget.",
3374
- command:
3375
- "zinkee --json displays widgets delete 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111",
3215
+ command: "zinkee --json displays widgets delete 0f6f062f-1478-4df2-96a1-c495d037d260 11111111-1111-4111-a111-111111111111",
3376
3216
  response: `{
3377
3217
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
3378
3218
  "widgetId": "11111111-1111-4111-a111-111111111111"
3379
- }`,
3380
- },
3381
- ]),
3382
- "displays navigation-targets list": buildCommandExamples([
3219
+ }`
3220
+ }
3221
+ ],
3222
+ "displays navigation-targets list": [
3383
3223
  {
3384
3224
  description: "List navigation targets for a display.",
3385
- command: "zinkee --json displays navigation-targets list 0f6f062f-1478-4df2-96a1-c495d037d260",
3386
- },
3387
- ]),
3388
- "displays navigation-targets delete": buildCommandExamples([
3225
+ command: "zinkee --json displays navigation-targets list 0f6f062f-1478-4df2-96a1-c495d037d260"
3226
+ }
3227
+ ],
3228
+ "displays navigation-targets delete": [
3389
3229
  {
3390
3230
  description: "Delete a navigation target.",
3391
- command:
3392
- "zinkee --json displays navigation-targets delete 0f6f062f-1478-4df2-96a1-c495d037d260 nav-target-customer",
3231
+ command: "zinkee --json displays navigation-targets delete 0f6f062f-1478-4df2-96a1-c495d037d260 nav-target-customer",
3393
3232
  response: `{
3394
3233
  "displayId": "0f6f062f-1478-4df2-96a1-c495d037d260",
3395
3234
  "navigationTargetId": "nav-target-customer"
3396
- }`,
3397
- },
3398
- ]),
3399
- "displays cross-widget-filter get": buildCommandExamples([
3235
+ }`
3236
+ }
3237
+ ],
3238
+ "displays cross-widget-filter get": [
3400
3239
  {
3401
3240
  description: "Get the cross-widget filter of a display (can be null if none is set).",
3402
- command: "zinkee --json displays cross-widget-filter get 0f6f062f-1478-4df2-96a1-c495d037d260",
3403
- },
3404
- ]),
3405
- "displays cross-widget-filter delete": buildCommandExamples([
3241
+ command: "zinkee --json displays cross-widget-filter get 0f6f062f-1478-4df2-96a1-c495d037d260"
3242
+ }
3243
+ ],
3244
+ "displays cross-widget-filter delete": [
3406
3245
  {
3407
3246
  description: "Delete the cross-widget filter of a display.",
3408
- command:
3409
- "zinkee --json displays cross-widget-filter delete 0f6f062f-1478-4df2-96a1-c495d037d260",
3410
- },
3411
- ]),
3412
- "automations list": buildCommandExamples([
3247
+ command: "zinkee --json displays cross-widget-filter delete 0f6f062f-1478-4df2-96a1-c495d037d260"
3248
+ }
3249
+ ],
3250
+ "automations list": [
3413
3251
  {
3414
3252
  description: "List automations with summaries.",
3415
3253
  command: "zinkee --json automations list",
@@ -3427,18 +3265,16 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3427
3265
  "triggerType": "record_changed",
3428
3266
  "actionTypes": ["create_record", "http_request", "execute_plugin", "send_message"]
3429
3267
  }
3430
- ]`,
3268
+ ]`
3431
3269
  },
3432
3270
  {
3433
3271
  description: "Filter automations by folder, status, and trigger type.",
3434
- command:
3435
- 'zinkee --json automations list --folder "Codex Frontend Demo" --status active --trigger-type record_changed',
3436
- },
3437
- ]),
3438
- "automations get": buildCommandExamples([
3272
+ command: 'zinkee --json automations list --folder "Codex Frontend Demo" --status active --trigger-type record_changed'
3273
+ }
3274
+ ],
3275
+ "automations get": [
3439
3276
  {
3440
- description:
3441
- "Get the full automation document, including trigger, actions and flow.",
3277
+ description: "Get the full automation document, including trigger, actions and flow.",
3442
3278
  command: "zinkee --json automations get automation-1",
3443
3279
  response: `{
3444
3280
  "id": "d2df2478-2513-4ecb-a2aa-2cea8c3d614a",
@@ -3520,40 +3356,40 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3520
3356
  }
3521
3357
  ]
3522
3358
  }
3523
- }`,
3524
- },
3525
- ]),
3526
- "automations delete": buildCommandExamples([
3359
+ }`
3360
+ }
3361
+ ],
3362
+ "automations delete": [
3527
3363
  {
3528
3364
  description: "Delete an automation. The response mirrors the mutation shape.",
3529
3365
  command: "zinkee --json automations delete automation-1",
3530
3366
  response: `{
3531
3367
  "automationId": "d2df2478-2513-4ecb-a2aa-2cea8c3d614a",
3532
3368
  "webhookEndpoint": null
3533
- }`,
3534
- },
3535
- ]),
3536
- "automations activate": buildCommandExamples([
3369
+ }`
3370
+ }
3371
+ ],
3372
+ "automations activate": [
3537
3373
  {
3538
3374
  description: "Activate an automation (transitions it to status=active).",
3539
3375
  command: "zinkee --json automations activate automation-1",
3540
3376
  response: `{
3541
3377
  "automationId": "d2df2478-2513-4ecb-a2aa-2cea8c3d614a",
3542
3378
  "webhookEndpoint": null
3543
- }`,
3544
- },
3545
- ]),
3546
- "automations deactivate": buildCommandExamples([
3379
+ }`
3380
+ }
3381
+ ],
3382
+ "automations deactivate": [
3547
3383
  {
3548
3384
  description: "Deactivate an automation (transitions it to status=inactive).",
3549
3385
  command: "zinkee --json automations deactivate automation-1",
3550
3386
  response: `{
3551
3387
  "automationId": "d2df2478-2513-4ecb-a2aa-2cea8c3d614a",
3552
3388
  "webhookEndpoint": null
3553
- }`,
3554
- },
3555
- ]),
3556
- "automations folders list": buildCommandExamples([
3389
+ }`
3390
+ }
3391
+ ],
3392
+ "automations folders list": [
3557
3393
  {
3558
3394
  description: "List flat automation folders (non-root plus the root bucket).",
3559
3395
  command: "zinkee --json automations folders list",
@@ -3570,10 +3406,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3570
3406
  "isRoot": true,
3571
3407
  "automationCount": 3
3572
3408
  }
3573
- ]`,
3574
- },
3575
- ]),
3576
- "automations folders delete": buildCommandExamples([
3409
+ ]`
3410
+ }
3411
+ ],
3412
+ "automations folders delete": [
3577
3413
  {
3578
3414
  description: "Delete a non-root automation folder by exact name.",
3579
3415
  command: 'zinkee --json automations folders delete "Codex Frontend Demo"',
@@ -3582,26 +3418,24 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3582
3418
  "name": "Codex Frontend Demo",
3583
3419
  "isRoot": false,
3584
3420
  "automationCount": 0
3585
- }`,
3586
- },
3587
- ]),
3588
- "automations trigger get": buildCommandExamples([
3421
+ }`
3422
+ }
3423
+ ],
3424
+ "automations trigger get": [
3589
3425
  {
3590
- description:
3591
- "Get the trigger subresource. Response shape depends on trigger type; here the scheduled variant.",
3426
+ description: "Get the trigger subresource. Response shape depends on trigger type; here the scheduled variant.",
3592
3427
  command: "zinkee --json automations trigger get automation-1",
3593
3428
  response: `{
3594
3429
  "type": "scheduled",
3595
3430
  "config": {
3596
3431
  "cronExpression": "0 15 10 * * 1"
3597
3432
  }
3598
- }`,
3599
- },
3600
- ]),
3601
- "automations webhook get": buildCommandExamples([
3433
+ }`
3434
+ }
3435
+ ],
3436
+ "automations webhook get": [
3602
3437
  {
3603
- description:
3604
- "Get the webhook endpoint companion resource (only exists when the trigger is a webhook).",
3438
+ description: "Get the webhook endpoint companion resource (only exists when the trigger is a webhook).",
3605
3439
  command: "zinkee --json automations webhook get automation-1",
3606
3440
  response: `{
3607
3441
  "endpointId": "b3cb4283-97ab-4d94-9e6f-82d0ee5cee24",
@@ -3617,16 +3451,16 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3617
3451
  "jsonPath": "$.data.id"
3618
3452
  }
3619
3453
  ]
3620
- }`,
3621
- },
3622
- ]),
3623
- "automations webhook delete": buildCommandExamples([
3454
+ }`
3455
+ }
3456
+ ],
3457
+ "automations webhook delete": [
3624
3458
  {
3625
3459
  description: "Delete the webhook endpoint companion resource (returns no body).",
3626
- command: "zinkee --json automations webhook delete automation-1",
3627
- },
3628
- ]),
3629
- "automations actions list": buildCommandExamples([
3460
+ command: "zinkee --json automations webhook delete automation-1"
3461
+ }
3462
+ ],
3463
+ "automations actions list": [
3630
3464
  {
3631
3465
  description: "List the ordered actions of an automation.",
3632
3466
  command: "zinkee --json automations actions list automation-1",
@@ -3670,20 +3504,20 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3670
3504
  "pluginArgs": {"mode": "safe"}
3671
3505
  }
3672
3506
  }
3673
- ]`,
3674
- },
3675
- ]),
3676
- "automations actions delete": buildCommandExamples([
3507
+ ]`
3508
+ }
3509
+ ],
3510
+ "automations actions delete": [
3677
3511
  {
3678
3512
  description: "Delete one action from an automation.",
3679
3513
  command: "zinkee --json automations actions delete automation-1 action-1",
3680
3514
  response: `{
3681
3515
  "automationId": "d2df2478-2513-4ecb-a2aa-2cea8c3d614a",
3682
3516
  "webhookEndpoint": null
3683
- }`,
3684
- },
3685
- ]),
3686
- "automations flow get": buildCommandExamples([
3517
+ }`
3518
+ }
3519
+ ],
3520
+ "automations flow get": [
3687
3521
  {
3688
3522
  description: "Get the flow subresource (entry actions and transitions).",
3689
3523
  command: "zinkee --json automations flow get automation-1",
@@ -3699,10 +3533,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3699
3533
  "toActionId": "dae13307-057f-4c39-817c-4d2dd5898421"
3700
3534
  }
3701
3535
  ]
3702
- }`,
3703
- },
3704
- ]),
3705
- "automations plugins list": buildCommandExamples([
3536
+ }`
3537
+ }
3538
+ ],
3539
+ "automations plugins list": [
3706
3540
  {
3707
3541
  description: "List active workspace plugins available for execute_plugin actions.",
3708
3542
  command: "zinkee --json automations plugins list",
@@ -3716,10 +3550,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3716
3550
  "version": "1.0"
3717
3551
  }
3718
3552
  }
3719
- ]`,
3720
- },
3721
- ]),
3722
- "automations plugins get": buildCommandExamples([
3553
+ ]`
3554
+ }
3555
+ ],
3556
+ "automations plugins get": [
3723
3557
  {
3724
3558
  description: "Get one plugin by id.",
3725
3559
  command: "zinkee --json automations plugins get demo-plugin",
@@ -3731,10 +3565,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3731
3565
  "properties": {
3732
3566
  "version": "1.0"
3733
3567
  }
3734
- }`,
3735
- },
3736
- ]),
3737
- "automations connections list": buildCommandExamples([
3568
+ }`
3569
+ }
3570
+ ],
3571
+ "automations connections list": [
3738
3572
  {
3739
3573
  description: "List stored workspace connections (secrets are never returned).",
3740
3574
  command: "zinkee --json automations connections list",
@@ -3749,10 +3583,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3749
3583
  "headerName": "Authorization"
3750
3584
  }
3751
3585
  }
3752
- ]`,
3753
- },
3754
- ]),
3755
- "automations connections get": buildCommandExamples([
3586
+ ]`
3587
+ }
3588
+ ],
3589
+ "automations connections get": [
3756
3590
  {
3757
3591
  description: "Get one stored connection by id.",
3758
3592
  command: "zinkee --json automations connections get connection-1",
@@ -3770,21 +3604,19 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3770
3604
  "updatedAt": "2026-04-21T09:00:00Z",
3771
3605
  "createdBy": "developer@zinkee.com",
3772
3606
  "updatedBy": "developer@zinkee.com"
3773
- }`,
3774
- },
3775
- ]),
3776
- "automations connections delete": buildCommandExamples([
3607
+ }`
3608
+ }
3609
+ ],
3610
+ "automations connections delete": [
3777
3611
  {
3778
3612
  description: "Delete one stored connection (returns no body).",
3779
- command: "zinkee --json automations connections delete connection-1",
3780
- },
3781
- ]),
3782
- "automations create": buildCommandExamples([
3613
+ command: "zinkee --json automations connections delete connection-1"
3614
+ }
3615
+ ],
3616
+ "automations create": [
3783
3617
  {
3784
- description:
3785
- "Create a scheduled automation with description and target folder. Safe first example because it does not depend on workspace schemas.",
3786
- command:
3787
- 'zinkee --json automations create --name "Nightly invoice sync" --description "Runs every Monday morning" --folder cdfc14e3-3169-4ffb-8d9b-b11858a9240f --trigger-type scheduled --cron "0 15 10 * * 1"',
3618
+ description: "Create a scheduled automation with description and target folder. Safe first example because it does not depend on workspace schemas.",
3619
+ command: 'zinkee --json automations create --name "Nightly invoice sync" --description "Runs every Monday morning" --folder cdfc14e3-3169-4ffb-8d9b-b11858a9240f --trigger-type scheduled --cron "0 15 10 * * 1"',
3788
3620
  raw: `{
3789
3621
  "name": "Nightly invoice sync",
3790
3622
  "description": "Runs every Monday morning",
@@ -3799,13 +3631,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3799
3631
  response: `{
3800
3632
  "automationId": "d2df2478-2513-4ecb-a2aa-2cea8c3d614a",
3801
3633
  "webhookEndpoint": null
3802
- }`,
3634
+ }`
3803
3635
  },
3804
3636
  {
3805
- description:
3806
- "Create a record-created automation with an 'is not empty' condition. Replace 'leads' and 'status' with real schema/field slugs or UUIDs.",
3807
- command:
3808
- `zinkee --json automations create --name "Lead welcome" --trigger-type record_created --trigger-schema leads --condition-json '{"field":"status","comparator":"ine","values":[{"rawValue":"","source":null}]}'`,
3637
+ description: "Create a record-created automation with an 'is not empty' condition. Replace 'leads' and 'status' with real schema/field slugs or UUIDs.",
3638
+ command: `zinkee --json automations create --name "Lead welcome" --trigger-type record_created --trigger-schema leads --condition-json '{"field":"status","comparator":"ine","values":[{"rawValue":"","source":null}]}'`,
3809
3639
  raw: `{
3810
3640
  "name": "Lead welcome",
3811
3641
  "trigger": {
@@ -3821,13 +3651,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3821
3651
  ]
3822
3652
  }
3823
3653
  }
3824
- }`,
3654
+ }`
3825
3655
  },
3826
3656
  {
3827
- description:
3828
- "Create a record-changed automation watching a single field, with an 'is not empty' condition. Replace 'orders' and 'status' with values from your workspace.",
3829
- command:
3830
- `zinkee --json automations create --name "Order status sync" --trigger-type record_changed --trigger-schema orders --trigger-field status --condition-json '{"field":"status","comparator":"ine","values":[{"rawValue":"","source":null}]}'`,
3657
+ description: "Create a record-changed automation watching a single field, with an 'is not empty' condition. Replace 'orders' and 'status' with values from your workspace.",
3658
+ command: `zinkee --json automations create --name "Order status sync" --trigger-type record_changed --trigger-schema orders --trigger-field status --condition-json '{"field":"status","comparator":"ine","values":[{"rawValue":"","source":null}]}'`,
3831
3659
  raw: `{
3832
3660
  "name": "Order status sync",
3833
3661
  "trigger": {
@@ -3844,49 +3672,42 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3844
3672
  ]
3845
3673
  }
3846
3674
  }
3847
- }`,
3848
- },
3849
- ]),
3850
- "automations update": buildCommandExamples([
3675
+ }`
3676
+ }
3677
+ ],
3678
+ "automations update": [
3851
3679
  {
3852
- description:
3853
- "Update automation description and move it to a folder. Supported patch paths: name, description, folderId.",
3854
- command:
3855
- 'zinkee --json automations update automation-1 --description "Updated by an agent" --folder cdfc14e3-3169-4ffb-8d9b-b11858a9240f',
3680
+ description: "Update automation description and move it to a folder. Supported patch paths: name, description, folderId.",
3681
+ command: 'zinkee --json automations update automation-1 --description "Updated by an agent" --folder cdfc14e3-3169-4ffb-8d9b-b11858a9240f',
3856
3682
  raw: `{
3857
3683
  "set": {
3858
3684
  "description": "Updated by an agent",
3859
3685
  "folderId": "cdfc14e3-3169-4ffb-8d9b-b11858a9240f"
3860
3686
  }
3861
- }`,
3687
+ }`
3862
3688
  },
3863
3689
  {
3864
- description:
3865
- "Clear the folder assignment by combining an explicit unset through the raw payload.",
3866
- command:
3867
- 'zinkee --json automations update automation-1 --raw \'{"unset":["folderId"]}\'',
3690
+ description: "Clear the folder assignment by combining an explicit unset through the raw payload.",
3691
+ command: `zinkee --json automations update automation-1 --raw '{"unset":["folderId"]}'`,
3868
3692
  raw: `{
3869
3693
  "unset": ["folderId"]
3870
- }`,
3871
- },
3872
- ]),
3873
- "automations trigger set": buildCommandExamples([
3694
+ }`
3695
+ }
3696
+ ],
3697
+ "automations trigger set": [
3874
3698
  {
3875
3699
  description: "Replace the trigger with a scheduled (cron) trigger.",
3876
- command:
3877
- 'zinkee --json automations trigger set automation-1 --trigger-type scheduled --cron "0 15 10 * * 1"',
3700
+ command: 'zinkee --json automations trigger set automation-1 --trigger-type scheduled --cron "0 15 10 * * 1"',
3878
3701
  raw: `{
3879
3702
  "type": "scheduled",
3880
3703
  "config": {
3881
3704
  "cronExpression": "0 15 10 * * 1"
3882
3705
  }
3883
- }`,
3706
+ }`
3884
3707
  },
3885
3708
  {
3886
- description:
3887
- "Replace the trigger with a record-created trigger plus an 'is not empty' condition. Agents should provide at least one meaningful condition.",
3888
- command:
3889
- `zinkee --json automations trigger set automation-1 --trigger-type record_created --trigger-schema orders --condition-json '{"field":"status","comparator":"ine","values":[{"rawValue":"","source":null}]}'`,
3709
+ description: "Replace the trigger with a record-created trigger plus an 'is not empty' condition. Agents should provide at least one meaningful condition.",
3710
+ command: `zinkee --json automations trigger set automation-1 --trigger-type record_created --trigger-schema orders --condition-json '{"field":"status","comparator":"ine","values":[{"rawValue":"","source":null}]}'`,
3890
3711
  raw: `{
3891
3712
  "type": "record_created",
3892
3713
  "config": {
@@ -3899,13 +3720,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3899
3720
  }
3900
3721
  ]
3901
3722
  }
3902
- }`,
3723
+ }`
3903
3724
  },
3904
3725
  {
3905
- description:
3906
- "Replace the trigger with a record-changed trigger watching one field, with an 'is not empty' condition on that field.",
3907
- command:
3908
- `zinkee --json automations trigger set automation-1 --trigger-type record_changed --trigger-schema orders --trigger-field status --condition-json '{"field":"status","comparator":"ine","values":[{"rawValue":"","source":null}]}'`,
3726
+ description: "Replace the trigger with a record-changed trigger watching one field, with an 'is not empty' condition on that field.",
3727
+ command: `zinkee --json automations trigger set automation-1 --trigger-type record_changed --trigger-schema orders --trigger-field status --condition-json '{"field":"status","comparator":"ine","values":[{"rawValue":"","source":null}]}'`,
3909
3728
  raw: `{
3910
3729
  "type": "record_changed",
3911
3730
  "config": {
@@ -3919,26 +3738,23 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3919
3738
  }
3920
3739
  ]
3921
3740
  }
3922
- }`,
3741
+ }`
3923
3742
  },
3924
3743
  {
3925
3744
  description: "Replace the trigger with a webhook trigger that reuses an existing webhook endpoint id.",
3926
- command:
3927
- "zinkee --json automations trigger set automation-1 --trigger-type webhook --webhook-endpoint-id b3cb4283-97ab-4d94-9e6f-82d0ee5cee24",
3745
+ command: "zinkee --json automations trigger set automation-1 --trigger-type webhook --webhook-endpoint-id b3cb4283-97ab-4d94-9e6f-82d0ee5cee24",
3928
3746
  raw: `{
3929
3747
  "type": "webhook",
3930
3748
  "config": {
3931
3749
  "webhookEndpointId": "b3cb4283-97ab-4d94-9e6f-82d0ee5cee24"
3932
3750
  }
3933
- }`,
3934
- },
3935
- ]),
3936
- "automations actions add": buildCommandExamples([
3751
+ }`
3752
+ }
3753
+ ],
3754
+ "automations actions add": [
3937
3755
  {
3938
- description:
3939
- "Add a create-record action with two literal field mappings. Populate visible fieldMapping entries so the frontend form is complete.",
3940
- command:
3941
- 'zinkee --json automations actions add automation-1 --type create_record --name "Create follow-up order" --target-schema followups --map status=pending --map description="Created by automation"',
3756
+ description: "Add a create-record action with two literal field mappings. Populate visible fieldMapping entries so the frontend form is complete.",
3757
+ command: 'zinkee --json automations actions add automation-1 --type create_record --name "Create follow-up order" --target-schema followups --map status=pending --map description="Created by automation"',
3942
3758
  raw: `{
3943
3759
  "type": "create_record",
3944
3760
  "name": "Create follow-up order",
@@ -3955,13 +3771,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3955
3771
  }
3956
3772
  }
3957
3773
  }
3958
- }`,
3774
+ }`
3959
3775
  },
3960
3776
  {
3961
- description:
3962
- "Add an update-record action that targets the trigger record. Pair --use-trigger-record with --map to rewrite fields on the record that fired the automation.",
3963
- command:
3964
- 'zinkee --json automations actions add automation-1 --type update_record --name "Mark order as processed" --target-schema orders --use-trigger-record --map status=processed',
3777
+ description: "Add an update-record action that targets the trigger record. Pair --use-trigger-record with --map to rewrite fields on the record that fired the automation.",
3778
+ command: 'zinkee --json automations actions add automation-1 --type update_record --name "Mark order as processed" --target-schema orders --use-trigger-record --map status=processed',
3965
3779
  raw: `{
3966
3780
  "type": "update_record",
3967
3781
  "name": "Mark order as processed",
@@ -3975,25 +3789,22 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
3975
3789
  },
3976
3790
  "useTriggerRecord": true
3977
3791
  }
3978
- }`,
3792
+ }`
3979
3793
  },
3980
3794
  {
3981
3795
  description: "Add a search-records action scoped to a target schema.",
3982
- command:
3983
- 'zinkee --json automations actions add automation-1 --type search_records --name "Find related invoices" --target-schema orders',
3796
+ command: 'zinkee --json automations actions add automation-1 --type search_records --name "Find related invoices" --target-schema orders',
3984
3797
  raw: `{
3985
3798
  "type": "search_records",
3986
3799
  "name": "Find related invoices",
3987
3800
  "config": {
3988
3801
  "targetSchemaId": "orders"
3989
3802
  }
3990
- }`,
3803
+ }`
3991
3804
  },
3992
3805
  {
3993
- description:
3994
- "Add a search-records action whose condition pulls its value from the trigger payload using --condition-json.",
3995
- command:
3996
- `zinkee --json automations actions add automation-1 --type search_records --name "Find duplicates" --target-schema followups --condition-json '{"field":"email","comparator":"eq","values":[{"rawValue":null,"source":{"type":"TRIGGER","id":"f1e1d000-0000-0000-0000-000000000005"}}]}'`,
3806
+ description: "Add a search-records action whose condition pulls its value from the trigger payload using --condition-json.",
3807
+ command: `zinkee --json automations actions add automation-1 --type search_records --name "Find duplicates" --target-schema followups --condition-json '{"field":"email","comparator":"eq","values":[{"rawValue":null,"source":{"type":"TRIGGER","id":"f1e1d000-0000-0000-0000-000000000005"}}]}'`,
3997
3808
  raw: `{
3998
3809
  "type": "search_records",
3999
3810
  "name": "Find duplicates",
@@ -4015,13 +3826,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4015
3826
  }
4016
3827
  ]
4017
3828
  }
4018
- }`,
3829
+ }`
4019
3830
  },
4020
3831
  {
4021
- description:
4022
- "Add an HTTP request action using a stored workspace connection for authentication.",
4023
- command:
4024
- 'zinkee --json automations actions add automation-1 --type http_request --name "Notify external ERP" --method POST --url https://example.com/integrations/order-status --header X-Demo=codex --content-type application/json --timeout-ms 5000 --auth-mode STORED --connection connection-1',
3832
+ description: "Add an HTTP request action using a stored workspace connection for authentication.",
3833
+ command: 'zinkee --json automations actions add automation-1 --type http_request --name "Notify external ERP" --method POST --url https://example.com/integrations/order-status --header X-Demo=codex --content-type application/json --timeout-ms 5000 --auth-mode STORED --connection connection-1',
4025
3834
  raw: `{
4026
3835
  "type": "http_request",
4027
3836
  "name": "Notify external ERP",
@@ -4036,13 +3845,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4036
3845
  "authMode": "STORED",
4037
3846
  "connectionId": "connection-1"
4038
3847
  }
4039
- }`,
3848
+ }`
4040
3849
  },
4041
3850
  {
4042
- description:
4043
- "Add an execute-plugin action with structured plugin arguments. Replace 'demo-plugin' with an active id from 'zinkee --json automations plugins list'.",
4044
- command:
4045
- `zinkee --json automations actions add automation-1 --type execute_plugin --name "Run billing plugin" --plugin demo-plugin --arg mode=safe --arg-json steps='["one","two"]'`,
3851
+ description: "Add an execute-plugin action with structured plugin arguments. Replace 'demo-plugin' with an active id from 'zinkee --json automations plugins list'.",
3852
+ command: `zinkee --json automations actions add automation-1 --type execute_plugin --name "Run billing plugin" --plugin demo-plugin --arg mode=safe --arg-json steps='["one","two"]'`,
4046
3853
  raw: `{
4047
3854
  "type": "execute_plugin",
4048
3855
  "name": "Run billing plugin",
@@ -4053,13 +3860,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4053
3860
  "steps": ["one", "two"]
4054
3861
  }
4055
3862
  }
4056
- }`,
3863
+ }`
4057
3864
  },
4058
3865
  {
4059
- description:
4060
- "Add a send-message action. --to maps to fieldMapping.recipients and --message maps to fieldMapping.body. Values are wrapped in {rawValue, source} like every other automation field mapping; use --map / --map-json for extra keys.",
4061
- command:
4062
- `zinkee --json automations actions add automation-1 --type send_message --name "Notify customer" --to customer@example.com --subject "Your order status has changed" --message "Hello, your order is now processed."`,
3866
+ description: "Add a send-message action. --to maps to fieldMapping.recipients and --message maps to fieldMapping.body. Values are wrapped in {rawValue, source} like every other automation field mapping; use --map / --map-json for extra keys.",
3867
+ command: `zinkee --json automations actions add automation-1 --type send_message --name "Notify customer" --to customer@example.com --subject "Your order status has changed" --message "Hello, your order is now processed."`,
4063
3868
  raw: `{
4064
3869
  "type": "send_message",
4065
3870
  "name": "Notify customer",
@@ -4079,13 +3884,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4079
3884
  }
4080
3885
  }
4081
3886
  }
4082
- }`,
3887
+ }`
4083
3888
  },
4084
3889
  {
4085
- description:
4086
- "Add a generate-document action. The renderer reads the template, writes the file, and stores its id in the target FileField of the target schema.",
4087
- command:
4088
- 'zinkee --json automations actions add automation-1 --type generate_document --name "Generate invoice PDF" --document-template 6c08673e-f8a6-44d2-8c91-d09eca911f8f --target-schema 68d2c7be-4392-42de-b5ae-625ad79cfc3c --target-file-field c8edbde8-a361-4e9f-a39a-2e88971f21a7',
3890
+ description: "Add a generate-document action. The renderer reads the template, writes the file, and stores its id in the target FileField of the target schema.",
3891
+ command: 'zinkee --json automations actions add automation-1 --type generate_document --name "Generate invoice PDF" --document-template 6c08673e-f8a6-44d2-8c91-d09eca911f8f --target-schema 68d2c7be-4392-42de-b5ae-625ad79cfc3c --target-file-field c8edbde8-a361-4e9f-a39a-2e88971f21a7',
4089
3892
  raw: `{
4090
3893
  "type": "generate_document",
4091
3894
  "name": "Generate invoice PDF",
@@ -4094,15 +3897,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4094
3897
  "targetSchemaId": "68d2c7be-4392-42de-b5ae-625ad79cfc3c",
4095
3898
  "targetFileFieldId": "c8edbde8-a361-4e9f-a39a-2e88971f21a7"
4096
3899
  }
4097
- }`,
4098
- },
4099
- ]),
4100
- "automations actions update": buildCommandExamples([
3900
+ }`
3901
+ }
3902
+ ],
3903
+ "automations actions update": [
4101
3904
  {
4102
- description:
4103
- "Replace an update-record action so it targets the trigger record. Conditions are stripped automatically when --use-trigger-record is provided.",
4104
- command:
4105
- 'zinkee --json automations actions update automation-1 action-1 --type update_record --name "Update trigger record" --target-schema followups --map status=ready --use-trigger-record',
3905
+ description: "Replace an update-record action so it targets the trigger record. Conditions are stripped automatically when --use-trigger-record is provided.",
3906
+ command: 'zinkee --json automations actions update automation-1 action-1 --type update_record --name "Update trigger record" --target-schema followups --map status=ready --use-trigger-record',
4106
3907
  raw: `{
4107
3908
  "type": "update_record",
4108
3909
  "name": "Update trigger record",
@@ -4130,13 +3931,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4130
3931
  }
4131
3932
  }
4132
3933
  }
4133
- }`,
3934
+ }`
4134
3935
  },
4135
3936
  {
4136
- description:
4137
- "Replace an HTTP request action, keeping it authenticated through a stored connection.",
4138
- command:
4139
- 'zinkee --json automations actions update automation-1 action-1 --type http_request --name "Notify external ERP" --method POST --url https://example.com/integrations/order-status --content-type application/json --timeout-ms 5000 --auth-mode STORED --connection connection-1',
3937
+ description: "Replace an HTTP request action, keeping it authenticated through a stored connection.",
3938
+ command: 'zinkee --json automations actions update automation-1 action-1 --type http_request --name "Notify external ERP" --method POST --url https://example.com/integrations/order-status --content-type application/json --timeout-ms 5000 --auth-mode STORED --connection connection-1',
4140
3939
  raw: `{
4141
3940
  "type": "http_request",
4142
3941
  "name": "Notify external ERP",
@@ -4148,13 +3947,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4148
3947
  "authMode": "STORED",
4149
3948
  "connectionId": "connection-1"
4150
3949
  }
4151
- }`,
3950
+ }`
4152
3951
  },
4153
3952
  {
4154
- description:
4155
- "Replace a send-message action. --to maps to fieldMapping.recipients and --message maps to fieldMapping.body; values are wrapped in {rawValue, source}.",
4156
- command:
4157
- `zinkee --json automations actions update automation-1 action-1 --type send_message --name "Notify customer" --to customer@example.com --subject "Your order status has changed" --message "Hello, your order is now processed."`,
3953
+ description: "Replace a send-message action. --to maps to fieldMapping.recipients and --message maps to fieldMapping.body; values are wrapped in {rawValue, source}.",
3954
+ command: `zinkee --json automations actions update automation-1 action-1 --type send_message --name "Notify customer" --to customer@example.com --subject "Your order status has changed" --message "Hello, your order is now processed."`,
4158
3955
  raw: `{
4159
3956
  "type": "send_message",
4160
3957
  "name": "Notify customer",
@@ -4174,15 +3971,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4174
3971
  }
4175
3972
  }
4176
3973
  }
4177
- }`,
4178
- },
4179
- ]),
4180
- "automations flow set": buildCommandExamples([
3974
+ }`
3975
+ }
3976
+ ],
3977
+ "automations flow set": [
4181
3978
  {
4182
- description:
4183
- "Set one entry action and chain two transitions (action-1 → action-2 → action-3).",
4184
- command:
4185
- "zinkee --json automations flow set automation-1 --entry action-1 --transition action-1:action-2 --transition action-2:action-3",
3979
+ description: "Set one entry action and chain two transitions (action-1 \u2192 action-2 \u2192 action-3).",
3980
+ command: "zinkee --json automations flow set automation-1 --entry action-1 --transition action-1:action-2 --transition action-2:action-3",
4186
3981
  raw: `{
4187
3982
  "entryActionIds": ["action-1"],
4188
3983
  "transitions": [
@@ -4195,15 +3990,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4195
3990
  "toActionId": "action-3"
4196
3991
  }
4197
3992
  ]
4198
- }`,
4199
- },
4200
- ]),
4201
- "automations webhook set": buildCommandExamples([
3993
+ }`
3994
+ }
3995
+ ],
3996
+ "automations webhook set": [
4202
3997
  {
4203
- description:
4204
- "Create or update the webhook endpoint companion resource with idempotency key, event type filter, and a field mapping. This config is separate from the webhook trigger itself.",
4205
- command:
4206
- `zinkee --json automations webhook set automation-1 --idempotency-key-path "$.id" --event-type-path "$.type" --allowed-event-type frontend.demo.created --field-mapping '{"variable":"external_id","jsonPath":"$.data.id"}' --active`,
3998
+ description: "Create or update the webhook endpoint companion resource with idempotency key, event type filter, and a field mapping. This config is separate from the webhook trigger itself.",
3999
+ command: `zinkee --json automations webhook set automation-1 --idempotency-key-path "$.id" --event-type-path "$.type" --allowed-event-type frontend.demo.created --field-mapping '{"variable":"external_id","jsonPath":"$.data.id"}' --active`,
4207
4000
  raw: `{
4208
4001
  "active": true,
4209
4002
  "idempotencyKeyJsonPath": "$.id",
@@ -4230,15 +4023,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4230
4023
  "jsonPath": "$.data.id"
4231
4024
  }
4232
4025
  ]
4233
- }`,
4234
- },
4235
- ]),
4236
- "automations connections create": buildCommandExamples([
4026
+ }`
4027
+ }
4028
+ ],
4029
+ "automations connections create": [
4237
4030
  {
4238
- description:
4239
- "Create a stored workspace connection for http_request actions. Secret values are write-only and never returned on read.",
4240
- command:
4241
- `zinkee --json automations connections create --name "ERP API Key" --type api_key --scope workspace --config '{"headerName":"Authorization"}' --secret apiKey=super-secret --active`,
4031
+ description: "Create a stored workspace connection for http_request actions. Secret values are write-only and never returned on read.",
4032
+ command: `zinkee --json automations connections create --name "ERP API Key" --type api_key --scope workspace --config '{"headerName":"Authorization"}' --secret apiKey=super-secret --active`,
4242
4033
  raw: `{
4243
4034
  "name": "ERP API Key",
4244
4035
  "type": "api_key",
@@ -4265,15 +4056,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4265
4056
  "updatedAt": "2026-04-21T09:00:00Z",
4266
4057
  "createdBy": "developer@zinkee.com",
4267
4058
  "updatedBy": "developer@zinkee.com"
4268
- }`,
4269
- },
4270
- ]),
4271
- "automations connections update": buildCommandExamples([
4059
+ }`
4060
+ }
4061
+ ],
4062
+ "automations connections update": [
4272
4063
  {
4273
- description:
4274
- "Patch an existing stored connection. Use set.secret only when rotating secrets.",
4275
- command:
4276
- `zinkee --json automations connections update connection-1 --raw '{"set":{"name":"ERP API Key Updated","config":{"headerName":"Authorization"}}}'`,
4064
+ description: "Patch an existing stored connection. Use set.secret only when rotating secrets.",
4065
+ command: `zinkee --json automations connections update connection-1 --raw '{"set":{"name":"ERP API Key Updated","config":{"headerName":"Authorization"}}}'`,
4277
4066
  raw: `{
4278
4067
  "set": {
4279
4068
  "name": "ERP API Key Updated",
@@ -4296,10 +4085,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4296
4085
  "updatedAt": "2026-04-21T10:15:00Z",
4297
4086
  "createdBy": "developer@zinkee.com",
4298
4087
  "updatedBy": "developer@zinkee.com"
4299
- }`,
4300
- },
4301
- ]),
4302
- "automations folders create": buildCommandExamples([
4088
+ }`
4089
+ }
4090
+ ],
4091
+ "automations folders create": [
4303
4092
  {
4304
4093
  description: "Create one flat automation folder.",
4305
4094
  command: 'zinkee --json automations folders create --name "Codex Frontend Demo"',
@@ -4311,14 +4100,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4311
4100
  "name": "Codex Frontend Demo",
4312
4101
  "isRoot": false,
4313
4102
  "automationCount": 0
4314
- }`,
4315
- },
4316
- ]),
4317
- "automations folders update": buildCommandExamples([
4103
+ }`
4104
+ }
4105
+ ],
4106
+ "automations folders update": [
4318
4107
  {
4319
4108
  description: "Rename a non-root automation folder. The folder argument accepts a UUID or an exact name.",
4320
- command:
4321
- 'zinkee --json automations folders update "Codex Frontend Demo" --name "Codex Frontend Demo Updated"',
4109
+ command: 'zinkee --json automations folders update "Codex Frontend Demo" --name "Codex Frontend Demo Updated"',
4322
4110
  raw: `{
4323
4111
  "name": "Codex Frontend Demo Updated"
4324
4112
  }`,
@@ -4327,10 +4115,10 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4327
4115
  "name": "Codex Frontend Demo Updated",
4328
4116
  "isRoot": false,
4329
4117
  "automationCount": 2
4330
- }`,
4331
- },
4332
- ]),
4333
- "automations folders move": buildCommandExamples([
4118
+ }`
4119
+ }
4120
+ ],
4121
+ "automations folders move": [
4334
4122
  {
4335
4123
  description: "Move one automation into a target folder by exact folder name.",
4336
4124
  command: 'zinkee --json automations folders move automation-1 --to "Codex Frontend Demo"',
@@ -4342,13 +4130,12 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4342
4130
  "id": "cdfc14e3-3169-4ffb-8d9b-b11858a9240f",
4343
4131
  "name": "Codex Frontend Demo",
4344
4132
  "isRoot": false
4345
- }`,
4346
- },
4347
- ]),
4348
- "document-templates list": buildCommandExamples([
4133
+ }`
4134
+ }
4135
+ ],
4136
+ "document-templates list": [
4349
4137
  {
4350
- description:
4351
- "List every document template in the workspace. Each asset's link is a relative path to the asset download endpoint, ready to call without composition.",
4138
+ description: "List every document template in the workspace. Each asset's link is a relative path to the asset download endpoint, ready to call without composition.",
4352
4139
  command: "zinkee --json document-templates list",
4353
4140
  response: `[
4354
4141
  {
@@ -4366,15 +4153,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4366
4153
  "createdBy": "creator@example.com",
4367
4154
  "updatedBy": "updater@example.com"
4368
4155
  }
4369
- ]`,
4370
- },
4371
- ]),
4372
- "document-templates get": buildCommandExamples([
4156
+ ]`
4157
+ }
4158
+ ],
4159
+ "document-templates get": [
4373
4160
  {
4374
- description:
4375
- "Look up one template by UUID. The CLI filters the list endpoint locally (the backend does not expose a get-one route).",
4376
- command:
4377
- "zinkee --json document-templates get 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e",
4161
+ description: "Look up one template by UUID. The CLI filters the list endpoint locally (the backend does not expose a get-one route).",
4162
+ command: "zinkee --json document-templates get 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e",
4378
4163
  response: `{
4379
4164
  "id": "7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e",
4380
4165
  "name": "Quarterly report",
@@ -4389,18 +4174,16 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4389
4174
  "updatedAt": "2026-01-20T14:30:00Z",
4390
4175
  "createdBy": "creator@example.com",
4391
4176
  "updatedBy": "creator@example.com"
4392
- }`,
4177
+ }`
4393
4178
  },
4394
4179
  {
4395
- description:
4396
- "Look up by exact template name. Names are unique within the workspace; ambiguity is reported as an error.",
4397
- command: 'zinkee --json document-templates get "Quarterly report"',
4398
- },
4399
- ]),
4400
- "document-templates create": buildCommandExamples([
4180
+ description: "Look up by exact template name. Names are unique within the workspace; ambiguity is reported as an error.",
4181
+ command: 'zinkee --json document-templates get "Quarterly report"'
4182
+ }
4183
+ ],
4184
+ "document-templates create": [
4401
4185
  {
4402
- description:
4403
- "Typical create: empty template by name. Assets are uploaded afterwards via document-templates assets add.",
4186
+ description: "Typical create: empty template by name. Assets are uploaded afterwards via document-templates assets add.",
4404
4187
  command: 'zinkee --json document-templates create --name "Quarterly report"',
4405
4188
  raw: `{
4406
4189
  "name": "Quarterly report",
@@ -4414,13 +4197,11 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4414
4197
  "updatedAt": "2026-01-15T10:00:00Z",
4415
4198
  "createdBy": "creator@example.com",
4416
4199
  "updatedBy": "creator@example.com"
4417
- }`,
4200
+ }`
4418
4201
  },
4419
4202
  {
4420
- description:
4421
- "Create with pre-existing asset records via --raw. Used for import/migration flows where the assets already exist elsewhere; the typical UX is to create empty and upload via assets add.",
4422
- command:
4423
- `zinkee --json document-templates create --raw '{"name":"Annual report","assets":[{"id":"9e8d7c6b-5a4f-3e2d-1c0b-9a8b7c6d5e4f","name":"Cover.docx","link":"/existing/cover.docx"},{"id":"3f2e1d0c-9b8a-7654-3210-fedcba987654","name":"Appendix.docx","link":"/existing/appendix.docx"}]}'`,
4203
+ description: "Create with pre-existing asset records via --raw. Used for import/migration flows where the assets already exist elsewhere; the typical UX is to create empty and upload via assets add.",
4204
+ command: `zinkee --json document-templates create --raw '{"name":"Annual report","assets":[{"id":"9e8d7c6b-5a4f-3e2d-1c0b-9a8b7c6d5e4f","name":"Cover.docx","link":"/existing/cover.docx"},{"id":"3f2e1d0c-9b8a-7654-3210-fedcba987654","name":"Appendix.docx","link":"/existing/appendix.docx"}]}'`,
4424
4205
  raw: `{
4425
4206
  "name": "Annual report",
4426
4207
  "assets": [
@@ -4435,15 +4216,13 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4435
4216
  "link": "/existing/appendix.docx"
4436
4217
  }
4437
4218
  ]
4438
- }`,
4439
- },
4440
- ]),
4441
- "document-templates update": buildCommandExamples([
4219
+ }`
4220
+ }
4221
+ ],
4222
+ "document-templates update": [
4442
4223
  {
4443
- description:
4444
- "Rename a template. The template argument accepts a UUID or an exact current name. Only the name is updatable through this endpoint; assets are managed via the assets subcommands.",
4445
- command:
4446
- 'zinkee --json document-templates update "Quarterly report" --name "Annual report"',
4224
+ description: "Rename a template. The template argument accepts a UUID or an exact current name. Only the name is updatable through this endpoint; assets are managed via the assets subcommands.",
4225
+ command: 'zinkee --json document-templates update "Quarterly report" --name "Annual report"',
4447
4226
  raw: `{
4448
4227
  "name": "Annual report"
4449
4228
  }`,
@@ -4461,27 +4240,23 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4461
4240
  "updatedAt": "2026-01-22T09:15:00Z",
4462
4241
  "createdBy": "creator@example.com",
4463
4242
  "updatedBy": "updater@example.com"
4464
- }`,
4465
- },
4466
- ]),
4467
- "document-templates delete": buildCommandExamples([
4243
+ }`
4244
+ }
4245
+ ],
4246
+ "document-templates delete": [
4468
4247
  {
4469
- description:
4470
- "Delete a template and remove its asset files from storage. Record fields that reference previously generated documents are not modified.",
4471
- command:
4472
- "zinkee --json document-templates delete 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e",
4248
+ description: "Delete a template and remove its asset files from storage. Record fields that reference previously generated documents are not modified.",
4249
+ command: "zinkee --json document-templates delete 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e",
4473
4250
  response: `{
4474
4251
  "id": "7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e",
4475
4252
  "deleted": true
4476
- }`,
4477
- },
4478
- ]),
4479
- "document-templates assets add": buildCommandExamples([
4253
+ }`
4254
+ }
4255
+ ],
4256
+ "document-templates assets add": [
4480
4257
  {
4481
- description:
4482
- "Upload a local file as an asset of a template. The CLI sends a multipart form with a part named \"file\"; the asset display name defaults to the uploaded filename.",
4483
- command:
4484
- 'zinkee --json document-templates assets add "Quarterly report" ./contract.docx',
4258
+ description: 'Upload a local file as an asset of a template. The CLI sends a multipart form with a part named "file"; the asset display name defaults to the uploaded filename.',
4259
+ command: 'zinkee --json document-templates assets add "Quarterly report" ./contract.docx',
4485
4260
  response: `{
4486
4261
  "id": "7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e",
4487
4262
  "name": "Quarterly report",
@@ -4496,84 +4271,56 @@ const specificExamples: Record<string, readonly CommandExample[]> = {
4496
4271
  "updatedAt": "2026-01-22T09:15:00Z",
4497
4272
  "createdBy": "creator@example.com",
4498
4273
  "updatedBy": "updater@example.com"
4499
- }`,
4274
+ }`
4500
4275
  },
4501
4276
  {
4502
- description:
4503
- "Override the asset display name with --name (otherwise the uploaded filename is used).",
4504
- command:
4505
- 'zinkee --json document-templates assets add "Quarterly report" ./contract.docx --name "Customer Contract"',
4506
- },
4507
- ]),
4508
- "document-templates assets delete": buildCommandExamples([
4277
+ description: "Override the asset display name with --name (otherwise the uploaded filename is used).",
4278
+ command: 'zinkee --json document-templates assets add "Quarterly report" ./contract.docx --name "Customer Contract"'
4279
+ }
4280
+ ],
4281
+ "document-templates assets delete": [
4509
4282
  {
4510
4283
  description: "Delete one asset from a template and remove its file from storage.",
4511
- command:
4512
- "zinkee --json document-templates assets delete 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e 9e8d7c6b-5a4f-3e2d-1c0b-9a8b7c6d5e4f",
4284
+ command: "zinkee --json document-templates assets delete 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e 9e8d7c6b-5a4f-3e2d-1c0b-9a8b7c6d5e4f",
4513
4285
  response: `{
4514
4286
  "id": "9e8d7c6b-5a4f-3e2d-1c0b-9a8b7c6d5e4f",
4515
4287
  "deleted": true
4516
- }`,
4517
- },
4518
- ]),
4519
- "document-templates assets download": buildCommandExamples([
4288
+ }`
4289
+ }
4290
+ ],
4291
+ "document-templates assets download": [
4520
4292
  {
4521
- description:
4522
- "Download asset bytes to disk. The CLI streams the raw bytes to --output; in --json mode --output is required and the JSON envelope only carries metadata.",
4523
- command:
4524
- "zinkee --json document-templates assets download 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e 9e8d7c6b-5a4f-3e2d-1c0b-9a8b7c6d5e4f --output ./contract.docx",
4293
+ description: "Download asset bytes to disk. The CLI streams the raw bytes to --output; in --json mode --output is required and the JSON envelope only carries metadata.",
4294
+ command: "zinkee --json document-templates assets download 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e 9e8d7c6b-5a4f-3e2d-1c0b-9a8b7c6d5e4f --output ./contract.docx"
4525
4295
  },
4526
4296
  {
4527
- description:
4528
- "Stream asset bytes to stdout (omit --json and --output). Useful for piping into other tools.",
4529
- command:
4530
- "zinkee document-templates assets download 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e 9e8d7c6b-5a4f-3e2d-1c0b-9a8b7c6d5e4f > contract.docx",
4531
- },
4532
- ]),
4297
+ description: "Stream asset bytes to stdout (omit --json and --output). Useful for piping into other tools.",
4298
+ command: "zinkee document-templates assets download 7c4a8d3f-1b2e-4a5c-9d6e-1f2a3b4c5d6e 9e8d7c6b-5a4f-3e2d-1c0b-9a8b7c6d5e4f > contract.docx"
4299
+ }
4300
+ ]
4533
4301
  };
4534
-
4535
- function fallbackExamples(commandName: string): readonly CommandExample[] {
4536
- switch (commandName) {
4537
- default:
4538
- return [];
4539
- }
4540
- }
4541
-
4542
- function buildSchemaFieldCreateExamples(type?: string): readonly CommandExample[] {
4302
+ function buildSchemaFieldCreateExamples(type) {
4543
4303
  const definitions = getSchemaFieldTypeDefinitions();
4544
4304
  const selectedDefinition = resolveSchemaFieldType(type);
4545
- const filteredDefinitions = selectedDefinition
4546
- ? definitions.filter((definition) => definition.key === selectedDefinition.key)
4547
- : definitions;
4548
-
4549
- const flat = filteredDefinitions.flatMap((definition) =>
4550
- definition.examplePayloads.map((example) => ({ definition, example })),
4551
- );
4552
-
4553
- const flagExamples: CommandExample[] =
4554
- selectedDefinition === undefined || selectedDefinition.key === "text"
4555
- ? [
4556
- {
4557
- description: "Text field with a description.",
4558
- command:
4559
- 'zinkee --json schemas fields create contacts --type text --slug customer-name --label "Customer Name" --description "Primary name shown for the customer"',
4560
- raw: `{
4305
+ const filteredDefinitions = selectedDefinition ? definitions.filter((definition) => definition.key === selectedDefinition.key) : definitions;
4306
+ const payloads = filteredDefinitions.flatMap((definition) => definition.examplePayloads);
4307
+ const flagExamples = selectedDefinition === void 0 || selectedDefinition.key === "text" ? [
4308
+ {
4309
+ description: "Text field with a description.",
4310
+ command: 'zinkee --json schemas fields create contacts --type text --slug customer-name --label "Customer Name" --description "Primary name shown for the customer"',
4311
+ raw: `{
4561
4312
  "type": "TextField",
4562
4313
  "slug": "customer-name",
4563
4314
  "label": "Customer Name",
4564
4315
  "description": "Primary name shown for the customer"
4565
- }`,
4566
- },
4567
- ]
4568
- : [];
4569
-
4570
- return buildCommandExamples([
4316
+ }`
4317
+ }
4318
+ ] : [];
4319
+ return [
4571
4320
  ...flagExamples,
4572
- ...flat.map(({ example }, index) => {
4573
- const slug =
4574
- typeof example.payload.slug === "string" ? example.payload.slug : "field";
4321
+ ...payloads.map((example, index) => {
4322
+ const slug = typeof example.payload.slug === "string" ? example.payload.slug : "field";
4575
4323
  const command = `zinkee --json schemas fields create contacts --raw '${JSON.stringify(example.payload)}'`;
4576
-
4577
4324
  if (index === 0) {
4578
4325
  return {
4579
4326
  description: example.name,
@@ -4582,58 +4329,36 @@ function buildSchemaFieldCreateExamples(type?: string): readonly CommandExample[
4582
4329
  "schemaId": "2eb8bdcf-6d9c-4fbb-9018-7fa8180f4c5e",
4583
4330
  "fieldId": "a8f1d7e3-2b5c-4d9e-8a1b-3c4d5e6f7890",
4584
4331
  "slug": "${slug}"
4585
- }`,
4332
+ }`
4586
4333
  };
4587
4334
  }
4588
-
4589
4335
  return {
4590
4336
  description: example.name,
4591
- command,
4337
+ command
4592
4338
  };
4593
- }),
4594
- ]);
4339
+ })
4340
+ ];
4595
4341
  }
4596
-
4597
- export function getCommandExamples(
4598
- commandName: string,
4599
- filters: { type?: string } = {},
4600
- ): readonly CommandExample[] {
4601
- const examples =
4602
- commandName === "schemas fields create"
4603
- ? buildSchemaFieldCreateExamples(filters.type)
4604
- : (specificExamples[commandName] ?? fallbackExamples(commandName));
4605
-
4342
+ function getCommandExamples(commandName, filters = {}) {
4343
+ const examples = commandName === "schemas fields create" ? buildSchemaFieldCreateExamples(filters.type) : specificExamples[commandName] ?? [];
4606
4344
  return examples.map((example) => withResponseEnvelope(example, commandName));
4607
4345
  }
4608
-
4609
- // The CLI's --json output wraps every payload in a { data, meta } envelope (see
4610
- // buildJsonSuccess in ./output). Example "response" bodies are authored as the
4611
- // bare data payload for readability, so we wrap them here to match what the
4612
- // command actually prints. Non-JSON responses (if any) are left untouched.
4613
- function withResponseEnvelope(
4614
- example: CommandExample,
4615
- commandName: string,
4616
- ): CommandExample {
4617
- if (example.response === undefined) {
4346
+ function withResponseEnvelope(example, commandName) {
4347
+ if (example.response === void 0) {
4618
4348
  return example;
4619
4349
  }
4620
-
4621
- let payload: unknown;
4350
+ let payload;
4622
4351
  try {
4623
4352
  payload = JSON.parse(example.response);
4624
4353
  } catch {
4625
4354
  return example;
4626
4355
  }
4627
-
4628
4356
  return {
4629
4357
  ...example,
4630
- response: JSON.stringify(buildJsonSuccess(payload, { command: commandName }), null, 2),
4358
+ response: JSON.stringify(buildJsonSuccess(payload, { command: commandName }), null, 2)
4631
4359
  };
4632
4360
  }
4633
-
4634
- export function getResolvedCommandExamples(
4635
- commandName: string,
4636
- filters: { type?: string } = {},
4637
- ): readonly CommandExample[] {
4638
- return getCommandExamples(commandName, filters);
4639
- }
4361
+ export {
4362
+ getCommandExamples
4363
+ };
4364
+ //# sourceMappingURL=examples-67U5IRBS.js.map