@sellable/mcp 0.1.628-phase111.20260720204709 → 0.1.629

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.
@@ -747,6 +747,7 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
747
747
  selectedTarget?: undefined;
748
748
  completedTarget?: undefined;
749
749
  exactRunResult?: undefined;
750
+ note?: undefined;
750
751
  };
751
752
  continuation: {
752
753
  required: boolean;
@@ -858,6 +859,7 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
858
859
  workspaceTargetPlan?: undefined;
859
860
  completedTarget?: undefined;
860
861
  exactRunResult?: undefined;
862
+ note?: undefined;
861
863
  };
862
864
  continuation: {
863
865
  required: boolean;
@@ -1057,13 +1059,7 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1057
1059
  coordinator: {
1058
1060
  scope: string;
1059
1061
  status: string;
1060
- completedTarget: {
1061
- campaignId: string;
1062
- tableId: string;
1063
- senderIds: string[];
1064
- actionTypes: string[];
1065
- actionKey: string | null;
1066
- } | null;
1062
+ completedTarget: WorkspaceExactTarget | null;
1067
1063
  workspaceTargetPlan: unknown;
1068
1064
  exactRunResult: {
1069
1065
  runSnapshot: unknown;
@@ -1083,6 +1079,7 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1083
1079
  conflicts?: undefined;
1084
1080
  };
1085
1081
  selectedTarget?: undefined;
1082
+ note?: undefined;
1086
1083
  };
1087
1084
  continuation: {
1088
1085
  required: boolean;
@@ -1202,13 +1199,7 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1202
1199
  coordinator: {
1203
1200
  scope: string;
1204
1201
  status: string;
1205
- completedTarget: {
1206
- campaignId: string;
1207
- tableId: string;
1208
- senderIds: string[];
1209
- actionTypes: string[];
1210
- actionKey: string | null;
1211
- } | null;
1202
+ completedTarget: WorkspaceExactTarget | null;
1212
1203
  selectedTarget: WorkspaceExactTarget | null;
1213
1204
  exactRunResult: {
1214
1205
  runSnapshot: unknown;
@@ -1228,6 +1219,7 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1228
1219
  conflicts?: undefined;
1229
1220
  };
1230
1221
  workspaceTargetPlan?: undefined;
1222
+ note?: undefined;
1231
1223
  };
1232
1224
  continuation: {
1233
1225
  required: boolean;
@@ -1324,6 +1316,147 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1324
1316
  workspaceId: string | null;
1325
1317
  workspaceResolution: string;
1326
1318
  intent: RefillSendsIntent;
1319
+ } | {
1320
+ targetPlan: unknown;
1321
+ exactTargetPlan: unknown;
1322
+ orchestration: {
1323
+ mode: string;
1324
+ scope: string;
1325
+ checkpointedFields: string[];
1326
+ transportBudgetMs: number;
1327
+ };
1328
+ coordinator: {
1329
+ scope: string;
1330
+ status: string;
1331
+ completedTarget: WorkspaceExactTarget | null;
1332
+ selectedTarget: WorkspaceExactTarget;
1333
+ workspaceTargetPlan: unknown;
1334
+ exactRunResult: {
1335
+ runSnapshot: unknown;
1336
+ readOnly: boolean;
1337
+ forbiddenActions: string[];
1338
+ boundedAuthority: string;
1339
+ status: "terminal";
1340
+ doneReason: string;
1341
+ report: Record<string, unknown>;
1342
+ runId: string;
1343
+ guidance?: string;
1344
+ journalPath?: string | null;
1345
+ targetConfig?: RefillTargetConfigV1;
1346
+ runHandle?: RefillRunHandleV1;
1347
+ refillReporting?: Record<string, unknown>;
1348
+ blocker?: undefined;
1349
+ conflicts?: undefined;
1350
+ };
1351
+ note: string;
1352
+ };
1353
+ continuation: {
1354
+ required: boolean;
1355
+ userActionRequired: boolean;
1356
+ kind?: undefined;
1357
+ owner?: undefined;
1358
+ tool?: undefined;
1359
+ arguments?: undefined;
1360
+ stopCondition?: undefined;
1361
+ };
1362
+ runSnapshot: unknown;
1363
+ readOnly: boolean;
1364
+ forbiddenActions: string[];
1365
+ boundedAuthority: string;
1366
+ status: "terminal";
1367
+ doneReason: string;
1368
+ report: Record<string, unknown>;
1369
+ runId: string;
1370
+ guidance?: string;
1371
+ journalPath?: string | null;
1372
+ targetConfig: RefillTargetConfigV1 | null;
1373
+ runHandle: RefillRunHandleV1 | null;
1374
+ refillReporting?: Record<string, unknown>;
1375
+ blocker?: undefined;
1376
+ conflicts?: undefined;
1377
+ targetDate: string | null;
1378
+ untilDate: string | null;
1379
+ horizonSendDays: number | null;
1380
+ fillWindow: {
1381
+ mode: string;
1382
+ targetDate: string;
1383
+ description: string;
1384
+ untilDate?: undefined;
1385
+ horizonSendDays?: undefined;
1386
+ horizonHours?: undefined;
1387
+ } | {
1388
+ mode: string;
1389
+ untilDate: string;
1390
+ description: string;
1391
+ targetDate?: undefined;
1392
+ horizonSendDays?: undefined;
1393
+ horizonHours?: undefined;
1394
+ } | {
1395
+ mode: string;
1396
+ horizonSendDays: number | null;
1397
+ horizonHours: number | null;
1398
+ description: string;
1399
+ targetDate?: undefined;
1400
+ untilDate?: undefined;
1401
+ };
1402
+ approvalMode: RefillSendsApprovalMode;
1403
+ campaignId: string | null;
1404
+ tableId: string | null;
1405
+ reportingContext: RefillReportingContextV2 | null;
1406
+ messageTemplateRevision: MessageTemplateRevisionV1 | null;
1407
+ senderScope: string;
1408
+ senderSelectors: {
1409
+ senders: string[];
1410
+ senderIds: string[];
1411
+ senderNames: string[];
1412
+ };
1413
+ firstOperationalSteps: string[];
1414
+ approvalContract: string;
1415
+ hostExamples: {
1416
+ claude: string[];
1417
+ codex: string[];
1418
+ mcpTool: {
1419
+ name: string;
1420
+ arguments: {
1421
+ workspaceCoordinator?: boolean | undefined;
1422
+ messageTemplateRevision?: MessageTemplateRevisionV1 | undefined;
1423
+ reportingContext?: RefillReportingContextV2 | undefined;
1424
+ targetConfig?: RefillTargetConfigV1 | undefined;
1425
+ runHandle?: RefillRunHandleV1 | undefined;
1426
+ fence?: number | undefined;
1427
+ runId?: string | undefined;
1428
+ expectedActionKey?: string | undefined;
1429
+ expectedTargetShapeRevision?: string | undefined;
1430
+ targetDate: string | null;
1431
+ untilDate: string | null;
1432
+ horizonSendDays: number | null;
1433
+ campaignId: string | undefined;
1434
+ tableId: string | undefined;
1435
+ intent: RefillSendsIntent;
1436
+ approvalMode: RefillSendsApprovalMode;
1437
+ workspaceId: string | null;
1438
+ actionTypes?: ("send_invite" | "send_inmail_closed")[] | undefined;
1439
+ yolo: boolean;
1440
+ senders: string[];
1441
+ senderIds: string[];
1442
+ senderNames: string[];
1443
+ };
1444
+ };
1445
+ };
1446
+ actionTypes?: ("send_invite" | "send_inmail_closed")[] | undefined;
1447
+ command: string;
1448
+ tool: string;
1449
+ promptName: string;
1450
+ workflowPromptName: string;
1451
+ workflowAsset: {
1452
+ subskillName: string;
1453
+ assetPath: string;
1454
+ };
1455
+ yolo: boolean;
1456
+ executionMode: RefillSendsExecutionMode;
1457
+ workspaceId: string | null;
1458
+ workspaceResolution: string;
1459
+ intent: RefillSendsIntent;
1327
1460
  } | {
1328
1461
  status: "in_progress";
1329
1462
  targetPlan: unknown;
@@ -1337,13 +1470,7 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1337
1470
  coordinator: {
1338
1471
  scope: string;
1339
1472
  status: string;
1340
- completedTarget: {
1341
- campaignId: string;
1342
- tableId: string;
1343
- senderIds: string[];
1344
- actionTypes: string[];
1345
- actionKey: string | null;
1346
- } | null;
1473
+ completedTarget: WorkspaceExactTarget | null;
1347
1474
  selectedTarget: WorkspaceExactTarget;
1348
1475
  exactRunResult: {
1349
1476
  runSnapshot: unknown;
@@ -1363,6 +1490,7 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1363
1490
  conflicts?: undefined;
1364
1491
  };
1365
1492
  workspaceTargetPlan?: undefined;
1493
+ note?: undefined;
1366
1494
  };
1367
1495
  continuation: {
1368
1496
  required: boolean;
@@ -1516,15 +1644,10 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1516
1644
  exactTargetPlan?: unknown;
1517
1645
  scope: string;
1518
1646
  status: string | undefined;
1519
- selectedTarget: {
1520
- campaignId: string;
1521
- tableId: string;
1522
- senderIds: string[];
1523
- actionTypes: string[];
1524
- actionKey: string | null;
1525
- } | null;
1647
+ selectedTarget: WorkspaceExactTarget | null;
1526
1648
  completedTarget?: undefined;
1527
1649
  exactRunResult?: undefined;
1650
+ note?: undefined;
1528
1651
  } | undefined;
1529
1652
  orchestration: {
1530
1653
  checkpointedFields: string[];
@@ -1669,15 +1792,10 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1669
1792
  exactTargetPlan?: unknown;
1670
1793
  scope: string;
1671
1794
  status: string | undefined;
1672
- selectedTarget: {
1673
- campaignId: string;
1674
- tableId: string;
1675
- senderIds: string[];
1676
- actionTypes: string[];
1677
- actionKey: string | null;
1678
- } | null;
1795
+ selectedTarget: WorkspaceExactTarget | null;
1679
1796
  completedTarget?: undefined;
1680
1797
  exactRunResult?: undefined;
1798
+ note?: undefined;
1681
1799
  } | undefined;
1682
1800
  orchestration: {
1683
1801
  checkpointedFields: string[];
@@ -1826,15 +1944,10 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1826
1944
  exactTargetPlan?: unknown;
1827
1945
  scope: string;
1828
1946
  status: string | undefined;
1829
- selectedTarget: {
1830
- campaignId: string;
1831
- tableId: string;
1832
- senderIds: string[];
1833
- actionTypes: string[];
1834
- actionKey: string | null;
1835
- } | null;
1947
+ selectedTarget: WorkspaceExactTarget | null;
1836
1948
  completedTarget?: undefined;
1837
1949
  exactRunResult?: undefined;
1950
+ note?: undefined;
1838
1951
  } | undefined;
1839
1952
  orchestration: {
1840
1953
  checkpointedFields: string[];
@@ -1983,15 +2096,10 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
1983
2096
  exactTargetPlan?: unknown;
1984
2097
  scope: string;
1985
2098
  status: string | undefined;
1986
- selectedTarget: {
1987
- campaignId: string;
1988
- tableId: string;
1989
- senderIds: string[];
1990
- actionTypes: string[];
1991
- actionKey: string | null;
1992
- } | null;
2099
+ selectedTarget: WorkspaceExactTarget | null;
1993
2100
  completedTarget?: undefined;
1994
2101
  exactRunResult?: undefined;
2102
+ note?: undefined;
1995
2103
  } | undefined;
1996
2104
  orchestration: {
1997
2105
  checkpointedFields: string[];
@@ -2138,15 +2246,10 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
2138
2246
  exactTargetPlan?: unknown;
2139
2247
  scope: string;
2140
2248
  status: string | undefined;
2141
- selectedTarget: {
2142
- campaignId: string;
2143
- tableId: string;
2144
- senderIds: string[];
2145
- actionTypes: string[];
2146
- actionKey: string | null;
2147
- } | null;
2249
+ selectedTarget: WorkspaceExactTarget | null;
2148
2250
  completedTarget?: undefined;
2149
2251
  exactRunResult?: undefined;
2252
+ note?: undefined;
2150
2253
  } | undefined;
2151
2254
  orchestration: {
2152
2255
  checkpointedFields: string[];
@@ -2296,15 +2399,10 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
2296
2399
  exactTargetPlan?: unknown;
2297
2400
  scope: string;
2298
2401
  status: string | undefined;
2299
- selectedTarget: {
2300
- campaignId: string;
2301
- tableId: string;
2302
- senderIds: string[];
2303
- actionTypes: string[];
2304
- actionKey: string | null;
2305
- } | null;
2402
+ selectedTarget: WorkspaceExactTarget | null;
2306
2403
  completedTarget?: undefined;
2307
2404
  exactRunResult?: undefined;
2405
+ note?: undefined;
2308
2406
  } | undefined;
2309
2407
  orchestration: {
2310
2408
  checkpointedFields: string[];
@@ -2456,15 +2554,10 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
2456
2554
  exactTargetPlan?: unknown;
2457
2555
  scope: string;
2458
2556
  status: string | undefined;
2459
- selectedTarget: {
2460
- campaignId: string;
2461
- tableId: string;
2462
- senderIds: string[];
2463
- actionTypes: string[];
2464
- actionKey: string | null;
2465
- } | null;
2557
+ selectedTarget: WorkspaceExactTarget | null;
2466
2558
  completedTarget?: undefined;
2467
2559
  exactRunResult?: undefined;
2560
+ note?: undefined;
2468
2561
  } | undefined;
2469
2562
  orchestration: {
2470
2563
  checkpointedFields: string[];
@@ -121,7 +121,7 @@ function normalizeRefillSendsInput(input) {
121
121
  export const refillSendsToolDefinitions = [
122
122
  {
123
123
  name: "refill_sends",
124
- description: "Typed command entrypoint for Sellable refill sends. Workspace-wide --yolo reads globalActionQueue[0], preflights its exact campaign/table/sender/lane targetConfig, and executes one fenced checkpointed run slice before rereading workspace scope for the next exact target. An active_exact_run continuation carries targetConfig plus exact runId/fence; a next_exact_target continuation carries the next preflighted targetConfig and opens a new fence. The packaged workflow must immediately invoke the returned continuation arguments until workspace projected coverage fills or a concrete blocker appears, without asking the user to continue. Every primitive records actionKey/requestId/effectId before mutation and rereads the fresh target plan afterward. It may refresh stale paid InMail facts once, prepare/approve bounded existing rows, reuse/import receipt-proven same-source rows, add more leads to an existing campaign from its SAME provider source once that campaign's eligible/prepared rows are receipt-proven exhausted (cold-outbound campaigns may source Sales Nav or Prospeo), start a route-resolver start-eligible PAUSED campaign-backed sequence campaign selected by the packet when starting is needed to fill the send window, run a request-scoped product scheduler sweep, and wait/reread. Each source add and campaign start is one bounded primitive, then a full replan. It never sends directly, lowers paid InMail thresholds/floors, creates NEW campaigns, archives/deletes, or switches an existing campaign's source family (same provider source only). Unselected PAUSED campaigns that are not start-eligible remain paused. Scheduler placement stays product-native; the command never raw-writes scheduler fields.",
124
+ description: "Typed command entrypoint for Sellable refill sends. Workspace-wide --yolo reads globalActionQueue[0], preflights its exact campaign/table/sender/lane targetConfig, and executes one fenced checkpointed run slice before rereading workspace scope for the next exact target. An active_exact_run continuation carries targetConfig plus exact runId/fence; a next_exact_target continuation carries the next preflighted targetConfig and opens a new fence. When an exact run terminalizes as loaded_awaiting_scheduler and the fresh workspace queue reselects the same campaign/table/sender/lane, the coordinator returns that scheduler-owned workspace terminal instead of opening another identical fence. The packaged workflow must immediately invoke the returned continuation arguments until workspace projected coverage fills, the same-target scheduler terminal is returned, or a concrete blocker appears, without asking the user to continue. Every primitive records actionKey/requestId/effectId before mutation and rereads the fresh target plan afterward. It may refresh stale paid InMail facts once, prepare/approve bounded existing rows, reuse/import receipt-proven same-source rows, add more leads to an existing campaign from its SAME provider source once that campaign's eligible/prepared rows are receipt-proven exhausted (cold-outbound campaigns may source Sales Nav or Prospeo), start a route-resolver start-eligible PAUSED campaign-backed sequence campaign selected by the packet when starting is needed to fill the send window, run a request-scoped product scheduler sweep, and wait/reread. Each source add and campaign start is one bounded primitive, then a full replan. It never sends directly, lowers paid InMail thresholds/floors, creates NEW campaigns, archives/deletes, or switches an existing campaign's source family (same provider source only). Unselected PAUSED campaigns that are not start-eligible remain paused. Scheduler placement stays product-native; the command never raw-writes scheduler fields.",
125
125
  inputSchema: {
126
126
  type: "object",
127
127
  properties: {
@@ -328,7 +328,7 @@ function buildRefillSendsCommand(input) {
328
328
  : `, horizonSendDays: ${horizonSendDays}`}, approvalMode: "${approvalMode}" }) before any import, prep, approval, start, or schedule-affecting action.`,
329
329
  "Render target.eligibleSenderLedger and target.senderRefillPlans before mutation. Preserve the coverage labels Need to prepare, Goal, Already sent, Scheduled, Ready and waiting to be scheduled, Still need to schedule, and Still need to prepare. Never render an unlabeled Still need value.",
330
330
  "Use target.globalActionQueue as the only cross-sender yolo queue: execute only target.globalActionQueue[0], rerun get_refill_target_plan, and continue inside the same --yolo invocation until scheduler-projected coverage fills or a concrete blocker appears.",
331
- "The public --yolo command is transport-bounded. If refill_sends returns status:in_progress, immediately invoke its exact continuation.arguments. kind:active_exact_run preserves targetConfig plus runId/fence for the active fence; kind:next_exact_target preserves the workspace envelope plus the next preflighted targetConfig and intentionally has no prior runId/fence. Continue automatically inside this one user command; never ask the user to type continue and never start a second run while a fence is active.",
331
+ "The public --yolo command is transport-bounded. If refill_sends returns status:in_progress, immediately invoke its exact continuation.arguments. kind:active_exact_run preserves targetConfig plus runId/fence for the active fence; kind:next_exact_target preserves the workspace envelope plus the next preflighted targetConfig and intentionally has no prior runId/fence. A terminal loaded_awaiting_scheduler result with coordinator.status loaded_awaiting_scheduler is the bounded same-target scheduler backoff receipt and has no continuation. Continue automatically inside this one user command; never ask the user to type continue and never start a second run while a fence is active.",
332
332
  "When expectedTargetShapeRevision or expectedActionKey is supplied from an already rendered packet, compare both against the first fresh target plan before paid-credit refresh or any primitive. Return approval_scope_changed with the fresh packet on mismatch.",
333
333
  "Read target.senderRefillPlans[].refillReceipt as the public ladder receipt: it carries the selected campaign/sender/lane summary, skippedRungs, existingRowFrontier, and any absolute wait.deadlineAt. Do not choose source/copy/fallback work until that receipt proves the earlier ready/prep/approval rungs are exhausted.",
334
334
  "If get_refill_target_plan returns status complete, report eligible sender ledger, target.senderRefillPlans, gross target, selected days, sent count, scheduled count, projected count, campaign ids, targetShapeRevision, and no-op proof without asking for approval.",
@@ -481,6 +481,16 @@ function exactCampaignProjectionMatches(plan, campaignId, tableId) {
481
481
  stringValue(campaigns[0]?.campaignId) === campaignId &&
482
482
  stringValue(campaigns[0]?.tableId) === tableId);
483
483
  }
484
+ function sameWorkspaceExactTarget(left, right) {
485
+ if (!left)
486
+ return false;
487
+ const sameStringSet = (a, b) => JSON.stringify([...new Set(a)].sort()) ===
488
+ JSON.stringify([...new Set(b)].sort());
489
+ return (left.campaignId === right.campaignId &&
490
+ left.tableId === right.tableId &&
491
+ sameStringSet(left.senderIds, right.senderIds) &&
492
+ sameStringSet(left.actionTypes, right.actionTypes));
493
+ }
484
494
  function workspaceCoordinatorInput(input) {
485
495
  const coordinatorInput = { ...input };
486
496
  delete coordinatorInput.campaignId;
@@ -1539,7 +1549,7 @@ export async function executeRefillSendsCommand(input = {}) {
1539
1549
  campaignId: exactTargetConfig.campaignId,
1540
1550
  tableId: exactTargetConfig.tableId,
1541
1551
  senderIds: exactTargetConfig.senderScope.senderIds,
1542
- actionTypes: exactTargetConfig.actionScope,
1552
+ actionTypes: exactTargetConfig.actionScope.filter((actionType) => REFILL_SEND_ACTION_TYPE_SET.has(actionType)),
1543
1553
  actionKey: exactTargetConfig.approvalInputs.expectedActionKey,
1544
1554
  }
1545
1555
  : null;
@@ -1616,6 +1626,41 @@ export async function executeRefillSendsCommand(input = {}) {
1616
1626
  },
1617
1627
  };
1618
1628
  }
1629
+ if (result.doneReason === "loaded_awaiting_scheduler" &&
1630
+ sameWorkspaceExactTarget(selectedCoordinatorTarget, nextSelection.selectedTarget)) {
1631
+ return {
1632
+ ...command,
1633
+ ...result,
1634
+ targetPlan: nextSelection.workspacePlan,
1635
+ exactTargetPlan: nextSelection.exactTargetPlan,
1636
+ orchestration: {
1637
+ mode: "fenced_bounded_yolo",
1638
+ scope: "workspace_exact_target_coordinator",
1639
+ checkpointedFields: [
1640
+ "runId",
1641
+ "fence",
1642
+ "runState",
1643
+ "actionKey",
1644
+ "requestId",
1645
+ "effectId",
1646
+ ],
1647
+ transportBudgetMs: 40_000,
1648
+ },
1649
+ coordinator: {
1650
+ scope: "workspace",
1651
+ status: "loaded_awaiting_scheduler",
1652
+ completedTarget: selectedCoordinatorTarget,
1653
+ selectedTarget: nextSelection.selectedTarget,
1654
+ workspaceTargetPlan: nextSelection.workspacePlan,
1655
+ exactRunResult: result,
1656
+ note: "The exact target terminalized as loaded_awaiting_scheduler and the fresh workspace queue reselected the same campaign/table/sender/lane. Returning the scheduler-owned terminal receipt instead of opening another identical fence.",
1657
+ },
1658
+ continuation: {
1659
+ required: false,
1660
+ userActionRequired: false,
1661
+ },
1662
+ };
1663
+ }
1619
1664
  return {
1620
1665
  ...command,
1621
1666
  status: "in_progress",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sellable/mcp",
3
- "version": "0.1.628-phase111.20260720204709",
3
+ "version": "0.1.629",
4
4
  "type": "module",
5
5
  "description": "Sellable MCP server for Claude Code, Codex, and Hermes campaign workflows",
6
6
  "main": "dist/index.js",
@@ -105,8 +105,12 @@ its exact `continuation.arguments`. `kind:"active_exact_run"` carries the exact
105
105
  `targetConfig`, `runId`, and `fence`; `kind:"next_exact_target"` carries the
106
106
  unchanged workspace envelope and next preflighted `targetConfig` with no stale
107
107
  run fence. Do this automatically inside the same user command until terminal
108
- workspace projected coverage or a concrete blocker; do not ask the user to type
109
- `continue` and do not start a second run while a fence is active.
108
+ workspace projected coverage or a concrete blocker. If an exact run terminalizes
109
+ as `loaded_awaiting_scheduler` and the fresh workspace queue reselects the same
110
+ campaign/table/sender/lane, the coordinator returns that scheduler-owned
111
+ workspace terminal with no continuation instead of opening another identical
112
+ fence. Do not ask the user to type `continue` and do not start a second run while
113
+ a fence is active.
110
114
 
111
115
  `targetConfig` and the server-issued `runHandle` are separate values and must
112
116
  survive each continuation unchanged except for a server-issued takeover fence.
@@ -349,7 +353,8 @@ Structured planner packet:
349
353
  through exact `continuation.arguments`: resume active targets with their
350
354
  `targetConfig`/`runId`/`fence`, and start each next planner-preflighted target
351
355
  with its `targetConfig` and a new fence, until workspace projected coverage
352
- fills or a concrete blocker appears.
356
+ fills, the coordinator returns the same-target `loaded_awaiting_scheduler`
357
+ terminal, or a concrete blocker appears.
353
358
  - When that primitive is `run_scheduler_sweep`, show `workspaceWide:true` and
354
359
  its reason in the approval/yolo packet so the operator sees that the sweep
355
360
  may schedule other eligible workspace cells on the approved date.
@@ -99,8 +99,12 @@ When it returns `status:"in_progress"`, immediately invoke its exact
99
99
  the active `runId`/`fence`. `kind:"next_exact_target"` carries the unchanged
100
100
  workspace envelope plus the next preflighted `targetConfig` and intentionally
101
101
  has no prior run fence. Continue automatically inside the same user command
102
- until terminal workspace projected coverage or a concrete blocker. Never ask
103
- the user to type `continue` and never start a second run while a fence is active.
102
+ until terminal workspace projected coverage or a concrete blocker. If an exact
103
+ run terminalizes as `loaded_awaiting_scheduler` and the fresh workspace queue
104
+ reselects the same campaign/table/sender/lane, accept the coordinator's
105
+ scheduler-owned workspace terminal with no continuation instead of opening
106
+ another identical fence. Never ask the user to type `continue` and never start a
107
+ second run while a fence is active.
104
108
 
105
109
  Preserve exact `targetConfig` and server `runHandle` as separate authority on
106
110
  every continuation. The only revision authority is a complete literal
@@ -236,7 +240,8 @@ files or memory.
236
240
  through exact `continuation.arguments`: resume active targets with their
237
241
  `targetConfig`/`runId`/`fence`, and start each next planner-preflighted
238
242
  target with its `targetConfig` and a new fence, until workspace projected
239
- coverage fills or a concrete blocker appears.
243
+ coverage fills, the coordinator returns the same-target
244
+ `loaded_awaiting_scheduler` terminal, or a concrete blocker appears.
240
245
  - When that primitive is `run_scheduler_sweep`, show `workspaceWide:true`
241
246
  and its reason in the approval/yolo packet so the operator sees that the
242
247
  sweep may schedule other eligible workspace cells on the approved date.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": "v1.4",
3
3
  "workflow": "refill-sends-workflow",
4
- "principle": "Use the target planner and scheduler readback as canonical facts. In workspace-wide --yolo, select and preflight one exact globalActionQueue target before each fenced run. Automatically invoke returned continuation arguments: preserve targetConfig plus runId/fence for an active exact run, or open a new fence from the next preflighted targetConfig between exact targets. Continue until workspace projected coverage fills or a concrete blocker appears. Refresh stale paid-InMail credit facts before scheduler-wait decisions; do not change scheduler allocation logic.",
4
+ "principle": "Use the target planner and scheduler readback as canonical facts. In workspace-wide --yolo, select and preflight one exact globalActionQueue target before each fenced run. Automatically invoke returned continuation arguments: preserve targetConfig plus runId/fence for an active exact run, or open a new fence from the next preflighted targetConfig between exact targets. When a loaded_awaiting_scheduler exact terminal rereads the same campaign/table/sender/lane at the workspace head, return that scheduler-owned workspace terminal without another fence. Continue until workspace projected coverage fills, that same-target scheduler terminal is returned, or a concrete blocker appears. Refresh stale paid-InMail credit facts before scheduler-wait decisions; do not change scheduler allocation logic.",
5
5
  "revisionProjectionContract": {
6
6
  "action": "revise_message_template_and_rerun",
7
7
  "requiredAuthorities": [
@@ -389,7 +389,12 @@
389
389
  }
390
390
  },
391
391
  "preserveOriginalScope": true,
392
- "userActionRequired": false
392
+ "userActionRequired": false,
393
+ "sameExactTargetTerminal": {
394
+ "doneReason": "loaded_awaiting_scheduler",
395
+ "coordinatorStatus": "loaded_awaiting_scheduler",
396
+ "continuationRequired": false
397
+ }
393
398
  },
394
399
  "autoExecutableActions": [
395
400
  "refresh_paid_inmail_credits",