@curviate/cli 0.40.0 → 0.42.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.
- package/CHANGELOG.md +67 -0
- package/dist/{account-LTXAUBBP.js → account-PFK5YROZ.js} +81 -26
- package/dist/{chunk-OTBJATDE.js → chunk-B5NIX4G6.js} +6 -1
- package/dist/{chunk-LD5KJSCT.js → chunk-BLJGV6ST.js} +2 -2
- package/dist/{chunk-6W7364S3.js → chunk-KJ24DIAJ.js} +1 -1
- package/dist/{chunk-T6G5AASF.js → chunk-OUMMWC7G.js} +79 -26
- package/dist/{chunk-BGVK73VI.js → chunk-PCZH5QJA.js} +1 -1
- package/dist/{chunk-XDQHNUEU.js → chunk-TC4ZPUWI.js} +12 -6
- package/dist/{chunk-DCZR4M7G.js → chunk-UJOTQPL6.js} +1 -1
- package/dist/cli.js +64 -53
- package/dist/{comment-2CSBSBOH.js → comment-G4EXIIAQ.js} +83 -29
- package/dist/{company-ZUIUR5UN.js → company-WX5QOASS.js} +104 -50
- package/dist/{config-RUBXWFQ3.js → config-K4G3VSBA.js} +44 -9
- package/dist/{connect-LSXKNEL2.js → connect-IYTFL7NT.js} +44 -21
- package/dist/{doctor-FHOHIQPX.js → doctor-ICAEETCL.js} +8 -4
- package/dist/examples-IJL3A6SZ.js +18 -0
- package/dist/{feed-UUHB2FXI.js → feed-XC5235UF.js} +16 -14
- package/dist/{group-NUCO3P2W.js → group-JDP2HVSV.js} +31 -20
- package/dist/{inbox-DEZTGTPO.js → inbox-W3KR65VD.js} +51 -24
- package/dist/{inboxes-F3NIQQRK.js → inboxes-XYS3IRT6.js} +23 -17
- package/dist/{job-YMGO3WJH.js → job-XW3WM57J.js} +112 -34
- package/dist/{login-YTVPIN27.js → login-OHAHNBRW.js} +7 -3
- package/dist/{message-RSBUXI64.js → message-5XC7U4JC.js} +5 -5
- package/dist/{notification-EJ35OD3Q.js → notification-RIUSYJV6.js} +26 -16
- package/dist/{post-VHVQ56A7.js → post-LSEBRQYK.js} +96 -32
- package/dist/{profile-3CBNI42H.js → profile-NHTYGX7K.js} +130 -43
- package/dist/{recruiter-M7XUFYNR.js → recruiter-4SDAROK4.js} +219 -67
- package/dist/{sales-nav-S47OCEUC.js → sales-nav-77NP3UXV.js} +102 -42
- package/dist/{search-UWI37MKG.js → search-XDOQZAVG.js} +80 -39
- package/dist/{setup-3EQRACT6.js → setup-BPNLAHPC.js} +9 -4
- package/dist/{webhook-I4U4C4XE.js → webhook-XOPRW63N.js} +62 -23
- package/package.json +3 -2
|
@@ -86,7 +86,7 @@ var GLOBAL_FLAGS = {
|
|
|
86
86
|
},
|
|
87
87
|
account: {
|
|
88
88
|
type: "string",
|
|
89
|
-
description: "Account id for account-scoped commands. Optional when exactly one account is connected."
|
|
89
|
+
description: "Account id for account-scoped commands. Optional when exactly one account is connected, and required with --preview."
|
|
90
90
|
},
|
|
91
91
|
"base-url": {
|
|
92
92
|
type: "string",
|
|
@@ -121,11 +121,11 @@ var GLOBAL_FLAGS = {
|
|
|
121
121
|
},
|
|
122
122
|
"max-pages": {
|
|
123
123
|
type: "string",
|
|
124
|
-
description: "Maximum number of pages to fetch when --all is used."
|
|
124
|
+
description: "Maximum number of pages to fetch when --all is used. Refused (exit 2) without --all."
|
|
125
125
|
},
|
|
126
126
|
"page-delay": {
|
|
127
127
|
type: "string",
|
|
128
|
-
description: "Milliseconds to pause between pages when --all is used (default 400; pass 0 to disable). A modest delay keeps a long stream under the platform rate gate."
|
|
128
|
+
description: "Milliseconds to pause between pages when --all is used (default 400; pass 0 to disable). A modest delay keeps a long stream under the platform rate gate. Refused (exit 2) without --all."
|
|
129
129
|
},
|
|
130
130
|
preview: {
|
|
131
131
|
type: "boolean",
|
|
@@ -184,6 +184,11 @@ var READ_SINGLE_FLAGS = {
|
|
|
184
184
|
beta: GLOBAL_FLAGS.beta
|
|
185
185
|
};
|
|
186
186
|
var WRITE_SINGLE_FLAGS = READ_SINGLE_FLAGS;
|
|
187
|
+
function readOnly(flags) {
|
|
188
|
+
const rest = { ...flags };
|
|
189
|
+
delete rest.preview;
|
|
190
|
+
return rest;
|
|
191
|
+
}
|
|
187
192
|
|
|
188
193
|
// src/lib/beta.ts
|
|
189
194
|
var BETA_CONSENT_HEADER = "X-Curviate-Beta";
|
|
@@ -258,12 +263,13 @@ export {
|
|
|
258
263
|
restoreLiteralDashes,
|
|
259
264
|
assertNoStdinPlaceholder,
|
|
260
265
|
resolveTextOrStdin,
|
|
266
|
+
parseBetaFlag,
|
|
267
|
+
setBetaOverride,
|
|
268
|
+
betaOverrideHeader,
|
|
261
269
|
GLOBAL_FLAGS,
|
|
262
270
|
NON_STREAM_FLAGS,
|
|
263
271
|
WRITE_FLAGS,
|
|
264
272
|
READ_SINGLE_FLAGS,
|
|
265
273
|
WRITE_SINGLE_FLAGS,
|
|
266
|
-
|
|
267
|
-
setBetaOverride,
|
|
268
|
-
betaOverrideHeader
|
|
274
|
+
readOnly
|
|
269
275
|
};
|
package/dist/cli.js
CHANGED
|
@@ -8,14 +8,58 @@ import {
|
|
|
8
8
|
parseBetaFlag,
|
|
9
9
|
restoreLiteralDashes,
|
|
10
10
|
setBetaOverride
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-TC4ZPUWI.js";
|
|
12
12
|
|
|
13
|
-
// src/
|
|
13
|
+
// src/main.ts
|
|
14
14
|
import { defineCommand } from "citty";
|
|
15
15
|
import { createRequire } from "module";
|
|
16
|
+
import { fileURLToPath } from "url";
|
|
17
|
+
import { dirname, resolve } from "path";
|
|
18
|
+
var __dirname = dirname(fileURLToPath(import.meta.url));
|
|
19
|
+
var require2 = createRequire(import.meta.url);
|
|
20
|
+
var pkg = require2(resolve(__dirname, "../package.json"));
|
|
21
|
+
var main = defineCommand({
|
|
22
|
+
meta: {
|
|
23
|
+
name: "curviate",
|
|
24
|
+
version: pkg.version,
|
|
25
|
+
description: "Official command-line interface for the Curviate API."
|
|
26
|
+
},
|
|
27
|
+
// Subcommand registry, names and descriptions are static for help rendering;
|
|
28
|
+
// the handler implementation is loaded lazily on first invocation.
|
|
29
|
+
subCommands: {
|
|
30
|
+
setup: () => import("./setup-BPNLAHPC.js").then((m) => m.setupCommand),
|
|
31
|
+
doctor: () => import("./doctor-ICAEETCL.js").then((m) => m.doctorCommand),
|
|
32
|
+
login: () => import("./login-OHAHNBRW.js").then((m) => m.loginCommand),
|
|
33
|
+
config: () => import("./config-K4G3VSBA.js").then((m) => m.configCommand),
|
|
34
|
+
// ---------------------------------------------------------------------------
|
|
35
|
+
// Noun groups, lazy-loaded on first invocation.
|
|
36
|
+
// ---------------------------------------------------------------------------
|
|
37
|
+
profile: () => import("./profile-NHTYGX7K.js").then((m) => m.profileCommand),
|
|
38
|
+
company: () => import("./company-WX5QOASS.js").then((m) => m.companyCommand),
|
|
39
|
+
job: () => import("./job-XW3WM57J.js").then((m) => m.jobCommand),
|
|
40
|
+
connect: () => import("./connect-IYTFL7NT.js").then((m) => m.connectCommand),
|
|
41
|
+
search: () => import("./search-XDOQZAVG.js").then((m) => m.searchCommand),
|
|
42
|
+
inbox: () => import("./inbox-W3KR65VD.js").then((m) => m.inboxCommand),
|
|
43
|
+
inboxes: () => import("./inboxes-XYS3IRT6.js").then((m) => m.inboxesCommand),
|
|
44
|
+
message: () => import("./message-5XC7U4JC.js").then((m) => m.messageCommand),
|
|
45
|
+
post: () => import("./post-LSEBRQYK.js").then((m) => m.postCommand),
|
|
46
|
+
comment: () => import("./comment-G4EXIIAQ.js").then((m) => m.commentCommand),
|
|
47
|
+
account: () => import("./account-PFK5YROZ.js").then((m) => m.accountCommand),
|
|
48
|
+
webhook: () => import("./webhook-XOPRW63N.js").then((m) => m.webhookCommand),
|
|
49
|
+
"sales-nav": () => import("./sales-nav-77NP3UXV.js").then((m) => m.salesNavCommand),
|
|
50
|
+
recruiter: () => import("./recruiter-4SDAROK4.js").then((m) => m.recruiterCommand),
|
|
51
|
+
group: () => import("./group-JDP2HVSV.js").then((m) => m.groupCommand),
|
|
52
|
+
feed: () => import("./feed-XC5235UF.js").then((m) => m.feedCommand),
|
|
53
|
+
notification: () => import("./notification-RIUSYJV6.js").then((m) => m.notificationCommand)
|
|
54
|
+
},
|
|
55
|
+
async run() {
|
|
56
|
+
const { runMain } = await import("citty");
|
|
57
|
+
await runMain(main, { rawArgs: ["--help"] });
|
|
58
|
+
}
|
|
59
|
+
});
|
|
16
60
|
|
|
17
61
|
// src/dispatch.ts
|
|
18
|
-
import { runCommand } from "citty";
|
|
62
|
+
import { parseArgs, runCommand } from "citty";
|
|
19
63
|
var GLOBAL_FLAG_NAMES = new Set(Object.keys(GLOBAL_FLAGS));
|
|
20
64
|
var GLOBAL_BOOLEAN_FLAG_NAMES = new Set(
|
|
21
65
|
Object.entries(GLOBAL_FLAGS).filter(([, def]) => def.type === "boolean").map(([name]) => name)
|
|
@@ -221,6 +265,14 @@ async function declaredArgNames(cmd) {
|
|
|
221
265
|
}
|
|
222
266
|
return names;
|
|
223
267
|
}
|
|
268
|
+
function dropFalsePreview(args, walk, declared) {
|
|
269
|
+
if (declared.has("preview") || !declared.has("beta")) return args;
|
|
270
|
+
const readsFalse = (token) => parseArgs([token], { preview: GLOBAL_FLAGS.preview }).preview === false;
|
|
271
|
+
const drop = new Set(
|
|
272
|
+
walk.flags.filter(({ token, name }) => (name === "preview" || name === "no-preview") && readsFalse(token)).map(({ index }) => index)
|
|
273
|
+
);
|
|
274
|
+
return drop.size ? args.filter((_, i) => !drop.has(i)) : args;
|
|
275
|
+
}
|
|
224
276
|
function findUnknownFlag(flags, declared, booleans) {
|
|
225
277
|
for (const { token, name, index } of flags) {
|
|
226
278
|
const dashes = /^-*/.exec(token)[0].length;
|
|
@@ -322,9 +374,9 @@ async function resolveLeaf(cmd, rawArgs, descent) {
|
|
|
322
374
|
}
|
|
323
375
|
async function dispatch(root, rawArgs) {
|
|
324
376
|
if (rawArgs.includes("--help") || rawArgs.includes("-h")) {
|
|
325
|
-
const {
|
|
326
|
-
|
|
327
|
-
await runMain(root, { rawArgs });
|
|
377
|
+
const { runMain } = await import("citty");
|
|
378
|
+
const { showUsageWithExamples } = await import("./examples-IJL3A6SZ.js");
|
|
379
|
+
await runMain(root, { rawArgs, showUsage: showUsageWithExamples });
|
|
328
380
|
return;
|
|
329
381
|
}
|
|
330
382
|
const versionProbe = parseBetaFlag(rawArgs);
|
|
@@ -344,17 +396,20 @@ async function dispatch(root, rawArgs) {
|
|
|
344
396
|
const argsAfterBeta = beta.ok ? beta.rest : rawArgs;
|
|
345
397
|
let hintLeaf;
|
|
346
398
|
try {
|
|
347
|
-
const { leaf, leafArgs } = await resolveLeaf(root, argsAfterBeta);
|
|
399
|
+
const { leaf, leafArgs: resolvedArgs } = await resolveLeaf(root, argsAfterBeta);
|
|
348
400
|
hintLeaf = leaf;
|
|
349
|
-
if (hasEmptyFields(
|
|
401
|
+
if (hasEmptyFields(resolvedArgs)) {
|
|
350
402
|
usageError("--fields must not be empty.");
|
|
351
403
|
}
|
|
352
404
|
const booleanFlags = await booleanFlagNames(leaf);
|
|
353
405
|
const declared = await declaredArgNames(leaf);
|
|
406
|
+
const leafArgs = dropFalsePreview(resolvedArgs, walkTokens(resolvedArgs, booleanFlags, declared), declared);
|
|
354
407
|
const walk = walkTokens(leafArgs, booleanFlags, declared);
|
|
355
408
|
const unknown = findUnknownFlag(walk.flags, declared, booleanFlags);
|
|
356
409
|
if (unknown !== null) {
|
|
357
|
-
usageError(
|
|
410
|
+
usageError(
|
|
411
|
+
unknown === "`--preview`" && declared.has("beta") ? "--preview is only valid on write commands (mutations). Reads just run." : `unknown flag ${unknown}.`
|
|
412
|
+
);
|
|
358
413
|
}
|
|
359
414
|
const repeated = await repeatedFlag(leaf, walk.flags);
|
|
360
415
|
if (repeated !== null) {
|
|
@@ -400,48 +455,4 @@ async function dispatch(root, rawArgs) {
|
|
|
400
455
|
}
|
|
401
456
|
|
|
402
457
|
// src/cli.ts
|
|
403
|
-
import { fileURLToPath } from "url";
|
|
404
|
-
import { dirname, resolve } from "path";
|
|
405
|
-
var __dirname = dirname(fileURLToPath(import.meta.url));
|
|
406
|
-
var require2 = createRequire(import.meta.url);
|
|
407
|
-
var pkg = require2(resolve(__dirname, "../package.json"));
|
|
408
|
-
var main = defineCommand({
|
|
409
|
-
meta: {
|
|
410
|
-
name: "curviate",
|
|
411
|
-
version: pkg.version,
|
|
412
|
-
description: "Official command-line interface for the Curviate API."
|
|
413
|
-
},
|
|
414
|
-
// Subcommand registry, names and descriptions are static for help rendering;
|
|
415
|
-
// the handler implementation is loaded lazily on first invocation.
|
|
416
|
-
subCommands: {
|
|
417
|
-
setup: () => import("./setup-3EQRACT6.js").then((m) => m.setupCommand),
|
|
418
|
-
doctor: () => import("./doctor-FHOHIQPX.js").then((m) => m.doctorCommand),
|
|
419
|
-
login: () => import("./login-YTVPIN27.js").then((m) => m.loginCommand),
|
|
420
|
-
config: () => import("./config-RUBXWFQ3.js").then((m) => m.configCommand),
|
|
421
|
-
// ---------------------------------------------------------------------------
|
|
422
|
-
// Noun groups, lazy-loaded on first invocation.
|
|
423
|
-
// ---------------------------------------------------------------------------
|
|
424
|
-
profile: () => import("./profile-3CBNI42H.js").then((m) => m.profileCommand),
|
|
425
|
-
company: () => import("./company-ZUIUR5UN.js").then((m) => m.companyCommand),
|
|
426
|
-
job: () => import("./job-YMGO3WJH.js").then((m) => m.jobCommand),
|
|
427
|
-
connect: () => import("./connect-LSXKNEL2.js").then((m) => m.connectCommand),
|
|
428
|
-
search: () => import("./search-UWI37MKG.js").then((m) => m.searchCommand),
|
|
429
|
-
inbox: () => import("./inbox-DEZTGTPO.js").then((m) => m.inboxCommand),
|
|
430
|
-
inboxes: () => import("./inboxes-F3NIQQRK.js").then((m) => m.inboxesCommand),
|
|
431
|
-
message: () => import("./message-RSBUXI64.js").then((m) => m.messageCommand),
|
|
432
|
-
post: () => import("./post-VHVQ56A7.js").then((m) => m.postCommand),
|
|
433
|
-
comment: () => import("./comment-2CSBSBOH.js").then((m) => m.commentCommand),
|
|
434
|
-
account: () => import("./account-LTXAUBBP.js").then((m) => m.accountCommand),
|
|
435
|
-
webhook: () => import("./webhook-I4U4C4XE.js").then((m) => m.webhookCommand),
|
|
436
|
-
"sales-nav": () => import("./sales-nav-S47OCEUC.js").then((m) => m.salesNavCommand),
|
|
437
|
-
recruiter: () => import("./recruiter-M7XUFYNR.js").then((m) => m.recruiterCommand),
|
|
438
|
-
group: () => import("./group-NUCO3P2W.js").then((m) => m.groupCommand),
|
|
439
|
-
feed: () => import("./feed-UUHB2FXI.js").then((m) => m.feedCommand),
|
|
440
|
-
notification: () => import("./notification-EJ35OD3Q.js").then((m) => m.notificationCommand)
|
|
441
|
-
},
|
|
442
|
-
async run() {
|
|
443
|
-
const { runMain } = await import("citty");
|
|
444
|
-
await runMain(main, { rawArgs: ["--help"] });
|
|
445
|
-
}
|
|
446
|
-
});
|
|
447
458
|
void dispatch(main, process.argv.slice(2));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
resolveMemberOrMeProviderId
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-PCZH5QJA.js";
|
|
5
5
|
import {
|
|
6
6
|
AttachError,
|
|
7
7
|
describeAttachment,
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
import "./chunk-UEAX6KUB.js";
|
|
12
12
|
import {
|
|
13
13
|
requireAccount
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-BLJGV6ST.js";
|
|
15
15
|
import {
|
|
16
16
|
buildPreviewOutput
|
|
17
17
|
} from "./chunk-TCUYH5GO.js";
|
|
@@ -27,16 +27,17 @@ import {
|
|
|
27
27
|
resolveEffectiveConfig,
|
|
28
28
|
streamAll,
|
|
29
29
|
writeNdjsonItem
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-B5NIX4G6.js";
|
|
31
31
|
import "./chunk-XZJQQJBE.js";
|
|
32
32
|
import {
|
|
33
33
|
createClient
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-UJOTQPL6.js";
|
|
35
35
|
import {
|
|
36
36
|
GLOBAL_FLAGS,
|
|
37
37
|
WRITE_SINGLE_FLAGS,
|
|
38
|
+
readOnly,
|
|
38
39
|
resolveTextOrStdin
|
|
39
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-TC4ZPUWI.js";
|
|
40
41
|
|
|
41
42
|
// src/commands/comment.ts
|
|
42
43
|
import { defineCommand } from "citty";
|
|
@@ -47,12 +48,6 @@ function buildOutputStreams() {
|
|
|
47
48
|
stderr: { write: (s) => process.stderr.write(s) }
|
|
48
49
|
};
|
|
49
50
|
}
|
|
50
|
-
function rejectPreviewOnRead(preview, out) {
|
|
51
|
-
if (preview) {
|
|
52
|
-
out.stderr.write("error: --preview is only valid on write commands (mutations). Reads just run.\n");
|
|
53
|
-
process.exit(2);
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
51
|
function resolveOutputOpts(flags) {
|
|
57
52
|
return {
|
|
58
53
|
json: (flags.json ?? false) || !process.stdout.isTTY,
|
|
@@ -91,7 +86,6 @@ function assertReaction(reaction, out) {
|
|
|
91
86
|
}
|
|
92
87
|
}
|
|
93
88
|
async function runCommentList(client, flags, out) {
|
|
94
|
-
rejectPreviewOnRead(flags.preview, out);
|
|
95
89
|
rejectPaginationModifiersWithoutAll(flags, out);
|
|
96
90
|
const accountId = await requireAccount(client, flags, out);
|
|
97
91
|
const postId = flags.postId ?? "";
|
|
@@ -120,7 +114,6 @@ async function runCommentList(client, flags, out) {
|
|
|
120
114
|
}
|
|
121
115
|
}
|
|
122
116
|
async function runCommentReplies(client, flags, out) {
|
|
123
|
-
rejectPreviewOnRead(flags.preview, out);
|
|
124
117
|
rejectPaginationModifiersWithoutAll(flags, out);
|
|
125
118
|
const accountId = await requireAccount(client, flags, out);
|
|
126
119
|
const postId = flags.postId ?? "";
|
|
@@ -150,7 +143,6 @@ async function runCommentReplies(client, flags, out) {
|
|
|
150
143
|
}
|
|
151
144
|
}
|
|
152
145
|
async function runCommentReactions(client, flags, out) {
|
|
153
|
-
rejectPreviewOnRead(flags.preview, out);
|
|
154
146
|
rejectPaginationModifiersWithoutAll(flags, out);
|
|
155
147
|
const accountId = await requireAccount(client, flags, out);
|
|
156
148
|
const postId = flags.postId ?? "";
|
|
@@ -180,7 +172,6 @@ async function runCommentReactions(client, flags, out) {
|
|
|
180
172
|
}
|
|
181
173
|
}
|
|
182
174
|
async function runCommentUser(client, flags, out) {
|
|
183
|
-
rejectPreviewOnRead(flags.preview, out);
|
|
184
175
|
rejectPaginationModifiersWithoutAll(flags, out);
|
|
185
176
|
const accountId = await requireAccount(client, flags, out);
|
|
186
177
|
const ns = client.account(accountId);
|
|
@@ -414,9 +405,16 @@ async function withClient(flags, fn) {
|
|
|
414
405
|
await fn(client, { ...flags, account: flags.account ?? cfg.account }, out);
|
|
415
406
|
}
|
|
416
407
|
var commentListCommand = defineCommand({
|
|
417
|
-
meta: {
|
|
408
|
+
meta: {
|
|
409
|
+
name: "list",
|
|
410
|
+
description: "List the comments on a post. A very recent add/delete may take a few minutes to appear or clear here (LinkedIn-side indexing).",
|
|
411
|
+
examples: [
|
|
412
|
+
"curviate comment list 7290000000000000000",
|
|
413
|
+
"curviate comment list 7290000000000000000 --all"
|
|
414
|
+
]
|
|
415
|
+
},
|
|
418
416
|
args: {
|
|
419
|
-
...GLOBAL_FLAGS,
|
|
417
|
+
...readOnly(GLOBAL_FLAGS),
|
|
420
418
|
postId: { type: "positional", description: "Post id (or share URN) to list comments for." }
|
|
421
419
|
},
|
|
422
420
|
async run({ args }) {
|
|
@@ -424,9 +422,16 @@ var commentListCommand = defineCommand({
|
|
|
424
422
|
}
|
|
425
423
|
});
|
|
426
424
|
var commentRepliesCommand = defineCommand({
|
|
427
|
-
meta: {
|
|
425
|
+
meta: {
|
|
426
|
+
name: "replies",
|
|
427
|
+
description: "List the replies to a comment.",
|
|
428
|
+
examples: [
|
|
429
|
+
"curviate comment replies 7290000000000000000 COMMENT_ID",
|
|
430
|
+
"curviate comment replies 7290000000000000000 COMMENT_ID --all"
|
|
431
|
+
]
|
|
432
|
+
},
|
|
428
433
|
args: {
|
|
429
|
-
...GLOBAL_FLAGS,
|
|
434
|
+
...readOnly(GLOBAL_FLAGS),
|
|
430
435
|
postId: { type: "positional", description: "Post id the comment belongs to." },
|
|
431
436
|
commentId: { type: "positional", description: "Comment id to list replies for." }
|
|
432
437
|
},
|
|
@@ -435,9 +440,15 @@ var commentRepliesCommand = defineCommand({
|
|
|
435
440
|
}
|
|
436
441
|
});
|
|
437
442
|
var commentReactionsCommand = defineCommand({
|
|
438
|
-
meta: {
|
|
443
|
+
meta: {
|
|
444
|
+
name: "reactions",
|
|
445
|
+
description: "List the reactions on a comment.",
|
|
446
|
+
examples: [
|
|
447
|
+
"curviate comment reactions 7290000000000000000 COMMENT_ID"
|
|
448
|
+
]
|
|
449
|
+
},
|
|
439
450
|
args: {
|
|
440
|
-
...GLOBAL_FLAGS,
|
|
451
|
+
...readOnly(GLOBAL_FLAGS),
|
|
441
452
|
postId: { type: "positional", description: "Post id the comment belongs to." },
|
|
442
453
|
commentId: { type: "positional", description: "Comment id to list reactions for." }
|
|
443
454
|
},
|
|
@@ -446,9 +457,16 @@ var commentReactionsCommand = defineCommand({
|
|
|
446
457
|
}
|
|
447
458
|
});
|
|
448
459
|
var commentUserCommand = defineCommand({
|
|
449
|
-
meta: {
|
|
460
|
+
meta: {
|
|
461
|
+
name: "user",
|
|
462
|
+
description: "List the comments authored by a user (accepts 'me').",
|
|
463
|
+
examples: [
|
|
464
|
+
"curviate comment user me",
|
|
465
|
+
"curviate comment user janesmith --limit 10"
|
|
466
|
+
]
|
|
467
|
+
},
|
|
450
468
|
args: {
|
|
451
|
-
...GLOBAL_FLAGS,
|
|
469
|
+
...readOnly(GLOBAL_FLAGS),
|
|
452
470
|
userId: { type: "positional", description: "Member identifier (URL, slug, provider id, or 'me')." }
|
|
453
471
|
},
|
|
454
472
|
async run({ args }) {
|
|
@@ -456,7 +474,13 @@ var commentUserCommand = defineCommand({
|
|
|
456
474
|
}
|
|
457
475
|
});
|
|
458
476
|
var commentAddCommand = defineCommand({
|
|
459
|
-
meta: {
|
|
477
|
+
meta: {
|
|
478
|
+
name: "add",
|
|
479
|
+
description: "Publish a comment on a post.",
|
|
480
|
+
examples: [
|
|
481
|
+
'curviate comment add 7290000000000000000 "Useful breakdown, thanks for sharing."'
|
|
482
|
+
]
|
|
483
|
+
},
|
|
460
484
|
args: {
|
|
461
485
|
...WRITE_SINGLE_FLAGS,
|
|
462
486
|
postId: { type: "positional", description: "Post id to comment on." },
|
|
@@ -468,7 +492,13 @@ var commentAddCommand = defineCommand({
|
|
|
468
492
|
}
|
|
469
493
|
});
|
|
470
494
|
var commentReplyCommand = defineCommand({
|
|
471
|
-
meta: {
|
|
495
|
+
meta: {
|
|
496
|
+
name: "reply",
|
|
497
|
+
description: "Reply to a comment.",
|
|
498
|
+
examples: [
|
|
499
|
+
'curviate comment reply 7290000000000000000 COMMENT_ID "Agreed, that matches what we saw."'
|
|
500
|
+
]
|
|
501
|
+
},
|
|
472
502
|
args: {
|
|
473
503
|
...WRITE_SINGLE_FLAGS,
|
|
474
504
|
postId: { type: "positional", description: "Post id the comment belongs to." },
|
|
@@ -481,7 +511,13 @@ var commentReplyCommand = defineCommand({
|
|
|
481
511
|
}
|
|
482
512
|
});
|
|
483
513
|
var commentEditCommand = defineCommand({
|
|
484
|
-
meta: {
|
|
514
|
+
meta: {
|
|
515
|
+
name: "edit",
|
|
516
|
+
description: "Edit your own comment.",
|
|
517
|
+
examples: [
|
|
518
|
+
'curviate comment edit 7290000000000000000 COMMENT_ID "Useful breakdown, thanks for writing it up."'
|
|
519
|
+
]
|
|
520
|
+
},
|
|
485
521
|
args: {
|
|
486
522
|
...WRITE_SINGLE_FLAGS,
|
|
487
523
|
postId: { type: "positional", description: "Post id the comment belongs to." },
|
|
@@ -493,7 +529,13 @@ var commentEditCommand = defineCommand({
|
|
|
493
529
|
}
|
|
494
530
|
});
|
|
495
531
|
var commentDeleteCommand = defineCommand({
|
|
496
|
-
meta: {
|
|
532
|
+
meta: {
|
|
533
|
+
name: "delete",
|
|
534
|
+
description: "Delete your own comment.",
|
|
535
|
+
examples: [
|
|
536
|
+
"curviate comment delete 7290000000000000000 COMMENT_ID"
|
|
537
|
+
]
|
|
538
|
+
},
|
|
497
539
|
args: {
|
|
498
540
|
...WRITE_SINGLE_FLAGS,
|
|
499
541
|
postId: { type: "positional", description: "Post id the comment belongs to." },
|
|
@@ -504,7 +546,13 @@ var commentDeleteCommand = defineCommand({
|
|
|
504
546
|
}
|
|
505
547
|
});
|
|
506
548
|
var commentReactCommand = defineCommand({
|
|
507
|
-
meta: {
|
|
549
|
+
meta: {
|
|
550
|
+
name: "react",
|
|
551
|
+
description: "React to a comment (like|celebrate|support|love|insightful|funny).",
|
|
552
|
+
examples: [
|
|
553
|
+
"curviate comment react 7290000000000000000 COMMENT_ID insightful"
|
|
554
|
+
]
|
|
555
|
+
},
|
|
508
556
|
args: {
|
|
509
557
|
...WRITE_SINGLE_FLAGS,
|
|
510
558
|
postId: { type: "positional", description: "Post id the comment belongs to." },
|
|
@@ -516,7 +564,13 @@ var commentReactCommand = defineCommand({
|
|
|
516
564
|
}
|
|
517
565
|
});
|
|
518
566
|
var commentUnreactCommand = defineCommand({
|
|
519
|
-
meta: {
|
|
567
|
+
meta: {
|
|
568
|
+
name: "unreact",
|
|
569
|
+
description: "Remove your reaction from a comment.",
|
|
570
|
+
examples: [
|
|
571
|
+
"curviate comment unreact 7290000000000000000 COMMENT_ID insightful"
|
|
572
|
+
]
|
|
573
|
+
},
|
|
520
574
|
args: {
|
|
521
575
|
...WRITE_SINGLE_FLAGS,
|
|
522
576
|
postId: { type: "positional", description: "Post id the comment belongs to." },
|