@sellable/mcp 0.1.443 → 0.1.444
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.
|
@@ -6,7 +6,7 @@ async function postSetupEvergreenCampaigns(body) {
|
|
|
6
6
|
export const setupEvergreenCampaignsToolDefinitions = [
|
|
7
7
|
{
|
|
8
8
|
name: "setup_evergreen_campaigns",
|
|
9
|
-
description: "Evergreen campaign setup plan/verify command. Use plan mode first to inspect exact workspace/sender/campaign/table/source state and receive immutable lane packets. `selectedSenderIds` is a legacy shorthand for both scopes; prefer `postEngagerSenderIds` for the Post Engagers sender scope and `sharedSenderIds` for the shared lane sender scope when they differ. If a protected existing Post Engagers campaign must stay unchanged and the operator requested only shared lane execution, pass postEngagerSenderIds:[] and sharedSenderIds; do not include the protected active Post Engagers lane as a reuse packet because it can make the yolo plan non-autoExecutable. The command plans one Post Engagers lane per post-engager sender plus shared Signal Discovery and Shared Cold Fallback lanes for the shared sender set. yolo is only a parent-skill auto-execution hint for safe lane packets; pass yolo only in plan mode and never include yolo on mode:\"verify\" calls. This backend command remains read-only in plan mode and verifies receipts in verify mode. Package-backed prompt authority: the installed public wrapper can be the local Codex skill entrypoint, but lane workers must use get_subskill_prompt and get_subskill_asset for nested `$sellable:create-campaign`, create-campaign-v2, generate-messages, validation, and assets; nested filesystem prompt fallback is a failed UAT. Use mcp__sellable only for workspace selection and product mutations/readbacks. Do not use mcp__sellable_admin, direct DB, Prisma, SQL, built-in web search, browser search, web.run, or any external browsing/search tool as execution or research proof; if Sellable MCP research tools are insufficient, write a blocked receipt instead of browsing externally. Worker-local replans are read-only drift checks and must preserve the exact parent sender scopes, including postEngagerSenderIds:[] when intentionally empty and the exact sharedSenderIds array; if scope, planRevision, actionId, or laneKey drifts, stop with blocked:worker_plan_scope_drift before mutation. Each lane packet includes workerDispatch with acceptedRuntimes, rejectedRuntimes, requiresVisibleThreadOrDurableReceipt, receiptArtifactHint, receiptRunId, and receiptMustBeWrittenAfter; pre-existing receipts at old deterministic paths are stale and must not be used, so stop with blocked:stale_receipt_artifact if the receipt was not freshly written for the current receiptRunId. `multi_agent_v1.spawn_agent`/opaque spawn_agent is not accepted for mutating command proof unless the parent has visible thread or durable receipt proof. In local Codex, prefer `codex_app.list_projects` then `codex_app.create_thread` with a local project target; do not create a worktree for lane execution. If Codex app thread tools are unavailable but local Codex CLI is available, use durable streaming workers with `codex -a never -s danger-full-access exec -C <repo> -o <worker-final-file> -`; approval and
|
|
9
|
+
description: "Evergreen campaign setup plan/verify command. Use plan mode first to inspect exact workspace/sender/campaign/table/source state and receive immutable lane packets. `selectedSenderIds` is a legacy shorthand for both scopes; prefer `postEngagerSenderIds` for the Post Engagers sender scope and `sharedSenderIds` for the shared lane sender scope when they differ. If a protected existing Post Engagers campaign must stay unchanged and the operator requested only shared lane execution, pass postEngagerSenderIds:[] and sharedSenderIds; do not include the protected active Post Engagers lane as a reuse packet because it can make the yolo plan non-autoExecutable. The command plans one Post Engagers lane per post-engager sender plus shared Signal Discovery and Shared Cold Fallback lanes for the shared sender set. yolo is only a parent-skill auto-execution hint for safe lane packets; pass yolo only in plan mode and never include yolo on mode:\"verify\" calls. This backend command remains read-only in plan mode and verifies receipts in verify mode. Package-backed prompt authority: the installed public wrapper can be the local Codex skill entrypoint, but lane workers must use get_subskill_prompt and get_subskill_asset for nested `$sellable:create-campaign`, create-campaign-v2, generate-messages, validation, and assets; nested filesystem prompt fallback is a failed UAT. Use mcp__sellable only for workspace selection and product mutations/readbacks. Do not use mcp__sellable_admin, direct DB, Prisma, SQL, built-in web search, browser search, web.run, or any external browsing/search tool as execution or research proof; if Sellable MCP research tools are insufficient, write a blocked receipt instead of browsing externally. Worker-local replans are read-only drift checks and must preserve the exact parent sender scopes, including postEngagerSenderIds:[] when intentionally empty and the exact sharedSenderIds array; if scope, planRevision, actionId, or laneKey drifts, stop with blocked:worker_plan_scope_drift before mutation. Each lane packet includes workerDispatch with acceptedRuntimes, rejectedRuntimes, requiresVisibleThreadOrDurableReceipt, receiptArtifactHint, receiptRunId, and receiptMustBeWrittenAfter; pre-existing receipts at old deterministic paths are stale and must not be used, so stop with blocked:stale_receipt_artifact if the receipt was not freshly written for the current receiptRunId. `multi_agent_v1.spawn_agent`/opaque spawn_agent is not accepted for mutating command proof unless the parent has visible thread or durable receipt proof. In local Codex, prefer `codex_app.list_projects` then `codex_app.create_thread` with a local project target; do not create a worktree for lane execution. If Codex app thread tools are unavailable but local Codex CLI is available, use durable streaming workers with `codex -a never -s danger-full-access -c model_reasoning_effort=xhigh exec --skip-git-repo-check -m <worker-model> -C <repo> -o <worker-final-file> -`; approval, sandbox, and reasoning-effort config flags must appear before `exec`, and current customer CLI installs reject `codex exec --ask-for-approval never` and `codex exec -a never`. Do not rely on default model or default reasoning effort: copy the parent model such as `gpt-5.5` into `-m` and always pass `-c model_reasoning_effort=xhigh`; a child worker that reports GPT 5.5 with high reasoning is a launcher bug to relaunch before mutation, not a user-continue path. Plan responses include approvalSummary; render approvalSummary when asking for bounded delegated approval because it explicitly lists campaignsToCreate, campaignsToUpdate, campaignsToVerifyOnly, campaignsLeftUntouched, attachedSenders, selectedActionIds, allowedSideEffects, forbiddenSideEffects, blockers, and approvalQuestion. When safe-yolo needs normal setup work, the parent skill may ask for bounded delegated approval: one approval over the current planRevision, selected action ids, caps, allowed side-effect classes, and stop conditions lets lane workers execute without per-substep approval while staying inside that packet. In exec/automation mode, do not call request_user_input; if yolo plan autoExecutable:false and no interactive approval can be received, stop with blocked:bounded_approval_unavailable_in_exec_mode before any mutation. Lane workers must explicitly load and use the installed `$sellable:create-campaign` wrapper as the nested workflow entrypoint, then load `create-campaign-v2` and `create-campaign-v2/core/flow.v2.json`; they must execute creation, source import, create-campaign workflow steps, generate-messages, sequence attachment, pause_campaign review-state transition when the current table is still DRAFT, and review readiness through that existing create-campaign workflow/subskills, then return receipts here for verification. Customer-visible verify receipts must set status:'succeeded' or status:'completed'; status:'passed', status:'pass', and status:'passed_with_warnings' are rejected as primary success statuses. Exception: a Post Engagers lane may write status:'blocked' with blocker:'post_engagers_no_sender_posts', 'post_engagers_no_recent_sender_posts', 'post_engagers_no_sender_owned_posts', or 'post_engagers_source_author_mismatch' when Sellable MCP readback proves no usable sender-authored posts/source exists; verify returns these as acceptedLaneBlockers so the parent can report the no-op instead of retrying invalid source repair. Any other blocked receipt, including model-quality/preflight or worker model availability blockers, is not a goal-complete success condition and must not let the parent report evergreen completion. Receipts must include createCampaignStepReceipt with setupPlanCall, createCampaignWorkflowReceipt, campaignBriefReceipt, sourceDecisionReceipt, filterDecisionReceipt, messageDraftingReceipt, reviewBatchReceipt, sequenceReceipt, and verifyCall nested inside createCampaignStepReceipt; top-level-only copies of those objects are not enough and are not promoted by verify. setupPlanCall must use canonical keys: planRevision, actionId, laneKey, workspaceId, senderIds, campaignId, tableId, createIntent. Do not use laneActionId, lanePacketActionId, delegatedPlanRevision, delegatedActionId, or requestedCall text as a substitute for those canonical fields. createCampaignWorkflowReceipt must include skillCommand:'$sellable:create-campaign', skillName:'create-campaign', wrapperSkillLoaded:true, workflowPromptName:'create-campaign-v2', workflowPromptLoadedToHasMoreFalse:true, workflowAssetPath:'create-campaign-v2/core/flow.v2.json', workflowAssetLoaded:true, workerRuntime, workerThreadId or receiptArtifactPath, durableReceiptWritten when using a receipt file, and notAdHoc:true. messageDraftingReceipt must use exactly statusSource:'branch' or statusSource:'packaged-generate-messages-worker'; descriptive aliases such as statusSource:'package-readback-local-thread' are rejected. It must include proof that generate-messages was loaded, start_campaign_message_preparation/get_campaign_message_preparation_status ran when the packaged worker path is used, validationResult:'passed', a passed qualityReview, and at least 3 concrete sampleMessages with rowId, generatedMessageText, verdict, and issues; Do not substitute `message` for `generatedMessageText`; Do not substitute `passVerdict` for `verdict`. Before writing durable receipts, run a receipt self-check: top-level `planRevision`, `actionId`, `laneKey`, `laneType`, `workspaceId`, and `senderIds` must exist; if the self-check fails, fix the receipt before ending. Use start_campaign_message_preparation with approvalMode:\"mark_ready\" only for evergreen setup. Never call `start_campaign_message_preparation` with `approvalMode:\"approve\"`; approve exactly one semantic Approved cell through select_campaign_cells/update_cell and final proof must show approvedGeneratedMessageCount exactly 1. Shared Cold Fallback samples with a standalone name followed by 'Hey there' are rejected. This command does not launch campaigns, does not schedule sends, does not assign scheduler-owned send fields, does not raw-write campaign status, does not archive/delete cleanup targets, and does not spend paid credits.",
|
|
10
10
|
inputSchema: {
|
|
11
11
|
type: "object",
|
|
12
12
|
properties: {
|
package/package.json
CHANGED
|
@@ -409,30 +409,37 @@ acceptable only when it writes a fresh durable per-lane receipt artifact as it
|
|
|
409
409
|
works.
|
|
410
410
|
When visible Codex app thread tools are unavailable but local Codex CLI is
|
|
411
411
|
available, the accepted durable streaming-worker command shape is:
|
|
412
|
-
`codex -a never -s danger-full-access exec --skip-git-repo-check -m <worker-model> -C <repo> -o <worker-final-file> -`.
|
|
413
|
-
The approval and
|
|
414
|
-
CLI builds that expose `-a`/`-s` only at top
|
|
412
|
+
`codex -a never -s danger-full-access -c model_reasoning_effort=xhigh exec --skip-git-repo-check -m <worker-model> -C <repo> -o <worker-final-file> -`.
|
|
413
|
+
The approval, sandbox, and reasoning-effort config flags must come before the
|
|
414
|
+
`exec` subcommand for Codex CLI builds that expose `-a`/`-s`/`-c` only at top
|
|
415
|
+
level. `--skip-git-repo-check` belongs after `exec` because current customer and VPS Codex CLI builds expose it
|
|
415
416
|
as an `exec` subcommand flag, not a top-level flag. Do not use
|
|
416
417
|
`codex exec --ask-for-approval never ...` or `codex exec -a never ...`; those
|
|
417
418
|
forms fail on current customer CLI installs. Pipe the lane packet prompt on
|
|
418
419
|
stdin, require the worker to write `workerDispatch.receiptArtifactHint`, and
|
|
419
420
|
pass exactly one lane packet per worker.
|
|
420
421
|
When launching durable Codex CLI workers from an automation parent, pass an
|
|
421
|
-
explicit supported worker model
|
|
422
|
-
|
|
423
|
-
|
|
422
|
+
explicit supported worker model and explicit `xhigh` reasoning effort instead
|
|
423
|
+
of relying on the Codex CLI defaults. Use the parent runtime model when known,
|
|
424
|
+
for example:
|
|
425
|
+
`codex -a never -s danger-full-access -c model_reasoning_effort=xhigh exec --skip-git-repo-check -m <worker-model> -C <repo> -o <worker-final-file> -`.
|
|
424
426
|
In Codex CLI, the parent runtime model is visible in the run header as
|
|
425
427
|
`model: <model-name>`. Copy that exact model string into child worker launches
|
|
426
428
|
first. If the parent header says `model: gpt-5.5`, launch workers with
|
|
427
|
-
`-m gpt-5.5`; do not invent or probe
|
|
428
|
-
`gpt-5.
|
|
429
|
-
the exact parent model. A
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
429
|
+
`-m gpt-5.5` plus `-c model_reasoning_effort=xhigh`; do not invent or probe
|
|
430
|
+
nearby aliases such as `gpt-5.3-codex`, `gpt-5.2`, `gpt-5-codex`,
|
|
431
|
+
`codex-latest`, or `codex-mini-latest` before trying the exact parent model. A
|
|
432
|
+
one-line probe must include the same `-c model_reasoning_effort=xhigh` override
|
|
433
|
+
and count as supported only when it exits 0 and returns the requested output; a
|
|
434
|
+
session header followed by a `not supported` error is rejected, not accepted.
|
|
435
|
+
Do not rely on the Codex CLI default model or default reasoning effort; some
|
|
436
|
+
customer and VPS installs default to unavailable model aliases or to `high`
|
|
437
|
+
reasoning. `-m gpt-5.5` alone is not enough. If a child worker reports GPT 5.5
|
|
438
|
+
with `high` reasoning, treat that as a launcher bug, relaunch with the explicit
|
|
439
|
+
`xhigh` config before mutation, and do not ask the user to continue through the
|
|
440
|
+
model-quality warning. If the parent cannot identify a supported worker model
|
|
441
|
+
and launch it with `xhigh` reasoning, stop with
|
|
442
|
+
`blocked: worker_model_unavailable` before mutation.
|
|
436
443
|
When wrapping multiple local Codex CLI workers in a shell launcher, run the
|
|
437
444
|
wrapper with `/bin/bash -lc` or another explicitly chosen portable shell. Do not
|
|
438
445
|
rely on zsh-specific behavior. Do not use `status` as a shell variable because
|
|
@@ -444,7 +451,7 @@ Do not embed `<<'WORKER_PROMPT'` heredocs inside a single quoted or double
|
|
|
444
451
|
quoted `/bin/bash -lc '...'` command string; nested quoting is brittle and can
|
|
445
452
|
truncate the first worker before mutation. For multi-worker launchers, write one
|
|
446
453
|
plain prompt file per lane under the current run directory, then start each
|
|
447
|
-
worker with `codex -a never -s danger-full-access exec --skip-git-repo-check -m "$WORKER_MODEL" -C "$REPO" -o
|
|
454
|
+
worker with `codex -a never -s danger-full-access -c model_reasoning_effort=xhigh exec --skip-git-repo-check -m "$WORKER_MODEL" -C "$REPO" -o
|
|
448
455
|
"$worker_final_file" - < "$worker_prompt_file"`. Keep launcher shell variables
|
|
449
456
|
double-quoted and keep the prompt heredoc only in a standalone script/prompt-file
|
|
450
457
|
write step, not inside an already quoted shell argument. If the first launcher
|
|
@@ -550,7 +557,7 @@ launchers, write the same prompt body to `<worker-prompt-file>` and launch the
|
|
|
550
557
|
worker with stdin redirected from that file:
|
|
551
558
|
|
|
552
559
|
```
|
|
553
|
-
codex -a never -s danger-full-access exec --skip-git-repo-check -m <worker-model> -C <repo> -o <worker-final-file> - <<'WORKER_PROMPT'
|
|
560
|
+
codex -a never -s danger-full-access -c model_reasoning_effort=xhigh exec --skip-git-repo-check -m <worker-model> -C <repo> -o <worker-final-file> - <<'WORKER_PROMPT'
|
|
554
561
|
Use $sellable:create-campaign as the governing campaign workflow for this one lane worker.
|
|
555
562
|
Use the evergreen plan/packet below only for lane scope, source metadata,
|
|
556
563
|
postconditions, side-effect caps, and durable receipt proof.
|
|
@@ -567,7 +574,8 @@ Write the durable receipt to this exact path: <receiptArtifactPath>
|
|
|
567
574
|
|
|
568
575
|
If your runtime exposes a goal tool, create or maintain this exact goal:
|
|
569
576
|
complete action <actionId> only when <receiptArtifactPath> exists as valid JSON
|
|
570
|
-
for this lane or
|
|
577
|
+
for this lane, or only for the accepted Post Engagers no-source blockers listed
|
|
578
|
+
below when a blocked receipt has been written at that same path.
|
|
571
579
|
|
|
572
580
|
Create-campaign goal prompt (authoritative; paste verbatim from the matching
|
|
573
581
|
createCampaignGoals[].goalPrompt):
|
|
@@ -595,6 +603,11 @@ Use mcp__sellable only. Do not use admin tools, direct DB, Prisma, SQL, web sear
|
|
|
595
603
|
Do not launch, start, schedule, send, or use paid InMail.
|
|
596
604
|
For filter proof, durable receipt status must be `filterDecisionReceipt.status:"applied"` only; never `completed`, `confirmed`, `done`, or aliases.
|
|
597
605
|
For generated messages, `update_cell` is allowed only for the semantic Approved checkbox. Never use `update_cell` for generated message text/body/sample copy. Bad copy requires `revise_message_template_and_rerun` or brief/template revision plus Generate Message rerun. Any generated-message cell override is `blocked: generated_message_cell_override`.
|
|
606
|
+
If `bootstrap_create_campaign.modelQuality.status === "warn"` because the child
|
|
607
|
+
worker reports GPT 5.5 with `high` reasoning, that is a parent launcher
|
|
608
|
+
configuration bug, not an operator approval path inside the worker. Stop before
|
|
609
|
+
mutation, tell the parent to relaunch this lane with
|
|
610
|
+
`-c model_reasoning_effort=xhigh`, and do not mark the worker goal complete.
|
|
598
611
|
Complete only this lane. Do not end with narration only. Before your final
|
|
599
612
|
response, run a local file-existence and JSON self-check for
|
|
600
613
|
<receiptArtifactPath>. If the lane succeeded, write the canonical success
|
|
@@ -608,12 +621,14 @@ receipt, not a worker crash: use one of
|
|
|
608
621
|
`post_engagers_no_sender_owned_posts`, or
|
|
609
622
|
`post_engagers_source_author_mismatch`, include the source/readback evidence,
|
|
610
623
|
and stop without scraping third-party authors or generating misleading warm
|
|
611
|
-
copy.
|
|
612
|
-
|
|
624
|
+
copy. Any other blocked receipt is not a goal-complete success condition; it is
|
|
625
|
+
a failed lane return that the parent must report or repair. The terminal success
|
|
626
|
+
condition is filesystem proof that <receiptArtifactPath> exists with a success
|
|
627
|
+
receipt, or an accepted Post Engagers no-source blocked/no-op receipt.
|
|
613
628
|
WORKER_PROMPT
|
|
614
629
|
|
|
615
630
|
# Multi-worker launcher equivalent:
|
|
616
|
-
codex -a never -s danger-full-access exec --skip-git-repo-check -m <worker-model> -C <repo> -o <worker-final-file> - < <worker-prompt-file>
|
|
631
|
+
codex -a never -s danger-full-access -c model_reasoning_effort=xhigh exec --skip-git-repo-check -m <worker-model> -C <repo> -o <worker-final-file> - < <worker-prompt-file>
|
|
617
632
|
```
|
|
618
633
|
|
|
619
634
|
If any placeholder cannot be filled from the current plan, matching
|
|
@@ -863,7 +878,11 @@ by someone else. Use the explicit blocker codes
|
|
|
863
878
|
`acceptedLaneBlockers`, so the parent can report the truthful no-op instead of
|
|
864
879
|
retrying invalid source repair. This exception does not apply to shared lanes,
|
|
865
880
|
bad generated copy, stale plans, target mismatch, missing receipt files, launch
|
|
866
|
-
or schedule side effects,
|
|
881
|
+
or schedule side effects, model-quality/preflight blockers, worker model
|
|
882
|
+
availability blockers, or arbitrary worker failures. A blocked receipt outside
|
|
883
|
+
the accepted Post Engagers source codes must not be treated as completion, must
|
|
884
|
+
not be used to mark the worker goal complete, and must not let the parent report
|
|
885
|
+
the evergreen command as complete.
|
|
867
886
|
|
|
868
887
|
All step proof objects must live under `createCampaignStepReceipt`. Do not put
|
|
869
888
|
`createCampaignWorkflowReceipt`, `campaignBriefReceipt`,
|