@gonovus-ai/spec-flow-cli 0.6.3 → 1.0.0

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 +58 -7
  2. package/dist/authentication-command-topology.js.map +1 -1
  3. package/dist/bin.js.map +1 -1
  4. package/dist/cli.d.ts +1 -1
  5. package/dist/cli.js +864 -287
  6. package/dist/cli.js.map +1 -1
  7. package/dist/client-identity.d.ts +1 -1
  8. package/dist/client-identity.js +3 -1
  9. package/dist/client-identity.js.map +1 -1
  10. package/dist/commands/client-compatibility.d.ts +3 -0
  11. package/dist/commands/client-compatibility.js +191 -0
  12. package/dist/commands/client-compatibility.js.map +1 -0
  13. package/dist/commands/guide.d.ts +2 -0
  14. package/dist/commands/guide.js +35 -0
  15. package/dist/commands/guide.js.map +1 -0
  16. package/dist/commands/work-item-output.d.ts +15 -5
  17. package/dist/commands/work-item-output.js +47 -9
  18. package/dist/commands/work-item-output.js.map +1 -1
  19. package/dist/credential-store.js +6 -7
  20. package/dist/credential-store.js.map +1 -1
  21. package/dist/custom-field-color-commands.js +13 -3
  22. package/dist/custom-field-color-commands.js.map +1 -1
  23. package/dist/default-api-origin.js.map +1 -1
  24. package/dist/github-account-commands.js +116 -20
  25. package/dist/github-account-commands.js.map +1 -1
  26. package/dist/github-connection-commands.js +284 -36
  27. package/dist/github-connection-commands.js.map +1 -1
  28. package/dist/github-import-commands.js +41 -11
  29. package/dist/github-import-commands.js.map +1 -1
  30. package/dist/http-origin.js +1 -1
  31. package/dist/http-origin.js.map +1 -1
  32. package/dist/index.d.ts +2 -2
  33. package/dist/index.js +125 -35
  34. package/dist/index.js.map +1 -1
  35. package/dist/input/text-source.js +8 -2
  36. package/dist/input/text-source.js.map +1 -1
  37. package/dist/node-version.js.map +1 -1
  38. package/dist/product-map-commands.js +220 -37
  39. package/dist/product-map-commands.js.map +1 -1
  40. package/dist/program.js +9 -3
  41. package/dist/program.js.map +1 -1
  42. package/dist/project-administration-commands.js +36 -8
  43. package/dist/project-administration-commands.js.map +1 -1
  44. package/dist/runtime/client-compatibility.d.ts +13 -0
  45. package/dist/runtime/client-compatibility.js +79 -0
  46. package/dist/runtime/client-compatibility.js.map +1 -0
  47. package/dist/runtime/errors.js +21 -3
  48. package/dist/runtime/errors.js.map +1 -1
  49. package/dist/runtime/execute.js +16 -2
  50. package/dist/runtime/execute.js.map +1 -1
  51. package/dist/runtime/identity.d.ts +8 -80
  52. package/dist/runtime/identity.js +21 -4
  53. package/dist/runtime/identity.js.map +1 -1
  54. package/dist/runtime/npm-upgrade.d.ts +32 -0
  55. package/dist/runtime/npm-upgrade.js +132 -0
  56. package/dist/runtime/npm-upgrade.js.map +1 -0
  57. package/dist/runtime/output.js +6 -1
  58. package/dist/runtime/output.js.map +1 -1
  59. package/dist/runtime/session.js +44 -11
  60. package/dist/runtime/session.js.map +1 -1
  61. package/dist/screen-image-commands.js +66 -14
  62. package/dist/screen-image-commands.js.map +1 -1
  63. package/dist/spec-discussion-commands.js +87 -24
  64. package/dist/spec-discussion-commands.js.map +1 -1
  65. package/dist/spec-owner-commands.js +22 -7
  66. package/dist/spec-owner-commands.js.map +1 -1
  67. package/dist/user-api-key-commands.js +92 -20
  68. package/dist/user-api-key-commands.js.map +1 -1
  69. package/dist/work-item-asset-commands.js +23 -6
  70. package/dist/work-item-asset-commands.js.map +1 -1
  71. package/dist/work-item-delivery-commands.js +97 -31
  72. package/dist/work-item-delivery-commands.js.map +1 -1
  73. package/dist/work-item-exchange-file.js +22 -8
  74. package/dist/work-item-exchange-file.js.map +1 -1
  75. package/dist/work-item-query-commands.js +403 -35
  76. package/dist/work-item-query-commands.js.map +1 -1
  77. package/dist/work-item-resource-link-commands.js +105 -28
  78. package/dist/work-item-resource-link-commands.js.map +1 -1
  79. package/dist/work-item-thread-commands.d.ts +3 -0
  80. package/dist/work-item-thread-commands.js +101 -0
  81. package/dist/work-item-thread-commands.js.map +1 -0
  82. package/dist/work-item-watcher-commands.d.ts +20 -0
  83. package/dist/work-item-watcher-commands.js +93 -0
  84. package/dist/work-item-watcher-commands.js.map +1 -0
  85. package/guides/authoring.md +178 -0
  86. package/guides/delivery.md +60 -0
  87. package/guides/discussions-audit.md +32 -0
  88. package/guides/errors.md +41 -0
  89. package/guides/glossary.md +40 -0
  90. package/guides/map-and-screens.md +31 -0
  91. package/guides/search.md +9 -0
  92. package/guides/work-items.md +195 -0
  93. package/guides/workspace-admin.md +130 -0
  94. package/package.json +8 -3
@@ -0,0 +1,130 @@
1
+ # workspace-admin
2
+
3
+ Authentication, Workspace and Project administration, credentials, and integrations.
4
+
5
+ Installing the Skill or CLI never starts authentication. Device Authorization remains
6
+ a separate, explicit User operation when SpecFlow access is actually needed.
7
+
8
+ The CLI uses its built-in public origin. Pass `--server <origin>` only when the User
9
+ names a different SpecFlow origin, and use that same flag on authentication and every
10
+ resource command:
11
+
12
+ ```bash
13
+ specflow auth login
14
+ specflow project list
15
+ ```
16
+
17
+ Tell the User to click Approve in the browser.
18
+
19
+ The resulting independently revocable CLI Session belongs to the User and uses
20
+ all of that User's current SpecFlow permissions. No Workspace, Project, resource,
21
+ or action selection is required. New Workspaces and Projects are available without
22
+ another login. Membership, Role, lifecycle, User eligibility and Session revocation
23
+ are checked by the server on every operation; login does not save a permission
24
+ snapshot or bypass those checks. Do not register an Agent identity or request an Agent grant.
25
+
26
+ A legacy explicitly restricted Session retains its original scope. When the User
27
+ requests normal User access, log in again without `--grants`; do not repeatedly
28
+ request new target grants as Workspaces or Projects are created. Account identity
29
+ security and management of other Sessions remain outside this CLI surface.
30
+
31
+ User API Keys accept WorkspaceKnowledge/ProjectTasks arrays without UserAccount
32
+ or Session-only administration. A Key’s ProjectTasks.project admits only read. Use
33
+ `api-key create --name <name> --grants <json>
34
+ --expires-at <UTC timestamp|never> --idempotency-key <uuid>`. Use `api-key list` and
35
+ `api-key revoke --key-id <uuid> --expected-version <quoted version>
36
+ --idempotency-key <uuid>` to manage them. Creation stores the one-time secret in the
37
+ origin-scoped credential store; stdout contains metadata only. Replayed issuance
38
+ never returns a secret. Select a stored key with `--api-key-id`, or supply
39
+ `SPEC_FLOW_API_KEY`. Never combine credentials or fall back to a Session after a
40
+ key or Token fails.
41
+
42
+ Workspace administrators issue read-only credentials with `token issue
43
+ --workspace-id <id> --name <name> [--expires-at <UTC timestamp>]`; `token list` and
44
+ `token revoke --workspace-id <id> --token-id <id>` manage them. The issue secret is
45
+ shown once; metadata and audit retain the credential identity. Inject it through
46
+ `SPEC_FLOW_WORKSPACE_READ_TOKEN` for `spec current`, `spec revision`, and
47
+ `workspace glossary revision`, each with `--workspace-id` and the explicit resource/version
48
+ IDs. Current reads require a published Ready Spec; explicit revisions are immutable
49
+ published content. Drafts, Findings, Members, Project tasks and every mutation are
50
+ excluded. Tokens have optional expiry and can be revoked. They never enter the
51
+ Session credential store. The old Project Token and its environment variable are
52
+ retired.
53
+
54
+ Personal GitHub authorization and notification commands act as the same current
55
+ User. GitHub OAuth remains a separate normal browser authorization. API Keys and
56
+ Workspace read-only Tokens do not gain personal account capabilities.
57
+
58
+ - Manage public Task sharing only when the User requests it. Read the independent
59
+ sharing version with `specflow project sharing read --project-id <id>`; use
60
+ `specflow project sharing set --project-id <id> --public true|false
61
+ --expected-version <version> --idempotency-key <uuid>` with an authorized CLI
62
+ Session. Retain the same key and intent after an uncertain response. A replay
63
+ reports the current switch and cannot reopen a Project another command closed.
64
+ Public sharing exposes Task fields and current description assets, and grants
65
+ no Workspace membership, Spec/Glossary, task-resource or comment-asset access.
66
+ Archive and Trash close sharing; Restore keeps it private until explicitly
67
+ enabled again. Workspace read-only Tokens cannot manage sharing.
68
+
69
+ - Read the current User's notification inbox with `notification list`. A target
70
+ never grants access: use the fresh target returned by `notification read
71
+ --notification-id <uuid> --idempotency-key <uuid>` before navigating. `notification
72
+ read-all` and `notification clear` require an explicit UUID command key and a
73
+ current User authority; clear only when the
74
+ User requests it. Retain the key
75
+ after an ambiguous outcome so retrying cannot change newer entries. Read category
76
+ preferences with `notification preferences get`; update only requested fields
77
+ through `notification preferences update --expected-version <version> --preferences <json> --idempotency-key
78
+ <uuid>`. Project-scoped Sessions can read admitted targets, while Workspace read-only Tokens cannot access personal notifications. Do not claim scheduled reminders,
79
+ external delivery, or live Gateway push from this durable inbox.
80
+
81
+ - Use `specflow project list` before choosing a Project; never infer a hidden current
82
+ Project. Every newly created Project belongs to exactly one owning Workspace, and
83
+ Workspace Membership is the only source of Project permissions.
84
+ - Discover Workspaces with `specflow workspace list` and create one with `specflow workspace create --name <name> --prefix <prefix>` when the User asks for a new container. Select one
85
+ Workspace's Projects with `specflow project list --workspace-id <workspaceId>` —
86
+ an explicit, stateless filter combinable with `--status`; an unknown or
87
+ inaccessible Workspace returns an empty list, and discovery reflects the current User membership and Role.
88
+ - Administer Workspace membership and Roles only when the User asks. `specflow workspace member list|search|add|set-role|remove` governs who holds access —
89
+ `search` reads the identity directory and `add` provisions the selected User
90
+ by exact issuer+subject identity, including before first login; there is no
91
+ invitation path. `specflow workspace role list|create|update|delete` manages
92
+ statement sets: pass `--statements` as a JSON resource-to-actions object, a
93
+ Role never exceeds the caller's own grants, `Owner` is immutable, and a Role
94
+ still assigned cannot be deleted. Member writes and Role writes take the
95
+ resource's opaque `version` as `--expected-version`; reread deliberately
96
+ after `Resource Changed`.
97
+ - Workspace Creation requires an immutable, globally unique prefix of 2-10 letters.
98
+ Specs use PAY-S123, Scenarios PAY-S123-4, and Work Items PAY-123 across its Projects.
99
+ - Project Creation requires an owning Workspace. Run `specflow project create --name <name> --workspace-id <workspaceId>`. Spec language belongs to the Workspace.
100
+ The server generates the Project ID; discover and pass that ID without deriving it from a task number.
101
+
102
+ - Archive, Trash, or Restore only when the User's task requires that lifecycle
103
+ change. Pass the opaque version returned by Project discovery or context, and
104
+ reread deliberately after `Resource Changed` or an ambiguous transport outcome.
105
+ A Trashed Project surfaces only to an Admin through `project list --status
106
+ Trashed`, and Restore always lands it on Archived — never directly on Active.
107
+
108
+ Connect 1–50 repositories atomically with one idempotency key:
109
+
110
+ ```bash
111
+ specflow github connection connect-batch --project-id PROJECT_ID \
112
+ --repository owner/tasks:10:20 --repository owner/mobile:10:21 \
113
+ --outbound-repository-id 20 --idempotency-key UUID
114
+ ```
115
+
116
+ Repeat `--repository owner/name:installationId:repositoryId` for each repository.
117
+ Use `--no-outbound` to explicitly select none. Without either option, only the
118
+ first repository of the Project's first batch becomes outbound; later batches
119
+ only create from GitHub. A Project with an outbound repository cannot nominate
120
+ another during connection. Workspace binding conflicts reject the whole batch.
121
+ A real Web/CLI Session with current Workspace settings permission and personal
122
+ GitHub administrator access to every repository is required. The single-repository
123
+ `github connection connect` command remains available.
124
+
125
+ Use `project rename --project-id ID --name NAME --expected-version VERSION
126
+ --idempotency-key UUID` for an explicit rename request. It preserves identity and
127
+ respects lifecycle restrictions.
128
+
129
+ Related guides: Workspace Spec language (`--spec-language`, `workspace settings`)
130
+ is in authoring; `specflow auth whoami` is described in work-items.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gonovus-ai/spec-flow-cli",
3
- "version": "0.6.3",
3
+ "version": "1.0.0",
4
4
  "description": "SpecFlow supported command-line client",
5
5
  "repository": {
6
6
  "type": "git",
@@ -22,7 +22,8 @@
22
22
  }
23
23
  },
24
24
  "files": [
25
- "dist"
25
+ "dist",
26
+ "guides"
26
27
  ],
27
28
  "engines": {
28
29
  "node": ">=24.0.0 <25.0.0"
@@ -47,10 +48,14 @@
47
48
  "commander": "15.0.0",
48
49
  "open": "11.0.0",
49
50
  "openapi-fetch": "^0.17.0",
51
+ "proper-lockfile": "4.1.2",
52
+ "semver": "7.8.5",
50
53
  "zod": "4.4.3"
51
54
  },
52
55
  "devDependencies": {
53
56
  "@spec-flow/api-client": "workspace:*",
54
- "@types/node": "24.13.3"
57
+ "@types/node": "24.13.3",
58
+ "@types/proper-lockfile": "4.1.4",
59
+ "@types/semver": "7.8.0"
55
60
  }
56
61
  }