@letterstory/cli 0.177.116 → 0.177.117
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 +2 -1
- package/lib/cli.mjs +5 -3
- package/lib/commands/outbound.mjs +16 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -903,6 +903,7 @@ letterstory mail postal-address "123 Main St, Portland, OR 97201" # CAN-SPAM f
|
|
|
903
903
|
# Sequences (approving or enrolling SENDS)
|
|
904
904
|
letterstory sequences list | get <id> | create | update <id> | pause <id> | resume <id>
|
|
905
905
|
letterstory sequences enroll <id> --list <list-id> # or --email a@x.com ...
|
|
906
|
+
letterstory sequences stop <id> --list <list-id> # or <enrollment-id>... or --all
|
|
906
907
|
letterstory sequences review list | approve <item-id> | skip <item-id> | edit <item-id> --subject "…"
|
|
907
908
|
letterstory sequences links create --days 2 # no-login phone review link, shown once
|
|
908
909
|
letterstory sequences update <id> --test-mode # internal accounts only: walks as live, sends nothing
|
|
@@ -915,7 +916,7 @@ letterstory prospects lists | ls --list <list-id> | get <id> | import --csv-file
|
|
|
915
916
|
letterstory prospects source --description "heads of growth at seed-stage fintech" --list-name "Fintech"
|
|
916
917
|
letterstory prospects openers <list-id> --new-group "Fintech openers" # print an opening line per row
|
|
917
918
|
letterstory prospects columns add "Cake image" | columns delete <column-id> --yes
|
|
918
|
-
letterstory prospects delete <prospect-id>... --yes
|
|
919
|
+
letterstory prospects delete <prospect-id>... --yes # or --list <list-id> for the whole list; active enrollments stop
|
|
919
920
|
```
|
|
920
921
|
|
|
921
922
|
Connecting a bring-your-own Gmail mailbox needs a browser (Google consent), so it is done in the
|
package/lib/cli.mjs
CHANGED
|
@@ -91,7 +91,7 @@ import {
|
|
|
91
91
|
import { fetchParkedSections, withoutParked } from "./parked.mjs";
|
|
92
92
|
|
|
93
93
|
// Matches cli/package.json; publish-cli.yml rewrites both to the published version.
|
|
94
|
-
export const VERSION = "0.177.
|
|
94
|
+
export const VERSION = "0.177.117";
|
|
95
95
|
|
|
96
96
|
/** The exit code for a gate refusal (CARD_REQUIRED, PAYMENT_FAILED, OUT_OF_TOKENS): 1 is a plain error. */
|
|
97
97
|
export const EXIT_PAYMENT_REQUIRED = 3;
|
|
@@ -1773,7 +1773,8 @@ Sequences (multi-step cold email sent from your mailers; approving or enrolling
|
|
|
1773
1773
|
--enroll-on-cake-list: only for prospects in that list (none = any)
|
|
1774
1774
|
sequences pause|resume <sequence-id> Stop / restart sending
|
|
1775
1775
|
sequences enroll <sequence-id> (--list <list-id> | --email <addr>... | --recipients '<json>'|--recipients-file <path>)
|
|
1776
|
-
sequences stop <sequence-id> <enrollment-id>
|
|
1776
|
+
sequences stop <sequence-id> (<enrollment-id>... | --list <list-id> | --all)
|
|
1777
|
+
Stop recipients: these, a list's, or everyone
|
|
1777
1778
|
sequences review list Emails waiting for a decision
|
|
1778
1779
|
sequences review edit <item-id> [--subject <s>] [--body <text>|--file <path>]
|
|
1779
1780
|
[--personalize <line> [--personalize-mode replace|insert]] Mark the edit a personalization (proposed to the opener library)
|
|
@@ -1814,7 +1815,8 @@ Prospects (who you write to):
|
|
|
1814
1815
|
Funding + competitors for un-enriched rows
|
|
1815
1816
|
prospects openers <list-id> [--group <ledes-group-id>|--new-group <name>]
|
|
1816
1817
|
Print an opening line for every row without one (background)
|
|
1817
|
-
prospects delete <prospect-id>... --
|
|
1818
|
+
prospects delete (<prospect-id>... | --list <list-id> [--status <s>] [--q <text>]) --yes
|
|
1819
|
+
Permanently delete prospects (a whole list in one go); their active enrollments stop
|
|
1818
1820
|
prospects columns add <label> Add a custom column (key returned)
|
|
1819
1821
|
prospects columns delete <column-id> --yes
|
|
1820
1822
|
prospects update <prospect-id> [--status new|contacted|replied|unsubscribed|archived] [--name <n>]
|
|
@@ -216,9 +216,13 @@ export const ARGS = {
|
|
|
216
216
|
recipients: { value: readRecipients },
|
|
217
217
|
list_id: "list",
|
|
218
218
|
},
|
|
219
|
+
// `stop <sequence-id> <enrollment-id>...` | `--list <list-id>` | `--all`.
|
|
219
220
|
stop_sequence_enrollment: {
|
|
220
221
|
sequence_id: { positional: 0, label: "sequence-id", required: true },
|
|
221
|
-
enrollment_id: {
|
|
222
|
+
enrollment_id: { value: (_flags, positionals) => (positionals.length === 2 ? positionals[1] : undefined) },
|
|
223
|
+
enrollment_ids: { value: (_flags, positionals) => (positionals.length > 2 ? positionals.slice(1) : undefined) },
|
|
224
|
+
list_id: "list",
|
|
225
|
+
all: { flag: "all", type: "bool" },
|
|
222
226
|
},
|
|
223
227
|
list_review_items: {
|
|
224
228
|
dispatch_id: "dispatch",
|
|
@@ -317,14 +321,22 @@ export const ARGS = {
|
|
|
317
321
|
status: { flag: "status", enum: PROSPECT_STATUSES },
|
|
318
322
|
q: "q",
|
|
319
323
|
},
|
|
324
|
+
// `delete <prospect-id>...`, or a whole view: `--list <list-id>` / `--status` / `--q`.
|
|
320
325
|
delete_prospects: {
|
|
321
326
|
prospect_ids: {
|
|
322
327
|
value: (flags, positionals) => {
|
|
323
328
|
const ids = [...positionals, ...flagList(flags.id)];
|
|
324
|
-
if (
|
|
325
|
-
|
|
329
|
+
if (ids.length) return ids;
|
|
330
|
+
if (flags.list === undefined && flags.status === undefined && flags.q === undefined)
|
|
331
|
+
throw new CliError(
|
|
332
|
+
"Missing <prospect-id>... (or --list <list-id> / --status / --q for a whole view)"
|
|
333
|
+
);
|
|
334
|
+
return undefined;
|
|
326
335
|
},
|
|
327
336
|
},
|
|
337
|
+
list_id: "list",
|
|
338
|
+
status: { flag: "status", enum: PROSPECT_STATUSES },
|
|
339
|
+
q: "q",
|
|
328
340
|
},
|
|
329
341
|
create_prospect_column: {
|
|
330
342
|
label: { positional: 0, label: "label", required: true },
|
|
@@ -587,7 +599,7 @@ export async function cmdSequences(ctx) {
|
|
|
587
599
|
case "enroll":
|
|
588
600
|
return run(rest, "enroll_in_sequence", "Enrolled.");
|
|
589
601
|
case "stop":
|
|
590
|
-
return run(rest, "stop_sequence_enrollment", "
|
|
602
|
+
return run(rest, "stop_sequence_enrollment", "Stopped.");
|
|
591
603
|
case "review":
|
|
592
604
|
return sequencesReview({ ...rest, positionals: rest.positionals.slice(1) }, rest.positionals[0]);
|
|
593
605
|
case "links":
|