@cxtms/cx-schema 1.6.7 → 1.7.1

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.
@@ -1,6 +1,8 @@
1
1
  ---
2
2
  name: cx-core
3
- description: Shared CargoXplorer entity field reference — domain entities, field names, enums, and customValues patterns
3
+ description: >
4
+ Shared CargoXplorer entity field reference — domain entities, field names, enums, and customValues patterns.
5
+ TRIGGER when: user asks about CX entity fields, enums, customValues, entity relationships, or needs domain reference for Orders, Contacts, Commodities, Jobs, etc.
4
6
  argument-hint: <entity name or question about fields>
5
7
  ---
6
8
 
@@ -14,10 +16,10 @@ The CLI can authenticate against CX environments and manage server resources. Au
14
16
 
15
17
  ```bash
16
18
  # Login to a CX environment (OAuth2 + PKCE — opens browser)
17
- npx cx-cli login https://tms-v3-dev.usatrt.com
19
+ npx cxtms login https://tms-v3-dev.usatrt.com
18
20
 
19
21
  # Logout from current session
20
- npx cx-cli logout
22
+ npx cxtms logout
21
23
  ```
22
24
 
23
25
  The session is stored at `~/.cxtms/<project-dir>/.session.json`, scoped by project directory name. Each project gets its own server session. The CLI auto-refreshes expired tokens.
@@ -28,16 +30,16 @@ For CI/CD or headless environments, use Personal Access Tokens instead of intera
28
30
 
29
31
  ```bash
30
32
  # Check PAT status and setup instructions
31
- npx cx-cli pat setup
33
+ npx cxtms pat setup
32
34
 
33
35
  # Create a new PAT token (requires OAuth login first)
34
- npx cx-cli pat create "my-ci-token"
36
+ npx cxtms pat create "my-ci-token"
35
37
 
36
38
  # List active PAT tokens
37
- npx cx-cli pat list
39
+ npx cxtms pat list
38
40
 
39
41
  # Revoke a PAT token
40
- npx cx-cli pat revoke <tokenId>
42
+ npx cxtms pat revoke <tokenId>
41
43
  ```
42
44
 
43
45
  After creating a PAT, add to `.env` in your project root:
@@ -52,16 +54,16 @@ When `CXTMS_AUTH` is set, the CLI skips OAuth and uses the PAT token directly. `
52
54
 
53
55
  ```bash
54
56
  # List organizations on the server
55
- npx cx-cli orgs list
57
+ npx cxtms orgs list
56
58
 
57
59
  # Select an organization interactively
58
- npx cx-cli orgs select
60
+ npx cxtms orgs select
59
61
 
60
62
  # Set active organization by ID
61
- npx cx-cli orgs use <orgId>
63
+ npx cxtms orgs use <orgId>
62
64
 
63
65
  # Show current context (server, org, app)
64
- npx cx-cli orgs use
66
+ npx cxtms orgs use
65
67
  ```
66
68
 
67
69
  The active org is cached in the session file and used by all server commands. Override with `--org <id>`.
@@ -77,14 +79,14 @@ Server commands resolve the target session in this order:
77
79
 
78
80
  ```bash
79
81
  # Publish all modules and workflows from current project
80
- npx cx-cli publish
82
+ npx cxtms publish
81
83
 
82
84
  # Publish only a specific feature directory
83
- npx cx-cli publish --feature billing
84
- npx cx-cli publish billing
85
+ npx cxtms publish --feature billing
86
+ npx cxtms publish billing
85
87
 
86
88
  # Publish with explicit org ID
87
- npx cx-cli publish --org 42
89
+ npx cxtms publish --org 42
88
90
  ```
89
91
 
90
92
  Validates all YAML files first, then pushes modules and workflows to the server. Skips files with validation errors and reports results.
@@ -106,7 +108,7 @@ When creating new modules or workflows, always place them under the correct feat
106
108
  - `features/<feature_name>/modules/<name>-module.yaml`
107
109
  - `features/<feature_name>/workflows/<name>.yaml`
108
110
 
109
- Use `--feature <feature_name>` with `cx-cli create` to automatically place files in the correct location.
111
+ Use `--feature <feature_name>` with `cxtms create` to automatically place files in the correct location.
110
112
 
111
113
  ## Entity Field Reference
112
114
 
@@ -1,33 +1,36 @@
1
1
  ---
2
2
  name: cx-module
3
- description: Generate schema-valid CargoXplorer app module YAML files (UI screens, forms, grids, routes)
3
+ description: >
4
+ Generate schema-valid CargoXplorer app module YAML files (UI screens, forms, grids, routes).
5
+ TRIGGER when: user asks to create, modify, or fix a module YAML file, or references *-module.yaml files, or asks about UI components/forms/grids/routes in a CX project.
6
+ DO NOT TRIGGER when: working with workflow YAML files, general TypeScript/code changes, or non-YAML tasks.
4
7
  argument-hint: <description of what to build>
5
8
  ---
6
9
 
7
10
  You are a CargoXplorer module YAML builder. You generate schema-valid YAML for CX app modules — UI screens, forms, data grids, routes, and components. All output must conform to the JSON schemas in `.cx-schema/`.
8
11
 
9
- **IMPORTANT — use `cx-cli` for all module operations:**
10
- - **Scaffold**: `npx cx-cli create module <name> --template <template>` — generates a schema-valid YAML file. ALWAYS run this first, then read the generated file, then customize. Do NOT write YAML from scratch or copy templates manually.
11
- - **Scaffold with fields**: `npx cx-cli create module <name> --template <template> --options '<json>'`
12
- - **Validate**: `npx cx-cli <file.yaml>` — run after every change
13
- - **Schema lookup**: `npx cx-cli schema <component>` — e.g., `cx-cli schema form`, `cx-cli schema dataGrid`
14
- - **Examples**: `npx cx-cli example <component>` — show example YAML
15
- - **List schemas**: `npx cx-cli list`
16
- - **Extract**: `npx cx-cli extract <source> <component> --to <target>` — move components between modules
17
- - **Feature folder**: `npx cx-cli create module <name> --template <template> --feature <feature-name>`
18
- - **Deploy to server**: `npx cx-cli appmodule deploy <file.yaml>` — creates or updates module on the CX server
19
- - **Undeploy from server**: `npx cx-cli appmodule undeploy <appModuleId>` — removes a module by UUID
20
- - **Publish all**: `npx cx-cli publish [--feature <name>]` — push all modules and workflows to the server
12
+ **IMPORTANT — use `cxtms` for all module operations:**
13
+ - **Scaffold**: `npx cxtms create module <name> --template <template>` — generates a schema-valid YAML file. ALWAYS run this first, then read the generated file, then customize. Do NOT write YAML from scratch or copy templates manually.
14
+ - **Scaffold with fields**: `npx cxtms create module <name> --template <template> --options '<json>'`
15
+ - **Validate**: `npx cxtms <file.yaml>` — run after every change
16
+ - **Schema lookup**: `npx cxtms schema <component>` — e.g., `cxtms schema form`, `cxtms schema dataGrid`
17
+ - **Examples**: `npx cxtms example <component>` — show example YAML
18
+ - **List schemas**: `npx cxtms list`
19
+ - **Extract**: `npx cxtms extract <source> <component> --to <target>` — move components between modules
20
+ - **Feature folder**: `npx cxtms create module <name> --template <template> --feature <feature-name>`
21
+ - **Deploy to server**: `npx cxtms appmodule deploy <file.yaml>` — creates or updates module on the CX server
22
+ - **Undeploy from server**: `npx cxtms appmodule undeploy <appModuleId>` — removes a module by UUID
23
+ - **Publish all**: `npx cxtms publish [--feature <name>]` — push all modules and workflows to the server
21
24
 
22
25
  ## Generation Workflow
23
26
 
24
27
  ### Step 1: Scaffold via CLI — MANDATORY
25
28
 
26
- **You MUST run `cx-cli create module` to generate the initial file.** Do not skip this step. Do not write YAML from scratch. Do not read template files and copy them manually. The CLI generates correct UUIDs, file paths, and structure.
29
+ **You MUST run `cxtms create module` to generate the initial file.** Do not skip this step. Do not write YAML from scratch. Do not read template files and copy them manually. The CLI generates correct UUIDs, file paths, and structure.
27
30
 
28
31
  ```bash
29
- npx cx-cli create module <name> --template <template>
30
- npx cx-cli create module <name> --template <template> --options '<json>'
32
+ npx cxtms create module <name> --template <template>
33
+ npx cxtms create module <name> --template <template> --options '<json>'
31
34
  ```
32
35
 
33
36
  | Template | Use Case |
@@ -55,7 +58,7 @@ npx cx-cli create module <name> --template <template> --options '<json>'
55
58
  ### Step 4: Validate
56
59
 
57
60
  ```bash
58
- npx cx-cli <generated-file.yaml>
61
+ npx cxtms <generated-file.yaml>
59
62
  ```
60
63
 
61
64
  ---
@@ -67,7 +70,7 @@ Customize generated modules at scaffold time with `--options`. Accepts inline JS
67
70
  ### Field Array Format (all templates)
68
71
 
69
72
  ```bash
70
- npx cx-cli create module "Tariff" --template grid --options '[
73
+ npx cxtms create module "Tariff" --template grid --options '[
71
74
  {"name": "code", "type": "text", "label": "Tariff Code", "required": true},
72
75
  {"name": "rate", "type": "number", "label": "Rate %"},
73
76
  {"name": "effectiveDate", "type": "date"},
@@ -78,7 +81,7 @@ npx cx-cli create module "Tariff" --template grid --options '[
78
81
  ### Object Format (with entityName)
79
82
 
80
83
  ```bash
81
- npx cx-cli create module "Country" --template select --options '{
84
+ npx cxtms create module "Country" --template select --options '{
82
85
  "entityName": "Country",
83
86
  "fields": [
84
87
  {"name": "countryCode", "type": "text", "label": "Country Code"},
@@ -113,8 +116,8 @@ npx cx-cli create module "Country" --template select --options '{
113
116
  Move or copy a component (and its routes) from one module into another. Useful for splitting large modules or sharing components.
114
117
 
115
118
  ```bash
116
- cx-cli extract <source-file> <component-name> --to <target-file>
117
- cx-cli extract <source-file> <component-name> --to <target-file> --copy
119
+ cxtms extract <source-file> <component-name> --to <target-file>
120
+ cxtms extract <source-file> <component-name> --to <target-file> --copy
118
121
  ```
119
122
 
120
123
  ### Flags
@@ -130,13 +133,13 @@ cx-cli extract <source-file> <component-name> --to <target-file> --copy
130
133
 
131
134
  ```bash
132
135
  # Move a component to a new file (creates module scaffold automatically)
133
- npx cx-cli extract modules/orders.yaml Orders/CreateItem --to modules/order-create.yaml
136
+ npx cxtms extract modules/orders.yaml Orders/CreateItem --to modules/order-create.yaml
134
137
 
135
138
  # Copy a component (source unchanged, target gets higher priority)
136
- npx cx-cli extract modules/orders.yaml Orders/CreateItem --to modules/order-create.yaml --copy
139
+ npx cxtms extract modules/orders.yaml Orders/CreateItem --to modules/order-create.yaml --copy
137
140
 
138
141
  # Extract to an existing module
139
- npx cx-cli extract modules/main.yaml Dashboard --to modules/dashboard.yaml
142
+ npx cxtms extract modules/main.yaml Dashboard --to modules/dashboard.yaml
140
143
  ```
141
144
 
142
145
  ### New Target Scaffold
@@ -149,7 +152,7 @@ When the target file doesn't exist, a new module is created with:
149
152
  ### Workflow
150
153
  1. Run `extract` to move the component
151
154
  2. Manually move any related permissions/entities if needed
152
- 3. Validate both files: `npx cx-cli <source>` and `npx cx-cli <target>`
155
+ 3. Validate both files: `npx cxtms <source>` and `npx cxtms <target>`
153
156
 
154
157
  ---
155
158
 
@@ -401,26 +404,26 @@ Reusable select components (e.g., `Countries/Select`, `Ports/Select`) follow thi
401
404
 
402
405
  ```bash
403
406
  # Deploy a module YAML to the server (creates or updates)
404
- npx cx-cli appmodule deploy modules/my-module.yaml
407
+ npx cxtms appmodule deploy modules/my-module.yaml
405
408
 
406
409
  # Deploy with explicit org ID
407
- npx cx-cli appmodule deploy modules/my-module.yaml --org 42
410
+ npx cxtms appmodule deploy modules/my-module.yaml --org 42
408
411
 
409
412
  # Undeploy an app module by UUID
410
- npx cx-cli appmodule undeploy <appModuleId>
413
+ npx cxtms appmodule undeploy <appModuleId>
411
414
 
412
415
  # Publish all modules and workflows (validates first)
413
- npx cx-cli publish
414
- npx cx-cli publish --feature billing
416
+ npx cxtms publish
417
+ npx cxtms publish --feature billing
415
418
  ```
416
419
 
417
- Deploy reads `module.appModuleId` from the YAML, queries the server, and creates or updates accordingly. Requires an active session (`cx-cli login` or PAT token — see cx-core skill).
420
+ Deploy reads `module.appModuleId` from the YAML, queries the server, and creates or updates accordingly. Requires an active session (`cxtms login` or PAT token — see cx-core skill).
418
421
 
419
422
  ---
420
423
 
421
424
  # Generation Rules
422
425
 
423
- 1. **Always scaffold via `cx-cli create module` first** — never write YAML from scratch, never copy templates manually
426
+ 1. **Always scaffold via `cxtms create module` first** — never write YAML from scratch, never copy templates manually
424
427
  2. **Use localized strings** `{ en-US: "..." }` for all user-visible text
425
428
  3. **Follow naming conventions**:
426
429
  - Module names: PascalCase (e.g., `WarehouseLocations`)
@@ -433,4 +436,4 @@ Deploy reads `module.appModuleId` from the YAML, queries the server, and creates
433
436
  7. **DataGrid options** requires ALL properties: query, rootEntityName, entityKeys, navigationType, enableDynamicGrid, enableViews, enableSearch, enablePagination, enableColumns, enableFilter, defaultView, onRowClick
434
437
  8. **Form component** requires `validationSchema` in props
435
438
  9. **Do not change `appModuleId` or `filePath`** — set correctly by CLI scaffold
436
- 10. **Always validate** the final YAML: `npx cx-cli <file.yaml>`
439
+ 10. **Always validate** the final YAML: `npx cxtms <file.yaml>`
@@ -1,33 +1,36 @@
1
1
  ---
2
2
  name: cx-workflow
3
- description: Generate schema-valid CargoXplorer workflow YAML files (standard process and Flow state machine workflows)
3
+ description: >
4
+ Generate schema-valid CargoXplorer workflow YAML files (standard process and Flow state machine workflows).
5
+ TRIGGER when: user asks to create, modify, or fix a workflow YAML file, or references workflow/*.yaml files, or asks about workflow tasks/triggers/activities in a CX project.
6
+ DO NOT TRIGGER when: working with module YAML files, general TypeScript/code changes, or non-YAML tasks.
4
7
  argument-hint: <description of what to build>
5
8
  ---
6
9
 
7
10
  You are a CargoXplorer workflow YAML builder. You generate schema-valid YAML for CX workflows — both standard process workflows (activities, steps, triggers) and Flow state machine workflows (entity lifecycle, states, transitions). All output must conform to the JSON schemas in `.cx-schema/`.
8
11
 
9
- **IMPORTANT — use `cx-cli` for all workflow operations:**
10
- - **Scaffold**: `npx cx-cli create workflow <name> --template <template>` — generates a schema-valid YAML file. ALWAYS run this first, then read the generated file, then customize. Do NOT write YAML from scratch or copy templates manually.
11
- - **Validate**: `npx cx-cli <file.yaml>` — run after every change
12
- - **Schema lookup**: `npx cx-cli schema <task>` — e.g., `cx-cli schema graphql`, `cx-cli schema foreach`, `cx-cli schema action-event`. Schema names use kebab-case file names. Case-insensitive: `ActionEvent` resolves to `action-event`.
13
- - **Examples**: `npx cx-cli example <task>` — show example YAML for a task
14
- - **List schemas**: `npx cx-cli list --type workflow` — shows all available task schemas in the Tasks section
15
- - **Feature folder**: `npx cx-cli create workflow <name> --template <template> --feature <feature-name>`
16
- - **Deploy to server**: `npx cx-cli workflow deploy <file.yaml>` — creates or updates workflow on the CX server
17
- - **Undeploy from server**: `npx cx-cli workflow undeploy <workflowId>` — removes a workflow by UUID
18
- - **Execute**: `npx cx-cli workflow execute <workflowId|file.yaml> [--vars '<json>']` — trigger a workflow execution
19
- - **List logs**: `npx cx-cli workflow logs <workflowId|file.yaml> [--from YYYY-MM-DD] [--to YYYY-MM-DD]` — list executions with log availability
20
- - **Download log**: `npx cx-cli workflow log <executionId> [--json] [--console] [--output <file>]` — download execution log
21
- - **Publish all**: `npx cx-cli publish [--feature <name>]` — push all modules and workflows to the server
12
+ **IMPORTANT — use `cxtms` for all workflow operations:**
13
+ - **Scaffold**: `npx cxtms create workflow <name> --template <template>` — generates a schema-valid YAML file. ALWAYS run this first, then read the generated file, then customize. Do NOT write YAML from scratch or copy templates manually.
14
+ - **Validate**: `npx cxtms <file.yaml>` — run after every change
15
+ - **Schema lookup**: `npx cxtms schema <task>` — e.g., `cxtms schema graphql`, `cxtms schema foreach`, `cxtms schema action-event`. Schema names use kebab-case file names. Case-insensitive: `ActionEvent` resolves to `action-event`.
16
+ - **Examples**: `npx cxtms example <task>` — show example YAML for a task
17
+ - **List schemas**: `npx cxtms list --type workflow` — shows all available task schemas in the Tasks section
18
+ - **Feature folder**: `npx cxtms create workflow <name> --template <template> --feature <feature-name>`
19
+ - **Deploy to server**: `npx cxtms workflow deploy <file.yaml>` — creates or updates workflow on the CX server
20
+ - **Undeploy from server**: `npx cxtms workflow undeploy <workflowId>` — removes a workflow by UUID
21
+ - **Execute**: `npx cxtms workflow execute <workflowId|file.yaml> [--vars '<json>']` — trigger a workflow execution
22
+ - **List logs**: `npx cxtms workflow logs <workflowId|file.yaml> [--from YYYY-MM-DD] [--to YYYY-MM-DD]` — list executions with log availability
23
+ - **Download log**: `npx cxtms workflow log <executionId> [--json] [--console] [--output <file>]` — download execution log
24
+ - **Publish all**: `npx cxtms publish [--feature <name>]` — push all modules and workflows to the server
22
25
 
23
26
  ## Generation Workflow
24
27
 
25
28
  ### Step 1: Scaffold via CLI — MANDATORY
26
29
 
27
- **You MUST run `cx-cli create workflow` to generate the initial file.** Do not skip this step. Do not write YAML from scratch. Do not read template files and copy them manually. The CLI generates correct UUIDs, file paths, and structure.
30
+ **You MUST run `cxtms create workflow` to generate the initial file.** Do not skip this step. Do not write YAML from scratch. Do not read template files and copy them manually. The CLI generates correct UUIDs, file paths, and structure.
28
31
 
29
32
  ```bash
30
- npx cx-cli create workflow <name> --template <template>
33
+ npx cxtms create workflow <name> --template <template>
31
34
  ```
32
35
 
33
36
  | Template | Use Case |
@@ -77,7 +80,7 @@ npx cx-cli create workflow <name> --template <template>
77
80
  ### Step 4: Validate
78
81
 
79
82
  ```bash
80
- npx cx-cli <generated-file.yaml>
83
+ npx cxtms <generated-file.yaml>
81
84
  ```
82
85
 
83
86
  ### File Placement
@@ -319,27 +322,27 @@ Implicit variable: `iteration` (zero-based).
319
322
 
320
323
  ```bash
321
324
  # Push a workflow YAML to the server (creates or updates)
322
- npx cx-cli workflow deploy workflows/my-workflow.yaml
325
+ npx cxtms workflow deploy workflows/my-workflow.yaml
323
326
 
324
327
  # Delete a workflow by UUID
325
- npx cx-cli workflow undeploy <workflowId>
328
+ npx cxtms workflow undeploy <workflowId>
326
329
 
327
330
  # Publish all modules and workflows (validates first)
328
- npx cx-cli publish
329
- npx cx-cli publish --feature billing
331
+ npx cxtms publish
332
+ npx cxtms publish --feature billing
330
333
  ```
331
334
 
332
- Deploy reads `workflow.workflowId` from the YAML, queries the server, and creates or updates accordingly. Requires an active session (`cx-cli login` or PAT token — see cx-core skill).
335
+ Deploy reads `workflow.workflowId` from the YAML, queries the server, and creates or updates accordingly. Requires an active session (`cxtms login` or PAT token — see cx-core skill).
333
336
 
334
337
  ### Execute
335
338
 
336
339
  ```bash
337
340
  # Execute a workflow by UUID or YAML file
338
- npx cx-cli workflow execute <workflowId>
339
- npx cx-cli workflow execute workflows/my-workflow.yaml
341
+ npx cxtms workflow execute <workflowId>
342
+ npx cxtms workflow execute workflows/my-workflow.yaml
340
343
 
341
344
  # Pass input variables as JSON
342
- npx cx-cli workflow execute <workflowId> --vars '{"city": "London", "count": 5}'
345
+ npx cxtms workflow execute <workflowId> --vars '{"city": "London", "count": 5}'
343
346
  ```
344
347
 
345
348
  Returns execution result including `executionId`, `isAsync`, `outputs` (for Sync workflows).
@@ -348,25 +351,25 @@ Returns execution result including `executionId`, `isAsync`, `outputs` (for Sync
348
351
 
349
352
  ```bash
350
353
  # List executions with log availability (sorted desc by date)
351
- npx cx-cli workflow logs <workflowId|file.yaml>
354
+ npx cxtms workflow logs <workflowId|file.yaml>
352
355
 
353
356
  # Filter by date range
354
- npx cx-cli workflow logs <workflowId> --from 2026-01-01 --to 2026-01-31
357
+ npx cxtms workflow logs <workflowId> --from 2026-01-01 --to 2026-01-31
355
358
 
356
359
  # Download a specific execution log (saves to temp dir by default)
357
- npx cx-cli workflow log <executionId>
360
+ npx cxtms workflow log <executionId>
358
361
 
359
362
  # Save to specific file
360
- npx cx-cli workflow log <executionId> --output mylog.txt
363
+ npx cxtms workflow log <executionId> --output mylog.txt
361
364
 
362
365
  # Print to stdout
363
- npx cx-cli workflow log <executionId> --console
366
+ npx cxtms workflow log <executionId> --console
364
367
 
365
368
  # Download JSON log (richer data: inputs, outputs, timing, metadata)
366
- npx cx-cli workflow log <executionId> --json
369
+ npx cxtms workflow log <executionId> --json
367
370
 
368
371
  # JSON log to stdout
369
- npx cx-cli workflow log <executionId> --json --console
372
+ npx cxtms workflow log <executionId> --json --console
370
373
  ```
371
374
 
372
375
  `workflow logs` shows a table with execution status, date, duration, user, and log availability indicators (filled/empty circle). `workflow log` downloads the actual log content from the server (gzip-compressed S3 URLs).
@@ -382,7 +385,7 @@ npx cx-cli workflow log <executionId> --json --console
382
385
 
383
386
  ## Generation Rules
384
387
 
385
- 1. **Always scaffold via `cx-cli create workflow` first** — never write YAML from scratch, never copy templates manually
388
+ 1. **Always scaffold via `cxtms create workflow` first** — never write YAML from scratch, never copy templates manually
386
389
  2. **Naming conventions**: step names PascalCase, variables camelCase, states PascalCase, transitions camelCase
387
390
  3. **Template expressions** use `{{ expression }}` — NCalc conditions use `[variable]`
388
391
  4. **Do not change `workflowId` or `filePath`** — set correctly by CLI scaffold
@@ -390,4 +393,4 @@ npx cx-cli workflow log <executionId> --json --console
390
393
  6. **Flow workflows** require `entity`, `states`, `transitions` (no `activities`)
391
394
  7. **Entity triggers** require `entityName` and `eventType`
392
395
  8. **Always use null-safe `?`** on variable paths — `Activity?.Step?.output?` — unless referencing guaranteed system variables (see Variable References section)
393
- 9. **Always validate** the final YAML: `npx cx-cli <file.yaml>`
396
+ 9. **Always validate** the final YAML: `npx cxtms <file.yaml>`
package/README.md CHANGED
@@ -29,19 +29,19 @@ npm install @cxtms/cx-schema
29
29
 
30
30
  ```bash
31
31
  # Initialize a new project
32
- npx cx-cli init
32
+ npx cxtms init
33
33
 
34
34
  # Create a new module
35
- npx cx-cli create module orders
35
+ npx cxtms create module orders
36
36
 
37
37
  # Create a new workflow
38
- npx cx-cli create workflow invoice-processor
38
+ npx cxtms create workflow invoice-processor
39
39
 
40
40
  # Validate files
41
- npx cx-cli modules/*.yaml workflows/*.yaml
41
+ npx cxtms modules/*.yaml workflows/*.yaml
42
42
 
43
43
  # Generate validation report
44
- npx cx-cli report modules/*.yaml --report report.html
44
+ npx cxtms report modules/*.yaml --report report.html
45
45
  ```
46
46
 
47
47
  ## CLI Commands
@@ -51,14 +51,14 @@ npx cx-cli report modules/*.yaml --report report.html
51
51
  Validate YAML file(s) against JSON Schema definitions.
52
52
 
53
53
  ```bash
54
- cx-cli [files...]
55
- cx-cli validate [files...]
54
+ cxtms [files...]
55
+ cxtms validate [files...]
56
56
 
57
57
  # Examples
58
- cx-cli modules/orders-module.yaml
59
- cx-cli modules/*.yaml workflows/*.yaml
60
- cx-cli --verbose modules/orders-module.yaml
61
- cx-cli --format json modules/orders-module.yaml
58
+ cxtms modules/orders-module.yaml
59
+ cxtms modules/*.yaml workflows/*.yaml
60
+ cxtms --verbose modules/orders-module.yaml
61
+ cxtms --format json modules/orders-module.yaml
62
62
  ```
63
63
 
64
64
  ### init
@@ -66,7 +66,7 @@ cx-cli --format json modules/orders-module.yaml
66
66
  Initialize a new CX project with configuration files.
67
67
 
68
68
  ```bash
69
- cx-cli init
69
+ cxtms init
70
70
  ```
71
71
 
72
72
  Creates:
@@ -81,11 +81,11 @@ Creates:
81
81
  Create a new module or workflow from template.
82
82
 
83
83
  ```bash
84
- cx-cli create <type> <name>
84
+ cxtms create <type> <name>
85
85
 
86
86
  # Examples
87
- cx-cli create module orders
88
- cx-cli create workflow invoice-generator
87
+ cxtms create module orders
88
+ cxtms create workflow invoice-generator
89
89
  ```
90
90
 
91
91
  Generated files include:
@@ -98,12 +98,12 @@ Generated files include:
98
98
  Generate validation report for multiple files.
99
99
 
100
100
  ```bash
101
- cx-cli report [files...] --report <output-file>
101
+ cxtms report [files...] --report <output-file>
102
102
 
103
103
  # Examples
104
- cx-cli report modules/*.yaml --report report.html
105
- cx-cli report workflows/*.yaml --report report.md
106
- cx-cli report modules/*.yaml workflows/*.yaml --report results.json
104
+ cxtms report modules/*.yaml --report report.html
105
+ cxtms report workflows/*.yaml --report report.md
106
+ cxtms report modules/*.yaml workflows/*.yaml --report results.json
107
107
  ```
108
108
 
109
109
  Report formats (auto-detected from extension):
@@ -116,13 +116,13 @@ Report formats (auto-detected from extension):
116
116
  Display the JSON Schema definition for a component or task.
117
117
 
118
118
  ```bash
119
- cx-cli schema <name>
119
+ cxtms schema <name>
120
120
 
121
121
  # Examples
122
- cx-cli schema form
123
- cx-cli schema dataGrid
124
- cx-cli schema workflow
125
- cx-cli schema foreach
122
+ cxtms schema form
123
+ cxtms schema dataGrid
124
+ cxtms schema workflow
125
+ cxtms schema foreach
126
126
  ```
127
127
 
128
128
  ### example
@@ -130,11 +130,11 @@ cx-cli schema foreach
130
130
  Show example YAML for a component or task.
131
131
 
132
132
  ```bash
133
- cx-cli example <name>
133
+ cxtms example <name>
134
134
 
135
135
  # Examples
136
- cx-cli example form
137
- cx-cli example workflow
136
+ cxtms example form
137
+ cxtms example workflow
138
138
  ```
139
139
 
140
140
  ### list
@@ -142,9 +142,9 @@ cx-cli example workflow
142
142
  List all available schemas for validation.
143
143
 
144
144
  ```bash
145
- cx-cli list
146
- cx-cli list --type module
147
- cx-cli list --type workflow
145
+ cxtms list
146
+ cxtms list --type module
147
+ cxtms list --type workflow
148
148
  ```
149
149
 
150
150
  ## CLI Options
@@ -298,11 +298,11 @@ Generated workflows include:
298
298
  ```yaml
299
299
  - name: Validate YAML files
300
300
  run: |
301
- npx cx-cli --format compact modules/*.yaml workflows/*.yaml
301
+ npx cxtms --format compact modules/*.yaml workflows/*.yaml
302
302
 
303
303
  - name: Generate validation report
304
304
  run: |
305
- npx cx-cli report modules/*.yaml workflows/*.yaml --report validation-report.html
305
+ npx cxtms report modules/*.yaml workflows/*.yaml --report validation-report.html
306
306
 
307
307
  - name: Upload report
308
308
  uses: actions/upload-artifact@v3
@@ -316,7 +316,7 @@ Generated workflows include:
316
316
  ```yaml
317
317
  validate:
318
318
  script:
319
- - npx cx-cli --format json modules/*.yaml > validation-results.json
319
+ - npx cxtms --format json modules/*.yaml > validation-results.json
320
320
  artifacts:
321
321
  paths:
322
322
  - validation-results.json
@@ -331,7 +331,7 @@ validate:
331
331
  staged_files=$(git diff --cached --name-only --diff-filter=ACM | grep -E '\.(yaml|yml)$')
332
332
 
333
333
  if [ -n "$staged_files" ]; then
334
- npx cx-cli --format compact $staged_files
334
+ npx cxtms --format compact $staged_files
335
335
  if [ $? -ne 0 ]; then
336
336
  echo "Validation failed. Please fix errors before committing."
337
337
  exit 1