@curviate/cli 0.32.0 → 0.34.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 (41) hide show
  1. package/CHANGELOG.md +264 -1
  2. package/README.md +13 -1
  3. package/dist/{account-JDSZC633.js → account-463D5EVY.js} +90 -47
  4. package/dist/{chunk-JRKM4OV2.js → chunk-6W7364S3.js} +1 -1
  5. package/dist/{chunk-KQXYEQAD.js → chunk-7JU4IXXG.js} +172 -8
  6. package/dist/{chunk-5EJDQ47B.js → chunk-BN7L7WSY.js} +16 -16
  7. package/dist/chunk-DCZR4M7G.js +327 -0
  8. package/dist/{chunk-V3PB4HSF.js → chunk-MNDXMGPX.js} +68 -24
  9. package/dist/chunk-TCUYH5GO.js +34 -0
  10. package/dist/{chunk-SKJNLN37.js → chunk-XDQHNUEU.js} +86 -2
  11. package/dist/{chunk-LJR4LJG6.js → chunk-XP2LN6F6.js} +53 -0
  12. package/dist/{chunk-EIEF2KFH.js → chunk-XZJQQJBE.js} +6 -4
  13. package/dist/{chunk-6P52Q2GK.js → chunk-ZJ7D3NFS.js} +5 -4
  14. package/dist/cli.js +104 -37
  15. package/dist/{comment-YOFNFQUE.js → comment-G6RB2PBZ.js} +32 -26
  16. package/dist/{company-6PKHDK6L.js → company-OWND3W3L.js} +53 -35
  17. package/dist/{config-FUHT23SX.js → config-RUBXWFQ3.js} +74 -29
  18. package/dist/{connect-DG2AVGVL.js → connect-3E7EC5ZM.js} +35 -32
  19. package/dist/{doctor-FK7B6754.js → doctor-Z6OSCGKT.js} +22 -16
  20. package/dist/{exit-codes-AAFTOAXF.js → exit-codes-YSFFFWMS.js} +1 -1
  21. package/dist/{feed-HXBKXKAQ.js → feed-VDTFIMKN.js} +18 -17
  22. package/dist/{group-UYX3KTX3.js → group-KDJHY2IM.js} +21 -18
  23. package/dist/{inbox-EVE2ZTHC.js → inbox-DQLX2LR7.js} +39 -23
  24. package/dist/{inboxes-JBB34WMQ.js → inboxes-WMNHOPY7.js} +18 -17
  25. package/dist/{job-GXUZANYN.js → job-ESKS2LDJ.js} +44 -30
  26. package/dist/{login-3OAUY7TG.js → login-YTVPIN27.js} +15 -3
  27. package/dist/{message-34AGROW2.js → message-5W2R3YHS.js} +7 -9
  28. package/dist/{notification-SKKZS2C5.js → notification-IGNUH2GR.js} +20 -19
  29. package/dist/{post-FIW522Q6.js → post-NLI76K74.js} +34 -26
  30. package/dist/{profile-SX6JOYMD.js → profile-TBKKIICM.js} +71 -90
  31. package/dist/{recruiter-H7ROBEVC.js → recruiter-AEJRHIX5.js} +42 -29
  32. package/dist/{sales-nav-7KCK562X.js → sales-nav-SW6WJVMD.js} +43 -29
  33. package/dist/{search-PASMDQEH.js → search-CS6VN5AG.js} +58 -44
  34. package/dist/{setup-YV5PVIU5.js → setup-ANHJZJ2S.js} +12 -8
  35. package/dist/{webhook-GPLFPC6N.js → webhook-NGMRJMQ5.js} +25 -22
  36. package/package.json +2 -2
  37. package/dist/chunk-LKF5MZIP.js +0 -90
  38. package/dist/chunk-PKSKQ3LN.js +0 -68
  39. package/dist/chunk-R3VLWLVV.js +0 -23
  40. package/dist/chunk-TD2ZIXFR.js +0 -67
  41. package/dist/chunk-TQJ77SL4.js +0 -147
@@ -1,13 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  slimJob
4
- } from "./chunk-LJR4LJG6.js";
5
- import {
6
- DEFAULT_PAGE_DELAY_MS,
7
- ndjsonModeNotice,
8
- pageDelayFromFlags,
9
- streamAll
10
- } from "./chunk-LKF5MZIP.js";
4
+ } from "./chunk-XP2LN6F6.js";
11
5
  import {
12
6
  BinaryOutputError,
13
7
  writeBinaryOutput
@@ -15,29 +9,35 @@ import {
15
9
  import {
16
10
  resolveJobIdentifier
17
11
  } from "./chunk-UEAX6KUB.js";
18
- import {
19
- buildPreviewOutput
20
- } from "./chunk-R3VLWLVV.js";
21
12
  import {
22
13
  requireAccount
23
- } from "./chunk-V3PB4HSF.js";
14
+ } from "./chunk-MNDXMGPX.js";
15
+ import {
16
+ buildPreviewOutput
17
+ } from "./chunk-TCUYH5GO.js";
24
18
  import {
19
+ DEFAULT_PAGE_DELAY_MS,
20
+ ndjsonModeNotice,
21
+ pageDelayFromFlags,
22
+ readablePage,
23
+ rejectPaginationModifiersWithoutAll,
25
24
  renderError,
26
25
  renderSuccess,
27
- renderUnexpectedError
28
- } from "./chunk-KQXYEQAD.js";
26
+ renderUnexpectedError,
27
+ resolveEffectiveConfig,
28
+ streamAll,
29
+ writeNdjsonItem
30
+ } from "./chunk-7JU4IXXG.js";
31
+ import "./chunk-XZJQQJBE.js";
29
32
  import {
30
33
  createClient,
31
- resolveEffectiveConfig
32
- } from "./chunk-TD2ZIXFR.js";
33
- import "./chunk-PKSKQ3LN.js";
34
- import "./chunk-EIEF2KFH.js";
35
- import "./chunk-TQJ77SL4.js";
34
+ downloadBinary
35
+ } from "./chunk-DCZR4M7G.js";
36
36
  import {
37
37
  GLOBAL_FLAGS,
38
38
  READ_SINGLE_FLAGS,
39
39
  WRITE_SINGLE_FLAGS
40
- } from "./chunk-SKJNLN37.js";
40
+ } from "./chunk-XDQHNUEU.js";
41
41
 
42
42
  // src/commands/job.ts
43
43
  import { defineCommand } from "citty";
@@ -99,9 +99,9 @@ function requireEnum(value, allowed, flag, out) {
99
99
  async function handleSdkError(err, outOpts, out) {
100
100
  const { CurviateError } = await import("@curviate/sdk");
101
101
  if (err instanceof CurviateError) {
102
- const { getExitCode } = await import("./exit-codes-AAFTOAXF.js");
102
+ const { getExitCode } = await import("./exit-codes-YSFFFWMS.js");
103
103
  renderError(err, outOpts, out);
104
- process.exit(getExitCode(err.code));
104
+ process.exit(getExitCode(err));
105
105
  }
106
106
  renderUnexpectedError(err, out);
107
107
  process.exit(1);
@@ -136,8 +136,16 @@ async function runJobGet(client, flags, out) {
136
136
  }
137
137
  async function runJobList(client, flags, out) {
138
138
  rejectPreviewOnRead(flags.preview, out);
139
- const accountId = await requireAccount(client, flags, out);
140
139
  const state = requireFlag(flags.state, "--state", out);
140
+ if (state === "ALL") {
141
+ if (!flags.all && flags["max-pages"] !== void 0) {
142
+ out.stderr.write("error: --max-pages requires --all; without it, streaming never engages so the flag does nothing.\n");
143
+ process.exit(2);
144
+ }
145
+ } else {
146
+ rejectPaginationModifiersWithoutAll(flags, out);
147
+ }
148
+ const accountId = await requireAccount(client, flags, out);
141
149
  const ns = client.account(accountId);
142
150
  const outOpts = resolveOutputOpts(flags);
143
151
  const all = flags.all ?? false;
@@ -153,7 +161,7 @@ async function runJobList(client, flags, out) {
153
161
  if (flags.cursor) base.cursor = flags.cursor;
154
162
  try {
155
163
  if (all) {
156
- const fn = (p) => ns.jobs.list(p).then((page) => {
164
+ const fn = (p) => listJobs(ns, p).then((page) => {
157
165
  const { items: filtered, dropped } = filterJobsByState(page.items, state);
158
166
  if (dropped > 0) {
159
167
  out.stderr.write(stateFilterDroppedNote(dropped, page.items?.length ?? 0, state));
@@ -165,10 +173,11 @@ async function runJobList(client, flags, out) {
165
173
  out,
166
174
  pageDelayMs: pageDelayFromFlags(flags)
167
175
  })) {
168
- out.stdout.write(JSON.stringify(item) + "\n");
176
+ writeNdjsonItem(out, item, outOpts.fields);
169
177
  }
170
178
  } else {
171
- const result = await ns.jobs.list(base);
179
+ const result = await listJobs(ns, base);
180
+ readablePage(result);
172
181
  const { items: filtered, dropped } = filterJobsByState(result.items, state);
173
182
  if (dropped > 0) {
174
183
  out.stderr.write(stateFilterDroppedNote(dropped, result.items?.length ?? 0, state));
@@ -179,6 +188,9 @@ async function runJobList(client, flags, out) {
179
188
  await handleSdkError(err, outOpts, out);
180
189
  }
181
190
  }
191
+ function listJobs(ns, query) {
192
+ return ns.jobs.list(query).then(readablePage);
193
+ }
182
194
  function pace(ms) {
183
195
  return ms > 0 ? new Promise((resolve) => setTimeout(resolve, ms)) : Promise.resolve();
184
196
  }
@@ -200,7 +212,7 @@ async function runJobListAllStates(ns, flags, out, outOpts, opts) {
200
212
  const s = JOB_STATES[i];
201
213
  const base = { state: s };
202
214
  if (limit !== void 0) base.limit = limit;
203
- const fn = (p) => ns.jobs.list(p).then((page) => ({
215
+ const fn = (p) => listJobs(ns, p).then((page) => ({
204
216
  ...page,
205
217
  items: filterJobsByState(page.items, s).items
206
218
  }));
@@ -212,7 +224,7 @@ async function runJobListAllStates(ns, flags, out, outOpts, opts) {
212
224
  const id = jobItemId(item);
213
225
  if (id !== void 0 && seen.has(id)) continue;
214
226
  if (id !== void 0) seen.add(id);
215
- out.stdout.write(JSON.stringify(item) + "\n");
227
+ writeNdjsonItem(out, item, outOpts.fields);
216
228
  }
217
229
  if (i < JOB_STATES.length - 1) await pace(betweenStatesDelay);
218
230
  }
@@ -223,7 +235,7 @@ async function runJobListAllStates(ns, flags, out, outOpts, opts) {
223
235
  const s = JOB_STATES[i];
224
236
  const base = { state: s };
225
237
  if (limit !== void 0) base.limit = limit;
226
- const page = await ns.jobs.list(base);
238
+ const page = await listJobs(ns, base);
227
239
  const { items: filtered } = filterJobsByState(page.items, s);
228
240
  for (const item of filtered) {
229
241
  const id = jobItemId(item);
@@ -254,6 +266,7 @@ async function runJobBudget(client, flags, out) {
254
266
  }
255
267
  async function runJobApplicants(client, flags, out) {
256
268
  rejectPreviewOnRead(flags.preview, out);
269
+ rejectPaginationModifiersWithoutAll(flags, out);
257
270
  const accountId = await requireAccount(client, flags, out);
258
271
  const jobId = resolveJobIdentifier(flags.id ?? "");
259
272
  const ns = client.account(accountId);
@@ -276,10 +289,11 @@ async function runJobApplicants(client, flags, out) {
276
289
  out,
277
290
  pageDelayMs: pageDelayFromFlags(flags)
278
291
  })) {
279
- out.stdout.write(JSON.stringify(item) + "\n");
292
+ writeNdjsonItem(out, item, outOpts.fields);
280
293
  }
281
294
  } else {
282
295
  const result = await ns.jobs.listApplicants(jobId, base);
296
+ readablePage(result);
283
297
  renderSuccess(result, outOpts, out);
284
298
  }
285
299
  } catch (err) {
@@ -307,7 +321,7 @@ async function runJobApplicantResume(client, flags, out, isTTY) {
307
321
  const applicantId = flags.applicantId ?? "";
308
322
  const ns = client.account(accountId);
309
323
  try {
310
- const data = await ns.jobs.downloadResume(jobId, applicantId);
324
+ const data = await downloadBinary(() => ns.jobs.downloadResume(jobId, applicantId));
311
325
  await writeBinaryOutput(data, { outputPath: flags.output, isTTY, stdout: process.stdout });
312
326
  } catch (err) {
313
327
  if (err instanceof BinaryOutputError) {
@@ -3,13 +3,14 @@ import {
3
3
  readlineSync
4
4
  } from "./chunk-YLSJ4HKU.js";
5
5
  import {
6
+ baseUrlProblem,
6
7
  writeProfile
7
- } from "./chunk-TQJ77SL4.js";
8
+ } from "./chunk-DCZR4M7G.js";
8
9
  import {
9
10
  GLOBAL_FLAGS,
10
11
  defaultReadStdin,
11
12
  resolveTextOrStdin
12
- } from "./chunk-SKJNLN37.js";
13
+ } from "./chunk-XDQHNUEU.js";
13
14
 
14
15
  // src/commands/login.ts
15
16
  import { defineCommand } from "citty";
@@ -27,6 +28,13 @@ async function runLogin(args, out) {
27
28
  process.exit(2);
28
29
  return;
29
30
  }
31
+ const badUrl = baseUrl === void 0 ? null : baseUrlProblem(baseUrl);
32
+ if (badUrl) {
33
+ out.stderr.write(`error: ${badUrl}
34
+ `);
35
+ process.exit(2);
36
+ return;
37
+ }
30
38
  const account = args.account;
31
39
  const entry = { apiKey, account };
32
40
  if (baseUrl !== void 0 && baseUrl !== "") {
@@ -43,8 +51,12 @@ var loginCommand = defineCommand({
43
51
  name: "login",
44
52
  description: "Save an API key to a local profile. Run `curviate profile me` to verify."
45
53
  },
54
+ // Only what login acts on: it makes no request, so pagination, projection,
55
+ // preview and transport flags would be accepted and do nothing. `--json` is
56
+ // kept: callers pass it on every command as an output-mode selector.
46
57
  args: {
47
- ...GLOBAL_FLAGS,
58
+ "base-url": GLOBAL_FLAGS["base-url"],
59
+ json: GLOBAL_FLAGS.json,
48
60
  "api-key": {
49
61
  type: "string",
50
62
  stdinArg: true,
@@ -13,19 +13,17 @@ import {
13
13
  runMessageSend,
14
14
  sentAsNotice,
15
15
  willSendAsNotice
16
- } from "./chunk-5EJDQ47B.js";
16
+ } from "./chunk-BN7L7WSY.js";
17
17
  import "./chunk-UWO2D4HW.js";
18
18
  import "./chunk-HOQ7EUHJ.js";
19
19
  import "./chunk-BGZW6B7G.js";
20
20
  import "./chunk-UEAX6KUB.js";
21
- import "./chunk-R3VLWLVV.js";
22
- import "./chunk-V3PB4HSF.js";
23
- import "./chunk-KQXYEQAD.js";
24
- import "./chunk-TD2ZIXFR.js";
25
- import "./chunk-PKSKQ3LN.js";
26
- import "./chunk-EIEF2KFH.js";
27
- import "./chunk-TQJ77SL4.js";
28
- import "./chunk-SKJNLN37.js";
21
+ import "./chunk-MNDXMGPX.js";
22
+ import "./chunk-TCUYH5GO.js";
23
+ import "./chunk-7JU4IXXG.js";
24
+ import "./chunk-XZJQQJBE.js";
25
+ import "./chunk-DCZR4M7G.js";
26
+ import "./chunk-XDQHNUEU.js";
29
27
  export {
30
28
  guardBareMessageForm,
31
29
  messageCommand,
@@ -1,30 +1,29 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
- pageDelayFromFlags,
4
- streamAll
5
- } from "./chunk-LKF5MZIP.js";
3
+ requireAccount
4
+ } from "./chunk-MNDXMGPX.js";
6
5
  import {
7
6
  buildPreviewOutput
8
- } from "./chunk-R3VLWLVV.js";
9
- import {
10
- requireAccount
11
- } from "./chunk-V3PB4HSF.js";
7
+ } from "./chunk-TCUYH5GO.js";
12
8
  import {
9
+ pageDelayFromFlags,
10
+ readablePage,
11
+ rejectPaginationModifiersWithoutAll,
13
12
  renderError,
14
13
  renderSuccess,
15
- renderUnexpectedError
16
- } from "./chunk-KQXYEQAD.js";
14
+ renderUnexpectedError,
15
+ resolveEffectiveConfig,
16
+ streamAll,
17
+ writeNdjsonItem
18
+ } from "./chunk-7JU4IXXG.js";
19
+ import "./chunk-XZJQQJBE.js";
17
20
  import {
18
- createClient,
19
- resolveEffectiveConfig
20
- } from "./chunk-TD2ZIXFR.js";
21
- import "./chunk-PKSKQ3LN.js";
22
- import "./chunk-EIEF2KFH.js";
23
- import "./chunk-TQJ77SL4.js";
21
+ createClient
22
+ } from "./chunk-DCZR4M7G.js";
24
23
  import {
25
24
  GLOBAL_FLAGS,
26
25
  WRITE_SINGLE_FLAGS
27
- } from "./chunk-SKJNLN37.js";
26
+ } from "./chunk-XDQHNUEU.js";
28
27
 
29
28
  // src/commands/notification.ts
30
29
  import { defineCommand } from "citty";
@@ -51,15 +50,16 @@ function resolveOutputOpts(flags) {
51
50
  async function handleSdkError(err, outOpts, out) {
52
51
  const { CurviateError } = await import("@curviate/sdk");
53
52
  if (err instanceof CurviateError) {
54
- const { getExitCode } = await import("./exit-codes-AAFTOAXF.js");
53
+ const { getExitCode } = await import("./exit-codes-YSFFFWMS.js");
55
54
  renderError(err, outOpts, out);
56
- process.exit(getExitCode(err.code));
55
+ process.exit(getExitCode(err));
57
56
  }
58
57
  renderUnexpectedError(err, out);
59
58
  process.exit(1);
60
59
  }
61
60
  async function runNotificationList(client, flags, out) {
62
61
  rejectPreviewOnRead(flags.preview, out);
62
+ rejectPaginationModifiersWithoutAll(flags, out);
63
63
  const accountId = await requireAccount(client, flags, out);
64
64
  const ns = client.account(accountId);
65
65
  const outOpts = resolveOutputOpts(flags);
@@ -77,10 +77,11 @@ async function runNotificationList(client, flags, out) {
77
77
  out,
78
78
  pageDelayMs: pageDelayFromFlags(flags)
79
79
  })) {
80
- out.stdout.write(JSON.stringify(item) + "\n");
80
+ writeNdjsonItem(out, item, outOpts.fields);
81
81
  }
82
82
  } else {
83
83
  const result = await ns.notifications.list(params);
84
+ readablePage(result);
84
85
  renderSuccess(result, outOpts, out);
85
86
  }
86
87
  } catch (err) {
@@ -1,41 +1,41 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  resolveMemberOrMeProviderId
4
- } from "./chunk-6P52Q2GK.js";
5
- import {
6
- pageDelayFromFlags,
7
- streamAll
8
- } from "./chunk-LKF5MZIP.js";
4
+ } from "./chunk-ZJ7D3NFS.js";
9
5
  import {
10
6
  AttachError,
11
7
  readAttachment,
12
8
  toAttachmentPayload
13
9
  } from "./chunk-BGZW6B7G.js";
14
10
  import "./chunk-UEAX6KUB.js";
15
- import {
16
- buildPreviewOutput
17
- } from "./chunk-R3VLWLVV.js";
18
11
  import {
19
12
  requireAccount
20
- } from "./chunk-V3PB4HSF.js";
13
+ } from "./chunk-MNDXMGPX.js";
21
14
  import {
15
+ buildPreviewOutput
16
+ } from "./chunk-TCUYH5GO.js";
17
+ import {
18
+ pageDelayFromFlags,
19
+ readablePage,
20
+ rejectPaginationModifiersWithoutAll,
22
21
  renderError,
23
22
  renderSuccess,
24
- renderUnexpectedError
25
- } from "./chunk-KQXYEQAD.js";
23
+ renderUnexpectedError,
24
+ resolveEffectiveConfig,
25
+ streamAll,
26
+ writeNdjsonItem
27
+ } from "./chunk-7JU4IXXG.js";
28
+ import "./chunk-XZJQQJBE.js";
26
29
  import {
27
- createClient,
28
- resolveEffectiveConfig
29
- } from "./chunk-TD2ZIXFR.js";
30
- import "./chunk-PKSKQ3LN.js";
31
- import "./chunk-EIEF2KFH.js";
32
- import "./chunk-TQJ77SL4.js";
30
+ createClient
31
+ } from "./chunk-DCZR4M7G.js";
33
32
  import {
34
33
  GLOBAL_FLAGS,
34
+ NON_STREAM_FLAGS,
35
35
  WRITE_FLAGS,
36
36
  WRITE_SINGLE_FLAGS,
37
37
  resolveTextOrStdin
38
- } from "./chunk-SKJNLN37.js";
38
+ } from "./chunk-XDQHNUEU.js";
39
39
 
40
40
  // src/commands/post.ts
41
41
  import { defineCommand } from "citty";
@@ -78,9 +78,9 @@ function normalizeAttachPaths(attach) {
78
78
  async function handleSdkError(err, outOpts, out) {
79
79
  const { CurviateError } = await import("@curviate/sdk");
80
80
  if (err instanceof CurviateError) {
81
- const { getExitCode } = await import("./exit-codes-AAFTOAXF.js");
81
+ const { getExitCode } = await import("./exit-codes-YSFFFWMS.js");
82
82
  renderError(err, outOpts, out);
83
- process.exit(getExitCode(err.code));
83
+ process.exit(getExitCode(err));
84
84
  }
85
85
  renderUnexpectedError(err, out);
86
86
  process.exit(1);
@@ -182,6 +182,7 @@ async function runPostReact(client, flags, out) {
182
182
  }
183
183
  async function runPostReactions(client, flags, out) {
184
184
  rejectPreviewOnRead(flags.preview, out);
185
+ rejectPaginationModifiersWithoutAll(flags, out);
185
186
  const accountId = await requireAccount(client, flags, out);
186
187
  const postId = flags.postId ?? "";
187
188
  const ns = client.account(accountId);
@@ -197,10 +198,11 @@ async function runPostReactions(client, flags, out) {
197
198
  out,
198
199
  pageDelayMs: pageDelayFromFlags(flags)
199
200
  })) {
200
- out.stdout.write(JSON.stringify(item) + "\n");
201
+ writeNdjsonItem(out, item, outOpts.fields);
201
202
  }
202
203
  } else {
203
204
  const result = await ns.posts.listReactions(postId, params);
205
+ readablePage(result);
204
206
  renderSuccess(result, outOpts, out);
205
207
  }
206
208
  } catch (err) {
@@ -209,6 +211,7 @@ async function runPostReactions(client, flags, out) {
209
211
  }
210
212
  async function runPostSaved(client, flags, out) {
211
213
  rejectPreviewOnRead(flags.preview, out);
214
+ rejectPaginationModifiersWithoutAll(flags, out);
212
215
  const accountId = await requireAccount(client, flags, out);
213
216
  const ns = client.account(accountId);
214
217
  const outOpts = resolveOutputOpts(flags);
@@ -223,10 +226,11 @@ async function runPostSaved(client, flags, out) {
223
226
  out,
224
227
  pageDelayMs: pageDelayFromFlags(flags)
225
228
  })) {
226
- out.stdout.write(JSON.stringify(item) + "\n");
229
+ writeNdjsonItem(out, item, outOpts.fields);
227
230
  }
228
231
  } else {
229
232
  const result = await ns.posts.listSaved(params);
233
+ readablePage(result);
230
234
  renderSuccess(result, outOpts, out);
231
235
  }
232
236
  } catch (err) {
@@ -315,6 +319,7 @@ async function runPostUnreact(client, flags, out) {
315
319
  }
316
320
  async function runPostUserPosts(client, flags, out) {
317
321
  rejectPreviewOnRead(flags.preview, out);
322
+ rejectPaginationModifiersWithoutAll(flags, out);
318
323
  const accountId = await requireAccount(client, flags, out);
319
324
  const ns = client.account(accountId);
320
325
  const outOpts = resolveOutputOpts(flags);
@@ -336,10 +341,11 @@ async function runPostUserPosts(client, flags, out) {
336
341
  out,
337
342
  pageDelayMs: pageDelayFromFlags(flags)
338
343
  })) {
339
- out.stdout.write(JSON.stringify(item) + "\n");
344
+ writeNdjsonItem(out, item, outOpts.fields);
340
345
  }
341
346
  } else {
342
347
  const result = await ns.posts.listUserPosts(userId, params);
348
+ readablePage(result);
343
349
  renderSuccess(result, outOpts, out);
344
350
  }
345
351
  } catch (err) {
@@ -348,6 +354,7 @@ async function runPostUserPosts(client, flags, out) {
348
354
  }
349
355
  async function runPostUserReactions(client, flags, out) {
350
356
  rejectPreviewOnRead(flags.preview, out);
357
+ rejectPaginationModifiersWithoutAll(flags, out);
351
358
  const accountId = await requireAccount(client, flags, out);
352
359
  const ns = client.account(accountId);
353
360
  const outOpts = resolveOutputOpts(flags);
@@ -369,10 +376,11 @@ async function runPostUserReactions(client, flags, out) {
369
376
  out,
370
377
  pageDelayMs: pageDelayFromFlags(flags)
371
378
  })) {
372
- out.stdout.write(JSON.stringify(item) + "\n");
379
+ writeNdjsonItem(out, item, outOpts.fields);
373
380
  }
374
381
  } else {
375
382
  const result = await ns.posts.listUserReactions(userId, params);
383
+ readablePage(result);
376
384
  renderSuccess(result, outOpts, out);
377
385
  }
378
386
  } catch (err) {
@@ -382,7 +390,7 @@ async function runPostUserReactions(client, flags, out) {
382
390
  var postGetCommand = defineCommand({
383
391
  meta: { name: "get", description: "Get a post by id." },
384
392
  args: {
385
- ...GLOBAL_FLAGS,
393
+ ...NON_STREAM_FLAGS,
386
394
  postId: {
387
395
  type: "positional",
388
396
  description: "Numeric post id, urn:li:activity:N, or full LinkedIn share URL (activity-<N>- extracted). POSTID is always the post's id. To list comments on a post, use 'comment list <post_id>'."
@@ -579,7 +587,7 @@ var postUserPostsCommand = defineCommand({
579
587
  }
580
588
  });
581
589
  var postUserReactionsCommand = defineCommand({
582
- meta: { name: "user-reactions", description: "List a member's own reactions (accepts 'me')." },
590
+ meta: { name: "user-reactions", description: "List a member's own reactions (accepts 'me'). Items carry no time of the reaction: `parent_post.created_at` is when the post was created, not when it was reacted to, so the listing cannot be filtered by date; without `--all`, `--limit` caps the read at one page." },
583
591
  args: {
584
592
  ...GLOBAL_FLAGS,
585
593
  userId: { type: "positional", description: "Member identifier (URL, slug, provider id, or 'me')." }