@sellable/install 0.1.299 → 0.1.301
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/bin/sellable-install.mjs
CHANGED
|
@@ -1059,7 +1059,10 @@ const REFILL_SENDS_ALLOWED_TOOLS = [
|
|
|
1059
1059
|
"mcp__sellable__list_workspaces",
|
|
1060
1060
|
"mcp__sellable__set_active_workspace",
|
|
1061
1061
|
"mcp__sellable__get_subskill_prompt",
|
|
1062
|
+
"mcp__sellable__get_subskill_asset",
|
|
1062
1063
|
"mcp__sellable__search_subskill_prompts",
|
|
1064
|
+
"mcp__sellable__get_scheduler_fill_capacity",
|
|
1065
|
+
"mcp__sellable__refresh_paid_inmail_credits",
|
|
1063
1066
|
"mcp__sellable__list_senders",
|
|
1064
1067
|
"mcp__sellable__get_sender_routing",
|
|
1065
1068
|
"mcp__sellable__get_campaign_waterfall",
|
|
@@ -2002,10 +2005,17 @@ Desktop, then start a new thread.
|
|
|
2002
2005
|
2. Resolve the target workspace id from the user request, automation config, or install-time workspace mapping. Pass \`workspaceId\` on every scheduled or \`--yolo\` refill tool call. Missing \`workspaceId\` in scheduled or \`--yolo\` mode is a blocker; return \`WORKSPACE_REQUIRED\` instead of running against shared config state. Do not solve automation workspace uncertainty by changing the shared active workspace.
|
|
2003
2006
|
3. Normalize invocation arguments with \`mcp__sellable__refill_sends({ yolo, executionMode, requireWorkspace, workspaceId, senders, senderIds, senderNames, targetDate, untilDate })\` when the host exposes typed MCP tools. Type shape: \`refill_sends({ yolo?: boolean, executionMode?: "manual" | "scheduled" | "yolo", requireWorkspace?: boolean, workspaceId?: string, senders?: string[], senderIds?: string[], senderNames?: string[], horizonSendDays?: number, untilDate?: "YYYY-MM-DD", targetDate?: "YYYY-MM-DD" })\`.
|
|
2004
2007
|
4. Clover scheduled automation example: \`mcp__sellable__refill_sends({ yolo:false, executionMode:"scheduled", requireWorkspace:true, workspaceId:"cmlq1v8ms0000jx04ang4hi7e" })\`, then \`mcp__sellable__get_refill_target_plan({ intent:"plain", approvalMode:"mark_ready", workspaceId:"cmlq1v8ms0000jx04ang4hi7e" })\`.
|
|
2005
|
-
5. Call \`mcp__sellable__get_refill_target_plan({ workspaceId, senders, senderIds, senderNames, targetDate, untilDate })\` before any mutation. Render \`target.eligibleSenderLedger\`, \`target.senderRefillPlans[]\`, and \`target.globalActionQueue\` as the structured packet. Preserve the labels \`Need to prepare\`, \`Goal\`, \`Already sent\`, \`Scheduled\`, \`Ready and waiting to be scheduled\`, and \`Still need\`. In \`--yolo\`, \`mcp__sellable__refill_sends\` maintains a run-local \`refreshedPaidInmailSenderIds\` set, refreshes stale/missing paid InMail facts for each selected paid-InMail sender at most once, reruns \`get_refill_target_plan\`, and returns \`autoPaidInmailRefresh\` plus the post-refresh \`targetPlan\` before choosing the next prep/approval/
|
|
2006
|
-
6. Load the canonical prompt via
|
|
2008
|
+
5. Call \`mcp__sellable__get_refill_target_plan({ workspaceId, senders, senderIds, senderNames, targetDate, untilDate })\` before any mutation. Render \`target.eligibleSenderLedger\`, \`target.senderRefillPlans[]\`, and \`target.globalActionQueue\` as the structured packet. Preserve the labels \`Need to prepare\`, \`Goal\`, \`Already sent\`, \`Scheduled\`, \`Ready and waiting to be scheduled\`, and \`Still need\`. In \`--yolo\`, \`mcp__sellable__refill_sends\` maintains a run-local \`refreshedPaidInmailSenderIds\` set, refreshes stale/missing paid InMail facts for each selected paid-InMail sender at most once, reruns \`get_refill_target_plan\`, and returns \`autoPaidInmailRefresh\` plus the post-refresh \`targetPlan\` before choosing the next prep/source-copy/bounded-approval/read-only wait action. Refill ladder: approve generated rows only through the explicit bounded approval gate, process existing same-campaign unenriched/unprepared rows before source work, then same-source copy, then provider-aligned source-more. New source/provider switches change reply-rate baseline and are manual alternates, not \`--yolo\` side effects. Do not present paid-credit refresh as the next operator action after \`refill_sends\` returns that post-refresh plan. For exact-date proof, \`mcp__sellable__get_scheduler_fill_capacity\` is read-only and tells how many cells the scheduler will try to place for a sender/action/date. If the returned target is already complete, stop with the no-op receipt. If ready rows cover the target but scheduled rows do not, keep the run open in the read-only scheduler wait/re-read loop until projected coverage fills, a concrete non-scheduler blocker appears, or Christian explicitly stops/statuses the run.
|
|
2009
|
+
6. Load the canonical prompt and deterministic flow asset via
|
|
2007
2010
|
\`mcp__sellable__get_subskill_prompt({ subskillName: "refill-sends" })\`,
|
|
2008
|
-
then load \`mcp__sellable__get_subskill_prompt({ subskillName: "refill-sends-workflow" })
|
|
2011
|
+
then load \`mcp__sellable__get_subskill_prompt({ subskillName: "refill-sends-workflow" })\`,
|
|
2012
|
+
then load \`mcp__sellable__get_subskill_asset({ subskillName: "refill-sends-workflow", assetPath: "core/flow.v1.json" })\`.
|
|
2013
|
+
Continue prompt and asset loads until \`hasMore:false\`; parse the flow JSON
|
|
2014
|
+
and verify \`workflow:"refill-sends-workflow"\` with a \`v1\` version.
|
|
2015
|
+
Freshness gate precedes scheduler wait: when stale or missing paid-credit
|
|
2016
|
+
facts are present, refresh exact selected sender facts once, rerun
|
|
2017
|
+
\`get_refill_target_plan\`, and only then enter \`wait_for_scheduler\` if
|
|
2018
|
+
freshness is clean.
|
|
2009
2019
|
7. Follow the canonical prompt exactly. Do not launch, start, archive, delete,
|
|
2010
2020
|
or write scheduler rows as part of refill sends.
|
|
2011
2021
|
|
package/package.json
CHANGED
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: refill-sends-evergreen
|
|
3
|
+
description: Plan evergreen waterfall send refill work through the Phase 85 dry-run workflow.
|
|
4
|
+
visibility: public
|
|
5
|
+
allowed-tools:
|
|
6
|
+
- mcp__sellable__refill_sends_evergreen
|
|
7
|
+
- mcp__sellable__get_evergreen_refill_plan
|
|
8
|
+
- mcp__sellable__get_subskill_prompt
|
|
9
|
+
- mcp__sellable__get_subskill_asset
|
|
10
|
+
- mcp__sellable__get_auth_status
|
|
11
|
+
- mcp__sellable__get_active_workspace
|
|
12
|
+
- mcp__sellable__list_workspaces
|
|
13
|
+
- mcp__sellable__get_workspace
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
# Refill Sends Evergreen
|
|
17
|
+
|
|
18
|
+
Use this public command wrapper for evergreen waterfall refill requests such as
|
|
19
|
+
"refill evergreen", "fill evergreen senders", "load evergreen lanes", or
|
|
20
|
+
"plan evergreen refill".
|
|
21
|
+
|
|
22
|
+
Host command names:
|
|
23
|
+
|
|
24
|
+
- Claude Code: `/sellable:refill-sends-evergreen`
|
|
25
|
+
- Codex: `$sellable:refill-sends-evergreen`
|
|
26
|
+
|
|
27
|
+
Phase 85 is read-only, dry-run, zero mutations. It plans the deterministic
|
|
28
|
+
waterfall-ladder refill packet and writes a local dry-run journal, but it does
|
|
29
|
+
not prepare messages, approve messages, start campaigns, schedule sends, send
|
|
30
|
+
messages, refresh paid InMail credit facts, create campaigns, or change source
|
|
31
|
+
configuration. Execution ships in the follow-up phase.
|
|
32
|
+
|
|
33
|
+
## Entry
|
|
34
|
+
|
|
35
|
+
Resolve the explicit `workspaceId` from the request, automation config, or
|
|
36
|
+
active workspace readback. Scheduled or autonomous usage must carry
|
|
37
|
+
`workspaceId` on every tool call. If the workspace is missing or ambiguous, stop
|
|
38
|
+
with `WORKSPACE_REQUIRED`; do not switch the shared active workspace.
|
|
39
|
+
|
|
40
|
+
Start with the command contract:
|
|
41
|
+
|
|
42
|
+
```text
|
|
43
|
+
refill_sends_evergreen({ workspaceId })
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
Then load the internal workflow prompt and flow asset:
|
|
47
|
+
|
|
48
|
+
```text
|
|
49
|
+
get_subskill_prompt({ subskillName: "refill-sends-evergreen-workflow" })
|
|
50
|
+
get_subskill_asset({ subskillName: "refill-sends-evergreen-workflow", assetPath: "core/flow.v1.json" })
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
Continue both loads until `hasMore:false`; parse the flow JSON and verify
|
|
54
|
+
`workflow:"refill-sends-evergreen-workflow"` with a `v1` version before the
|
|
55
|
+
planner call.
|
|
56
|
+
|
|
57
|
+
Call the dry-run planner with the explicit workspace id:
|
|
58
|
+
|
|
59
|
+
```text
|
|
60
|
+
get_evergreen_refill_plan({ workspaceId, senderIds?, runState?, journal?, journalNote? })
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
Use `senderIds` only when the user scoped the request to exact senders. Use
|
|
64
|
+
`runState` only for an explicit what-if dry run; otherwise let the MCP read
|
|
65
|
+
local lane memory hints. Leave `journal` enabled unless the user specifically
|
|
66
|
+
asked for no local journal.
|
|
67
|
+
|
|
68
|
+
## Report
|
|
69
|
+
|
|
70
|
+
Review the returned packet before giving a recommendation:
|
|
71
|
+
|
|
72
|
+
- `planRevision` starts with `pr1:`.
|
|
73
|
+
- `stateRevision` identifies the current readback.
|
|
74
|
+
- `packet` is the operator-facing facts receipt.
|
|
75
|
+
- `plans[]` contains per-sender lane decisions and itinerary details.
|
|
76
|
+
- `globalActionQueue[]` is a dry-run sequence only in Phase 85.
|
|
77
|
+
- `evergreen.enumeratedRungs` and each action's `evergreenRung` map to the
|
|
78
|
+
locked ladder from the workflow asset.
|
|
79
|
+
- `journalPath` points to the dry-run markdown journal written by the MCP.
|
|
80
|
+
- `sideEffects` must be all false.
|
|
81
|
+
|
|
82
|
+
Report campaign names and sender names first, ids second. Include the chosen
|
|
83
|
+
rung, the itinerary, the plan revision, the journal path, and any blockers or
|
|
84
|
+
warnings. Stop after the report; do not execute the action queue in Phase 85.
|
|
@@ -7,6 +7,7 @@ allowed-tools:
|
|
|
7
7
|
- mcp__sellable__get_refill_target_plan
|
|
8
8
|
- mcp__sellable__get_scheduler_fill_capacity
|
|
9
9
|
- mcp__sellable__refresh_paid_inmail_credits
|
|
10
|
+
- mcp__sellable__get_subskill_asset
|
|
10
11
|
- mcp__sellable__get_auth_status
|
|
11
12
|
- mcp__sellable__start_cli_login
|
|
12
13
|
- mcp__sellable__wait_for_cli_login
|
|
@@ -92,10 +93,16 @@ When the host can call typed MCP tools, start with:
|
|
|
92
93
|
refill_sends({ yolo?: boolean, executionMode?: "manual" | "scheduled" | "yolo", requireWorkspace?: boolean, workspaceId?: string, senders?: string[], senderIds?: string[], senderNames?: string[], horizonSendDays?: number, untilDate?: "YYYY-MM-DD", targetDate?: "YYYY-MM-DD" })
|
|
93
94
|
```
|
|
94
95
|
|
|
95
|
-
That command helper
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
96
|
+
That command helper normalizes arguments and returns the execution contract. In
|
|
97
|
+
non-yolo mode it does not mutate. In `--yolo`, it may execute exactly one safe
|
|
98
|
+
bounded primitive from the fresh `target.globalActionQueue[0]`, then reread and
|
|
99
|
+
return the new target plan; currently safe primitives are paid-credit refresh,
|
|
100
|
+
existing-row message preparation, same-source row copy, and read-only wait
|
|
101
|
+
rereads. It does not run unbounded approval, lower
|
|
102
|
+
paid-InMail thresholds, switch source families, create campaigns, launch, send,
|
|
103
|
+
or write scheduler rows. Continue with the workflow below for route selection,
|
|
104
|
+
state rereads, approval gating, source import, preparation, and bounded
|
|
105
|
+
approval.
|
|
99
106
|
|
|
100
107
|
## Workspace Contract
|
|
101
108
|
|
|
@@ -145,19 +152,23 @@ explicitly stops/statuses the run, or a concrete non-scheduler blocker appears.
|
|
|
145
152
|
Do not call the goal complete or blocked only because the current state is
|
|
146
153
|
`awaiting_scheduler_after_ready_buffer`; treat it as loaded, awaiting scheduler.
|
|
147
154
|
|
|
148
|
-
Load the internal workflow prompt
|
|
155
|
+
Load the internal workflow prompt and deterministic flow asset before taking
|
|
156
|
+
any operational step:
|
|
149
157
|
|
|
150
158
|
```text
|
|
151
159
|
get_subskill_prompt({ subskillName: "refill-sends-workflow" })
|
|
160
|
+
get_subskill_asset({ subskillName: "refill-sends-workflow", assetPath: "core/flow.v1.json" })
|
|
152
161
|
```
|
|
153
162
|
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
163
|
+
Continue both loads until `hasMore:false`; parse the flow JSON and verify
|
|
164
|
+
`workflow:"refill-sends-workflow"` with a `v1` version. Then follow that
|
|
165
|
+
workflow exactly. The default path is read-only research: compute the refill
|
|
166
|
+
target plan first, resolve the route, identify the sender-relevant campaign
|
|
167
|
+
that most recently had scheduler-owned sends, read refill state for that target,
|
|
168
|
+
report the next safe step using campaign names first, and stop before mutation
|
|
169
|
+
unless the user has explicitly approved the exact workspace,
|
|
170
|
+
campaign/table/source ids, caps/dates, approval mode, expected side effects,
|
|
171
|
+
and stop/rollback condition.
|
|
161
172
|
|
|
162
173
|
Immediately after loading the internal workflow, call
|
|
163
174
|
`get_refill_target_plan`. The target plan is the canonical first fact receipt:
|
|
@@ -199,16 +210,38 @@ Structured planner packet:
|
|
|
199
210
|
- `manualAlternates` are not yolo actions. Threshold lowering and campaign
|
|
200
211
|
creation are manual continuations only.
|
|
201
212
|
|
|
213
|
+
Refill action ladder: approve generated rows only when an explicit bounded
|
|
214
|
+
approval gate exists, process all existing same-campaign unenriched/unprepared
|
|
215
|
+
rows in bounded batches before any source work, then copy bounded net-new rows
|
|
216
|
+
from the selected source (`selectedLeadListId`, provider, and source
|
|
217
|
+
fingerprint preserved), then use provider-aligned source-more. A new source or
|
|
218
|
+
provider switch changes the reply-rate baseline and is a manual alternate, not a
|
|
219
|
+
`--yolo` side effect.
|
|
220
|
+
|
|
202
221
|
Run-local paid-credit guard: in `--yolo`, the `refill_sends` MCP command
|
|
203
222
|
automatically maintains a `refreshedPaidInmailSenderIds` set for the current
|
|
204
223
|
command call. If its first target plan has stale/missing paid-InMail credit
|
|
205
224
|
facts, it refreshes each selected sender at most once, reruns
|
|
206
225
|
`get_refill_target_plan`, and returns the post-refresh `targetPlan` before
|
|
207
|
-
choosing the next prep/approval/
|
|
226
|
+
choosing the next prep/source-copy/bounded-approval/read-only wait action. If fresh facts are still below
|
|
208
227
|
threshold, below-threshold paid-InMail facts fall back to an existing connection
|
|
209
228
|
lane, the same Sales Nav cascade campaign's connection branch, or a manual
|
|
210
229
|
continuation.
|
|
211
230
|
|
|
231
|
+
Freshness gate precedes scheduler wait: if any selected
|
|
232
|
+
`target.senderRefillPlans[].paidInmail.status` is `missing_credit_facts` or
|
|
233
|
+
`stale_credit_facts`, or the target plan contains a
|
|
234
|
+
`refresh_paid_inmail_credits` candidate, do not enter `wait_for_scheduler` even
|
|
235
|
+
when `remainingReadyOrProjectedGap:0`. Refresh the exact selected sender credit
|
|
236
|
+
facts once, rerun `get_refill_target_plan`, and only then decide whether
|
|
237
|
+
scheduler wait is the next safe action. If facts remain missing/stale after the
|
|
238
|
+
single refresh attempt, stop with a paid-InMail freshness blocker instead of
|
|
239
|
+
waiting on scheduler pickup.
|
|
240
|
+
The standalone MCP refresh surface is the scoped route
|
|
241
|
+
`/api/v3/mcp/senders/:senderId/refresh-inmail-credits` with explicit
|
|
242
|
+
`workspaceId`; do not use active-workspace mutation as the automation control
|
|
243
|
+
path.
|
|
244
|
+
|
|
212
245
|
Compact refill lessons: sender-level target plan is final truth; trust
|
|
213
246
|
`schedulerGate.sendable` and scheduler gate blockers, not raw
|
|
214
247
|
`unipileAccountStatus` labels alone; use compact prep status checks for
|
|
@@ -225,8 +258,9 @@ will try to place and does not import, approve, schedule, refresh credits, or
|
|
|
225
258
|
mutate.
|
|
226
259
|
If the target plan is complete by projected coverage, report that the selected
|
|
227
260
|
target is already filled and no-op without asking for approval. If the ready
|
|
228
|
-
buffer covers the projected gap
|
|
229
|
-
|
|
261
|
+
buffer covers the projected gap, paid InMail credit facts are fresh for every
|
|
262
|
+
selected paid-InMail lane, but scheduled coverage is still short, keep the run
|
|
263
|
+
open in a persistent read-only scheduler wait loop. Poll
|
|
230
264
|
`get_refill_target_plan` every 60-120 seconds, or on the host's next continuation
|
|
231
265
|
interval, until projected coverage fills the target, a concrete non-scheduler
|
|
232
266
|
blocker appears, or Christian explicitly asks to stop or only receive a status
|
|
@@ -293,7 +327,7 @@ they change `stateRevision`, not `targetShapeRevision`, and do not require a
|
|
|
293
327
|
second approval.
|
|
294
328
|
|
|
295
329
|
In `--yolo`, continue as far as the rendered packet safely allows. After each
|
|
296
|
-
apply/prep/
|
|
330
|
+
apply/prep/source-copy/bounded-approval/read-only wait result, reread state, settle processing when needed, and move to
|
|
297
331
|
the next selected sender or start-eligible same-packet campaign instead of
|
|
298
332
|
stopping after the first partial result. If no in-packet safe action remains,
|
|
299
333
|
return concrete continuation options with campaign names, exact ids, which option
|
|
@@ -307,7 +341,7 @@ selected sender: selected send days, gross capacity, actual sent cells, future
|
|
|
307
341
|
scheduler-owned scheduled cells with non-null `scheduledFor`, projected count,
|
|
308
342
|
ready-to-schedule buffer, remaining projected gap, paid-InMail feasibility,
|
|
309
343
|
`targetShapeRevision`, `stateRevision`, and the next MCP primitive that can
|
|
310
|
-
reduce the gap. After every apply/prep/
|
|
344
|
+
reduce the gap. After every apply/prep/source-copy/bounded-approval/read-only wait result, wait for processing, reread
|
|
311
345
|
the target plan/refill state, recompute the ledger, then keep applying safe
|
|
312
346
|
bounded actions until projected coverage fills the target window or a concrete
|
|
313
347
|
non-scheduler blocker is proven.
|