@fulldivevr/workcord-cli 1.3.0 → 2.17.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 (38) hide show
  1. package/README.md +91 -41
  2. package/dist/auth.js +24 -8
  3. package/dist/cli.js +7 -3
  4. package/dist/client.js +8 -1
  5. package/dist/commands/agent-skills.js +127 -0
  6. package/dist/commands/hub.js +667 -0
  7. package/dist/commands/messages.js +150 -4
  8. package/dist/commands/reflections.js +96 -0
  9. package/dist/commands/rooms.js +7 -3
  10. package/dist/generated/commands/agent-feedback-admin.js +69 -0
  11. package/dist/generated/commands/ai.js +31 -0
  12. package/dist/generated/commands/call-recordings.js +56 -0
  13. package/dist/generated/commands/contact-match.js +20 -1
  14. package/dist/generated/commands/credit-packs.js +112 -0
  15. package/dist/generated/commands/custom-agents.js +483 -1
  16. package/dist/generated/commands/desktop-releases.js +2 -2
  17. package/dist/generated/commands/edge-sizecheck.js +25 -0
  18. package/dist/generated/commands/feed.js +6 -0
  19. package/dist/generated/commands/interactive-events.js +47 -0
  20. package/dist/generated/commands/internal.js +191 -0
  21. package/dist/generated/commands/meetings.js +12 -0
  22. package/dist/generated/commands/messages.js +15 -0
  23. package/dist/generated/commands/my-feedback.js +18 -0
  24. package/dist/generated/commands/pinned-messages.js +6 -0
  25. package/dist/generated/commands/proxy-nodes.js +83 -0
  26. package/dist/generated/commands/push.js +20 -0
  27. package/dist/generated/commands/reviews.js +96 -0
  28. package/dist/generated/commands/room-agents.js +243 -1
  29. package/dist/generated/commands/room-invites.js +12 -0
  30. package/dist/generated/commands/rooms.js +79 -1
  31. package/dist/generated/commands/search.js +1 -1
  32. package/dist/generated/commands/shadow-dispatch-push.js +20 -0
  33. package/dist/generated/commands/shadow-reflections.js +111 -0
  34. package/dist/generated/index.js +20 -0
  35. package/dist/http.js +6 -2
  36. package/dist/room-types.js +10 -0
  37. package/package.json +1 -1
  38. package/dist/generated/commands/health.js +0 -29
@@ -4,7 +4,7 @@ import { call } from "../../client.js";
4
4
  import { actingUserId } from "../../auth.js";
5
5
  import { getOrCreateGroup, hasSubcommand } from "../_helpers.js";
6
6
  export function register(program) {
7
- const group = getOrCreateGroup(program, "room-agents", "RoomAgents operations");
7
+ const group = getOrCreateGroup(program, "room-agents", "AgentInstallations operations");
8
8
  if (!hasSubcommand(group, "preview-standalone")) {
9
9
  group
10
10
  .command("preview-standalone")
@@ -107,6 +107,236 @@ export function register(program) {
107
107
  process.stdout.write(JSON.stringify(data) + "\n");
108
108
  });
109
109
  }
110
+ if (!hasSubcommand(group, "list-agent-files")) {
111
+ group
112
+ .command("list-agent-files")
113
+ .description("GET /api/v1/rooms/{roomId}/agents/{agentId}/files")
114
+ .requiredOption("--room-id <value>", "roomId (path param)")
115
+ .requiredOption("--agent-id <value>", "agentId (path param)")
116
+ .option("--path <json>", " (JSON)")
117
+ .action(async (opts) => {
118
+ const as = actingUserId(program);
119
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/files`;
120
+ const query = {};
121
+ {
122
+ const v = opts.path === undefined ? undefined : JSON.parse(opts.path);
123
+ if (v !== undefined)
124
+ query["path"] = v;
125
+ }
126
+ const data = await call({ method: "GET", path, asUserId: as, query });
127
+ process.stdout.write(JSON.stringify(data) + "\n");
128
+ });
129
+ }
130
+ if (!hasSubcommand(group, "list-agent-skills")) {
131
+ group
132
+ .command("list-agent-skills")
133
+ .description("GET /api/v1/rooms/{roomId}/agents/{agentId}/skills")
134
+ .requiredOption("--room-id <value>", "roomId (path param)")
135
+ .requiredOption("--agent-id <value>", "agentId (path param)")
136
+ .action(async (opts) => {
137
+ const as = actingUserId(program);
138
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/skills`;
139
+ const data = await call({ method: "GET", path, asUserId: as });
140
+ process.stdout.write(JSON.stringify(data) + "\n");
141
+ });
142
+ }
143
+ if (!hasSubcommand(group, "install-agent-skill")) {
144
+ group
145
+ .command("install-agent-skill")
146
+ .description("PUT /api/v1/rooms/{roomId}/agents/{agentId}/skills/{skillId}/market")
147
+ .requiredOption("--room-id <value>", "roomId (path param)")
148
+ .requiredOption("--agent-id <value>", "agentId (path param)")
149
+ .requiredOption("--skill-id <value>", "skillId (path param)")
150
+ .option("--body <json>", "request body as JSON (no schema available)")
151
+ .action(async (opts) => {
152
+ const as = actingUserId(program);
153
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/skills/${encodeURIComponent(opts.skillId)}/market`;
154
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
155
+ const data = await call({ method: "PUT", path, asUserId: as, body });
156
+ process.stdout.write(JSON.stringify(data) + "\n");
157
+ });
158
+ }
159
+ if (!hasSubcommand(group, "remove-agent-skill")) {
160
+ group
161
+ .command("remove-agent-skill")
162
+ .description("DELETE /api/v1/rooms/{roomId}/agents/{agentId}/skills/{skillId}/market")
163
+ .requiredOption("--room-id <value>", "roomId (path param)")
164
+ .requiredOption("--agent-id <value>", "agentId (path param)")
165
+ .requiredOption("--skill-id <value>", "skillId (path param)")
166
+ .action(async (opts) => {
167
+ const as = actingUserId(program);
168
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/skills/${encodeURIComponent(opts.skillId)}/market`;
169
+ const data = await call({ method: "DELETE", path, asUserId: as });
170
+ process.stdout.write(JSON.stringify(data) + "\n");
171
+ });
172
+ }
173
+ if (!hasSubcommand(group, "set-agent-skill-state")) {
174
+ group
175
+ .command("set-agent-skill-state")
176
+ .description("PUT /api/v1/rooms/{roomId}/agents/{agentId}/skills/{skillName}/state")
177
+ .requiredOption("--room-id <value>", "roomId (path param)")
178
+ .requiredOption("--agent-id <value>", "agentId (path param)")
179
+ .requiredOption("--skill-name <value>", "skillName (path param)")
180
+ .option("--body <json>", "request body as JSON (no schema available)")
181
+ .action(async (opts) => {
182
+ const as = actingUserId(program);
183
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/skills/${encodeURIComponent(opts.skillName)}/state`;
184
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
185
+ const data = await call({ method: "PUT", path, asUserId: as, body });
186
+ process.stdout.write(JSON.stringify(data) + "\n");
187
+ });
188
+ }
189
+ if (!hasSubcommand(group, "get-agent-file-content")) {
190
+ group
191
+ .command("get-agent-file-content")
192
+ .description("GET /api/v1/rooms/{roomId}/agents/{agentId}/files/content")
193
+ .requiredOption("--room-id <value>", "roomId (path param)")
194
+ .requiredOption("--agent-id <value>", "agentId (path param)")
195
+ .requiredOption("--path <value>", "string")
196
+ .action(async (opts) => {
197
+ const as = actingUserId(program);
198
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/files/content`;
199
+ const query = {};
200
+ {
201
+ const v = opts.path;
202
+ if (v !== undefined)
203
+ query["path"] = v;
204
+ }
205
+ const data = await call({ method: "GET", path, asUserId: as, query });
206
+ process.stdout.write(JSON.stringify(data) + "\n");
207
+ });
208
+ }
209
+ if (!hasSubcommand(group, "download-agent-file")) {
210
+ group
211
+ .command("download-agent-file")
212
+ .description("GET /api/v1/rooms/{roomId}/agents/{agentId}/files/download")
213
+ .requiredOption("--room-id <value>", "roomId (path param)")
214
+ .requiredOption("--agent-id <value>", "agentId (path param)")
215
+ .requiredOption("--path <value>", "string")
216
+ .action(async (opts) => {
217
+ const as = actingUserId(program);
218
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/files/download`;
219
+ const query = {};
220
+ {
221
+ const v = opts.path;
222
+ if (v !== undefined)
223
+ query["path"] = v;
224
+ }
225
+ const data = await call({ method: "GET", path, asUserId: as, query });
226
+ process.stdout.write(JSON.stringify(data) + "\n");
227
+ });
228
+ }
229
+ if (!hasSubcommand(group, "update-agent-file-access")) {
230
+ group
231
+ .command("update-agent-file-access")
232
+ .description("PATCH /api/v1/rooms/{roomId}/agents/{agentId}/file-access")
233
+ .requiredOption("--room-id <value>", "roomId (path param)")
234
+ .requiredOption("--agent-id <value>", "agentId (path param)")
235
+ .addOption(new Option("--access <value>", "string, enum").choices(["owner_only", "room_members"]).makeOptionMandatory())
236
+ .action(async (opts) => {
237
+ const as = actingUserId(program);
238
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/file-access`;
239
+ const body = {};
240
+ {
241
+ const v = opts.access;
242
+ if (v !== undefined)
243
+ body["access"] = v;
244
+ }
245
+ const data = await call({ method: "PATCH", path, asUserId: as, body });
246
+ process.stdout.write(JSON.stringify(data) + "\n");
247
+ });
248
+ }
249
+ if (!hasSubcommand(group, "list-agent-scheduled-jobs")) {
250
+ group
251
+ .command("list-agent-scheduled-jobs")
252
+ .description("GET /api/v1/rooms/{roomId}/agents/{agentId}/scheduled-jobs")
253
+ .requiredOption("--room-id <value>", "roomId (path param)")
254
+ .requiredOption("--agent-id <value>", "agentId (path param)")
255
+ .action(async (opts) => {
256
+ const as = actingUserId(program);
257
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/scheduled-jobs`;
258
+ const data = await call({ method: "GET", path, asUserId: as });
259
+ process.stdout.write(JSON.stringify(data) + "\n");
260
+ });
261
+ }
262
+ if (!hasSubcommand(group, "pause-room-agent-scheduled-job")) {
263
+ group
264
+ .command("pause-room-agent-scheduled-job")
265
+ .description("POST /api/v1/rooms/{roomId}/agents/{agentId}/scheduled-jobs/{jobId}/pause")
266
+ .requiredOption("--room-id <value>", "roomId (path param)")
267
+ .requiredOption("--agent-id <value>", "agentId (path param)")
268
+ .requiredOption("--job-id <value>", "jobId (path param)")
269
+ .option("--body <json>", "request body as JSON (no schema available)")
270
+ .action(async (opts) => {
271
+ const as = actingUserId(program);
272
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/scheduled-jobs/${encodeURIComponent(opts.jobId)}/pause`;
273
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
274
+ const data = await call({ method: "POST", path, asUserId: as, body });
275
+ process.stdout.write(JSON.stringify(data) + "\n");
276
+ });
277
+ }
278
+ if (!hasSubcommand(group, "resume-room-agent-scheduled-job")) {
279
+ group
280
+ .command("resume-room-agent-scheduled-job")
281
+ .description("POST /api/v1/rooms/{roomId}/agents/{agentId}/scheduled-jobs/{jobId}/resume")
282
+ .requiredOption("--room-id <value>", "roomId (path param)")
283
+ .requiredOption("--agent-id <value>", "agentId (path param)")
284
+ .requiredOption("--job-id <value>", "jobId (path param)")
285
+ .option("--body <json>", "request body as JSON (no schema available)")
286
+ .action(async (opts) => {
287
+ const as = actingUserId(program);
288
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/scheduled-jobs/${encodeURIComponent(opts.jobId)}/resume`;
289
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
290
+ const data = await call({ method: "POST", path, asUserId: as, body });
291
+ process.stdout.write(JSON.stringify(data) + "\n");
292
+ });
293
+ }
294
+ if (!hasSubcommand(group, "run-room-agent-scheduled-job")) {
295
+ group
296
+ .command("run-room-agent-scheduled-job")
297
+ .description("POST /api/v1/rooms/{roomId}/agents/{agentId}/scheduled-jobs/{jobId}/run")
298
+ .requiredOption("--room-id <value>", "roomId (path param)")
299
+ .requiredOption("--agent-id <value>", "agentId (path param)")
300
+ .requiredOption("--job-id <value>", "jobId (path param)")
301
+ .option("--body <json>", "request body as JSON (no schema available)")
302
+ .action(async (opts) => {
303
+ const as = actingUserId(program);
304
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/scheduled-jobs/${encodeURIComponent(opts.jobId)}/run`;
305
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
306
+ const data = await call({ method: "POST", path, asUserId: as, body });
307
+ process.stdout.write(JSON.stringify(data) + "\n");
308
+ });
309
+ }
310
+ if (!hasSubcommand(group, "update-room-agent-scheduled-job")) {
311
+ group
312
+ .command("update-room-agent-scheduled-job")
313
+ .description("PATCH /api/v1/rooms/{roomId}/agents/{agentId}/scheduled-jobs/{jobId}")
314
+ .requiredOption("--room-id <value>", "roomId (path param)")
315
+ .requiredOption("--agent-id <value>", "agentId (path param)")
316
+ .requiredOption("--job-id <value>", "jobId (path param)")
317
+ .option("--body <json>", "request body as JSON (no schema available)")
318
+ .action(async (opts) => {
319
+ const as = actingUserId(program);
320
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/scheduled-jobs/${encodeURIComponent(opts.jobId)}`;
321
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
322
+ const data = await call({ method: "PATCH", path, asUserId: as, body });
323
+ process.stdout.write(JSON.stringify(data) + "\n");
324
+ });
325
+ }
326
+ if (!hasSubcommand(group, "delete-room-agent-scheduled-job")) {
327
+ group
328
+ .command("delete-room-agent-scheduled-job")
329
+ .description("DELETE /api/v1/rooms/{roomId}/agents/{agentId}/scheduled-jobs/{jobId}")
330
+ .requiredOption("--room-id <value>", "roomId (path param)")
331
+ .requiredOption("--agent-id <value>", "agentId (path param)")
332
+ .requiredOption("--job-id <value>", "jobId (path param)")
333
+ .action(async (opts) => {
334
+ const as = actingUserId(program);
335
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}/scheduled-jobs/${encodeURIComponent(opts.jobId)}`;
336
+ const data = await call({ method: "DELETE", path, asUserId: as });
337
+ process.stdout.write(JSON.stringify(data) + "\n");
338
+ });
339
+ }
110
340
  if (!hasSubcommand(group, "preview")) {
111
341
  group
112
342
  .command("preview")
@@ -140,6 +370,8 @@ export function register(program) {
140
370
  .addOption(new Option("--mode <value>", "string, enum").choices(["silent", "proactive", "suggest"]))
141
371
  .option("--trigger-rule <value>", "string, ≤500 chars")
142
372
  .option("--priority <n>", "number")
373
+ .option("--voice-name <value>", "string, ≤64 chars")
374
+ .option("--voice-speed <n>", "number")
143
375
  .action(async (opts) => {
144
376
  const as = actingUserId(program);
145
377
  const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/agents/${encodeURIComponent(opts.agentId)}`;
@@ -184,6 +416,16 @@ export function register(program) {
184
416
  if (v !== undefined)
185
417
  body["priority"] = v;
186
418
  }
419
+ {
420
+ const v = opts.voiceName;
421
+ if (v !== undefined)
422
+ body["voiceName"] = v;
423
+ }
424
+ {
425
+ const v = opts.voiceSpeed === undefined ? undefined : Number(opts.voiceSpeed);
426
+ if (v !== undefined)
427
+ body["voiceSpeed"] = v;
428
+ }
187
429
  const data = await call({ method: "PATCH", path, asUserId: as, body });
188
430
  process.stdout.write(JSON.stringify(data) + "\n");
189
431
  });
@@ -104,6 +104,18 @@ export function register(program) {
104
104
  process.stdout.write(JSON.stringify(data) + "\n");
105
105
  });
106
106
  }
107
+ if (!hasSubcommand(group, "get-outstanding-invites")) {
108
+ group
109
+ .command("get-outstanding-invites")
110
+ .description("GET /api/v1/rooms/{roomId}/outstanding-invites")
111
+ .requiredOption("--room-id <value>", "roomId (path param)")
112
+ .action(async (opts) => {
113
+ const as = actingUserId(program);
114
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/outstanding-invites`;
115
+ const data = await call({ method: "GET", path, asUserId: as });
116
+ process.stdout.write(JSON.stringify(data) + "\n");
117
+ });
118
+ }
107
119
  if (!hasSubcommand(group, "preview-email")) {
108
120
  group
109
121
  .command("preview-email")
@@ -1,3 +1,5 @@
1
+ // Auto-generated. Do not edit by hand. Regenerate via `npm run generate`.
2
+ import { Option } from "commander";
1
3
  import { call } from "../../client.js";
2
4
  import { actingUserId } from "../../auth.js";
3
5
  import { getOrCreateGroup, hasSubcommand } from "../_helpers.js";
@@ -56,7 +58,7 @@ export function register(program) {
56
58
  .command("create-room")
57
59
  .description("POST /api/v1/rooms")
58
60
  .requiredOption("--name <value>", "string, ≥1 chars")
59
- .option("--type <value>", "string")
61
+ .addOption(new Option("--type <value>", "string, enum").choices(["verifiedIntelligence", "broadcastChannel", "room", "direct", "webApp"]))
60
62
  .option("--briefing-time <value>", "string")
61
63
  .option("--briefing-languages <comma-separated>", "array")
62
64
  .option("--sources <json>", "array (JSON)")
@@ -237,6 +239,43 @@ export function register(program) {
237
239
  process.stdout.write(JSON.stringify(data) + "\n");
238
240
  });
239
241
  }
242
+ if (!hasSubcommand(group, "list-new-messages")) {
243
+ group
244
+ .command("list-new-messages")
245
+ .description("GET /api/v1/rooms/new-messages")
246
+ .option("--cursor <value>", "string")
247
+ .option("--limit <value>", "string")
248
+ .action(async (opts) => {
249
+ const as = actingUserId(program);
250
+ const path = `/api/v1/rooms/new-messages`;
251
+ const query = {};
252
+ {
253
+ const v = opts.cursor;
254
+ if (v !== undefined)
255
+ query["cursor"] = v;
256
+ }
257
+ {
258
+ const v = opts.limit;
259
+ if (v !== undefined)
260
+ query["limit"] = v;
261
+ }
262
+ const data = await call({ method: "GET", path, asUserId: as, query });
263
+ process.stdout.write(JSON.stringify(data) + "\n");
264
+ });
265
+ }
266
+ if (!hasSubcommand(group, "mark-new-message-group-read")) {
267
+ group
268
+ .command("mark-new-message-group-read")
269
+ .description("PATCH /api/v1/rooms/new-messages/read")
270
+ .option("--body <json>", "request body as JSON (no schema available)")
271
+ .action(async (opts) => {
272
+ const as = actingUserId(program);
273
+ const path = `/api/v1/rooms/new-messages/read`;
274
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
275
+ const data = await call({ method: "PATCH", path, asUserId: as, body });
276
+ process.stdout.write(JSON.stringify(data) + "\n");
277
+ });
278
+ }
240
279
  if (!hasSubcommand(group, "list-agent-install-targets")) {
241
280
  group
242
281
  .command("list-agent-install-targets")
@@ -377,6 +416,7 @@ export function register(program) {
377
416
  .option("--rules <value>", "string")
378
417
  .option("--pin-permission <value>", "string")
379
418
  .option("--only-admins-can-post <true|false>", "boolean")
419
+ .option("--auto-translate-enabled <true|false>", "boolean")
380
420
  .option("--web-app-url <value>", "string")
381
421
  .option("--invite-permission <value>", "string")
382
422
  .option("--slow-mode-seconds <n>", "number")
@@ -488,6 +528,11 @@ export function register(program) {
488
528
  if (v !== undefined)
489
529
  body["onlyAdminsCanPost"] = v;
490
530
  }
531
+ {
532
+ const v = opts.autoTranslateEnabled === undefined ? undefined : opts.autoTranslateEnabled === "true";
533
+ if (v !== undefined)
534
+ body["autoTranslateEnabled"] = v;
535
+ }
491
536
  {
492
537
  const v = opts.webAppUrl;
493
538
  if (v !== undefined)
@@ -551,6 +596,20 @@ export function register(program) {
551
596
  process.stdout.write(JSON.stringify(data) + "\n");
552
597
  });
553
598
  }
599
+ if (!hasSubcommand(group, "generate-room-icon")) {
600
+ group
601
+ .command("generate-room-icon")
602
+ .description("POST /api/v1/rooms/{roomId}/generate-icon")
603
+ .requiredOption("--room-id <value>", "roomId (path param)")
604
+ .option("--body <json>", "request body as JSON (no schema available)")
605
+ .action(async (opts) => {
606
+ const as = actingUserId(program);
607
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/generate-icon`;
608
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
609
+ const data = await call({ method: "POST", path, asUserId: as, body });
610
+ process.stdout.write(JSON.stringify(data) + "\n");
611
+ });
612
+ }
554
613
  if (!hasSubcommand(group, "upload-room-icon")) {
555
614
  group
556
615
  .command("upload-room-icon")
@@ -692,6 +751,25 @@ export function register(program) {
692
751
  process.stdout.write(JSON.stringify(data) + "\n");
693
752
  });
694
753
  }
754
+ if (!hasSubcommand(group, "mention-candidates")) {
755
+ group
756
+ .command("mention-candidates")
757
+ .description("GET /api/v1/rooms/{roomId}/members/mention-candidates")
758
+ .requiredOption("--room-id <value>", "roomId (path param)")
759
+ .option("--limit <value>", "string")
760
+ .action(async (opts) => {
761
+ const as = actingUserId(program);
762
+ const path = `/api/v1/rooms/${encodeURIComponent(opts.roomId)}/members/mention-candidates`;
763
+ const query = {};
764
+ {
765
+ const v = opts.limit;
766
+ if (v !== undefined)
767
+ query["limit"] = v;
768
+ }
769
+ const data = await call({ method: "GET", path, asUserId: as, query });
770
+ process.stdout.write(JSON.stringify(data) + "\n");
771
+ });
772
+ }
695
773
  if (!hasSubcommand(group, "list-members")) {
696
774
  group
697
775
  .command("list-members")
@@ -7,7 +7,7 @@ export function register(program) {
7
7
  group
8
8
  .command("search")
9
9
  .description("GET /api/v1/search")
10
- .requiredOption("--q <value>", "string")
10
+ .option("--q <value>", "string")
11
11
  .option("--type <value>", "string")
12
12
  .option("--cursor <value>", "string")
13
13
  .option("--limit <value>", "string")
@@ -0,0 +1,20 @@
1
+ import { call } from "../../client.js";
2
+ import { actingUserId } from "../../auth.js";
3
+ import { getOrCreateGroup, hasSubcommand } from "../_helpers.js";
4
+ export function register(program) {
5
+ const group = getOrCreateGroup(program, "shadow-dispatch-push", "ShadowDispatchPush operations");
6
+ if (!hasSubcommand(group, "push")) {
7
+ group
8
+ .command("push")
9
+ .description("POST /api/v1/a2a/shadow/push")
10
+ .option("--body <json>", "request body as JSON (no schema available)")
11
+ .action(async (opts) => {
12
+ const as = actingUserId(program);
13
+ const path = `/api/v1/a2a/shadow/push`;
14
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
15
+ const data = await call({ method: "POST", path, asUserId: as, body });
16
+ process.stdout.write(JSON.stringify(data) + "\n");
17
+ });
18
+ }
19
+ }
20
+ //# sourceMappingURL=shadow-dispatch-push.js.map
@@ -0,0 +1,111 @@
1
+ import { call } from "../../client.js";
2
+ import { actingUserId } from "../../auth.js";
3
+ import { getOrCreateGroup, hasSubcommand } from "../_helpers.js";
4
+ export function register(program) {
5
+ const group = getOrCreateGroup(program, "shadow-reflections", "ShadowReflections operations");
6
+ if (!hasSubcommand(group, "list")) {
7
+ group
8
+ .command("list")
9
+ .description("GET /api/v1/shadow/reflections")
10
+ .action(async (opts) => {
11
+ const as = actingUserId(program);
12
+ const path = `/api/v1/shadow/reflections`;
13
+ const data = await call({ method: "GET", path, asUserId: as });
14
+ process.stdout.write(JSON.stringify(data) + "\n");
15
+ });
16
+ }
17
+ if (!hasSubcommand(group, "create")) {
18
+ group
19
+ .command("create")
20
+ .description("POST /api/v1/shadow/reflections")
21
+ .option("--body <json>", "request body as JSON (no schema available)")
22
+ .action(async (opts) => {
23
+ const as = actingUserId(program);
24
+ const path = `/api/v1/shadow/reflections`;
25
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
26
+ const data = await call({ method: "POST", path, asUserId: as, body });
27
+ process.stdout.write(JSON.stringify(data) + "\n");
28
+ });
29
+ }
30
+ if (!hasSubcommand(group, "get")) {
31
+ group
32
+ .command("get")
33
+ .description("GET /api/v1/shadow/reflections/{id}")
34
+ .requiredOption("--id <value>", "id (path param)")
35
+ .action(async (opts) => {
36
+ const as = actingUserId(program);
37
+ const path = `/api/v1/shadow/reflections/${encodeURIComponent(opts.id)}`;
38
+ const data = await call({ method: "GET", path, asUserId: as });
39
+ process.stdout.write(JSON.stringify(data) + "\n");
40
+ });
41
+ }
42
+ if (!hasSubcommand(group, "update")) {
43
+ group
44
+ .command("update")
45
+ .description("PATCH /api/v1/shadow/reflections/{id}")
46
+ .requiredOption("--id <value>", "id (path param)")
47
+ .option("--body <json>", "request body as JSON (no schema available)")
48
+ .action(async (opts) => {
49
+ const as = actingUserId(program);
50
+ const path = `/api/v1/shadow/reflections/${encodeURIComponent(opts.id)}`;
51
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
52
+ const data = await call({ method: "PATCH", path, asUserId: as, body });
53
+ process.stdout.write(JSON.stringify(data) + "\n");
54
+ });
55
+ }
56
+ if (!hasSubcommand(group, "archive")) {
57
+ group
58
+ .command("archive")
59
+ .description("DELETE /api/v1/shadow/reflections/{id}")
60
+ .requiredOption("--id <value>", "id (path param)")
61
+ .action(async (opts) => {
62
+ const as = actingUserId(program);
63
+ const path = `/api/v1/shadow/reflections/${encodeURIComponent(opts.id)}`;
64
+ const data = await call({ method: "DELETE", path, asUserId: as });
65
+ process.stdout.write(JSON.stringify(data) + "\n");
66
+ });
67
+ }
68
+ if (!hasSubcommand(group, "activate")) {
69
+ group
70
+ .command("activate")
71
+ .description("POST /api/v1/shadow/reflections/{id}/activate")
72
+ .requiredOption("--id <value>", "id (path param)")
73
+ .option("--body <json>", "request body as JSON (no schema available)")
74
+ .action(async (opts) => {
75
+ const as = actingUserId(program);
76
+ const path = `/api/v1/shadow/reflections/${encodeURIComponent(opts.id)}/activate`;
77
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
78
+ const data = await call({ method: "POST", path, asUserId: as, body });
79
+ process.stdout.write(JSON.stringify(data) + "\n");
80
+ });
81
+ }
82
+ if (!hasSubcommand(group, "install")) {
83
+ group
84
+ .command("install")
85
+ .description("POST /api/v1/shadow/reflections/{id}/install")
86
+ .requiredOption("--id <value>", "id (path param)")
87
+ .option("--body <json>", "request body as JSON (no schema available)")
88
+ .action(async (opts) => {
89
+ const as = actingUserId(program);
90
+ const path = `/api/v1/shadow/reflections/${encodeURIComponent(opts.id)}/install`;
91
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
92
+ const data = await call({ method: "POST", path, asUserId: as, body });
93
+ process.stdout.write(JSON.stringify(data) + "\n");
94
+ });
95
+ }
96
+ if (!hasSubcommand(group, "set-price")) {
97
+ group
98
+ .command("set-price")
99
+ .description("PATCH /api/v1/shadow/reflections/{id}/price")
100
+ .requiredOption("--id <value>", "id (path param)")
101
+ .option("--body <json>", "request body as JSON (no schema available)")
102
+ .action(async (opts) => {
103
+ const as = actingUserId(program);
104
+ const path = `/api/v1/shadow/reflections/${encodeURIComponent(opts.id)}/price`;
105
+ const body = opts.body ? JSON.parse(opts.body) : undefined;
106
+ const data = await call({ method: "PATCH", path, asUserId: as, body });
107
+ process.stdout.write(JSON.stringify(data) + "\n");
108
+ });
109
+ }
110
+ }
111
+ //# sourceMappingURL=shadow-reflections.js.map