@ted-galago/wave-cli 0.1.3 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +81 -5
- package/dist/index.cjs +816 -155
- package/dist/index.js +813 -152
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -26,9 +26,18 @@ Or run locally:
|
|
|
26
26
|
npm run dev -- tasks list --project-id 123 --organization-id 42 --base-url https://api.example.com --token token
|
|
27
27
|
```
|
|
28
28
|
|
|
29
|
+
Secure stdin auth/context examples:
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
printf '%s' "token-value" | wave --token-stdin --base-url https://api.example.com --organization-id 42 tasks list --page 1 --per 10
|
|
33
|
+
|
|
34
|
+
printf '%s' '{"token":"token-value","baseUrl":"https://api.example.com","organizationId":"42","agentName":"atlas"}' \
|
|
35
|
+
| wave --auth-json-stdin tasks list --page 1 --per 10
|
|
36
|
+
```
|
|
37
|
+
|
|
29
38
|
## Runtime Contract
|
|
30
39
|
|
|
31
|
-
Required env:
|
|
40
|
+
Required (from flags, stdin, or env):
|
|
32
41
|
|
|
33
42
|
- `WAVE_API_TOKEN`
|
|
34
43
|
- `WAVE_API_BASE_URL`
|
|
@@ -45,11 +54,12 @@ Optional env:
|
|
|
45
54
|
- `WAVE_OPENAPI_URL` (hosted contract file)
|
|
46
55
|
- `WAVE_OPENAPI_VERSION` (pinned spec version/hash)
|
|
47
56
|
|
|
48
|
-
|
|
57
|
+
Deterministic precedence:
|
|
49
58
|
|
|
50
|
-
-
|
|
51
|
-
-
|
|
52
|
-
-
|
|
59
|
+
- explicit flags (`--token` / `--jwt`, `--base-url`, `--organization-id`, and tracing/runtime flags)
|
|
60
|
+
- stdin context (`--token-stdin` or `--auth-json-stdin`)
|
|
61
|
+
- env vars (`WAVE_*`)
|
|
62
|
+
- failure with structured JSON error
|
|
53
63
|
|
|
54
64
|
## Commands
|
|
55
65
|
|
|
@@ -74,10 +84,29 @@ wave lists create --data-json '{"name":"Weekly List"}'
|
|
|
74
84
|
wave list-items create --data-json '{"list_id":"123","summary":"Follow up"}'
|
|
75
85
|
wave todos create --data-json '{"todo_group_id":"55","name":"Send update"}'
|
|
76
86
|
wave knowledge create --data-json '{"title":"Runbook","content":"..."}'
|
|
87
|
+
wave notes create-member --target-member-id 67 --name "1:1 Note" --body "Strong progress"
|
|
88
|
+
wave notes create-manager --actor-member-id 67 --target-member-id 68 --name "Manager Note" --body "Coaching plan"
|
|
89
|
+
wave notes create-team --actor-member-id 67 --team-id 9 --name "Team Note" --body "Team context"
|
|
90
|
+
wave notes create-project --actor-member-id 67 --project-id 80 --name "Project Note" --body "Project context"
|
|
91
|
+
wave notes create-customer --actor-member-id 67 --customer-id 30 --name "Customer Note" --body "Customer context"
|
|
92
|
+
wave notes create-contact --actor-member-id 67 --contact-id 31 --name "Contact Note" --body "Contact context"
|
|
93
|
+
wave notes list --contentable-type Member --contentable-id 67 --member-id 67 --page 1 --per 20
|
|
94
|
+
wave notes show --id 1001
|
|
95
|
+
wave notes update --id 1001 --name "Updated Note" --body "Updated body" --status published
|
|
96
|
+
wave notes destroy --id 1001
|
|
77
97
|
wave pulse update --id 12 --data-json '{"status":"on_track"}'
|
|
98
|
+
wave subtasks list --task-id 123 --page 1 --per 20
|
|
99
|
+
wave milestones list --rock-id 234 --page 1 --per 20
|
|
100
|
+
wave subitems list --list-item-id 345 --page 1 --per 20
|
|
101
|
+
wave subtodos list --todo-id 456 --page 1 --per 20
|
|
102
|
+
wave subissues list --issue-id 567 --page 1 --per 20
|
|
103
|
+
wave talking-points list --meeting-id 678 --page 1 --per 20
|
|
104
|
+
wave subtasks create --data-json '{"subtask":{"task_id":"123","member_id":"67","name":"Subtask name","description":"Subtask description"}}'
|
|
105
|
+
wave subissues destroy --id 999
|
|
78
106
|
```
|
|
79
107
|
|
|
80
108
|
All commands require organization context via `--organization-id` or `WAVE_ORGANIZATION_ID`.
|
|
109
|
+
You can also provide `organizationId` via `--auth-json-stdin`.
|
|
81
110
|
|
|
82
111
|
## Parent-Child Create Rules
|
|
83
112
|
|
|
@@ -88,9 +117,56 @@ These child resources enforce parent IDs at CLI validation time:
|
|
|
88
117
|
- `todos.create` requires `todo_group_id`
|
|
89
118
|
- `rocks.create` requires `rock_collection_id`
|
|
90
119
|
- `scorecards.create` requires `measurable_group_id`
|
|
120
|
+
- `subtasks.create` requires `task_id`
|
|
121
|
+
- `milestones.create` requires `rock_id`
|
|
122
|
+
- `subitems.create` requires `list_item_id`
|
|
123
|
+
- `subtodos.create` requires `todo_id`
|
|
124
|
+
- `subissues.create` requires `issue_id`
|
|
125
|
+
- `talking-points.create` requires `meeting_id`
|
|
91
126
|
|
|
92
127
|
If a required parent field is missing, CLI returns JSON error with exit code `2`.
|
|
93
128
|
|
|
129
|
+
## Notes Contract
|
|
130
|
+
|
|
131
|
+
The `notes` command uses exact GraphQL operation names:
|
|
132
|
+
|
|
133
|
+
- `CreateContent`
|
|
134
|
+
- `UpdateContent`
|
|
135
|
+
- `DestroyContent`
|
|
136
|
+
- `ContentShow`
|
|
137
|
+
- `ContentsIndex`
|
|
138
|
+
|
|
139
|
+
Placement rules enforced by command shape:
|
|
140
|
+
|
|
141
|
+
- `notes create-member`
|
|
142
|
+
- `contentable_type: "Member"`
|
|
143
|
+
- `contentable_id: TARGET_MEMBER_ID`
|
|
144
|
+
- `member_id: TARGET_MEMBER_ID`
|
|
145
|
+
- `focus_member_id: null`
|
|
146
|
+
- `focus_team_id: null`
|
|
147
|
+
- `notes create-manager`
|
|
148
|
+
- `contentable_type: "Member"`
|
|
149
|
+
- `contentable_id: ACTOR_MEMBER_ID`
|
|
150
|
+
- `member_id: ACTOR_MEMBER_ID`
|
|
151
|
+
- `focus_member_id: TARGET_MEMBER_ID`
|
|
152
|
+
- `notes create-team`
|
|
153
|
+
- `contentable_type: "Team"`
|
|
154
|
+
- `contentable_id: TEAM_ID`
|
|
155
|
+
- `member_id: ACTOR_MEMBER_ID`
|
|
156
|
+
- `focus_team_id: TEAM_ID`
|
|
157
|
+
- `notes create-project`
|
|
158
|
+
- `contentable_type: "Project"`
|
|
159
|
+
- `contentable_id: PROJECT_ID`
|
|
160
|
+
- `member_id: ACTOR_MEMBER_ID`
|
|
161
|
+
- `notes create-customer`
|
|
162
|
+
- `contentable_type: "Customer"`
|
|
163
|
+
- `contentable_id: CUSTOMER_ID`
|
|
164
|
+
- `member_id: ACTOR_MEMBER_ID`
|
|
165
|
+
- `notes create-contact`
|
|
166
|
+
- `contentable_type: "Contact"`
|
|
167
|
+
- `contentable_id: CONTACT_ID`
|
|
168
|
+
- `member_id: ACTOR_MEMBER_ID`
|
|
169
|
+
|
|
94
170
|
## JSON Envelope
|
|
95
171
|
|
|
96
172
|
Success:
|