@sellable/mcp 0.1.476 → 0.1.478

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.
@@ -179,6 +179,8 @@ export type ConfirmLeadListInput = {
179
179
  reviewBatchLimit?: number;
180
180
  includeRawImportResult?: boolean;
181
181
  allowPartialSourceList?: boolean;
182
+ sourceRowIds?: string[];
183
+ sourceRowLimit?: number;
182
184
  /**
183
185
  * Deprecated alias for reviewBatchLimit. Confirming a lead list now copies the
184
186
  * confirmed source into the campaign table; this value no longer caps clone
@@ -293,6 +295,8 @@ export declare const leadToolDefinitions: ({
293
295
  keepInSync?: undefined;
294
296
  jobId?: undefined;
295
297
  reviewBatchLimit?: undefined;
298
+ sourceRowIds?: undefined;
299
+ sourceRowLimit?: undefined;
296
300
  allowPartialSourceList?: undefined;
297
301
  includeRawImportResult?: undefined;
298
302
  selections?: undefined;
@@ -487,6 +491,8 @@ export declare const leadToolDefinitions: ({
487
491
  keepInSync?: undefined;
488
492
  jobId?: undefined;
489
493
  reviewBatchLimit?: undefined;
494
+ sourceRowIds?: undefined;
495
+ sourceRowLimit?: undefined;
490
496
  allowPartialSourceList?: undefined;
491
497
  includeRawImportResult?: undefined;
492
498
  selections?: undefined;
@@ -580,6 +586,8 @@ export declare const leadToolDefinitions: ({
580
586
  keepInSync?: undefined;
581
587
  jobId?: undefined;
582
588
  reviewBatchLimit?: undefined;
589
+ sourceRowIds?: undefined;
590
+ sourceRowLimit?: undefined;
583
591
  allowPartialSourceList?: undefined;
584
592
  includeRawImportResult?: undefined;
585
593
  selections?: undefined;
@@ -745,6 +753,8 @@ export declare const leadToolDefinitions: ({
745
753
  keepInSync?: undefined;
746
754
  jobId?: undefined;
747
755
  reviewBatchLimit?: undefined;
756
+ sourceRowIds?: undefined;
757
+ sourceRowLimit?: undefined;
748
758
  allowPartialSourceList?: undefined;
749
759
  includeRawImportResult?: undefined;
750
760
  selections?: undefined;
@@ -852,6 +862,8 @@ export declare const leadToolDefinitions: ({
852
862
  keepInSync?: undefined;
853
863
  jobId?: undefined;
854
864
  reviewBatchLimit?: undefined;
865
+ sourceRowIds?: undefined;
866
+ sourceRowLimit?: undefined;
855
867
  allowPartialSourceList?: undefined;
856
868
  includeRawImportResult?: undefined;
857
869
  selections?: undefined;
@@ -968,6 +980,8 @@ export declare const leadToolDefinitions: ({
968
980
  keepInSync?: undefined;
969
981
  jobId?: undefined;
970
982
  reviewBatchLimit?: undefined;
983
+ sourceRowIds?: undefined;
984
+ sourceRowLimit?: undefined;
971
985
  allowPartialSourceList?: undefined;
972
986
  includeRawImportResult?: undefined;
973
987
  selections?: undefined;
@@ -1073,6 +1087,8 @@ export declare const leadToolDefinitions: ({
1073
1087
  keepInSync?: undefined;
1074
1088
  jobId?: undefined;
1075
1089
  reviewBatchLimit?: undefined;
1090
+ sourceRowIds?: undefined;
1091
+ sourceRowLimit?: undefined;
1076
1092
  allowPartialSourceList?: undefined;
1077
1093
  includeRawImportResult?: undefined;
1078
1094
  selections?: undefined;
@@ -1183,6 +1199,8 @@ export declare const leadToolDefinitions: ({
1183
1199
  keepInSync?: undefined;
1184
1200
  jobId?: undefined;
1185
1201
  reviewBatchLimit?: undefined;
1202
+ sourceRowIds?: undefined;
1203
+ sourceRowLimit?: undefined;
1186
1204
  allowPartialSourceList?: undefined;
1187
1205
  includeRawImportResult?: undefined;
1188
1206
  selections?: undefined;
@@ -1281,6 +1299,8 @@ export declare const leadToolDefinitions: ({
1281
1299
  keepInSync?: undefined;
1282
1300
  jobId?: undefined;
1283
1301
  reviewBatchLimit?: undefined;
1302
+ sourceRowIds?: undefined;
1303
+ sourceRowLimit?: undefined;
1284
1304
  allowPartialSourceList?: undefined;
1285
1305
  includeRawImportResult?: undefined;
1286
1306
  selections?: undefined;
@@ -2171,6 +2191,8 @@ export declare const leadToolDefinitions: ({
2171
2191
  keepInSync?: undefined;
2172
2192
  jobId?: undefined;
2173
2193
  reviewBatchLimit?: undefined;
2194
+ sourceRowIds?: undefined;
2195
+ sourceRowLimit?: undefined;
2174
2196
  allowPartialSourceList?: undefined;
2175
2197
  includeRawImportResult?: undefined;
2176
2198
  selections?: undefined;
@@ -2278,6 +2300,8 @@ export declare const leadToolDefinitions: ({
2278
2300
  keepInSync?: undefined;
2279
2301
  jobId?: undefined;
2280
2302
  reviewBatchLimit?: undefined;
2303
+ sourceRowIds?: undefined;
2304
+ sourceRowLimit?: undefined;
2281
2305
  allowPartialSourceList?: undefined;
2282
2306
  includeRawImportResult?: undefined;
2283
2307
  selections?: undefined;
@@ -3323,6 +3347,8 @@ export declare const leadToolDefinitions: ({
3323
3347
  keepInSync?: undefined;
3324
3348
  jobId?: undefined;
3325
3349
  reviewBatchLimit?: undefined;
3350
+ sourceRowIds?: undefined;
3351
+ sourceRowLimit?: undefined;
3326
3352
  allowPartialSourceList?: undefined;
3327
3353
  includeRawImportResult?: undefined;
3328
3354
  selections?: undefined;
@@ -3477,6 +3503,8 @@ export declare const leadToolDefinitions: ({
3477
3503
  keepInSync?: undefined;
3478
3504
  jobId?: undefined;
3479
3505
  reviewBatchLimit?: undefined;
3506
+ sourceRowIds?: undefined;
3507
+ sourceRowLimit?: undefined;
3480
3508
  allowPartialSourceList?: undefined;
3481
3509
  includeRawImportResult?: undefined;
3482
3510
  selections?: undefined;
@@ -3618,6 +3646,8 @@ export declare const leadToolDefinitions: ({
3618
3646
  keepInSync?: undefined;
3619
3647
  jobId?: undefined;
3620
3648
  reviewBatchLimit?: undefined;
3649
+ sourceRowIds?: undefined;
3650
+ sourceRowLimit?: undefined;
3621
3651
  allowPartialSourceList?: undefined;
3622
3652
  includeRawImportResult?: undefined;
3623
3653
  selections?: undefined;
@@ -3714,6 +3744,8 @@ export declare const leadToolDefinitions: ({
3714
3744
  keepInSync?: undefined;
3715
3745
  jobId?: undefined;
3716
3746
  reviewBatchLimit?: undefined;
3747
+ sourceRowIds?: undefined;
3748
+ sourceRowLimit?: undefined;
3717
3749
  allowPartialSourceList?: undefined;
3718
3750
  includeRawImportResult?: undefined;
3719
3751
  selections?: undefined;
@@ -3760,6 +3792,17 @@ export declare const leadToolDefinitions: ({
3760
3792
  type: string;
3761
3793
  description: string;
3762
3794
  };
3795
+ sourceRowIds: {
3796
+ type: string;
3797
+ items: {
3798
+ type: string;
3799
+ };
3800
+ description: string;
3801
+ };
3802
+ sourceRowLimit: {
3803
+ type: string;
3804
+ description: string;
3805
+ };
3763
3806
  allowPartialSourceList: {
3764
3807
  type: string;
3765
3808
  description: string;
@@ -3969,6 +4012,8 @@ export declare const leadToolDefinitions: ({
3969
4012
  keepInSync?: undefined;
3970
4013
  jobId?: undefined;
3971
4014
  reviewBatchLimit?: undefined;
4015
+ sourceRowIds?: undefined;
4016
+ sourceRowLimit?: undefined;
3972
4017
  allowPartialSourceList?: undefined;
3973
4018
  includeRawImportResult?: undefined;
3974
4019
  };
@@ -4066,6 +4111,8 @@ export declare const leadToolDefinitions: ({
4066
4111
  keepInSync?: undefined;
4067
4112
  jobId?: undefined;
4068
4113
  reviewBatchLimit?: undefined;
4114
+ sourceRowIds?: undefined;
4115
+ sourceRowLimit?: undefined;
4069
4116
  allowPartialSourceList?: undefined;
4070
4117
  includeRawImportResult?: undefined;
4071
4118
  selections?: undefined;
@@ -2201,6 +2201,15 @@ export const leadToolDefinitions = [
2201
2201
  type: "number",
2202
2202
  description: "Number of campaign rows to use as the initial review/process sample. Defaults to 15.",
2203
2203
  },
2204
+ sourceRowIds: {
2205
+ type: "array",
2206
+ items: { type: "string" },
2207
+ description: "Optional exact source WorkflowTableRow ids to copy from the selected source lead list. Use only for bounded refill same-source copy packets.",
2208
+ },
2209
+ sourceRowLimit: {
2210
+ type: "number",
2211
+ description: "Optional cap for copying the first N source rows. Prefer sourceRowIds when a refill packet provides exact ids.",
2212
+ },
2204
2213
  allowPartialSourceList: {
2205
2214
  type: "boolean",
2206
2215
  description: "Explicit override for user-approved early continuation. Default false. When true, confirm_lead_list may copy the currently materialized rows from a still-running source import; use only after the user explicitly asks to keep going with the partial list.",
@@ -4127,7 +4136,7 @@ export async function cancelLeadImport(input) {
4127
4136
  }
4128
4137
  export async function confirmLeadList(input) {
4129
4138
  const api = getApi();
4130
- const { campaignOfferId, currentStep, confirmed, sourceLeadListId, campaignName, keepInSync, jobId, reviewBatchLimit, includeRawImportResult, allowPartialSourceList, targetLeadCount, } = input;
4139
+ const { campaignOfferId, currentStep, confirmed, sourceLeadListId, campaignName, keepInSync, jobId, reviewBatchLimit, includeRawImportResult, allowPartialSourceList, targetLeadCount, sourceRowIds, sourceRowLimit, } = input;
4131
4140
  assertInteractionApproval({
4132
4141
  campaignId: campaignOfferId,
4133
4142
  action: "confirm-lead-list",
@@ -4329,6 +4338,8 @@ export async function confirmLeadList(input) {
4329
4338
  campaignName,
4330
4339
  keepInSync,
4331
4340
  currentStep: null,
4341
+ sourceRowIds,
4342
+ sourceRowLimit,
4332
4343
  })
4333
4344
  .catch((error) => {
4334
4345
  if (isTerminalAccessError(error)) {
@@ -373,7 +373,7 @@ export function getPostFindLeadsScoutRegistry() {
373
373
  codex: 'After confirm_lead_list copies source rows and the initial campaign-table execution slice exists, ask the filter-choice question immediately. Do not spawn anything before that question. After the answer, launch only Message Drafting. The filter-choice answer is the post-import user gate for this single worker; do not ask another question about starting it in step-wise or YOLO mode. The registry lookup is not a launch: after get_post_find_leads_scout_registry, immediately invoke Task/spawn_agent or the host background-agent mechanism before loading filter-leads.md, before saving rubrics, and before treating skip-filters as ready for message review. Both choices route through this kickoff; do not let filters_skipped jump straight from filter-choice to message-generation. If filters are chosen, the parent stays on Filter Rules and drafts/saves rubrics with MCP tools while Message Drafting runs in the background. If filters are skipped, move to Messages/message review only after Message Drafting has started or is ready; update_campaign(currentStep=messages) is not proof of launch. If the named Message Drafting custom agent is unavailable, spawn a generic gpt-5.5 xhigh Message Drafting background agent with the same lean campaign/table basis. When the background worker starts, persist workerDetails.messageDraftBuilder with statusSource "branch", status "branch-running", runId, startedAt, updatedAt, basisToken when known, and basis containing campaignId, selectedLeadListId, workflowTableId, filterChoice, and reviewBatchRowHash or reviewBatchRowIds; workerStatuses.messageDraftBuilder may be "running" as a simple badge only. Never put rich proof under workerStatuses and never use workerStatuses.messageDrafting. If no background-agent tool is callable, start the same full message branch inline before filter drafting or before skip-filter message review, record workerDetails.messageDraftBuilder with statusSource "parent-thread-fallback" and status "fallback-active", and require the same live context, prompt, assets, and validation gate before message review; do not wait until filters are saved and then call the registry.',
374
374
  claude: "After confirm_lead_list copies source rows and the initial campaign-table execution slice exists, ask the filter-choice question immediately. Do not invoke any Task/Agent before that question. After the answer, invoke only Message Drafting. If filters are chosen, parent drafts/saves rubrics with MCP tools while Message Drafting runs, asks filter approval, then joins Message Drafting. If filters are skipped, invoke only Message Drafting and move to Messages/message review.",
375
375
  parentThreadRule: 'Named agents are optional acceleration, but message drafting is not optional. The only normal background worker is Message Drafting. The filter-choice answer is the campaign-scoped go-ahead for this single post-import worker; do not ask another question to start it in step-wise or YOLO mode. If a named agent is unavailable, use a generic gpt-5.5 xhigh Message Drafting background agent. source work and filter work stay in the parent thread with MCP tools. If post-find-leads-message-scout is available, run it as the background Message Draft Builder after the filter-choice answer. The registry lookup is not a launch: get_post_find_leads_scout_registry only identifies the worker, and Message Drafting counts as started only after Task/spawn_agent or the host background-agent tool is invoked, or after the parent begins the same full message branch inline because no background-agent tool is callable. This launch must happen before loading filter-leads.md, save_rubrics, filter approval, or skip-filter message review; currentStep=messages is not proof of launch. If post-find-leads-message-scout is absent, do not customer-surface install status. Do not silently treat message drafting as started; the main thread must either launch the background worker or execute the same message branch from CampaignOffer state, selected source state, workflowTableId, and initial campaign-table execution slice rows. For a spawned worker, record workerDetails.messageDraftBuilder with statusSource branch / status branch-running, runId, startedAt, updatedAt, and basis containing campaignId, selectedLeadListId, workflowTableId, filterChoice, and reviewBatchRowHash or reviewBatchRowIds. workerStatuses.messageDraftBuilder is optional simple badge text only ("running", "ready", "blocked", "idle"); never put runId/statusSource/basis under workerStatuses and never use workerStatuses.messageDrafting. If no background-agent tool is callable, start that same full message branch inline before filter drafting or before skip-filter message review, record workerDetails.messageDraftBuilder with statusSource parent-thread-fallback / status fallback-active then ready, and require the same live context, prompt, assets, and validation gate before message review; do not report that as a background worker failure. If neither branch nor inline fallback can run, return blocked/retry-needed; do not wait until filters are saved and then call the registry. The Message Drafting handoff must be lean. Do not paste copied row counts, brief hashes, review-batch hashes, full reviewBatchRowIds, broad row data, or local debug artifacts into the spawn prompt. Local markdown/json files are not normal-path inputs. The filter-choice question is the first post-import user gate; do not load post-lead registries or filter references before it. Message drafting starts after the filter-choice answer, must load get_subskill_prompt({ subskillName: "generate-messages" }), and must load every required message asset named by generate-messages Mode 0 through get_subskill_asset before drafting. Reference Asset Loading means loading the required pre-draft reference pack before drafting; return blocked/retry-needed if required assets cannot be loaded; load ai-tells.md because it is never optional. The branch or parent-thread fallback loads the full generate-messages prompt and every referenced asset through get_subskill_asset. After generating/revising the candidate and before returning ready, must load get_subskill_prompt({ subskillName: "create-campaign-v2-validation" }) as the final internal validation gate, must read live campaign table state through scoped MCP/product tools, and must reject mismatched selectedLeadListId/workflowTableId/campaign/workspace input. Do not block when filters were chosen but leadScoringRubrics are not yet visible in the branch read; the parent owns save_rubrics and filter approval in parallel, so Message Drafting should return status ready with basisStatus usable_initial when campaign/list/table identity and the non-empty execution slice match. Do not use any alternate, local-artifact, or examples-only message prompt. User copy feedback, message QA, or rewrite requests before approve-message must be routed back to Message Drafting with the current recommendation, lean campaign/table basis, and latest user text; the parent must not rewrite or QA the template from memory and must not call update_campaign_brief before approve-message. The worker validates internally and returns only templateRecommendation, tokenFillRules, renderedGoodSample, status, approveOrReviseRecommendation, validationStatus, outputAt, outputHash, and blocked/retry detail. Do not render renderedFallbackSample, risk notes, or a qaReceipt on the normal happy path. On the filter path, save_rubrics keeps the browser on Filter Rules after save_rubrics so the user can approve the saved criteria; after saved-filter approval, move to Filter Leads with currentStep=apply-icp-rubric whether Message Drafting is ready or still running. Wait there for message approval. Enrichment, filtering, Generate Message cells, sender setup, sequence attach, and launch wait for template approval on the Use Template path. On the skip path, move to Messages/message review after Message Drafting has started or is ready and wait for message approval before enrichment or Settings. Do not render message review from checklist or shortcut instructions; message review requires a messageDraftRecommendation whose basis proves the generate-messages prompt, required message assets, and validation gate ran for the current campaign/table execution slice. Do not automatically rerun Message Drafting after filters/enrichment finish; show the initial draft by default and offer an enriched rewrite only with explicit user opt-in. Handoff and recommendation output are Markdown with labeled fields, not raw JSON.',
376
- prepareMessagesRule: `Default create-campaign stays on the existing reviewBatchLimit:15 first campaign-table execution slice. For plain post-mint fill/load/refill requests, load get_subskill_prompt({ subskillName: "refill-sends-workflow" }), then call resolve_campaign_fill_route({ intent:"plain" }), list_senders, and get_campaign_refill_state for enough candidate campaigns to identify the campaign that most recently had scheduler-owned sends for the relevant sender set before any mutation. Route outcomes are route:"evergreen_horizon", route:"active_campaigns", and route:"ask_create"; if a plain managed-waterfall route has archived/completed skipped slots or does not cover the named sender set, immediately refetch with resolve_campaign_fill_route({ intent:"active" }) and inspect current dashboard-active ACTIVE/PAUSED campaign-backed sequence campaigns before declaring a sender blocked; stay in the same campaignOfferId/campaignId context after minting. Plain fill is not an alias for fill_campaign_horizon or campaign creation. fill_campaign_horizon is evergreen-only and is not the generic regular-campaign fill path. Campaign creation is allowed only after route:"ask_create" and explicit user selection; it is never the default response to plain fill. Treat "fill up/load sends" as capacity-fill preparation, and treat "refill senders", "fill senders", "max out senders", and "load everyone up" as sender-scoped capacity-fill preparation. For sender-scoped requests with no named senders, --yolo means all eligible healthy senders enrolled in active campaign-backed sequence campaigns in the active workspace; without --yolo, ask which eligible enrolled senders to refill before choosing campaigns or mutating. In non-yolo interactive Codex or Claude Code sessions, post the full sender/campaign/action approval packet in normal chat as Markdown first, then ask request_user_input/AskUserQuestion with exactly Accept and Decline and a compact body that refers back to the posted packet; do not duplicate the campaign table or full operator packet inside the structured question. The chat packet must show workspace, sender scope, a campaign-by-campaign table, exact ids/caps/dates, side effects, forbidden actions, and stop condition before mutation. Default --yolo target is the scheduler-forward 48-hour target window: sender-local send days whose configured sending windows overlap the rolling target window, skipping no-send-hour days. For campaign-scoped fill/refill, select the best recent-send campaign and calculate the bounded gap from healthy sender daily capacity minus projected coverage (actual sent plus future scheduler-owned scheduled sends) and ready-to-schedule rows, then prepare only that gap. For sender-scoped fill/refill, calculate the bounded gap per eligible sender across active enrolled campaigns, counting actual sent coverage, future scheduled rows, and ready-to-schedule rows across those campaigns, then choose the best same-sender campaign to fill each sender gap: prefer recent/future scheduler-owned sends for that sender, then strongest recent result evidence, then source health. Maintain a target-window saturation ledger per selected sender with selected send days, gross capacity, actual sent counts, future scheduler-owned scheduled counts, projected coverage, ready-to-schedule buffer, remaining projected gap, paid-InMail threshold feasibility, and the next MCP primitive. The structured packet lives in target.senderRefillPlans[] with target.eligibleSenderLedger, campaignRanking.options, sourcePlan, nextActions, manualAlternates, and target.globalActionQueue; preserve Need to prepare, Goal, Already sent, Scheduled, Ready and waiting to be scheduled, and Still need labels. In --yolo, execute exactly one globally ranked primitive from the post-refresh target.globalActionQueue[0], then rerun get_refill_target_plan before choosing another action. The refill_sends MCP command maintains a run-local refreshedPaidInmailSenderIds set: if the first target plan contains refresh_paid_inmail_credits for stale/missing paid-InMail facts, refill_sends refreshes each selected paid-InMail sender at most once, reruns get_refill_target_plan, and returns autoPaidInmailRefresh plus the post-refresh targetPlan before the operator chooses prep, approval, start, or fallback. Do not present paid-credit refresh as the next operator action after refill_sends has returned a post-refresh targetPlan. Do not stop after filling only one sender when the request was sender-scoped. In --yolo, continue through every safe selected sender/campaign action covered by the rendered packet, reread after each terminal apply/prep/start result, recompute the target-window saturation ledger, and keep going until projected coverage (sent + scheduled) fills the scheduler-forward target window or a concrete non-scheduler blocker is proven. Ready-to-schedule rows are buffer, not completion; if ready covers the projected gap but scheduled cells do not, report loaded, awaiting scheduler and run a persistent read-only scheduler wait/reread loop and keep the run open while awaiting_scheduler_after_ready_buffer is the only remaining state. Paid-InMail threshold changes and connection-campaign creation are explicit continuation options, never --yolo side effects. When no safe in-packet action remains return concrete continuation options with campaign names, exact ids, and which options require a new approval packet; do not return final completion for scheduler wait unless Christian explicitly asks for status or stops the run. Use the refill workflow to decide whether to enrich/prep more rows in that same recent-send/best-result campaign, add/import more rows to that same campaign/source path, use a different existing campaign only when the selected same-sender lane is blocked/exhausted/already loaded while the sender still has a gap, or ask what to create. Do not create warm-post-engager side campaigns. Surface sender-health blockers and paid-InMail threshold blockers separately from prepared/approved/scheduled counts. User-facing refill decisions must be campaign-name-first and sender-name-first, with ids as proof/execution targets only. Trust schedulerGate.sendable and scheduler blockers over raw unipileAccountStatus labels alone. For long-running prep use compact prep status checks, reread target plans after prep or cancel, avoid huge parallel target-plan reads when output is large, and if prepared/ready rows grow but sender-level projected coverage does not move after one bounded settle loop, pivot to compact prep status or a scheduler-proven lane instead of waiting on campaign-level ready counts. For already-running regular campaigns that need Signal Discovery source replenishment, use the guarded currentStep clear with clearCurrentStepIfMatches:"running", campaign-scoped provider prompt/search/select, and import_leads with the existing sourceLeadListId when a newly approved selected-post scrape would otherwise return reusedExistingSourceList. Before prep, inspect get_campaign_refill_state.preparationFrontier. If hasLaterPreparedIsland:true or earliestUnpreparedRow exists before later successful enrichment, use rowSelector:{type:"needsEnrichment"} with columnRole:"enrich" in table-position order or start_campaign_message_preparation adaptive defaults; do not use the UI Jump anchor or needsGeneratedMessage as the refill cursor. After confirm_lead_list copies rows into an existing table, avoid fixed maxRowsToCheck:100; if confirm_lead_list returns USER_ADDED_ROWS_LIMIT_EXCEEDED, create a bounded same-source split from selectedLeadListId with get_rows_minimal/load_csv_linkedin_leads, confirm that smaller source list into the same campaign, and inspect reviewBatch only as diagnostics unless the approved packet explicitly prioritizes the just-copied split and earlier needsEnrichment rows are exhausted, dependency-blocked, or excluded. For approval diagnostics use rowSelector:{type:"needsApproval"} after current generated messages exist; mutating Approved cells still requires approvalMode:approve and exact bounded approval. Do not interpret checkedRows as enriched rows; it is only the table cursor. Prepared, approved, and ready_to_schedule rows are intermediate states; never call them scheduled unless a re-read proves scheduler-owned scheduled cells with non-null scheduledFor contribute to projected coverage, and never call them complete unless a final re-read proves projected coverage fills the scheduler-forward target window. Before source import, prep, approval, or selected paused campaign start, require exact visible approval or --yolo packet auto-accept and a fresh get_campaign_refill_state reread; stop if freshness.stateHash or exact ids changed. For "approve X messages", use approvalMode:approve only when explicitly requested. For "schedule X sends" or "fill sender sends", approve only when explicitly requested, then re-read campaign/table scheduled counts; if projected coverage does not fill the horizon, keep polling when ready buffer covers the gap and report only interim prepared/approved/ready - awaiting scheduler status if Christian asks. Do not call start_campaign as part of fill/schedule horizon. start_campaign is allowed in refill only for exact selected PAUSED, dashboard-active, campaign-backed sequence targets named in the bounded packet, and the packet must state that starting can let the product scheduler schedule/send approved eligible sequence actions. Never start unrelated, archived, completed, draft, direct, or non-selected campaigns, never broad approve-all, and never use direct scheduler writes. campaignId is CampaignOffer.id. If the user asks to stop preparation, the target is wrong, or status shows the wrong campaign/table, use cancel_campaign_message_preparation only for the exact active job. Low-level selectors are diagnostics and recovery only for this lane.`,
376
+ prepareMessagesRule: `Default create-campaign stays on the existing reviewBatchLimit:15 first campaign-table execution slice. For plain post-mint fill/load/refill requests, load get_subskill_prompt({ subskillName: "refill-sends-workflow" }), then call resolve_campaign_fill_route({ intent:"plain" }), list_senders, and get_campaign_refill_state for enough candidate campaigns to identify the campaign that most recently had scheduler-owned sends for the relevant sender set before any mutation. Route outcomes are route:"evergreen_horizon", route:"active_campaigns", and route:"ask_create"; if a plain managed-waterfall route has archived/completed skipped slots or does not cover the named sender set, immediately refetch with resolve_campaign_fill_route({ intent:"active" }) and inspect current dashboard-active ACTIVE/PAUSED campaign-backed sequence campaigns before declaring a sender blocked; stay in the same campaignOfferId/campaignId context after minting. Plain fill is not an alias for fill_campaign_horizon or campaign creation. fill_campaign_horizon is evergreen-only and is not the generic regular-campaign fill path. Campaign creation is allowed only after route:"ask_create" and explicit user selection; it is never the default response to plain fill. Treat "fill up/load sends" as capacity-fill preparation, and treat "refill senders", "fill senders", "max out senders", and "load everyone up" as sender-scoped capacity-fill preparation. For sender-scoped requests with no named senders, --yolo means all eligible healthy senders enrolled in active campaign-backed sequence campaigns in the active workspace; without --yolo, ask which eligible enrolled senders to refill before choosing campaigns or mutating. In non-yolo interactive Codex or Claude Code sessions, post the full sender/campaign/action approval packet in normal chat as Markdown first, then ask request_user_input/AskUserQuestion with exactly Accept and Decline and a compact body that refers back to the posted packet; do not duplicate the campaign table or full operator packet inside the structured question. The chat packet must show workspace, sender scope, a campaign-by-campaign table, exact ids/caps/dates, side effects, forbidden actions, and stop condition before mutation. Default --yolo target is the scheduler-forward 48-hour target window: sender-local send days whose configured sending windows overlap the rolling target window, skipping no-send-hour days. For campaign-scoped fill/refill, select the best recent-send campaign and calculate the bounded gap from healthy sender daily capacity minus projected coverage (actual sent plus future scheduler-owned scheduled sends) and ready-to-schedule rows, then prepare only that gap. For sender-scoped fill/refill, calculate the bounded gap per eligible sender across active enrolled campaigns, counting actual sent coverage, future scheduled rows, and ready-to-schedule rows across those campaigns, then choose the best same-sender campaign to fill each sender gap: prefer recent/future scheduler-owned sends for that sender, then strongest recent result evidence, then source health. Maintain a target-window saturation ledger per selected sender with selected send days, gross capacity, actual sent counts, future scheduler-owned scheduled counts, projected coverage, ready-to-schedule buffer, remaining projected gap, paid-InMail threshold feasibility, and the next MCP primitive. The structured packet lives in target.senderRefillPlans[] with target.eligibleSenderLedger, campaignRanking.options, sourcePlan, nextActions, manualAlternates, and target.globalActionQueue; preserve Need to prepare, Goal, Already sent, Scheduled, Ready and waiting to be scheduled, and Still need labels. In --yolo, execute exactly one globally ranked primitive from the post-refresh target.globalActionQueue[0], then rerun get_refill_target_plan before choosing another action. Refill action ladder: approve generated rows only when an explicit bounded approval gate exists, process all existing same-campaign unenriched/unprepared rows in bounded batches before any source work, then copy bounded net-new rows from the selected source (selectedLeadListId, provider, and source fingerprint preserved), then use provider-aligned source-more. A new source or provider switch changes the reply-rate baseline and is a manual alternate, not a --yolo side effect. The refill_sends MCP command maintains a run-local refreshedPaidInmailSenderIds set: if the first target plan contains refresh_paid_inmail_credits for stale/missing paid-InMail facts, refill_sends refreshes each selected paid-InMail sender at most once, reruns get_refill_target_plan, and returns autoPaidInmailRefresh plus the post-refresh targetPlan before the operator chooses prep/source-copy/bounded-approval/read-only wait. Do not present paid-credit refresh as the next operator action after refill_sends has returned a post-refresh targetPlan. Do not stop after filling only one sender when the request was sender-scoped. In --yolo, continue through every safe selected sender/campaign action covered by the rendered packet, reread after each terminal apply/prep/source-copy/bounded-approval/read-only wait result, recompute the target-window saturation ledger, and keep going until projected coverage (sent + scheduled) fills the scheduler-forward target window or a concrete non-scheduler blocker is proven. Ready-to-schedule rows are buffer, not completion; if ready covers the projected gap but scheduled cells do not, report loaded, awaiting scheduler and run a persistent read-only scheduler wait/reread loop and keep the run open while awaiting_scheduler_after_ready_buffer is the only remaining state. Paid-InMail threshold changes and connection-campaign creation are explicit continuation options, never --yolo side effects. When no safe in-packet action remains return concrete continuation options with campaign names, exact ids, and which options require a new approval packet; do not return final completion for scheduler wait unless Christian explicitly asks for status or stops the run. Use the refill workflow to decide whether to enrich/prep more rows in that same recent-send/best-result campaign, add/import more rows to that same campaign/source path, use a different existing campaign only when the selected same-sender lane is blocked/exhausted/already loaded while the sender still has a gap, or ask what to create. Do not create warm-post-engager side campaigns. Surface sender-health blockers and paid-InMail threshold blockers separately from prepared/approved/scheduled counts. User-facing refill decisions must be campaign-name-first and sender-name-first, with ids as proof/execution targets only. Trust schedulerGate.sendable and scheduler blockers over raw unipileAccountStatus labels alone. For long-running prep use compact prep status checks, reread target plans after prep or cancel, avoid huge parallel target-plan reads when output is large, and if prepared/ready rows grow but sender-level projected coverage does not move after one bounded settle loop, pivot to compact prep status or a scheduler-proven lane instead of waiting on campaign-level ready counts. For already-running regular campaigns that need Signal Discovery source replenishment, use the guarded currentStep clear with clearCurrentStepIfMatches:"running", campaign-scoped provider prompt/search/select, and import_leads with the existing sourceLeadListId when a newly approved selected-post scrape would otherwise return reusedExistingSourceList. Before prep, inspect get_campaign_refill_state.preparationFrontier. If hasLaterPreparedIsland:true or earliestUnpreparedRow exists before later successful enrichment, use rowSelector:{type:"needsEnrichment"} with columnRole:"enrich" in table-position order or start_campaign_message_preparation adaptive defaults; do not use the UI Jump anchor or needsGeneratedMessage as the refill cursor. After confirm_lead_list copies rows into an existing table, avoid fixed maxRowsToCheck:100; if confirm_lead_list returns USER_ADDED_ROWS_LIMIT_EXCEEDED, create a bounded same-source split from selectedLeadListId with get_rows_minimal/load_csv_linkedin_leads, confirm that smaller source list into the same campaign, and inspect reviewBatch only as diagnostics unless the approved packet explicitly prioritizes the just-copied split and earlier needsEnrichment rows are exhausted, dependency-blocked, or excluded. For approval diagnostics use rowSelector:{type:"needsApproval"} after current generated messages exist; mutating Approved cells still requires approvalMode:approve and exact bounded approval. Do not interpret checkedRows as enriched rows; it is only the table cursor. Prepared, approved, and ready_to_schedule rows are intermediate states; never call them scheduled unless a re-read proves scheduler-owned scheduled cells with non-null scheduledFor contribute to projected coverage, and never call them complete unless a final re-read proves projected coverage fills the scheduler-forward target window. Before source import, prep, approval, or selected paused campaign start, require exact visible approval or --yolo packet auto-accept and a fresh get_campaign_refill_state reread; stop if freshness.stateHash or exact ids changed. For "approve X messages", use approvalMode:approve only when explicitly requested. For "schedule X sends" or "fill sender sends", approve only when explicitly requested, then re-read campaign/table scheduled counts; if projected coverage does not fill the horizon, keep polling when ready buffer covers the gap and report only interim prepared/approved/ready - awaiting scheduler status if Christian asks. Do not call start_campaign as part of fill/schedule horizon. start_campaign is allowed in refill only for exact selected PAUSED, dashboard-active, campaign-backed sequence targets named in the bounded packet, and the packet must state that starting can let the product scheduler schedule/send approved eligible sequence actions. Never start unrelated, archived, completed, draft, direct, or non-selected campaigns, never broad approve-all, and never use direct scheduler writes. campaignId is CampaignOffer.id. If the user asks to stop preparation, the target is wrong, or status shows the wrong campaign/table, use cancel_campaign_message_preparation only for the exact active job. Low-level selectors are diagnostics and recovery only for this lane.`,
377
377
  },
378
378
  };
379
379
  }
@@ -159,6 +159,15 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
159
159
  attemptedSenderIds?: undefined;
160
160
  targetPlanReread?: undefined;
161
161
  };
162
+ yoloExecution: {
163
+ enabled: false;
164
+ status: "not_run_without_yolo";
165
+ selectedAction: null;
166
+ targetPlanReread: false;
167
+ result?: undefined;
168
+ refusalReason?: undefined;
169
+ postActionFirstAction?: undefined;
170
+ };
162
171
  command: string;
163
172
  tool: string;
164
173
  promptName: string;
@@ -225,6 +234,7 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
225
234
  } | {
226
235
  targetPlan: unknown;
227
236
  targetPlanBeforePaidRefresh: unknown;
237
+ targetPlanBeforeYoloPrimitive: unknown;
228
238
  autoPaidInmailRefresh: {
229
239
  enabled: boolean;
230
240
  status: string;
@@ -242,6 +252,23 @@ export declare function executeRefillSendsCommand(input?: RefillSendsCommandInpu
242
252
  targetPlanReread: boolean;
243
253
  note: string;
244
254
  };
255
+ yoloExecution: {
256
+ enabled: true;
257
+ status: "skipped_after_paid_refresh";
258
+ selectedAction: null;
259
+ targetPlanReread: true;
260
+ result?: undefined;
261
+ refusalReason?: undefined;
262
+ postActionFirstAction?: undefined;
263
+ } | {
264
+ enabled: true;
265
+ status: "no_action" | "read_only_reread" | "executed_and_reread" | "refused";
266
+ selectedAction: Record<string, unknown> | null;
267
+ result: unknown;
268
+ targetPlanReread: boolean;
269
+ refusalReason: string | undefined;
270
+ postActionFirstAction: Record<string, unknown> | null;
271
+ };
245
272
  command: string;
246
273
  tool: string;
247
274
  promptName: string;
@@ -1,5 +1,8 @@
1
1
  import { getRefillTargetPlan } from "./refill-target-plan.js";
2
2
  import { refreshPaidInmailCredits } from "./senders.js";
3
+ import { startPrepareCampaignMessages } from "./campaign-message-preparation.js";
4
+ import { confirmLeadList } from "./leads.js";
5
+ import { getApi } from "../api.js";
3
6
  const DEFAULT_SCHEDULER_FORWARD_HOURS = 48;
4
7
  function normalizeStrings(values) {
5
8
  if (!Array.isArray(values))
@@ -58,7 +61,7 @@ function normalizeTargetDate(value) {
58
61
  export const refillSendsToolDefinitions = [
59
62
  {
60
63
  name: "refill_sends",
61
- description: "Typed command entrypoint for Sellable refill sends. Accepts --yolo semantics and optional sender selectors, then returns the bounded execution contract for the skill-led refill workflow. In --yolo, it may refresh stale paid InMail credit cache facts for exact selected senders once, then rerun and return the post-refresh target plan. This tool does not mutate campaigns, import leads, approve messages, schedule sends, launch, archive, delete, or write scheduler rows.",
64
+ description: "Typed command entrypoint for Sellable refill sends. Accepts --yolo semantics and optional sender selectors, then returns the bounded execution contract for the skill-led refill workflow. In --yolo, it may refresh stale paid InMail credit cache facts once, or execute exactly one safe primitive from target.globalActionQueue[0] (bounded existing-row preparation, bounded same-source copy, bounded generated-message approval, or read-only wait) and reread. It does not run unbounded approval, lower paid InMail thresholds, switch source families, create campaigns, schedule sends, launch, archive, delete, or write scheduler rows.",
62
65
  inputSchema: {
63
66
  type: "object",
64
67
  properties: {
@@ -213,14 +216,14 @@ export function refillSendsCommand(input = {}) {
213
216
  "Treat current dashboard-active PAUSED campaign-backed sequence campaigns as start-eligible candidates: read refill state before deciding whether to prep, approve, start, or skip.",
214
217
  "Fresh reread get_campaign_refill_state immediately before any import, prep, approval, or horizon-fill mutation.",
215
218
  "Maintain a target-window saturation ledger per selected sender from get_refill_target_plan: selected days, gross capacity, actual sent counts, future scheduler-owned scheduled counts, projected counts, ready-to-schedule buffer, remaining projected gap, paid InMail threshold feasibility, targetShapeRevision, stateRevision, and next MCP primitive.",
216
- "In --yolo, this tool automatically maintains a run-local refreshedPaidInmailSenderIds set: when the first target plan returns refresh_paid_inmail_credits candidates for selected paid-InMail lanes, it refreshes each exact sender at most once, reruns get_refill_target_plan, and returns the post-refresh targetPlan before any prep/import/approval/start action is chosen.",
219
+ "In --yolo, this tool automatically maintains a run-local refreshedPaidInmailSenderIds set: when the first target plan returns refresh_paid_inmail_credits candidates for selected paid-InMail lanes, it refreshes each exact sender at most once, reruns get_refill_target_plan, and returns the post-refresh targetPlan before any prep/source-copy/bounded-approval/read-only wait action is chosen.",
217
220
  "Do not present paid-credit refresh as the next operator action after refill_sends returns autoPaidInmailRefresh and the post-refresh targetPlan.",
218
221
  "If paid InMail feasibility remains below threshold after that automatic refresh, report the exact sender/campaign/table/column threshold action or same-campaign connection fallback; --yolo must not lower paid InMail thresholds or create campaigns.",
219
222
  "In --yolo or after one Accept, continue through every safe selected sender/campaign action covered by the rendered target packet; sent/scheduled-count progress changes stateRevision and should continue while targetShapeRevision is stable.",
220
223
  "Do not complete a fill/schedule request until a final get_refill_target_plan or refill-state reread proves projected coverage (sent + scheduled) fills the scheduler-forward target window. Treat awaiting_scheduler_after_ready_buffer as loaded, awaiting scheduler when ready buffer covers the gap; do not import/prep more rows in that state, and keep polling unless Christian stops/statuses the run or a concrete non-scheduler blocker such as paid_inmail_below_threshold appears.",
221
224
  ],
222
225
  approvalContract: yolo
223
- ? "Auto-accept only the rendered bounded refill target packet after get_refill_target_plan and fresh reread. Execute one globally ranked primitive from target.globalActionQueue at a time, then rerun get_refill_target_plan before taking another action. Continue through every safe apply/prep/start action inside that packet, including start_campaign only for exact selected PAUSED campaign-backed sequence refill targets named in the packet. After each action, rerun get_refill_target_plan; keep going while targetShapeRevision is stable and projected coverage (sent + scheduled) progresses toward the target, even though stateRevision changes. Ready-to-schedule rows are buffer, not completion. If ready buffer covers the projected gap, use only persistent read-only scheduler wait/reread and keep the run open until projected coverage fills or Christian stops/statuses it. Stop immediately if targetShapeRevision changes because sender set, route, ids, caps, dates, blockers, action class, paid InMail threshold feasibility, or side-effect class drifts. --yolo does not authorize lowering paid InMail thresholds or creating connection campaigns."
226
+ ? "Auto-accept only the rendered bounded refill target packet after get_refill_target_plan and fresh reread. Execute one globally ranked primitive from target.globalActionQueue at a time, then rerun get_refill_target_plan before taking another action. Continue through every safe prep/source-copy/bounded-approval/read-only wait action inside that packet. Unbounded approval, start_campaign, source-family switches, threshold changes, and campaign creation require their own explicit gates. After each safe action, rerun get_refill_target_plan; keep going while targetShapeRevision is stable and projected coverage (sent + scheduled) progresses toward the target, even though stateRevision changes. Ready-to-schedule rows are buffer, not completion. If ready buffer covers the projected gap, use only persistent read-only scheduler wait/reread and keep the run open until projected coverage fills or Christian stops/statuses it. Stop immediately if targetShapeRevision changes because sender set, route, ids, caps, dates, blockers, action class, paid InMail threshold feasibility, or side-effect class drifts. --yolo does not authorize lowering paid InMail thresholds or creating connection campaigns."
224
227
  : hasSenderSelectors
225
228
  ? "Before mutation, post the full bounded refill packet in normal chat as Markdown, including workspace, sender scope, campaign table, exact ids, caps/dates, gross target, sent count, scheduled count, projected count, ready buffer, remaining projected gap, paid InMail threshold feasibility, targetShapeRevision/stateRevision, side effects, forbidden actions, and stop condition. Then ask the final Accept/Decline structured approval question with a compact body that refers back to the posted packet instead of duplicating it. Only ask when get_refill_target_plan reports a positive remaining projected/ready gap. If target is complete by projected coverage, no-op without approval. If ready buffer covers the projected gap, run only persistent read-only scheduler wait/reread and keep the run open until projected coverage fills or Christian stops/statuses it. Threshold changes and campaign creation need separate explicit approval."
226
229
  : "Ask which eligible enrolled senders to refill first, then, before mutation, post the full bounded refill packet in normal chat as Markdown and ask the final Accept/Decline structured approval question with a compact body that refers back to the posted packet.",
@@ -302,6 +305,14 @@ function recordValue(value) {
302
305
  function stringValue(value) {
303
306
  return typeof value === "string" && value.trim() ? value.trim() : null;
304
307
  }
308
+ function numberValue(value) {
309
+ return typeof value === "number" && Number.isFinite(value) ? value : null;
310
+ }
311
+ function stringArray(value) {
312
+ if (!Array.isArray(value))
313
+ return [];
314
+ return value.filter((item) => typeof item === "string");
315
+ }
305
316
  function paidRefreshActionFrom(value) {
306
317
  const action = recordValue(value);
307
318
  if (!action || action.type !== "refresh_paid_inmail_credits")
@@ -349,6 +360,148 @@ function collectPaidInmailRefreshActions(plan) {
349
360
  add(action);
350
361
  return [...bySender.values()];
351
362
  }
363
+ function firstGlobalAction(plan) {
364
+ const root = recordValue(plan);
365
+ const target = recordValue(root?.target);
366
+ const globalActionQueue = Array.isArray(target?.globalActionQueue)
367
+ ? target.globalActionQueue
368
+ : [];
369
+ const [first] = globalActionQueue;
370
+ return recordValue(first);
371
+ }
372
+ function actionIds(action) {
373
+ return recordValue(action.ids) ?? {};
374
+ }
375
+ function actionToolInput(action) {
376
+ return recordValue(action.toolInput) ?? {};
377
+ }
378
+ function actionCampaignId(action) {
379
+ const ids = actionIds(action);
380
+ const toolInput = actionToolInput(action);
381
+ return (stringValue(toolInput.campaignId) ??
382
+ stringValue(toolInput.campaignOfferId) ??
383
+ stringValue(ids.campaignId) ??
384
+ stringValue(action.campaignId));
385
+ }
386
+ function actionTableId(action) {
387
+ const ids = actionIds(action);
388
+ const toolInput = actionToolInput(action);
389
+ return (stringValue(toolInput.tableId) ??
390
+ stringValue(ids.tableId) ??
391
+ stringValue(action.tableId));
392
+ }
393
+ function actionSourceLeadListId(action) {
394
+ const ids = actionIds(action);
395
+ const toolInput = actionToolInput(action);
396
+ return (stringValue(toolInput.sourceLeadListId) ??
397
+ stringValue(ids.sourceLeadListId) ??
398
+ stringValue(action.sourceLeadListId));
399
+ }
400
+ function boundedApprovalLimit(action) {
401
+ const toolInput = actionToolInput(action);
402
+ const rowSelector = recordValue(toolInput.rowSelector);
403
+ const selectorLimit = numberValue(rowSelector?.limit);
404
+ const inputLimit = numberValue(toolInput.limit);
405
+ const limit = selectorLimit ?? inputLimit;
406
+ if (!limit || limit <= 0)
407
+ return null;
408
+ return Math.floor(limit);
409
+ }
410
+ async function approveGeneratedMessagesBatch(action) {
411
+ const tableId = actionTableId(action);
412
+ const toolInput = actionToolInput(action);
413
+ const columnId = stringValue(toolInput.columnId) ?? stringValue(actionIds(action).columnId);
414
+ const limit = boundedApprovalLimit(action);
415
+ if (!tableId || !limit) {
416
+ return {
417
+ status: "refused",
418
+ refusalReason: "approve_messages action is missing tableId or a bounded rowSelector.limit",
419
+ };
420
+ }
421
+ const api = getApi();
422
+ const result = await api.post("/api/v3/workflow-tables/cells/approve-batch", {
423
+ tableId,
424
+ ...(columnId ? { columnId } : {}),
425
+ limit,
426
+ scope: "generated_unapproved",
427
+ });
428
+ return { status: "executed_and_reread", result };
429
+ }
430
+ async function executeOneYoloPrimitive(action) {
431
+ if (!action)
432
+ return { status: "no_action" };
433
+ if (action.yoloEligible === false) {
434
+ return {
435
+ status: "refused",
436
+ refusalReason: "first global action is not yolo eligible",
437
+ };
438
+ }
439
+ switch (action.type) {
440
+ case "wait_for_scheduler":
441
+ case "wait_for_active_work":
442
+ case "wait_for_source_import":
443
+ return { status: "read_only_reread", result: { waited: true } };
444
+ case "prepare_messages": {
445
+ const campaignId = actionCampaignId(action);
446
+ const tableId = actionTableId(action) ?? undefined;
447
+ const toolInput = actionToolInput(action);
448
+ const targetPreparedMessages = numberValue(toolInput.targetPreparedMessages);
449
+ const approvalMode = toolInput.approvalMode === "approve" ? "approve" : "mark_ready";
450
+ if (!campaignId || !targetPreparedMessages || targetPreparedMessages <= 0) {
451
+ return {
452
+ status: "refused",
453
+ refusalReason: "prepare_messages action is missing campaignId or bounded targetPreparedMessages",
454
+ };
455
+ }
456
+ const result = await startPrepareCampaignMessages({
457
+ campaignId,
458
+ tableId,
459
+ targetPreparedMessages,
460
+ approvalMode,
461
+ autoContinue: true,
462
+ });
463
+ return { status: "executed_and_reread", result };
464
+ }
465
+ case "copy_selected_source_rows": {
466
+ const campaignOfferId = actionCampaignId(action);
467
+ const sourceLeadListId = actionSourceLeadListId(action);
468
+ const toolInput = actionToolInput(action);
469
+ const sourceRowIds = stringArray(toolInput.sourceRowIds);
470
+ const sourceRowLimit = numberValue(toolInput.sourceRowLimit);
471
+ const sourceFingerprint = stringValue(toolInput.sourceFingerprint) ??
472
+ stringValue(actionIds(action).sourceFingerprint);
473
+ if (!campaignOfferId || !sourceLeadListId || !sourceFingerprint) {
474
+ return {
475
+ status: "refused",
476
+ refusalReason: "copy_selected_source_rows action is missing campaignOfferId, sourceLeadListId, or sourceFingerprint",
477
+ };
478
+ }
479
+ if (sourceRowIds.length === 0 && (!sourceRowLimit || sourceRowLimit <= 0)) {
480
+ return {
481
+ status: "refused",
482
+ refusalReason: "copy_selected_source_rows action is missing exact sourceRowIds or a bounded sourceRowLimit",
483
+ };
484
+ }
485
+ const result = await confirmLeadList({
486
+ campaignOfferId,
487
+ sourceLeadListId,
488
+ currentStep: null,
489
+ confirmed: true,
490
+ sourceRowIds: sourceRowIds.length > 0 ? sourceRowIds : undefined,
491
+ sourceRowLimit: sourceRowIds.length > 0 ? undefined : sourceRowLimit ?? undefined,
492
+ reviewBatchLimit: sourceRowIds.length > 0 ? sourceRowIds.length : sourceRowLimit ?? undefined,
493
+ });
494
+ return { status: "executed_and_reread", result };
495
+ }
496
+ case "approve_messages":
497
+ return approveGeneratedMessagesBatch(action);
498
+ default:
499
+ return {
500
+ status: "refused",
501
+ refusalReason: `action ${String(action.type)} is not a safe yolo primitive`,
502
+ };
503
+ }
504
+ }
352
505
  export async function executeRefillSendsCommand(input = {}) {
353
506
  const command = refillSendsCommand(input);
354
507
  if (input.yolo !== true) {
@@ -361,6 +514,12 @@ export async function executeRefillSendsCommand(input = {}) {
361
514
  failedPaidInmailRefreshes: [],
362
515
  note: "Automatic paid InMail credit refresh only runs for --yolo refill_sends calls.",
363
516
  },
517
+ yoloExecution: {
518
+ enabled: false,
519
+ status: "not_run_without_yolo",
520
+ selectedAction: null,
521
+ targetPlanReread: false,
522
+ },
364
523
  };
365
524
  }
366
525
  const targetPlanInput = targetPlanInputFor(input);
@@ -391,10 +550,21 @@ export async function executeRefillSendsCommand(input = {}) {
391
550
  const targetPlan = refreshActions.length > 0
392
551
  ? await getRefillTargetPlan(targetPlanInput)
393
552
  : targetPlanBeforePaidRefresh;
553
+ const selectedAction = refreshActions.length > 0 ? null : firstGlobalAction(targetPlan);
554
+ const primitiveAttempt = refreshActions.length > 0
555
+ ? null
556
+ : await executeOneYoloPrimitive(selectedAction);
557
+ const shouldRereadAfterPrimitive = primitiveAttempt?.status === "executed_and_reread" ||
558
+ primitiveAttempt?.status === "read_only_reread";
559
+ const postActionTargetPlan = shouldRereadAfterPrimitive
560
+ ? await getRefillTargetPlan(targetPlanInput)
561
+ : null;
562
+ const finalTargetPlan = postActionTargetPlan ?? targetPlan;
394
563
  return {
395
564
  ...command,
396
- targetPlan,
565
+ targetPlan: finalTargetPlan,
397
566
  targetPlanBeforePaidRefresh: refreshActions.length > 0 ? targetPlanBeforePaidRefresh : null,
567
+ targetPlanBeforeYoloPrimitive: refreshActions.length === 0 && postActionTargetPlan ? targetPlan : null,
398
568
  autoPaidInmailRefresh: {
399
569
  enabled: true,
400
570
  status: refreshActions.length === 0
@@ -411,5 +581,23 @@ export async function executeRefillSendsCommand(input = {}) {
411
581
  ? "refill_sends refreshed stale paid InMail credit facts internally, once per sender, then returned the post-refresh targetPlan."
412
582
  : "No stale or missing paid InMail credit refresh candidates were present in the initial target plan.",
413
583
  },
584
+ yoloExecution: refreshActions.length > 0
585
+ ? {
586
+ enabled: true,
587
+ status: "skipped_after_paid_refresh",
588
+ selectedAction: null,
589
+ targetPlanReread: true,
590
+ }
591
+ : {
592
+ enabled: true,
593
+ status: primitiveAttempt?.status ?? "no_action",
594
+ selectedAction,
595
+ result: primitiveAttempt?.result,
596
+ targetPlanReread: shouldRereadAfterPrimitive,
597
+ refusalReason: primitiveAttempt?.refusalReason,
598
+ postActionFirstAction: postActionTargetPlan
599
+ ? firstGlobalAction(postActionTargetPlan)
600
+ : null,
601
+ },
414
602
  };
415
603
  }
@@ -9,6 +9,13 @@ const SAFE_PACKET_ACTION_TYPES = new Set([
9
9
  "approve_messages",
10
10
  "start_paused_campaign",
11
11
  "wait_for_scheduler",
12
+ "wait_for_active_work",
13
+ "wait_for_source_import",
14
+ "copy_selected_source_rows",
15
+ "continue_signal_discovery_source",
16
+ "continue_sales_nav_source",
17
+ "continue_prospeo_source",
18
+ "manual_source_replenishment",
12
19
  "refresh_paid_inmail_credits",
13
20
  "lower_paid_inmail_threshold",
14
21
  "switch_to_connection_lane",
@@ -18,6 +25,10 @@ const MANUAL_ONLY_PACKET_ACTION_TYPES = new Set([
18
25
  "lower_paid_inmail_threshold",
19
26
  "switch_to_connection_lane",
20
27
  "create_connection_campaign",
28
+ "continue_signal_discovery_source",
29
+ "continue_sales_nav_source",
30
+ "continue_prospeo_source",
31
+ "manual_source_replenishment",
21
32
  ]);
22
33
  const SOURCE_PLAN_STATES = new Set([
23
34
  "not_needed",
@@ -26,6 +37,8 @@ const SOURCE_PLAN_STATES = new Set([
26
37
  "needs_signal_import",
27
38
  "waiting_for_import",
28
39
  "needs_confirm",
40
+ "needs_same_source_copy",
41
+ "needs_provider_continuation",
29
42
  "source_shortfall",
30
43
  "provider_exhausted",
31
44
  "provider_missing",
@@ -152,6 +165,16 @@ function sanitizeActionCandidate(candidate) {
152
165
  tableId: stringValue(candidate.tableId),
153
166
  tableName: stringValue(candidate.tableName) ?? null,
154
167
  columnId: stringValue(candidate.columnId) ?? null,
168
+ sourceLeadListId: stringValue(candidate.sourceLeadListId) ?? null,
169
+ leadSourceProvider: stringValue(candidate.leadSourceProvider) ?? null,
170
+ sourceFingerprint: stringValue(candidate.sourceFingerprint) ?? null,
171
+ sourceInventoryStatus: stringValue(candidate.sourceInventoryStatus) ?? null,
172
+ sourceRowIds: stringArray(candidate.sourceRowIds),
173
+ sourceRowLimit: typeof candidate.sourceRowLimit === "number"
174
+ ? candidate.sourceRowLimit
175
+ : undefined,
176
+ activeJobId: stringValue(candidate.activeJobId) ?? null,
177
+ activeImportStatus: stringValue(candidate.activeImportStatus) ?? null,
155
178
  targetRows: typeof candidate.targetRows === "number" ? candidate.targetRows : undefined,
156
179
  columnRole: stringValue(candidate.columnRole),
157
180
  rowSelector: sanitizeRowSelector(candidate.rowSelector),
@@ -189,6 +212,21 @@ function sanitizeToolInput(value) {
189
212
  campaignId: stringValue(value.campaignId),
190
213
  tableId: stringValue(value.tableId),
191
214
  columnId: stringValue(value.columnId) ?? null,
215
+ sourceLeadListId: stringValue(value.sourceLeadListId) ?? null,
216
+ leadSourceProvider: stringValue(value.leadSourceProvider) ?? null,
217
+ sourceFingerprint: stringValue(value.sourceFingerprint) ?? null,
218
+ activeJobId: stringValue(value.activeJobId) ?? null,
219
+ activeImportStatus: stringValue(value.activeImportStatus) ?? null,
220
+ sourceInventoryStatus: stringValue(value.sourceInventoryStatus) ?? null,
221
+ sourceRowIds: stringArray(value.sourceRowIds),
222
+ sourceRowLimit: typeof value.sourceRowLimit === "number"
223
+ ? value.sourceRowLimit
224
+ : undefined,
225
+ campaignOfferId: stringValue(value.campaignOfferId),
226
+ provider: stringValue(value.provider),
227
+ allowDifferentSourceLeadList: typeof value.allowDifferentSourceLeadList === "boolean"
228
+ ? value.allowDifferentSourceLeadList
229
+ : undefined,
192
230
  targetPreparedMessages: typeof value.targetPreparedMessages === "number"
193
231
  ? value.targetPreparedMessages
194
232
  : undefined,
@@ -215,6 +253,10 @@ function sanitizePacketIds(value) {
215
253
  campaignId: stringValue(value.campaignId),
216
254
  tableId: stringValue(value.tableId),
217
255
  columnId: stringValue(value.columnId) ?? null,
256
+ sourceLeadListId: stringValue(value.sourceLeadListId) ?? null,
257
+ leadSourceProvider: stringValue(value.leadSourceProvider) ?? null,
258
+ sourceFingerprint: stringValue(value.sourceFingerprint) ?? null,
259
+ activeJobId: stringValue(value.activeJobId) ?? null,
218
260
  };
219
261
  }
220
262
  function sanitizeStructuredAction(action, selectedBySender, mode, rank) {
@@ -334,6 +376,9 @@ function sanitizeSourcePlan(value) {
334
376
  reason: stringValue(value.reason),
335
377
  campaignId: stringValue(value.campaignId),
336
378
  tableId: stringValue(value.tableId),
379
+ sourceLeadListId: stringValue(value.sourceLeadListId) ?? null,
380
+ leadSourceProvider: stringValue(value.leadSourceProvider) ?? null,
381
+ sourceFingerprint: stringValue(value.sourceFingerprint) ?? null,
337
382
  remainingRowsNeeded: typeof value.remainingRowsNeeded === "number"
338
383
  ? value.remainingRowsNeeded
339
384
  : undefined,
@@ -2952,6 +2952,8 @@ export declare const allTools: ({
2952
2952
  keepInSync?: undefined;
2953
2953
  jobId?: undefined;
2954
2954
  reviewBatchLimit?: undefined;
2955
+ sourceRowIds?: undefined;
2956
+ sourceRowLimit?: undefined;
2955
2957
  allowPartialSourceList?: undefined;
2956
2958
  includeRawImportResult?: undefined;
2957
2959
  selections?: undefined;
@@ -3146,6 +3148,8 @@ export declare const allTools: ({
3146
3148
  keepInSync?: undefined;
3147
3149
  jobId?: undefined;
3148
3150
  reviewBatchLimit?: undefined;
3151
+ sourceRowIds?: undefined;
3152
+ sourceRowLimit?: undefined;
3149
3153
  allowPartialSourceList?: undefined;
3150
3154
  includeRawImportResult?: undefined;
3151
3155
  selections?: undefined;
@@ -3239,6 +3243,8 @@ export declare const allTools: ({
3239
3243
  keepInSync?: undefined;
3240
3244
  jobId?: undefined;
3241
3245
  reviewBatchLimit?: undefined;
3246
+ sourceRowIds?: undefined;
3247
+ sourceRowLimit?: undefined;
3242
3248
  allowPartialSourceList?: undefined;
3243
3249
  includeRawImportResult?: undefined;
3244
3250
  selections?: undefined;
@@ -3404,6 +3410,8 @@ export declare const allTools: ({
3404
3410
  keepInSync?: undefined;
3405
3411
  jobId?: undefined;
3406
3412
  reviewBatchLimit?: undefined;
3413
+ sourceRowIds?: undefined;
3414
+ sourceRowLimit?: undefined;
3407
3415
  allowPartialSourceList?: undefined;
3408
3416
  includeRawImportResult?: undefined;
3409
3417
  selections?: undefined;
@@ -3511,6 +3519,8 @@ export declare const allTools: ({
3511
3519
  keepInSync?: undefined;
3512
3520
  jobId?: undefined;
3513
3521
  reviewBatchLimit?: undefined;
3522
+ sourceRowIds?: undefined;
3523
+ sourceRowLimit?: undefined;
3514
3524
  allowPartialSourceList?: undefined;
3515
3525
  includeRawImportResult?: undefined;
3516
3526
  selections?: undefined;
@@ -3627,6 +3637,8 @@ export declare const allTools: ({
3627
3637
  keepInSync?: undefined;
3628
3638
  jobId?: undefined;
3629
3639
  reviewBatchLimit?: undefined;
3640
+ sourceRowIds?: undefined;
3641
+ sourceRowLimit?: undefined;
3630
3642
  allowPartialSourceList?: undefined;
3631
3643
  includeRawImportResult?: undefined;
3632
3644
  selections?: undefined;
@@ -3732,6 +3744,8 @@ export declare const allTools: ({
3732
3744
  keepInSync?: undefined;
3733
3745
  jobId?: undefined;
3734
3746
  reviewBatchLimit?: undefined;
3747
+ sourceRowIds?: undefined;
3748
+ sourceRowLimit?: undefined;
3735
3749
  allowPartialSourceList?: undefined;
3736
3750
  includeRawImportResult?: undefined;
3737
3751
  selections?: undefined;
@@ -3842,6 +3856,8 @@ export declare const allTools: ({
3842
3856
  keepInSync?: undefined;
3843
3857
  jobId?: undefined;
3844
3858
  reviewBatchLimit?: undefined;
3859
+ sourceRowIds?: undefined;
3860
+ sourceRowLimit?: undefined;
3845
3861
  allowPartialSourceList?: undefined;
3846
3862
  includeRawImportResult?: undefined;
3847
3863
  selections?: undefined;
@@ -3940,6 +3956,8 @@ export declare const allTools: ({
3940
3956
  keepInSync?: undefined;
3941
3957
  jobId?: undefined;
3942
3958
  reviewBatchLimit?: undefined;
3959
+ sourceRowIds?: undefined;
3960
+ sourceRowLimit?: undefined;
3943
3961
  allowPartialSourceList?: undefined;
3944
3962
  includeRawImportResult?: undefined;
3945
3963
  selections?: undefined;
@@ -4830,6 +4848,8 @@ export declare const allTools: ({
4830
4848
  keepInSync?: undefined;
4831
4849
  jobId?: undefined;
4832
4850
  reviewBatchLimit?: undefined;
4851
+ sourceRowIds?: undefined;
4852
+ sourceRowLimit?: undefined;
4833
4853
  allowPartialSourceList?: undefined;
4834
4854
  includeRawImportResult?: undefined;
4835
4855
  selections?: undefined;
@@ -4937,6 +4957,8 @@ export declare const allTools: ({
4937
4957
  keepInSync?: undefined;
4938
4958
  jobId?: undefined;
4939
4959
  reviewBatchLimit?: undefined;
4960
+ sourceRowIds?: undefined;
4961
+ sourceRowLimit?: undefined;
4940
4962
  allowPartialSourceList?: undefined;
4941
4963
  includeRawImportResult?: undefined;
4942
4964
  selections?: undefined;
@@ -5982,6 +6004,8 @@ export declare const allTools: ({
5982
6004
  keepInSync?: undefined;
5983
6005
  jobId?: undefined;
5984
6006
  reviewBatchLimit?: undefined;
6007
+ sourceRowIds?: undefined;
6008
+ sourceRowLimit?: undefined;
5985
6009
  allowPartialSourceList?: undefined;
5986
6010
  includeRawImportResult?: undefined;
5987
6011
  selections?: undefined;
@@ -6136,6 +6160,8 @@ export declare const allTools: ({
6136
6160
  keepInSync?: undefined;
6137
6161
  jobId?: undefined;
6138
6162
  reviewBatchLimit?: undefined;
6163
+ sourceRowIds?: undefined;
6164
+ sourceRowLimit?: undefined;
6139
6165
  allowPartialSourceList?: undefined;
6140
6166
  includeRawImportResult?: undefined;
6141
6167
  selections?: undefined;
@@ -6277,6 +6303,8 @@ export declare const allTools: ({
6277
6303
  keepInSync?: undefined;
6278
6304
  jobId?: undefined;
6279
6305
  reviewBatchLimit?: undefined;
6306
+ sourceRowIds?: undefined;
6307
+ sourceRowLimit?: undefined;
6280
6308
  allowPartialSourceList?: undefined;
6281
6309
  includeRawImportResult?: undefined;
6282
6310
  selections?: undefined;
@@ -6373,6 +6401,8 @@ export declare const allTools: ({
6373
6401
  keepInSync?: undefined;
6374
6402
  jobId?: undefined;
6375
6403
  reviewBatchLimit?: undefined;
6404
+ sourceRowIds?: undefined;
6405
+ sourceRowLimit?: undefined;
6376
6406
  allowPartialSourceList?: undefined;
6377
6407
  includeRawImportResult?: undefined;
6378
6408
  selections?: undefined;
@@ -6419,6 +6449,17 @@ export declare const allTools: ({
6419
6449
  type: string;
6420
6450
  description: string;
6421
6451
  };
6452
+ sourceRowIds: {
6453
+ type: string;
6454
+ items: {
6455
+ type: string;
6456
+ };
6457
+ description: string;
6458
+ };
6459
+ sourceRowLimit: {
6460
+ type: string;
6461
+ description: string;
6462
+ };
6422
6463
  allowPartialSourceList: {
6423
6464
  type: string;
6424
6465
  description: string;
@@ -6628,6 +6669,8 @@ export declare const allTools: ({
6628
6669
  keepInSync?: undefined;
6629
6670
  jobId?: undefined;
6630
6671
  reviewBatchLimit?: undefined;
6672
+ sourceRowIds?: undefined;
6673
+ sourceRowLimit?: undefined;
6631
6674
  allowPartialSourceList?: undefined;
6632
6675
  includeRawImportResult?: undefined;
6633
6676
  };
@@ -6725,6 +6768,8 @@ export declare const allTools: ({
6725
6768
  keepInSync?: undefined;
6726
6769
  jobId?: undefined;
6727
6770
  reviewBatchLimit?: undefined;
6771
+ sourceRowIds?: undefined;
6772
+ sourceRowLimit?: undefined;
6728
6773
  allowPartialSourceList?: undefined;
6729
6774
  includeRawImportResult?: undefined;
6730
6775
  selections?: undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sellable/mcp",
3
- "version": "0.1.476",
3
+ "version": "0.1.478",
4
4
  "type": "module",
5
5
  "description": "Sellable MCP server for Claude Code and Codex campaign workflows",
6
6
  "main": "dist/index.js",
@@ -89,10 +89,16 @@ When the host can call typed MCP tools, start with:
89
89
  refill_sends({ yolo?: boolean, senders?: string[], senderIds?: string[], senderNames?: string[], horizonSendDays?: number, untilDate?: "YYYY-MM-DD", targetDate?: "YYYY-MM-DD" })
90
90
  ```
91
91
 
92
- That command helper only normalizes arguments and returns the execution
93
- contract. It does not mutate. Continue with the workflow below for route
94
- selection, state rereads, approval gating, source import, preparation, and
95
- bounded approval.
92
+ That command helper normalizes arguments and returns the execution contract. In
93
+ non-yolo mode it does not mutate. In `--yolo`, it may execute exactly one safe
94
+ bounded primitive from the fresh `target.globalActionQueue[0]`, then reread and
95
+ return the new target plan; currently safe primitives are paid-credit refresh,
96
+ existing-row message preparation, same-source row copy, and read-only wait
97
+ rereads. It does not run unbounded approval, lower
98
+ paid-InMail thresholds, switch source families, create campaigns, launch, send,
99
+ or write scheduler rows. Continue with the workflow below for route selection,
100
+ state rereads, approval gating, source import, preparation, and bounded
101
+ approval.
96
102
 
97
103
  First call `get_auth_status({})`. If auth or active workspace is not OK, follow
98
104
  the returned login/workspace guidance before route resolution. Do not run refill
@@ -164,12 +170,20 @@ Structured planner packet:
164
170
  - `manualAlternates` are not yolo actions. Threshold lowering and campaign
165
171
  creation are manual continuations only.
166
172
 
173
+ Refill action ladder: approve generated rows only when an explicit bounded
174
+ approval gate exists, process all existing same-campaign unenriched/unprepared
175
+ rows in bounded batches before any source work, then copy bounded net-new rows
176
+ from the selected source (`selectedLeadListId`, provider, and source
177
+ fingerprint preserved), then use provider-aligned source-more. A new source or
178
+ provider switch changes the reply-rate baseline and is a manual alternate, not a
179
+ `--yolo` side effect.
180
+
167
181
  Run-local paid-credit guard: in `--yolo`, the `refill_sends` MCP command
168
182
  automatically maintains a `refreshedPaidInmailSenderIds` set for the current
169
183
  command call. If its first target plan has stale/missing paid-InMail credit
170
184
  facts, it refreshes each selected sender at most once, reruns
171
185
  `get_refill_target_plan`, and returns the post-refresh `targetPlan` before
172
- choosing the next prep/approval/start action. If fresh facts are still below
186
+ choosing the next prep/source-copy/bounded-approval/read-only wait action. If fresh facts are still below
173
187
  threshold, below-threshold paid-InMail facts fall back to an existing connection
174
188
  lane, the same Sales Nav cascade campaign's connection branch, or a manual
175
189
  continuation.
@@ -258,7 +272,7 @@ they change `stateRevision`, not `targetShapeRevision`, and do not require a
258
272
  second approval.
259
273
 
260
274
  In `--yolo`, continue as far as the rendered packet safely allows. After each
261
- apply/prep/start result, reread state, settle processing when needed, and move to
275
+ apply/prep/source-copy/bounded-approval/read-only wait result, reread state, settle processing when needed, and move to
262
276
  the next selected sender or start-eligible same-packet campaign instead of
263
277
  stopping after the first partial result. If no in-packet safe action remains,
264
278
  return concrete continuation options with campaign names, exact ids, which option
@@ -272,7 +286,7 @@ selected sender: selected send days, gross capacity, actual sent cells, future
272
286
  scheduler-owned scheduled cells with non-null `scheduledFor`, projected count,
273
287
  ready-to-schedule buffer, remaining projected gap, paid-InMail feasibility,
274
288
  `targetShapeRevision`, `stateRevision`, and the next MCP primitive that can
275
- reduce the gap. After every apply/prep/start result, wait for processing, reread
289
+ reduce the gap. After every apply/prep/source-copy/bounded-approval/read-only wait result, wait for processing, reread
276
290
  the target plan/refill state, recompute the ledger, then keep applying safe
277
291
  bounded actions until projected coverage fills the target window or a concrete
278
292
  non-scheduler blocker is proven.
@@ -108,12 +108,19 @@ in-progress wait state, not a reason to mark the goal complete or blocked.
108
108
  - `nextActions[0]` is the current sender's smallest safe primitive.
109
109
  - `manualAlternates` are not yolo actions. Threshold lowering and campaign
110
110
  creation are manual continuations only.
111
+ Refill action ladder: approve generated rows only when an explicit bounded
112
+ approval gate exists, process all existing same-campaign
113
+ unenriched/unprepared rows in bounded batches before any source work, then
114
+ copy bounded net-new rows from the selected source (`selectedLeadListId`,
115
+ provider, and source fingerprint preserved), then use provider-aligned
116
+ source-more. A new source or provider switch changes the reply-rate baseline
117
+ and is a manual alternate, not a `--yolo` side effect.
111
118
  Run-local paid-credit guard: in `--yolo`, the `refill_sends` MCP command
112
119
  automatically maintains a `refreshedPaidInmailSenderIds` set for the current
113
120
  command call. If its first target plan has stale/missing paid-InMail credit
114
121
  facts, it refreshes each selected sender at most once, reruns
115
122
  `get_refill_target_plan`, and returns the post-refresh `targetPlan` before
116
- choosing the next prep/approval/start action. If fresh facts are still below
123
+ choosing the next prep/source-copy/bounded-approval/read-only wait action. If fresh facts are still below
117
124
  threshold, below-threshold paid-InMail facts fall back to an existing
118
125
  connection lane, the same Sales Nav cascade campaign's connection branch, or
119
126
  a manual continuation.
@@ -552,7 +559,7 @@ same refill request, do not ask the `Accept` / `Decline` question. Instead:
552
559
  caps/dates, approval mode, blockers, and side-effect class still match the
553
560
  packet;
554
561
  4. execute only the exact packet;
555
- 5. after each terminal credit-refresh/apply/prep/start result, rerun
562
+ 5. after each terminal credit-refresh/apply/prep/source-copy/bounded-approval/read-only wait result, rerun
556
563
  `get_refill_target_plan`, reread state, settle processing when needed,
557
564
  recompute the target-window saturation ledger, and continue with the next smallest
558
565
  safe action inside the same bounded packet until every selected sender is